diff --git a/UniSwapSetUp.js b/UniSwapSetUp.js new file mode 100644 index 0000000..4e2fa0d --- /dev/null +++ b/UniSwapSetUp.js @@ -0,0 +1,155 @@ +const Web3 = require("web3"); +const fs = require('fs'); +const ERC20Token = JSON.parse(fs.readFileSync("./client/src/contracts/ERC20Token.json")); +const UniSwapFactory = JSON.parse(fs.readFileSync("./client/src/contracts/uniswap_factory_custom.json")); +const UniSwapExchange = JSON.parse(fs.readFileSync("./client/src/contracts/uniswap_exchange_custom.json")); +const BigNumber = require('bignumber.js'); +const Util = require("./client/src/utils/utils"); +const {table} = require('table'); +require('dotenv').config(); + +BigNumber.set({ DECIMAL_PLACES: 18}); + +const SOURCE_ACCOUNT = '0xeE398666cA860DFb7390b5D73EE927e9Fb41a60A'; +const DAI_ADDRESS = '0xFf795577d9AC8bD7D90Ee22b6C1703490b6512FD'; + +const web3 = new Web3(new Web3.providers.HttpProvider(process.env.INFURAKOVAN)); + +let DaiTokenInstance; + + +exports.setUp = async function(){ + // Used to initially deploy to UniSwap Exchanges and add some initial Pool liquidity. + var id = await web3.eth.net.getId(); + + // Load contract instances + DaiTokenInstance = new web3.eth.Contract(ERC20Token.abi, DAI_ADDRESS); + const UniSwapFactoryInstance = new web3.eth.Contract(UniSwapFactory.abi, UniSwapFactory.networks[id].address); + const UniSwapExchangeInstance = new web3.eth.Contract(UniSwapExchange.abi, UniSwapExchange.networks[id].address); + //console.log(UniSwapExchange.networks[id].address) + /* + // initializeFactory + console.log('Initialising Factory...'); + var tx = await UniSwapFactoryInstance.methods.initializeFactory(UniSwapExchange.networks[id].address); + await Util.sendTransaction(web3, tx, SOURCE_ACCOUNT, process.env.PRIVATEKEY, UniSwapFactory.networks[id].address); + + console.log('Creating 1st DAI Exchange...'); + tx = await UniSwapFactoryInstance.methods.createExchange(DAI_ADDRESS); + await Util.sendTransaction(web3, tx, SOURCE_ACCOUNT, process.env.PRIVATEKEY, UniSwapFactory.networks[id].address); + + console.log('Creating 2nd DAI Exchange...'); + tx = await UniSwapFactoryInstance.methods.createExchange(DAI_ADDRESS); + await Util.sendTransaction(web3, tx, SOURCE_ACCOUNT, process.env.PRIVATEKEY, UniSwapFactory.networks[id].address); + + */ + const leaderExchangeAddr = await UniSwapFactoryInstance.methods.getExchange(0).call(); // Custom UniSwap uses IDs for exchanges to allow two of same token + const followerExchangeAddr = await UniSwapFactoryInstance.methods.getExchange(1).call(); + /* + console.log('Approving...') + var approveQtyWei = web3.utils.toWei('100', 'ether'); + tx = await DaiTokenInstance.methods.approve(leaderExchangeAddr, approveQtyWei); + await Util.sendTransaction(web3, tx, SOURCE_ACCOUNT, process.env.PRIVATEKEY, DAI_ADDRESS); + tx = await DaiTokenInstance.methods.approve(followerExchangeAddr, approveQtyWei); + await Util.sendTransaction(web3, tx, SOURCE_ACCOUNT, process.env.PRIVATEKEY, DAI_ADDRESS); + + + const leaderExContract = new web3.eth.Contract(UniSwapExchange.abi, leaderExchangeAddr); + const followerExContract = new web3.eth.Contract(UniSwapExchange.abi, followerExchangeAddr); + + const MIN_LIQUIDITY = 0; + const ETH_ADDED = web3.utils.toWei('0.01', 'ether'); + const TOKEN_ADDED = web3.utils.toWei('5', 'ether'); + let block = await web3.eth.getBlock("latest"); + const DEADLINE = block.timestamp + 300; + console.log('Adding liquidity..') + tx = await leaderExContract.methods.addLiquidity(MIN_LIQUIDITY, TOKEN_ADDED, DEADLINE); + await Util.sendTransactionWithValue(web3, tx, SOURCE_ACCOUNT, process.env.PRIVATEKEY, leaderExchangeAddr, ETH_ADDED); + + tx = await followerExContract.methods.addLiquidity(MIN_LIQUIDITY, TOKEN_ADDED, DEADLINE); + await Util.sendTransactionWithValue(web3, tx, SOURCE_ACCOUNT, process.env.PRIVATEKEY, followerExchangeAddr, ETH_ADDED); + */ + await PoolInfo(leaderExchangeAddr); + await PoolInfo(followerExchangeAddr); +} + +async function displayPrice(web3){ + var id = await web3.eth.net.getId(); + const UniSwapFactoryInstance = new web3.eth.Contract(UniSwapFactory.abi, UniSwapFactory.networks[id].address); + const DaiTokenInstance = new web3.eth.Contract(LeaderToken.abi, LeaderToken.networks[id].address); + const FollowerTokenInstance = new web3.eth.Contract(FollowerToken.abi, FollowerToken.networks[id].address); + const leaderExchangeAddr = await UniSwapFactoryInstance.methods.getExchange(LeaderToken.networks[id].address).call(); + const followerExchangeAddr = await UniSwapFactoryInstance.methods.getExchange(FollowerToken.networks[id].address).call(); + + var leaderExEthBalanceWei = await web3.eth.getBalance(leaderExchangeAddr); + var leaderExTokenBalanceWei = await DaiTokenInstance.methods.balanceOf(leaderExchangeAddr).call(); + var followerExEthBalanceWei = await web3.eth.getBalance(followerExchangeAddr); + var followerExTokenBalanceWei = await FollowerTokenInstance.methods.balanceOf(followerExchangeAddr).call(); + + console.log('Leader Pool:'); + console.log(web3.utils.fromWei(leaderExEthBalanceWei, 'ether') + 'Eth'); + console.log(web3.utils.fromWei(leaderExTokenBalanceWei, 'ether') + 'Token'); + var leaderSpotPrices = await Util.getSpotPrices(leaderExEthBalanceWei, leaderExTokenBalanceWei, true); + console.log('Follower Pool:'); + console.log(web3.utils.fromWei(followerExEthBalanceWei, 'ether') + 'Eth'); + console.log(web3.utils.fromWei(followerExTokenBalanceWei, 'ether') + 'Token'); + var followerSpotPrices = await Util.getSpotPrices(followerExEthBalanceWei, followerExTokenBalanceWei, true); +} + +async function raiseTokenPrice(web3, SourceAccount, PrivateKey, ethSpendWei, leaderExchangeAddr){ + + var id = await web3.eth.net.getId(); + + const DaiTokenInstance = new web3.eth.Contract(LeaderToken.abi, LeaderToken.networks[id].address); + + var exchangeEthBalance = await web3.eth.getBalance(leaderExchangeAddr); + var exchangeTokenBalance = await DaiTokenInstance.methods.balanceOf(leaderExchangeAddr).call(); + var exchangeEthBalanceBN = new BigNumber(exchangeEthBalance); + var exchangeTokenBalanceBN = new BigNumber(exchangeTokenBalance); + + var prices = await Util.getEffectivePrices(web3, ethSpendWei, exchangeEthBalance, exchangeTokenBalance, true); + var block = await web3.eth.getBlock("latest"); + const DEADLINE = block.timestamp + 300; + var slippage = new BigNumber('0.997'); + var minTokens = prices.tokensToBuyWeiBN.multipliedBy(slippage).precision(18); + + const leaderContract = new web3.eth.Contract(UniSwapExchange.abi, leaderExchangeAddr); + + var tx = await leaderContract.methods.ethToTokenSwapInput(minTokens.toString(10), DEADLINE); + await Util.sendTransactionWithValue(web3, tx, SourceAccount, PrivateKey, leaderExchangeAddr, ethSpendWei); +} + +exports.ChangePrice = async function(){ + var web3 = new Web3(new Web3.providers.HttpProvider('http://127.0.0.1:8545')); + displayPrice(web3); + console.log('\nChanging Price...') + var id = await web3.eth.net.getId(); + const UniSwapFactoryInstance = new web3.eth.Contract(UniSwapFactory.abi, UniSwapFactory.networks[id].address); + const leaderExchangeAddr = await UniSwapFactoryInstance.methods.getExchange(LeaderToken.networks[id].address).call(); + const ethSpendWei = web3.utils.toWei('0.2', 'ether'); + await raiseTokenPrice(web3, SOURCE_ACCOUNT, process.env.PRIVATEKEY, ethSpendWei, leaderExchangeAddr); + console.log('\n') + displayPrice(web3); +} + +async function PoolInfo(Address){ + var leaderExEthBalanceWei = await web3.eth.getBalance(Address); + var leaderExTokenBalanceWei = await DaiTokenInstance.methods.balanceOf(Address).call(); + + var leaderSpotPrices = await Util.getSpotPrices(leaderExEthBalanceWei, leaderExTokenBalanceWei, false); + + data = [ + ['Pool', 'Leader Token'], + ['Eth Pool', web3.utils.fromWei(leaderExEthBalanceWei, 'ether')], + ['Token Pool', web3.utils.fromWei(leaderExTokenBalanceWei, 'ether')], + ['Eth Spot Price', leaderSpotPrices.ethPrice.toString(10)], + ['Token Spot Price', leaderSpotPrices.tokenPrice.toString(10)] + ]; + + output = table(data); + console.log(output); + return; +} + +// this.ChangePrice(); +this.setUp(); +// test(); diff --git a/client/src/contracts/AToken.json b/client/src/contracts/AToken.json new file mode 100644 index 0000000..606af46 --- /dev/null +++ b/client/src/contracts/AToken.json @@ -0,0 +1,13730 @@ +{ + "contractName": "AToken", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "initialExchangeRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "underlyingAssetAddress", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "underlyingAssetDecimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "name": "_addressesProvider", + "type": "address" + }, + { + "name": "_underlyingAsset", + "type": "address" + }, + { + "name": "_underlyingAssetDecimals", + "type": "uint256" + }, + { + "name": "_name", + "type": "string" + }, + { + "name": "_symbol", + "type": "string" + }, + { + "name": "_decimals", + "type": "uint8" + }, + { + "name": "_initialExchangeRate", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_from", + "type": "address" + }, + { + "indexed": false, + "name": "_value", + "type": "uint256" + }, + { + "indexed": false, + "name": "_underlyingValue", + "type": "uint256" + }, + { + "indexed": false, + "name": "_fromBalance", + "type": "uint256" + } + ], + "name": "Redeem", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_from", + "type": "address" + }, + { + "indexed": false, + "name": "_value", + "type": "uint256" + }, + { + "indexed": false, + "name": "_underlyingValue", + "type": "uint256" + }, + { + "indexed": false, + "name": "_fromBalance", + "type": "uint256" + } + ], + "name": "MintOnDeposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_from", + "type": "address" + }, + { + "indexed": false, + "name": "_value", + "type": "uint256" + }, + { + "indexed": false, + "name": "_underlyingValue", + "type": "uint256" + }, + { + "indexed": false, + "name": "_fromBalance", + "type": "uint256" + } + ], + "name": "BurnOnLiquidation", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_from", + "type": "address" + }, + { + "indexed": true, + "name": "_to", + "type": "address" + }, + { + "indexed": false, + "name": "_value", + "type": "uint256" + }, + { + "indexed": false, + "name": "_underlyingValue", + "type": "uint256" + }, + { + "indexed": false, + "name": "_fromBalance", + "type": "uint256" + }, + { + "indexed": false, + "name": "_toBalance", + "type": "uint256" + } + ], + "name": "TransferOnLiquidation", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_from", + "type": "address" + }, + { + "indexed": true, + "name": "_to", + "type": "address" + }, + { + "indexed": false, + "name": "_value", + "type": "uint256" + }, + { + "indexed": false, + "name": "_underlyingValue", + "type": "uint256" + }, + { + "indexed": false, + "name": "_fromBalance", + "type": "uint256" + }, + { + "indexed": false, + "name": "_toBalance", + "type": "uint256" + } + ], + "name": "BalanceTransfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "constant": false, + "inputs": [ + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "redeem", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_account", + "type": "address" + }, + { + "name": "_underlyingAmount", + "type": "uint256" + } + ], + "name": "mintOnDeposit", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "account", + "type": "address" + }, + { + "name": "value", + "type": "uint256" + } + ], + "name": "burnOnLiquidation", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "from", + "type": "address" + }, + { + "name": "to", + "type": "address" + }, + { + "name": "value", + "type": "uint256" + } + ], + "name": "transferOnLiquidation", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getExchangeRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_user", + "type": "address" + } + ], + "name": "balanceOfUnderlying", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "aTokenAmountToUnderlyingAmount", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_from", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "isTransferAllowed", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "underlyingAmountToATokenAmount", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"aTokenAmountToUnderlyingAmount\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint8\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"balanceOfUnderlying\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"},{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"burnOnLiquidation\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_from\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"isTransferAllowed\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"initialExchangeRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"underlyingAssetAddress\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_account\",\"type\":\"address\"},{\"name\":\"_underlyingAmount\",\"type\":\"uint256\"}],\"name\":\"mintOnDeposit\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"underlyingAssetDecimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"underlyingAmountToATokenAmount\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"redeem\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getExchangeRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"from\",\"type\":\"address\"},{\"name\":\"to\",\"type\":\"address\"},{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"transferOnLiquidation\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_addressesProvider\",\"type\":\"address\"},{\"name\":\"_underlyingAsset\",\"type\":\"address\"},{\"name\":\"_underlyingAssetDecimals\",\"type\":\"uint256\"},{\"name\":\"_name\",\"type\":\"string\"},{\"name\":\"_symbol\",\"type\":\"string\"},{\"name\":\"_decimals\",\"type\":\"uint8\"},{\"name\":\"_initialExchangeRate\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_from\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_value\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_underlyingValue\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_fromBalance\",\"type\":\"uint256\"}],\"name\":\"Redeem\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_from\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_value\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_underlyingValue\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_fromBalance\",\"type\":\"uint256\"}],\"name\":\"MintOnDeposit\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_from\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_value\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_underlyingValue\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_fromBalance\",\"type\":\"uint256\"}],\"name\":\"BurnOnLiquidation\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_value\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_underlyingValue\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_fromBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_toBalance\",\"type\":\"uint256\"}],\"name\":\"TransferOnLiquidation\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_value\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_underlyingValue\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_fromBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_toBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceTransfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"details\":\"Implementation of the interest bearing token for the DLP protocol.\",\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"burnOnLiquidation(address,uint256)\":{\"details\":\"burns token in the event of a borrow being liquidated, in case the liquidators reclaims the underlying assetonly lending pools can call this function\"},\"decimals()\":{\"details\":\"Returns the number of decimals used to get its user representation. For example, if `decimals` equals `2`, a balance of `505` tokens should be displayed to a user as `5,05` (`505 / 10 ** 2`). * Tokens usually opt for a value of 18, imitating the relationship between Ether and Wei. * NOTE: This information is only used for _display_ purposes: it in no way affects any of the arithmetic of the contract, including {IERC20-balanceOf} and {IERC20-transfer}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"getExchangeRate()\":{\"details\":\"returns the exchange rate of the aToken to the underlying asset\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mintOnDeposit(address,uint256)\":{\"details\":\"only lending pools can call this function\"},\"name()\":{\"details\":\"Returns the name of the token.\"},\"symbol()\":{\"details\":\"Returns the symbol of the token, usually a shorter version of the name.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"},\"transferOnLiquidation(address,address,uint256)\":{\"details\":\"transfers tokens in the event of a borrow being liquidated, in case the liquidators reclaims the aTokenonly lending pools can call this function\"}},\"title\":\"Aave ERC20 AToken\"},\"userdoc\":{\"methods\":{\"isTransferAllowed(address,uint256)\":{\"notice\":\"Used to validate transfers before actually executing them.*\"},\"mintOnDeposit(address,uint256)\":{\"notice\":\"mints token in the event of users depositing the underlying asset into the lending pool\"},\"redeem(uint256)\":{\"notice\":\"redeems aToken for the undelying asset.\"}}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol\":\"AToken\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x0ae6004410cd58a1c5151e67959167cf58cd5e77e8b625677826e295905fb318\",\"urls\":[\"bzzr://d223bea23f0e9bd70844e9852f490be93d30fc1c31bf114c807d0e4fe07d929b\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol\":{\"keccak256\":\"0xcd8c22e8b9f5c5c4bdb5b5262beafa93486c3b15262283c053afd423eca6e16b\",\"urls\":[\"bzzr://a9a5076a121f51ea42d9ebddc2684f299a0b57c0321837b5776c3a9eb26be97e\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol\":{\"keccak256\":\"0x479a8627304b58f37a4adbe06a72c7a056ad7ce6793a4ea66deeba04c6e443c8\",\"urls\":[\"bzzr://92bb0ae9b38ab361638c71c81f650ff8115da42cb4f50a0ee7a6fb5e03e5e640\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol\":{\"keccak256\":\"0x3f74e899243a66d556c0fa81875ab95ed1e3af1909b0281d03fe89590b95121f\",\"urls\":[\"bzzr://ef6ed6edeb1ec124bf1749991346f0708214f7e12c353175d36b491bce45d7a4\"]},\"/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol\":{\"keccak256\":\"0x3b825dc98b6a7aa21e9c9b05e1951bec7b5d7c84b7a0e8de0750069ccb31ebac\",\"urls\":[\"bzzr://8a616caca158d63de8db6037a2162c1effaaa71f6d7095a11516e03f7ea391d0\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol\":{\"keccak256\":\"0xdf72f6345d96ca2731656811b508db7f8e4975776d6de39ab24dbe4a13794fd8\",\"urls\":[\"bzzr://687ac9b4f396f264af2645041f5532b6881ec8c92dad3e505ca96477957c784d\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":{\"keccak256\":\"0xeeae2b67fa36103fe1c3a4e346b9c04171f9065949953abd00104c357834b0e3\",\"urls\":[\"bzzr://4e3bd29abfa796726532c3e42dd8039ab0f93388d7bbf358428dbc9b0399664a\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x0adf744884b9262f507aba565d1c96c82397f58d399a2dc2c60a452953197574\",\"urls\":[\"bzzr://03099f88c041565b5ac13ea7e645a8f9bff0c29bfa584c7969372ce12c5473f5\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol\":{\"keccak256\":\"0x35a7f1a34259948cdcb03084718f765215fe69559f557b395d9d6e18c63ac823\",\"urls\":[\"bzzr://f529e265dd06192a1d552f1f41c245790419562dfb52e7be9d443c758ccb72d0\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol\":{\"keccak256\":\"0x3f4ef00886795fb781b76e1fab7ce2f0422de9d0941bc8d5d9c377ad100e9a33\",\"urls\":[\"bzzr://8aff91a48f36ed3d3da74fc48d65cbc20e56e45172790ae38f18e234883ece70\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol\":{\"keccak256\":\"0xca757f989e0e7519d03d4e3086028e3022306ec4bb7f610fa78bff866f04c998\",\"urls\":[\"bzzr://f381f642ecce43d76d9e0011ea3c7c6218d1eaa2e0d3a7d5aecd55552cc0fb27\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol\":{\"keccak256\":\"0xe9e88d47e58f59345bb70a48960878e8b6d7525e3fe4f03c63f575599123957a\",\"urls\":[\"bzzr://ab72dddd7f00500a59b72b7f2f938ca25ae859517d524e446dc92a37f5f4a4e3\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol\":{\"keccak256\":\"0x8cd409571214e2d2f9196b8a31ce04bb44919ce7b12e66301c216c3de70a3f5f\",\"urls\":[\"bzzr://87f2c373a1f51ca84ac1132e72e3ef5a43e7a4f4f10341a63993c2cbdb769b64\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol\":{\"keccak256\":\"0xb8b4844881a9ea5c3f0f2584061efcbfb6c96863ca3a07b960d2f9d323293cac\",\"urls\":[\"bzzr://8cb1c5dcce198c0f60c21bd9807b361fc214a60d4b3aa3442153b045b51a4325\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol\":{\"keccak256\":\"0x547550bb7c7e61190fddae1b4dbe71932c9acdaf1d196524ee99c3340a5bec2d\",\"urls\":[\"bzzr://4a9ee0d136529517d7586cb3842177dbd767d9c34fdb035b0a90e8f4cc4d1b35\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol\":{\"keccak256\":\"0x4a3a810b7ebe742e897e1fd428b3eeed2196d3acea58eaf9c566ed10d545d2ed\",\"urls\":[\"bzzr://729aefb3f89f616c954a0735f8b4dd8804bdd0351e96f8e904fdb3e78a109b6c\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]},\"openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol\":{\"keccak256\":\"0xe86fdc15fbc379ecf14d6aa4f51b87c0be8476e114e23c171b790a6717230655\",\"urls\":[\"bzzr://364c5847b4ee3ac37a6ad6e54a288889ac3d2a85757b7999c00c719db6cd871d\"]}},\"version\":1}", + "bytecode": "0x60806040523480156200001157600080fd5b5060405162002bc338038062002bc3833981018060405260e08110156200003757600080fd5b8101908080519060200190929190805190602001909291908051906020019092919080516401000000008111156200006e57600080fd5b828101905060208101848111156200008557600080fd5b8151856001820283011164010000000082111715620000a357600080fd5b50509291906020018051640100000000811115620000c057600080fd5b82810190506020810184811115620000d757600080fd5b8151856001820283011164010000000082111715620000f557600080fd5b5050929190602001805190602001909291908051906020019092919050505083838382600390805190602001906200012f929190620002ea565b50816004908051906020019062000148929190620002ea565b5080600560006101000a81548160ff021916908360ff16021790555050505086600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200021157600080fd5b505afa15801562000226573d6000803e3d6000fd5b505050506040513d60208110156200023d57600080fd5b8101908080519060200190929190505050600960006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508060078190555085600560016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550846006819055505050505050505062000399565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106200032d57805160ff19168380011785556200035e565b828001600101855582156200035e579182015b828111156200035d57825182559160200191906001019062000340565b5b5090506200036d919062000371565b5090565b6200039691905b808211156200039257600081600090555060010162000378565b5090565b90565b61281a80620003a96000396000f3fe608060405234801561001057600080fd5b506004361061014d5760003560e01c806370a08231116100c3578063a9059cbb1161007c578063a9059cbb146106cc578063b32d461014610732578063db006a7514610774578063dd62ed3e146107a2578063e6aa216c1461081a578063f866c319146108385761014d565b806370a08231146104d557806389d1a0fc1461052d57806394362e8b1461057757806395d89b41146105c55780639a32c20714610648578063a457c2d7146106665761014d565b8063313ce56711610115578063313ce5671461032157806339509351146103455780633af9e669146103ab5780633edb7cb8146104035780635eae177c146104515780636d019f35146104b75761014d565b806306fdde0314610152578063095ea7b3146101d55780630ece1a5f1461023b57806318160ddd1461027d57806323b872dd1461029b575b600080fd5b61015a6108a6565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561019a57808201518184015260208101905061017f565b50505050905090810190601f1680156101c75780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b610221600480360360408110156101eb57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610948565b604051808215151515815260200191505060405180910390f35b6102676004803603602081101561025157600080fd5b8101908080359060200190929190505050610966565b6040518082815260200191505060405180910390f35b6102856109e7565b6040518082815260200191505060405180910390f35b610307600480360360608110156102b157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506109f1565b604051808215151515815260200191505060405180910390f35b610329610aca565b604051808260ff1660ff16815260200191505060405180910390f35b6103916004803603604081101561035b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610ae1565b604051808215151515815260200191505060405180910390f35b6103ed600480360360208110156103c157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b94565b6040518082815260200191505060405180910390f35b61044f6004803603604081101561041957600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610bae565b005b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610d50565b604051808215151515815260200191505060405180910390f35b6104bf610f25565b6040518082815260200191505060405180910390f35b610517600480360360208110156104eb57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f2b565b6040518082815260200191505060405180910390f35b610535610f73565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6105c36004803603604081101561058d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610f99565b005b6105cd611141565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561060d5780820151818401526020810190506105f2565b50505050905090810190601f16801561063a5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6106506111e3565b6040518082815260200191505060405180910390f35b6106b26004803603604081101561067c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506111e9565b604051808215151515815260200191505060405180910390f35b610718600480360360408110156106e257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506112b6565b604051808215151515815260200191505060405180910390f35b61075e6004803603602081101561074857600080fd5b81019080803590602001909291905050506112d4565b6040518082815260200191505060405180910390f35b6107a06004803603602081101561078a57600080fd5b8101908080359060200190929190505050611328565b005b610804600480360360408110156107b857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506115c6565b6040518082815260200191505060405180910390f35b61082261164d565b6040518082815260200191505060405180910390f35b6108a46004803603606081101561084e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611769565b005b606060038054600181600116156101000203166002900480601f01602080910402602001604051908101604052809291908181526020018280546001816001161561010002031660029004801561093e5780601f106109135761010080835404028352916020019161093e565b820191906000526020600020905b81548152906001019060200180831161092157829003601f168201915b5050505050905090565b600061095c610955611934565b848461193c565b6001905092915050565b60008082141561097957600090506109e2565b6000610983610aca565b60ff16600a0a90506109de6109d9826109cb600654600a0a6109bd6109a661164d565b6109af8a611b33565b611b5390919063ffffffff16565b611baf90919063ffffffff16565b611c3590919063ffffffff16565b611c7f565b9150505b919050565b6000600254905090565b60006109fe848484611c9f565b610abf84610a0a611934565b610aba8560405180606001604052806028815260200161273860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000610a70611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b61193c565b600190509392505050565b6000600560009054906101000a900460ff16905090565b6000610b8a610aee611934565b84610b858560016000610aff611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b61193c565b6001905092915050565b6000610ba7610ba283610f2b565b610966565b9050919050565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b158015610c1657600080fd5b505afa158015610c2a573d6000803e3d6000fd5b505050506040513d6020811015610c4057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610cd4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b610cde8282611f0c565b8173ffffffffffffffffffffffffffffffffffffffff167f90e5d3d68ec162d9c7de393037a3ede04dd44f68e051bf2ace4a73c299dbc4db82610d2084610966565b610d2986610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a25050565b600080600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f58b80d6040518163ffffffff1660e01b815260040160206040518083038186803b158015610dbb57600080fd5b505afa158015610dcf573d6000803e3d6000fd5b505050506040513d6020811015610de557600080fd5b810190808051906020019092919050505090506000610e0384610966565b90508173ffffffffffffffffffffffffffffffffffffffff166376e9d615600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1687846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001935050505060206040518083038186803b158015610ee057600080fd5b505afa158015610ef4573d6000803e3d6000fd5b505050506040513d6020811015610f0a57600080fd5b81019080805190602001909291905050509250505092915050565b60075481565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561100157600080fd5b505afa158015611015573d6000803e3d6000fd5b505050506040513d602081101561102b57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146110bf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b60006110ca826112d4565b90506110d683826120c4565b8273ffffffffffffffffffffffffffffffffffffffff167fbe7799898ca2d813ff902b487c1b434ab45b47edd8f38b77ad5e99aae8341b7a828461111987610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a2505050565b606060048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156111d95780601f106111ae576101008083540402835291602001916111d9565b820191906000526020600020905b8154815290600101906020018083116111bc57829003601f168201915b5050505050905090565b60065481565b60006112ac6111f6611934565b846112a7856040518060600160405280602581526020016127ca6025913960016000611220611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b61193c565b6001905092915050565b60006112ca6112c3611934565b8484611c9f565b6001905092915050565b6000808214156112e75760009050611323565b61132061131b600654600a0a61130d6112fe61164d565b86611baf90919063ffffffff16565b611c3590919063ffffffff16565b611c7f565b90505b919050565b33816113348282610d50565b6113a6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f5472616e736665722063616e6e6f7420626520616c6c6f7765642e000000000081525060200191505060405180910390fd5b60006113b184610966565b90506113bd338561227f565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561142757600080fd5b505afa15801561143b573d6000803e3d6000fd5b505050506040513d602081101561145157600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663935642cf600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633856040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561154157600080fd5b505af1158015611555573d6000803e3d6000fd5b505050503373ffffffffffffffffffffffffffffffffffffffff167fbd5034ffbd47e4e72a94baa2cdb74c6fad73cb3bcdc13036b72ec8306f5a7646868461159c33610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a25050505050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600080600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d15e0053600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff166040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561171157600080fd5b505afa158015611725573d6000803e3d6000fd5b505050506040513d602081101561173b57600080fd5b8101908080519060200190929190505050905061176381600754611b5390919063ffffffff16565b91505090565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156117d157600080fd5b505afa1580156117e5573d6000803e3d6000fd5b505050506040513d60208110156117fb57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461188f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b61189a83838361228d565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f2c335084544f8f7476a1c2e460962cd7e50d03d52a940d3d09e6f25894c75df3836118f385610966565b6118fc88610f2b565b61190588610f2b565b6040518085815260200184815260200183815260200182815260200194505050505060405180910390a3505050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156119c2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806127a66024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611a48576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806126996022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b6000611b4c633b9aca0083611baf90919063ffffffff16565b9050919050565b60008060028381611b6057fe5b049050611ba683611b98611b896b033b2e3c9fd0803ce800000088611baf90919063ffffffff16565b84611e8490919063ffffffff16565b611c3590919063ffffffff16565b91505092915050565b600080831415611bc25760009050611c2f565b6000828402905082848281611bd357fe5b0414611c2a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806126e16021913960400191505060405180910390fd5b809150505b92915050565b6000611c7783836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612543565b905092915050565b6000611c98633b9aca0083611c3590919063ffffffff16565b9050919050565b8281611cab8282610d50565b611d1d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f5472616e736665722063616e6e6f7420626520616c6c6f7765642e000000000081525060200191505060405180910390fd5b611d2885858561228d565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fbf553f39591e51c9524a30865d4a5590424976ba75d2046a6c7ce15d6321b62485611d8187610966565b611d8a8a610f2b565b611d938a610f2b565b6040518085815260200184815260200183815260200182815260200194505050505060405180910390a35050505050565b6000838311158290611e71576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611e36578082015181840152602081019050611e1b565b50505050905090810190601f168015611e635780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015611f02576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611f92576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806127606021913960400191505060405180910390fd5b611ffd81604051806060016040528060228152602001612677602291396000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506120548160025461260990919063ffffffff16565b600281905550600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612167576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b61217c81600254611e8490919063ffffffff16565b6002819055506121d3816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b6122898282611f0c565b5050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415612313576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806127816025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612399576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806126546023913960400191505060405180910390fd5b612404816040518060600160405280602681526020016126bb602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550612497816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b600080831182906125ef576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156125b4578082015181840152602081019050612599565b50505050905090810190601f1680156125e15780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816125fb57fe5b049050809150509392505050565b600061264b83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611dc4565b90509291505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e6365536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f775468652063616c6c6572206f6620746869732066756e6374696f6e2063616e206f6e6c792062652061206c656e64696e6720706f6f6c45524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058204a0bed3ae55c5673e00e38acc740d939f148a1b9c8a8f608b3b3212a756b93980029", + "deployedBytecode": "0x608060405234801561001057600080fd5b506004361061014d5760003560e01c806370a08231116100c3578063a9059cbb1161007c578063a9059cbb146106cc578063b32d461014610732578063db006a7514610774578063dd62ed3e146107a2578063e6aa216c1461081a578063f866c319146108385761014d565b806370a08231146104d557806389d1a0fc1461052d57806394362e8b1461057757806395d89b41146105c55780639a32c20714610648578063a457c2d7146106665761014d565b8063313ce56711610115578063313ce5671461032157806339509351146103455780633af9e669146103ab5780633edb7cb8146104035780635eae177c146104515780636d019f35146104b75761014d565b806306fdde0314610152578063095ea7b3146101d55780630ece1a5f1461023b57806318160ddd1461027d57806323b872dd1461029b575b600080fd5b61015a6108a6565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561019a57808201518184015260208101905061017f565b50505050905090810190601f1680156101c75780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b610221600480360360408110156101eb57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610948565b604051808215151515815260200191505060405180910390f35b6102676004803603602081101561025157600080fd5b8101908080359060200190929190505050610966565b6040518082815260200191505060405180910390f35b6102856109e7565b6040518082815260200191505060405180910390f35b610307600480360360608110156102b157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506109f1565b604051808215151515815260200191505060405180910390f35b610329610aca565b604051808260ff1660ff16815260200191505060405180910390f35b6103916004803603604081101561035b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610ae1565b604051808215151515815260200191505060405180910390f35b6103ed600480360360208110156103c157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b94565b6040518082815260200191505060405180910390f35b61044f6004803603604081101561041957600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610bae565b005b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610d50565b604051808215151515815260200191505060405180910390f35b6104bf610f25565b6040518082815260200191505060405180910390f35b610517600480360360208110156104eb57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f2b565b6040518082815260200191505060405180910390f35b610535610f73565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6105c36004803603604081101561058d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610f99565b005b6105cd611141565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561060d5780820151818401526020810190506105f2565b50505050905090810190601f16801561063a5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6106506111e3565b6040518082815260200191505060405180910390f35b6106b26004803603604081101561067c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506111e9565b604051808215151515815260200191505060405180910390f35b610718600480360360408110156106e257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506112b6565b604051808215151515815260200191505060405180910390f35b61075e6004803603602081101561074857600080fd5b81019080803590602001909291905050506112d4565b6040518082815260200191505060405180910390f35b6107a06004803603602081101561078a57600080fd5b8101908080359060200190929190505050611328565b005b610804600480360360408110156107b857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506115c6565b6040518082815260200191505060405180910390f35b61082261164d565b6040518082815260200191505060405180910390f35b6108a46004803603606081101561084e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611769565b005b606060038054600181600116156101000203166002900480601f01602080910402602001604051908101604052809291908181526020018280546001816001161561010002031660029004801561093e5780601f106109135761010080835404028352916020019161093e565b820191906000526020600020905b81548152906001019060200180831161092157829003601f168201915b5050505050905090565b600061095c610955611934565b848461193c565b6001905092915050565b60008082141561097957600090506109e2565b6000610983610aca565b60ff16600a0a90506109de6109d9826109cb600654600a0a6109bd6109a661164d565b6109af8a611b33565b611b5390919063ffffffff16565b611baf90919063ffffffff16565b611c3590919063ffffffff16565b611c7f565b9150505b919050565b6000600254905090565b60006109fe848484611c9f565b610abf84610a0a611934565b610aba8560405180606001604052806028815260200161273860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000610a70611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b61193c565b600190509392505050565b6000600560009054906101000a900460ff16905090565b6000610b8a610aee611934565b84610b858560016000610aff611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b61193c565b6001905092915050565b6000610ba7610ba283610f2b565b610966565b9050919050565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b158015610c1657600080fd5b505afa158015610c2a573d6000803e3d6000fd5b505050506040513d6020811015610c4057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610cd4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b610cde8282611f0c565b8173ffffffffffffffffffffffffffffffffffffffff167f90e5d3d68ec162d9c7de393037a3ede04dd44f68e051bf2ace4a73c299dbc4db82610d2084610966565b610d2986610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a25050565b600080600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f58b80d6040518163ffffffff1660e01b815260040160206040518083038186803b158015610dbb57600080fd5b505afa158015610dcf573d6000803e3d6000fd5b505050506040513d6020811015610de557600080fd5b810190808051906020019092919050505090506000610e0384610966565b90508173ffffffffffffffffffffffffffffffffffffffff166376e9d615600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1687846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001935050505060206040518083038186803b158015610ee057600080fd5b505afa158015610ef4573d6000803e3d6000fd5b505050506040513d6020811015610f0a57600080fd5b81019080805190602001909291905050509250505092915050565b60075481565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561100157600080fd5b505afa158015611015573d6000803e3d6000fd5b505050506040513d602081101561102b57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146110bf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b60006110ca826112d4565b90506110d683826120c4565b8273ffffffffffffffffffffffffffffffffffffffff167fbe7799898ca2d813ff902b487c1b434ab45b47edd8f38b77ad5e99aae8341b7a828461111987610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a2505050565b606060048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156111d95780601f106111ae576101008083540402835291602001916111d9565b820191906000526020600020905b8154815290600101906020018083116111bc57829003601f168201915b5050505050905090565b60065481565b60006112ac6111f6611934565b846112a7856040518060600160405280602581526020016127ca6025913960016000611220611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b61193c565b6001905092915050565b60006112ca6112c3611934565b8484611c9f565b6001905092915050565b6000808214156112e75760009050611323565b61132061131b600654600a0a61130d6112fe61164d565b86611baf90919063ffffffff16565b611c3590919063ffffffff16565b611c7f565b90505b919050565b33816113348282610d50565b6113a6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f5472616e736665722063616e6e6f7420626520616c6c6f7765642e000000000081525060200191505060405180910390fd5b60006113b184610966565b90506113bd338561227f565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561142757600080fd5b505afa15801561143b573d6000803e3d6000fd5b505050506040513d602081101561145157600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663935642cf600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633856040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561154157600080fd5b505af1158015611555573d6000803e3d6000fd5b505050503373ffffffffffffffffffffffffffffffffffffffff167fbd5034ffbd47e4e72a94baa2cdb74c6fad73cb3bcdc13036b72ec8306f5a7646868461159c33610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a25050505050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600080600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d15e0053600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff166040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561171157600080fd5b505afa158015611725573d6000803e3d6000fd5b505050506040513d602081101561173b57600080fd5b8101908080519060200190929190505050905061176381600754611b5390919063ffffffff16565b91505090565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156117d157600080fd5b505afa1580156117e5573d6000803e3d6000fd5b505050506040513d60208110156117fb57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461188f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b61189a83838361228d565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f2c335084544f8f7476a1c2e460962cd7e50d03d52a940d3d09e6f25894c75df3836118f385610966565b6118fc88610f2b565b61190588610f2b565b6040518085815260200184815260200183815260200182815260200194505050505060405180910390a3505050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156119c2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806127a66024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611a48576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806126996022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b6000611b4c633b9aca0083611baf90919063ffffffff16565b9050919050565b60008060028381611b6057fe5b049050611ba683611b98611b896b033b2e3c9fd0803ce800000088611baf90919063ffffffff16565b84611e8490919063ffffffff16565b611c3590919063ffffffff16565b91505092915050565b600080831415611bc25760009050611c2f565b6000828402905082848281611bd357fe5b0414611c2a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806126e16021913960400191505060405180910390fd5b809150505b92915050565b6000611c7783836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612543565b905092915050565b6000611c98633b9aca0083611c3590919063ffffffff16565b9050919050565b8281611cab8282610d50565b611d1d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f5472616e736665722063616e6e6f7420626520616c6c6f7765642e000000000081525060200191505060405180910390fd5b611d2885858561228d565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fbf553f39591e51c9524a30865d4a5590424976ba75d2046a6c7ce15d6321b62485611d8187610966565b611d8a8a610f2b565b611d938a610f2b565b6040518085815260200184815260200183815260200182815260200194505050505060405180910390a35050505050565b6000838311158290611e71576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611e36578082015181840152602081019050611e1b565b50505050905090810190601f168015611e635780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015611f02576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611f92576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806127606021913960400191505060405180910390fd5b611ffd81604051806060016040528060228152602001612677602291396000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506120548160025461260990919063ffffffff16565b600281905550600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612167576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b61217c81600254611e8490919063ffffffff16565b6002819055506121d3816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b6122898282611f0c565b5050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415612313576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806127816025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612399576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806126546023913960400191505060405180910390fd5b612404816040518060600160405280602681526020016126bb602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550612497816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b600080831182906125ef576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156125b4578082015181840152602081019050612599565b50505050905090810190601f1680156125e15780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816125fb57fe5b049050809150509392505050565b600061264b83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611dc4565b90509291505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e6365536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f775468652063616c6c6572206f6620746869732066756e6374696f6e2063616e206f6e6c792062652061206c656e64696e6720706f6f6c45524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058204a0bed3ae55c5673e00e38acc740d939f148a1b9c8a8f608b3b3212a756b93980029", + "sourceMap": "574:6678:51:-;;;2052:612;8:9:-1;5:2;;;30:1;27;20:12;5:2;2052:612:51;;;;;;;;;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;2052:612:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19:11:-1;14:3;11:20;8:2;;;44:1;41;34:12;8:2;71:11;66:3;62:21;55:28;;123:4;118:3;114:14;159:9;141:16;138:31;135:2;;;182:1;179;172:12;135:2;219:3;213:10;330:9;325:1;311:12;307:20;289:16;285:43;282:58;261:11;247:12;244:29;233:115;230:2;;;361:1;358;351:12;230:2;0:372;;2052:612:51;;;;;;;19:11:-1;14:3;11:20;8:2;;;44:1;41;34:12;8:2;71:11;66:3;62:21;55:28;;123:4;118:3;114:14;159:9;141:16;138:31;135:2;;;182:1;179;172:12;135:2;219:3;213:10;330:9;325:1;311:12;307:20;289:16;285:43;282:58;261:11;247:12;244:29;233:115;230:2;;;361:1;358;351:12;230:2;0:372;;2052:612:51;;;;;;;;;;;;;;;;;;;;;;;;;;2347:5;2354:7;2363:9;512:4:59;504:5;:12;;;;;;;;;;;;:::i;:::-;;536:6;526:7;:16;;;;;;;;;;;;:::i;:::-;;564:8;552:9;;:20;;;;;;;;;;;;;;;;;;416:163;;;2404:18:51;2384:17;;:38;;;;;;;;;;;;;;;;;;2455:17;;;;;;;;;;;:36;;;:38;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2455:38:51;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2455:38:51;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2455:38:51;;;;;;;;;;;;;;;;2432:4;;:62;;;;;;;;;;;;;;;;;;2526:20;2504:19;:42;;;;2581:16;2556:22;;:41;;;;;;;;;;;;;;;;;;2633:24;2607:23;:50;;;;2052:612;;;;;;;574:6678;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "574:6678:51:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;574:6678:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;644:81:59;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;644:81:59;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;5757:441:51;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5757:441:51;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1559:89:58;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1472:81:59;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;5605:146:51;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5605:146:51;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;4556:229;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4556:229:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;6295:390;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6295:390:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1541:34;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1706:108:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1454:37:51;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4042:317;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4042:317:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;838:85:59;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;838:85:59;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1497:38:51;;;:::i;:::-;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;6691:275:51;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6691:275:51;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3225:638;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3225:638:51;;;;;;;;;;;;;;;;;:::i;:::-;;2230:132:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;5345:254:51;;;:::i;:::-;;;;;;;;;;;;;;;;;;;4977:270;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4977:270:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;644:81:59;681:13;713:5;706:12;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;644:81;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;5757:441:51:-;5835:7;5869:1;5858:7;:12;5854:78;;;5920:1;5913:8;;;;5854:78;5942:25;5984:10;:8;:10::i;:::-;5976:19;;5970:2;:25;5942:53;;6013:178;:154;6149:17;6013:118;6107:23;;6101:2;:29;6013:70;6065:17;:15;:17::i;:::-;6013:31;:7;:29;:31::i;:::-;:51;;:70;;;;:::i;:::-;:87;;:118;;;;:::i;:::-;:135;;:154;;;;:::i;:::-;:176;:178::i;:::-;6006:185;;;5757:441;;;;:::o;1559:89:58:-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;1472:81:59:-;1513:5;1537:9;;;;;;;;;;;1530:16;;1472:81;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;5605:146:51:-;5670:7;5696:48;5727:16;5737:5;5727:9;:16::i;:::-;5696:30;:48::i;:::-;5689:55;;5605:146;;;:::o;4556:229::-;1747:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1747:34:51;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1747:34:51;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1747:34:51;;;;;;;;;;;;;;;;1733:48;;:10;:48;;;1712:149;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4650:21;4656:7;4665:5;4650;:21::i;:::-;4704:7;4686:92;;;4713:5;4720:37;4751:5;4720:30;:37::i;:::-;4759:18;4769:7;4759:9;:18::i;:::-;4686:92;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4556:229;;:::o;6295:390::-;6375:4;6391:36;6454:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6454:46:51;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6454:46:51;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6454:46:51;;;;;;;;;;;;;;;;6391:110;;6511:24;6538:39;6569:7;6538:30;:39::i;:::-;6511:66;;6594:12;:35;;;6630:22;;;;;;;;;;;6654:5;6661:16;6594:84;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6594:84:51;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6594:84:51;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6594:84:51;;;;;;;;;;;;;;;;6587:91;;;;6295:390;;;;:::o;1541:34::-;;;;:::o;1706:108:58:-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;1454:37:51:-;;;;;;;;;;;;;:::o;4042:317::-;1747:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1747:34:51;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1747:34:51;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1747:34:51;;;;;;;;;;;;;;;;1733:48;;:10;:48;;;1712:149;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4145:21;4169:49;4200:17;4169:30;:49::i;:::-;4145:73;;4229:30;4235:8;4245:13;4229:5;:30::i;:::-;4288:8;4274:78;;;4298:13;4313:17;4332:19;4342:8;4332:9;:19::i;:::-;4274:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1871:1;4042:317;;:::o;838:85:59:-;877:13;909:7;902:14;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;838:85;:::o;1497:38:51:-;;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;6691:275:51:-;6769:7;6803:1;6792:7;:12;6788:78;;;6854:1;6847:8;;;;6788:78;6883:76;:65;6924:23;;6918:2;:29;6883:30;6895:17;:15;:17::i;:::-;6883:7;:11;;:30;;;;:::i;:::-;:34;;:65;;;;:::i;:::-;:74;:76::i;:::-;6876:83;;6691:275;;;;:::o;3225:638::-;3286:10;3298:7;1963:33;1981:5;1988:7;1963:17;:33::i;:::-;1955:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3359:32;3394:39;3425:7;3394:30;:39::i;:::-;3359:74;;3503:41;3524:10;3536:7;3503:20;:41::i;:::-;3606:16;3637:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3637:34:51;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3637:34:51;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3637:34:51;;;;;;;;;;;;;;;;3606:66;;3682:4;:21;;;3704:22;;;;;;;;;;;3728:10;3740:24;3682:83;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3682:83:51;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3682:83:51;;;;3787:10;3780:76;;;3799:7;3808:24;3834:21;3844:10;3834:9;:21::i;:::-;3780:76;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2038:1;;3225:638;;;:::o;2230:132:58:-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;5345:254:51:-;5393:7;5412:42;5457:4;;;;;;;;;;;:31;;;5489:22;;;;;;;;;;;5457:55;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5457:55:51;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5457:55:51;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5457:55:51;;;;;;;;;;;;;;;;5412:100;;5530:62;5557:34;5530:19;;:26;;:62;;;;:::i;:::-;5523:69;;;5345:254;:::o;4977:270::-;1747:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1747:34:51;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1747:34:51;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1747:34:51;;;;;;;;;;;;;;;;1733:48;;:10;:48;;;1712:149;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5084:32;5100:4;5106:2;5110:5;5084:15;:32::i;:::-;5159:2;5131:109;;5153:4;5131:109;;;5163:5;5170:37;5201:5;5170:30;:37::i;:::-;5209:15;5219:4;5209:9;:15::i;:::-;5226:13;5236:2;5226:9;:13::i;:::-;5131:109;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4977:270;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;1584:105:29:-;1636:7;1662:20;547:3;1662:1;:5;;:20;;;;:::i;:::-;1655:27;;1584:105;;;:::o;1313:154::-;1374:7;1393:13;1413:1;1409;:5;;;;;;1393:21;;1432:28;1458:1;1432:21;1442:10;454:4;1442:1;:5;;:10;;;;:::i;:::-;1432:5;:9;;:21;;;;:::i;:::-;:25;;:28;;;;:::i;:::-;1425:35;;;1313:154;;;;:::o;2159:459:56:-;2217:7;2463:1;2458;:6;2454:45;;;2487:1;2480:8;;;;2454:45;2509:9;2525:1;2521;:5;2509:17;;2553:1;2548;2544;:5;;;;;;:10;2536:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2610:1;2603:8;;;2159:459;;;;;:::o;3073:130::-;3131:7;3157:39;3161:1;3164;3157:39;;;;;;;;;;;;;;;;;:3;:39::i;:::-;3150:46;;3073:130;;;;:::o;1473:105:29:-;1525:7;1551:20;547:3;1551:1;:5;;:20;;;;:::i;:::-;1544:27;;1473:105;;;:::o;2875:273:51:-;2964:4;2970:6;1963:33;1981:5;1988:7;1963:17;:33::i;:::-;1955:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2988:33;3004:4;3010:2;3014:6;2988:15;:33::i;:::-;3058:2;3036:105;;3052:4;3036:105;;;3062:6;3070:38;3101:6;3070:30;:38::i;:::-;3110:15;3120:4;3110:9;:15::i;:::-;3127:13;3137:2;3127:9;:13::i;:::-;3036:105;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2875:273;;;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;6584:342:58:-;6678:1;6659:21;;:7;:21;;;;6651:67;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6750:68;6773:6;6750:68;;;;;;;;;;;;;;;;;:9;:18;6760:7;6750:18;;;;;;;;;;;;;;;;:22;;:68;;;;;:::i;:::-;6729:9;:18;6739:7;6729:18;;;;;;;;;;;;;;;:89;;;;6843:24;6860:6;6843:12;;:16;;:24;;;;:::i;:::-;6828:12;:39;;;;6908:1;6882:37;;6891:7;6882:37;;;6912:6;6882:37;;;;;;;;;;;;;;;;;;6584:342;;:::o;5962:302::-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o;7141:109:51:-;7222:21;7228:7;7237:5;7222;:21::i;:::-;7141:109;;:::o;5228:464:58:-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;3718:338:56:-;3804:7;3901:1;3897;:5;3904:12;3889:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;3889:28:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3927:9;3943:1;3939;:5;;;;;;3927:17;;4048:1;4041:8;;;3718:338;;;;;:::o;1274:134::-;1332:7;1358:43;1362:1;1365;1358:43;;;;;;;;;;;;;;;;;:3;:43::i;:::-;1351:50;;1274:134;;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol\";\n\nimport \"../configuration/LendingPoolAddressesProvider.sol\";\nimport \"../lendingpool/LendingPool.sol\";\nimport \"../lendingpool/LendingPoolDataProvider.sol\";\nimport \"../lendingpool/LendingPoolCore.sol\";\nimport \"../libraries/WadRayMath.sol\";\n\n/**\n * @title Aave ERC20 AToken\n *\n * @dev Implementation of the interest bearing token for the DLP protocol.\n */\ncontract AToken is ERC20, ERC20Detailed {\n using WadRayMath for uint256;\n\n event Redeem(\n address indexed _from,\n uint256 _value,\n uint256 _underlyingValue,\n uint256 _fromBalance\n );\n\n event MintOnDeposit(address indexed _from, uint256 _value, uint256 _underlyingValue, uint256 _fromBalance);\n event BurnOnLiquidation(address indexed _from, uint256 _value, uint256 _underlyingValue, uint256 _fromBalance);\n event TransferOnLiquidation(\n address indexed _from,\n address indexed _to,\n uint256 _value,\n uint256 _underlyingValue,\n uint256 _fromBalance,\n uint256 _toBalance\n );\n\n\n event BalanceTransfer(\n address indexed _from,\n address indexed _to,\n uint256 _value,\n uint256 _underlyingValue,\n uint256 _fromBalance,\n uint256 _toBalance\n );\n\n address public underlyingAssetAddress;\n uint256 public underlyingAssetDecimals;\n uint256 public initialExchangeRate;\n\n LendingPoolAddressesProvider private addressesProvider;\n LendingPoolCore private core;\n\n modifier onlyLendingPool {\n require(\n msg.sender == addressesProvider.getLendingPool(),\n \"The caller of this function can only be a lending pool\"\n );\n _;\n }\n\n modifier whenTranferAllowed(address _from, uint256 _amount) {\n require(isTransferAllowed(_from, _amount), \"Transfer cannot be allowed.\");\n _;\n }\n\n constructor(\n LendingPoolAddressesProvider _addressesProvider,\n address _underlyingAsset,\n uint256 _underlyingAssetDecimals,\n string memory _name,\n string memory _symbol,\n uint8 _decimals,\n uint256 _initialExchangeRate\n ) public ERC20Detailed(_name, _symbol, _decimals) {\n addressesProvider = _addressesProvider;\n core = LendingPoolCore(addressesProvider.getLendingPoolCore());\n initialExchangeRate = _initialExchangeRate;\n underlyingAssetAddress = _underlyingAsset;\n underlyingAssetDecimals = _underlyingAssetDecimals;\n }\n\n /**\n * @notice ERC20 implementation internal function backing transfer() and transferFrom()\n * @dev validates the transfer before allowing it. NOTE: This is not standard ERC20 behavior\n */\n function _transfer(address from, address to, uint256 amount) internal whenTranferAllowed(from, amount) {\n super._transfer(from, to, amount);\n emit BalanceTransfer(from, to, amount, aTokenAmountToUnderlyingAmount(amount), balanceOf(from), balanceOf(to));\n }\n\n /**\n * @notice redeems aToken for the undelying asset.\n */\n function redeem(uint256 _amount) external whenTranferAllowed(msg.sender, _amount) {\n // calculate underlying to redeem\n uint256 underlyingAmountToRedeem = aTokenAmountToUnderlyingAmount(_amount);\n\n // burns tokens equivalent to the amount requested\n burnOnRedeemInternal(msg.sender, _amount);\n\n // executes redeem of the underlying asset\n LendingPool pool = LendingPool(addressesProvider.getLendingPool());\n pool.redeemUnderlying(underlyingAssetAddress, msg.sender, underlyingAmountToRedeem);\n emit Redeem(msg.sender, _amount, underlyingAmountToRedeem, balanceOf(msg.sender));\n }\n\n /**\n * @notice mints token in the event of users depositing the underlying asset into the lending pool\n * @dev only lending pools can call this function\n */\n function mintOnDeposit(address _account, uint256 _underlyingAmount) external onlyLendingPool {\n uint256 aTokensToMint = underlyingAmountToATokenAmount(_underlyingAmount);\n\n _mint(_account, aTokensToMint);\n emit MintOnDeposit(_account, aTokensToMint, _underlyingAmount, balanceOf(_account));\n }\n\n /**\n * @dev burns token in the event of a borrow being liquidated, in case the liquidators reclaims the underlying asset\n * @dev only lending pools can call this function\n */\n function burnOnLiquidation(address account, uint256 value) external onlyLendingPool {\n _burn(account, value);\n emit BurnOnLiquidation(account, value, aTokenAmountToUnderlyingAmount(value), balanceOf(account));\n }\n\n /**\n * @dev transfers tokens in the event of a borrow being liquidated, in case the liquidators reclaims the aToken\n * @dev only lending pools can call this function\n */\n function transferOnLiquidation(address from, address to, uint256 value) external onlyLendingPool {\n super._transfer(from, to, value);\n emit TransferOnLiquidation(from, to, value, aTokenAmountToUnderlyingAmount(value), balanceOf(from), balanceOf(to));\n }\n\n /**\n * @dev returns the exchange rate of the aToken to the underlying asset\n */\n function getExchangeRate() public view returns (uint256) {\n uint256 currentNormalizedCumulatedInterest = core.getReserveNormalizedIncome(underlyingAssetAddress);\n\n return initialExchangeRate.rayDiv(currentNormalizedCumulatedInterest);\n }\n\n function balanceOfUnderlying(address _user) public view returns (uint256) {\n return aTokenAmountToUnderlyingAmount(balanceOf(_user));\n }\n\n function aTokenAmountToUnderlyingAmount(uint256 _amount) public view returns (uint256) {\n if (_amount == 0) {\n // Optmization\n return 0;\n }\n\n uint256 overlyingDecimals = 10 ** uint256(decimals());\n\n return _amount\n .wadToRay()\n .rayDiv(getExchangeRate())\n .mul(10 ** underlyingAssetDecimals)\n .div(overlyingDecimals)\n .rayToWad();\n }\n\n /**\n * @notice Used to validate transfers before actually executing them.\n **/\n function isTransferAllowed(address _from, uint256 _amount) public view returns (bool) {\n LendingPoolDataProvider dataProvider = LendingPoolDataProvider(addressesProvider.getLendingPoolDataProvider());\n uint256 amountUnderlying = aTokenAmountToUnderlyingAmount(_amount);\n return dataProvider.balanceDecreaseAllowed(underlyingAssetAddress, _from, amountUnderlying);\n }\n\n function underlyingAmountToATokenAmount(uint256 _amount) public view returns (uint256) {\n if (_amount == 0) {\n // Optmization\n return 0;\n }\n\n return _amount.mul(getExchangeRate()).div(10 ** underlyingAssetDecimals).rayToWad();\n }\n\n /**\n * @dev burns token in the event of users redeeming the underlying asset from the lending pool\n * @dev only lending pools can call this function\n */\n function burnOnRedeemInternal(address account, uint256 value) internal {\n _burn(account, value);\n }\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "exportedSymbols": { + "AToken": [ + 10327 + ] + }, + "id": 10328, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9841, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:51" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 9842, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 11141, + "src": "25:59:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "id": 9843, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 11660, + "src": "85:63:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "id": 9844, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 11718, + "src": "149:71:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 9845, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 1358, + "src": "222:59:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol", + "file": "../lendingpool/LendingPool.sol", + "id": 9846, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 4095, + "src": "282:40:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol", + "file": "../lendingpool/LendingPoolDataProvider.sol", + "id": 9847, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 7661, + "src": "323:52:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "../lendingpool/LendingPoolCore.sol", + "id": 9848, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 6683, + "src": "376:44:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 9849, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 9175, + "src": "421:37:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9850, + "name": "ERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11659, + "src": "593:5:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + }, + "id": 9851, + "nodeType": "InheritanceSpecifier", + "src": "593:5:51" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9852, + "name": "ERC20Detailed", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11717, + "src": "600:13:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + } + }, + "id": 9853, + "nodeType": "InheritanceSpecifier", + "src": "600:13:51" + } + ], + "contractDependencies": [ + 10953, + 11659, + 11717, + 11786 + ], + "contractKind": "contract", + "documentation": "@title Aave ERC20 AToken\n * @dev Implementation of the interest bearing token for the DLP protocol.", + "fullyImplemented": true, + "id": 10327, + "linearizedBaseContracts": [ + 10327, + 11717, + 11659, + 11786, + 10953 + ], + "name": "AToken", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 9856, + "libraryName": { + "contractScope": null, + "id": 9854, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "626:10:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "620:29:51", + "typeName": { + "id": 9855, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "641:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "anonymous": false, + "documentation": null, + "id": 9866, + "name": "Redeem", + "nodeType": "EventDefinition", + "parameters": { + "id": 9865, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9858, + "indexed": true, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9866, + "src": "677:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9857, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "677:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9860, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 9866, + "src": "708:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9859, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "708:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9862, + "indexed": false, + "name": "_underlyingValue", + "nodeType": "VariableDeclaration", + "scope": 9866, + "src": "732:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9861, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "732:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9864, + "indexed": false, + "name": "_fromBalance", + "nodeType": "VariableDeclaration", + "scope": 9866, + "src": "766:20:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9863, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "766:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "667:125:51" + }, + "src": "655:138:51" + }, + { + "anonymous": false, + "documentation": null, + "id": 9876, + "name": "MintOnDeposit", + "nodeType": "EventDefinition", + "parameters": { + "id": 9875, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9868, + "indexed": true, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9876, + "src": "819:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9867, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "819:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9870, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 9876, + "src": "842:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9869, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "842:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9872, + "indexed": false, + "name": "_underlyingValue", + "nodeType": "VariableDeclaration", + "scope": 9876, + "src": "858:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9871, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "858:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9874, + "indexed": false, + "name": "_fromBalance", + "nodeType": "VariableDeclaration", + "scope": 9876, + "src": "884:20:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9873, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "884:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "818:87:51" + }, + "src": "799:107:51" + }, + { + "anonymous": false, + "documentation": null, + "id": 9886, + "name": "BurnOnLiquidation", + "nodeType": "EventDefinition", + "parameters": { + "id": 9885, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9878, + "indexed": true, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9886, + "src": "935:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9877, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "935:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9880, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 9886, + "src": "958:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9879, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "958:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9882, + "indexed": false, + "name": "_underlyingValue", + "nodeType": "VariableDeclaration", + "scope": 9886, + "src": "974:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9881, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "974:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9884, + "indexed": false, + "name": "_fromBalance", + "nodeType": "VariableDeclaration", + "scope": 9886, + "src": "1000:20:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9883, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1000:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "934:87:51" + }, + "src": "911:111:51" + }, + { + "anonymous": false, + "documentation": null, + "id": 9900, + "name": "TransferOnLiquidation", + "nodeType": "EventDefinition", + "parameters": { + "id": 9899, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9888, + "indexed": true, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1064:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9887, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1064:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9890, + "indexed": true, + "name": "_to", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1095:19:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9889, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1095:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9892, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1124:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9891, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1124:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9894, + "indexed": false, + "name": "_underlyingValue", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1148:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9893, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1148:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9896, + "indexed": false, + "name": "_fromBalance", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1182:20:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9895, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1182:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9898, + "indexed": false, + "name": "_toBalance", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1212:18:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9897, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1212:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1054:182:51" + }, + "src": "1027:210:51" + }, + { + "anonymous": false, + "documentation": null, + "id": 9914, + "name": "BalanceTransfer", + "nodeType": "EventDefinition", + "parameters": { + "id": 9913, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9902, + "indexed": true, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1275:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9901, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1275:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9904, + "indexed": true, + "name": "_to", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1306:19:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9903, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1306:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9906, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1335:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9905, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1335:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9908, + "indexed": false, + "name": "_underlyingValue", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1359:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9907, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1359:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9910, + "indexed": false, + "name": "_fromBalance", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1393:20:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9909, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1393:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9912, + "indexed": false, + "name": "_toBalance", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1423:18:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9911, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1423:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1265:182:51" + }, + "src": "1244:204:51" + }, + { + "constant": false, + "id": 9916, + "name": "underlyingAssetAddress", + "nodeType": "VariableDeclaration", + "scope": 10327, + "src": "1454:37:51", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9915, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1454:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": false, + "id": 9918, + "name": "underlyingAssetDecimals", + "nodeType": "VariableDeclaration", + "scope": 10327, + "src": "1497:38:51", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9917, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1497:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": false, + "id": 9920, + "name": "initialExchangeRate", + "nodeType": "VariableDeclaration", + "scope": 10327, + "src": "1541:34:51", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9919, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1541:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": false, + "id": 9922, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 10327, + "src": "1582:54:51", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 9921, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1582:28:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "private" + }, + { + "constant": false, + "id": 9924, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 10327, + "src": "1642:28:51", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 9923, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "1642:15:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "private" + }, + { + "body": { + "id": 9937, + "nodeType": "Block", + "src": "1702:177:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 9932, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 9927, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "1733:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 9928, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1733:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9929, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9922, + "src": "1747:17:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9930, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPool", + "nodeType": "MemberAccess", + "referencedDeclaration": 1058, + "src": "1747:32:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 9931, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1747:34:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1733:48:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206f6620746869732066756e6374696f6e2063616e206f6e6c792062652061206c656e64696e6720706f6f6c", + "id": 9933, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1795:56:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_93ed9b25aafeea7e49d0f8673c2cc037db8607981cc926f3a2b0e9362933797c", + "typeString": "literal_string \"The caller of this function can only be a lending pool\"" + }, + "value": "The caller of this function can only be a lending pool" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_93ed9b25aafeea7e49d0f8673c2cc037db8607981cc926f3a2b0e9362933797c", + "typeString": "literal_string \"The caller of this function can only be a lending pool\"" + } + ], + "id": 9926, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1712:7:51", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 9934, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1712:149:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9935, + "nodeType": "ExpressionStatement", + "src": "1712:149:51" + }, + { + "id": 9936, + "nodeType": "PlaceholderStatement", + "src": "1871:1:51" + } + ] + }, + "documentation": null, + "id": 9938, + "name": "onlyLendingPool", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 9925, + "nodeType": "ParameterList", + "parameters": [], + "src": "1702:0:51" + }, + "src": "1677:202:51", + "visibility": "internal" + }, + { + "body": { + "id": 9953, + "nodeType": "Block", + "src": "1945:101:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9946, + "name": "_from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9940, + "src": "1981:5:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 9947, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9942, + "src": "1988:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9945, + "name": "isTransferAllowed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10285, + "src": "1963:17:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,uint256) view returns (bool)" + } + }, + "id": 9948, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1963:33:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5472616e736665722063616e6e6f7420626520616c6c6f7765642e", + "id": 9949, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1998:29:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_98d6e8a9ecd35361644ac3724939e9463b2ca9166b9de58ad5770d9cfc551ff1", + "typeString": "literal_string \"Transfer cannot be allowed.\"" + }, + "value": "Transfer cannot be allowed." + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_98d6e8a9ecd35361644ac3724939e9463b2ca9166b9de58ad5770d9cfc551ff1", + "typeString": "literal_string \"Transfer cannot be allowed.\"" + } + ], + "id": 9944, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1955:7:51", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 9950, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1955:73:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9951, + "nodeType": "ExpressionStatement", + "src": "1955:73:51" + }, + { + "id": 9952, + "nodeType": "PlaceholderStatement", + "src": "2038:1:51" + } + ] + }, + "documentation": null, + "id": 9954, + "name": "whenTranferAllowed", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 9943, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9940, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9954, + "src": "1913:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9939, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1913:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9942, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 9954, + "src": "1928:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9941, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1928:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1912:32:51" + }, + "src": "1885:161:51", + "visibility": "internal" + }, + { + "body": { + "id": 10000, + "nodeType": "Block", + "src": "2374:290:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9978, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9976, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9922, + "src": "2384:17:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9977, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9956, + "src": "2404:18:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "2384:38:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9979, + "nodeType": "ExpressionStatement", + "src": "2384:38:51" + }, + { + "expression": { + "argumentTypes": null, + "id": 9986, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9980, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9924, + "src": "2432:4:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9982, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9922, + "src": "2455:17:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9983, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "2455:36:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 9984, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2455:38:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 9981, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "2439:15:51", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 9985, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2439:55:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "src": "2432:62:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 9987, + "nodeType": "ExpressionStatement", + "src": "2432:62:51" + }, + { + "expression": { + "argumentTypes": null, + "id": 9990, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9988, + "name": "initialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9920, + "src": "2504:19:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9989, + "name": "_initialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9968, + "src": "2526:20:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2504:42:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9991, + "nodeType": "ExpressionStatement", + "src": "2504:42:51" + }, + { + "expression": { + "argumentTypes": null, + "id": 9994, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9992, + "name": "underlyingAssetAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9916, + "src": "2556:22:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9993, + "name": "_underlyingAsset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9958, + "src": "2581:16:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "2556:41:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 9995, + "nodeType": "ExpressionStatement", + "src": "2556:41:51" + }, + { + "expression": { + "argumentTypes": null, + "id": 9998, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9996, + "name": "underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9918, + "src": "2607:23:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9997, + "name": "_underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9960, + "src": "2633:24:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2607:50:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9999, + "nodeType": "ExpressionStatement", + "src": "2607:50:51" + } + ] + }, + "documentation": null, + "id": 10001, + "implemented": true, + "kind": "constructor", + "modifiers": [ + { + "arguments": [ + { + "argumentTypes": null, + "id": 9971, + "name": "_name", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9962, + "src": "2347:5:51", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "id": 9972, + "name": "_symbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9964, + "src": "2354:7:51", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "id": 9973, + "name": "_decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9966, + "src": "2363:9:51", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + } + ], + "id": 9974, + "modifierName": { + "argumentTypes": null, + "id": 9970, + "name": "ERC20Detailed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11717, + "src": "2333:13:51", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ERC20Detailed_$11717_$", + "typeString": "type(contract ERC20Detailed)" + } + }, + "nodeType": "ModifierInvocation", + "src": "2333:40:51" + } + ], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9969, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9956, + "name": "_addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2073:47:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 9955, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "2073:28:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9958, + "name": "_underlyingAsset", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2130:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9957, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2130:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9960, + "name": "_underlyingAssetDecimals", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2164:32:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9959, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2164:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9962, + "name": "_name", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2206:19:51", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 9961, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "2206:6:51", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9964, + "name": "_symbol", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2235:21:51", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 9963, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "2235:6:51", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9966, + "name": "_decimals", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2266:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + }, + "typeName": { + "id": 9965, + "name": "uint8", + "nodeType": "ElementaryTypeName", + "src": "2266:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9968, + "name": "_initialExchangeRate", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2291:28:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9967, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2291:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2063:262:51" + }, + "returnParameters": { + "id": 9975, + "nodeType": "ParameterList", + "parameters": [], + "src": "2374:0:51" + }, + "scope": 10327, + "src": "2052:612:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10037, + "nodeType": "Block", + "src": "2978:170:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10017, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10003, + "src": "3004:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10018, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10005, + "src": "3010:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10019, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10007, + "src": "3014:6:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10014, + "name": "super", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12223, + "src": "2988:5:51", + "typeDescriptions": { + "typeIdentifier": "t_super$_AToken_$10327", + "typeString": "contract super AToken" + } + }, + "id": 10016, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "_transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": 11500, + "src": "2988:15:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256)" + } + }, + "id": 10020, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2988:33:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10021, + "nodeType": "ExpressionStatement", + "src": "2988:33:51" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10023, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10003, + "src": "3052:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10024, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10005, + "src": "3058:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10025, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10007, + "src": "3062:6:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10027, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10007, + "src": "3101:6:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10026, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "3070:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10028, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3070:38:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10030, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10003, + "src": "3120:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10029, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "3110:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10031, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3110:15:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10033, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10005, + "src": "3137:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10032, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "3127:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10034, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3127:13:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10022, + "name": "BalanceTransfer", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9914, + "src": "3036:15:51", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256,uint256,uint256)" + } + }, + "id": 10035, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3036:105:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10036, + "nodeType": "EmitStatement", + "src": "3031:110:51" + } + ] + }, + "documentation": "@notice ERC20 implementation internal function backing transfer() and transferFrom()\n@dev validates the transfer before allowing it. NOTE: This is not standard ERC20 behavior", + "id": 10038, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": [ + { + "argumentTypes": null, + "id": 10010, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10003, + "src": "2964:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10011, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10007, + "src": "2970:6:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 10012, + "modifierName": { + "argumentTypes": null, + "id": 10009, + "name": "whenTranferAllowed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9954, + "src": "2945:18:51", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$_t_uint256_$", + "typeString": "modifier (address,uint256)" + } + }, + "nodeType": "ModifierInvocation", + "src": "2945:32:51" + } + ], + "name": "_transfer", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10008, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10003, + "name": "from", + "nodeType": "VariableDeclaration", + "scope": 10038, + "src": "2894:12:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10002, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2894:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10005, + "name": "to", + "nodeType": "VariableDeclaration", + "scope": 10038, + "src": "2908:10:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10004, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2908:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10007, + "name": "amount", + "nodeType": "VariableDeclaration", + "scope": 10038, + "src": "2920:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10006, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2920:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2893:42:51" + }, + "returnParameters": { + "id": 10013, + "nodeType": "ParameterList", + "parameters": [], + "src": "2978:0:51" + }, + "scope": 10327, + "src": "2875:273:51", + "stateMutability": "nonpayable", + "superFunction": 11500, + "visibility": "internal" + }, + { + "body": { + "id": 10088, + "nodeType": "Block", + "src": "3307:556:51", + "statements": [ + { + "assignments": [ + 10049 + ], + "declarations": [ + { + "constant": false, + "id": 10049, + "name": "underlyingAmountToRedeem", + "nodeType": "VariableDeclaration", + "scope": 10088, + "src": "3359:32:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10048, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3359:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10053, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10051, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10040, + "src": "3425:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10050, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "3394:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10052, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3394:39:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3359:74:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10055, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "3524:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10056, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3524:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 10057, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10040, + "src": "3536:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10054, + "name": "burnOnRedeemInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10326, + "src": "3503:20:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 10058, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3503:41:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10059, + "nodeType": "ExpressionStatement", + "src": "3503:41:51" + }, + { + "assignments": [ + 10061 + ], + "declarations": [ + { + "constant": false, + "id": 10061, + "name": "pool", + "nodeType": "VariableDeclaration", + "scope": 10088, + "src": "3606:16:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPool_$4094", + "typeString": "contract LendingPool" + }, + "typeName": { + "contractScope": null, + "id": 10060, + "name": "LendingPool", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 4094, + "src": "3606:11:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPool_$4094", + "typeString": "contract LendingPool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10067, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 10063, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9922, + "src": "3637:17:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 10064, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPool", + "nodeType": "MemberAccess", + "referencedDeclaration": 1058, + "src": "3637:32:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 10065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3637:34:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10062, + "name": "LendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4094, + "src": "3625:11:51", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPool_$4094_$", + "typeString": "type(contract LendingPool)" + } + }, + "id": 10066, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3625:47:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPool_$4094", + "typeString": "contract LendingPool" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3606:66:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10071, + "name": "underlyingAssetAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9916, + "src": "3704:22:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10072, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "3728:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10073, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3728:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 10074, + "name": "underlyingAmountToRedeem", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10049, + "src": "3740:24:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10068, + "name": "pool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10061, + "src": "3682:4:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPool_$4094", + "typeString": "contract LendingPool" + } + }, + "id": 10070, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "redeemUnderlying", + "nodeType": "MemberAccess", + "referencedDeclaration": 2596, + "src": "3682:21:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) external" + } + }, + "id": 10075, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3682:83:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10076, + "nodeType": "ExpressionStatement", + "src": "3682:83:51" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10078, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "3787:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10079, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3787:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 10080, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10040, + "src": "3799:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 10081, + "name": "underlyingAmountToRedeem", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10049, + "src": "3808:24:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10083, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "3844:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10084, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3844:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 10082, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "3834:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10085, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3834:21:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10077, + "name": "Redeem", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9866, + "src": "3780:6:51", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256,uint256)" + } + }, + "id": 10086, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3780:76:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10087, + "nodeType": "EmitStatement", + "src": "3775:81:51" + } + ] + }, + "documentation": "@notice redeems aToken for the undelying asset.", + "id": 10089, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10043, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "3286:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10044, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3286:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 10045, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10040, + "src": "3298:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 10046, + "modifierName": { + "argumentTypes": null, + "id": 10042, + "name": "whenTranferAllowed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9954, + "src": "3267:18:51", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$_t_uint256_$", + "typeString": "modifier (address,uint256)" + } + }, + "nodeType": "ModifierInvocation", + "src": "3267:39:51" + } + ], + "name": "redeem", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10041, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10040, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 10089, + "src": "3241:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10039, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3241:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3240:17:51" + }, + "returnParameters": { + "id": 10047, + "nodeType": "ParameterList", + "parameters": [], + "src": "3307:0:51" + }, + "scope": 10327, + "src": "3225:638:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 10118, + "nodeType": "Block", + "src": "4135:224:51", + "statements": [ + { + "assignments": [ + 10099 + ], + "declarations": [ + { + "constant": false, + "id": 10099, + "name": "aTokensToMint", + "nodeType": "VariableDeclaration", + "scope": 10118, + "src": "4145:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10098, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4145:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10103, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10101, + "name": "_underlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10093, + "src": "4200:17:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10100, + "name": "underlyingAmountToATokenAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10313, + "src": "4169:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10102, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4169:49:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4145:73:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10105, + "name": "_account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10091, + "src": "4235:8:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10106, + "name": "aTokensToMint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10099, + "src": "4245:13:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10104, + "name": "_mint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11543, + "src": "4229:5:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 10107, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4229:30:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10108, + "nodeType": "ExpressionStatement", + "src": "4229:30:51" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10110, + "name": "_account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10091, + "src": "4288:8:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10111, + "name": "aTokensToMint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10099, + "src": "4298:13:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 10112, + "name": "_underlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10093, + "src": "4313:17:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10114, + "name": "_account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10091, + "src": "4342:8:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10113, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "4332:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10115, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4332:19:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10109, + "name": "MintOnDeposit", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9876, + "src": "4274:13:51", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256,uint256)" + } + }, + "id": 10116, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4274:78:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10117, + "nodeType": "EmitStatement", + "src": "4269:83:51" + } + ] + }, + "documentation": "@notice mints token in the event of users depositing the underlying asset into the lending pool\n@dev only lending pools can call this function", + "id": 10119, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 10096, + "modifierName": { + "argumentTypes": null, + "id": 10095, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9938, + "src": "4119:15:51", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4119:15:51" + } + ], + "name": "mintOnDeposit", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10094, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10091, + "name": "_account", + "nodeType": "VariableDeclaration", + "scope": 10119, + "src": "4065:16:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10090, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4065:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10093, + "name": "_underlyingAmount", + "nodeType": "VariableDeclaration", + "scope": 10119, + "src": "4083:25:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10092, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4083:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4064:45:51" + }, + "returnParameters": { + "id": 10097, + "nodeType": "ParameterList", + "parameters": [], + "src": "4135:0:51" + }, + "scope": 10327, + "src": "4042:317:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 10144, + "nodeType": "Block", + "src": "4640:145:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10129, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10121, + "src": "4656:7:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10130, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10123, + "src": "4665:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10128, + "name": "_burn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11587, + "src": "4650:5:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 10131, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4650:21:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10132, + "nodeType": "ExpressionStatement", + "src": "4650:21:51" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10134, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10121, + "src": "4704:7:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10135, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10123, + "src": "4713:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10137, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10123, + "src": "4751:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10136, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "4720:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10138, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4720:37:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10140, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10121, + "src": "4769:7:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10139, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "4759:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10141, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4759:18:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10133, + "name": "BurnOnLiquidation", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9886, + "src": "4686:17:51", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256,uint256)" + } + }, + "id": 10142, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4686:92:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10143, + "nodeType": "EmitStatement", + "src": "4681:97:51" + } + ] + }, + "documentation": "@dev burns token in the event of a borrow being liquidated, in case the liquidators reclaims the underlying asset\n@dev only lending pools can call this function", + "id": 10145, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 10126, + "modifierName": { + "argumentTypes": null, + "id": 10125, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9938, + "src": "4624:15:51", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4624:15:51" + } + ], + "name": "burnOnLiquidation", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10124, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10121, + "name": "account", + "nodeType": "VariableDeclaration", + "scope": 10145, + "src": "4583:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10120, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4583:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10123, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 10145, + "src": "4600:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10122, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4600:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4582:32:51" + }, + "returnParameters": { + "id": 10127, + "nodeType": "ParameterList", + "parameters": [], + "src": "4640:0:51" + }, + "scope": 10327, + "src": "4556:229:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 10179, + "nodeType": "Block", + "src": "5074:173:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10159, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10147, + "src": "5100:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10160, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10149, + "src": "5106:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10161, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10151, + "src": "5110:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10156, + "name": "super", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12223, + "src": "5084:5:51", + "typeDescriptions": { + "typeIdentifier": "t_super$_AToken_$10327", + "typeString": "contract super AToken" + } + }, + "id": 10158, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "_transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": 11500, + "src": "5084:15:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256)" + } + }, + "id": 10162, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5084:32:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10163, + "nodeType": "ExpressionStatement", + "src": "5084:32:51" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10165, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10147, + "src": "5153:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10166, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10149, + "src": "5159:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10167, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10151, + "src": "5163:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10169, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10151, + "src": "5201:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10168, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "5170:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10170, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5170:37:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10172, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10147, + "src": "5219:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10171, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "5209:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10173, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5209:15:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10175, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10149, + "src": "5236:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10174, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "5226:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10176, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5226:13:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10164, + "name": "TransferOnLiquidation", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9900, + "src": "5131:21:51", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256,uint256,uint256)" + } + }, + "id": 10177, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5131:109:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10178, + "nodeType": "EmitStatement", + "src": "5126:114:51" + } + ] + }, + "documentation": "@dev transfers tokens in the event of a borrow being liquidated, in case the liquidators reclaims the aToken\n@dev only lending pools can call this function", + "id": 10180, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 10154, + "modifierName": { + "argumentTypes": null, + "id": 10153, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9938, + "src": "5058:15:51", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5058:15:51" + } + ], + "name": "transferOnLiquidation", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10152, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10147, + "name": "from", + "nodeType": "VariableDeclaration", + "scope": 10180, + "src": "5008:12:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10146, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5008:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10149, + "name": "to", + "nodeType": "VariableDeclaration", + "scope": 10180, + "src": "5022:10:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10148, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5022:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10151, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 10180, + "src": "5034:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10150, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5034:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5007:41:51" + }, + "returnParameters": { + "id": 10155, + "nodeType": "ParameterList", + "parameters": [], + "src": "5074:0:51" + }, + "scope": 10327, + "src": "4977:270:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 10197, + "nodeType": "Block", + "src": "5402:197:51", + "statements": [ + { + "assignments": [ + 10186 + ], + "declarations": [ + { + "constant": false, + "id": 10186, + "name": "currentNormalizedCumulatedInterest", + "nodeType": "VariableDeclaration", + "scope": 10197, + "src": "5412:42:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10185, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5412:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10191, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10189, + "name": "underlyingAssetAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9916, + "src": "5489:22:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 10187, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9924, + "src": "5457:4:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 10188, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveNormalizedIncome", + "nodeType": "MemberAccess", + "referencedDeclaration": 5521, + "src": "5457:31:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 10190, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5457:55:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5412:100:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10194, + "name": "currentNormalizedCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10186, + "src": "5557:34:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10192, + "name": "initialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9920, + "src": "5530:19:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10193, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "5530:26:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10195, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5530:62:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 10184, + "id": 10196, + "nodeType": "Return", + "src": "5523:69:51" + } + ] + }, + "documentation": "@dev returns the exchange rate of the aToken to the underlying asset", + "id": 10198, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getExchangeRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10181, + "nodeType": "ParameterList", + "parameters": [], + "src": "5369:2:51" + }, + "returnParameters": { + "id": 10184, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10183, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10198, + "src": "5393:7:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10182, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5393:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5392:9:51" + }, + "scope": 10327, + "src": "5345:254:51", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10211, + "nodeType": "Block", + "src": "5679:72:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10207, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10200, + "src": "5737:5:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10206, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "5727:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10208, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5727:16:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10205, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "5696:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10209, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5696:48:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 10204, + "id": 10210, + "nodeType": "Return", + "src": "5689:55:51" + } + ] + }, + "documentation": null, + "id": 10212, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "balanceOfUnderlying", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10201, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10200, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 10212, + "src": "5634:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10199, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5634:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5633:15:51" + }, + "returnParameters": { + "id": 10204, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10203, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10212, + "src": "5670:7:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10202, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5670:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5669:9:51" + }, + "scope": 10327, + "src": "5605:146:51", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10253, + "nodeType": "Block", + "src": "5844:354:51", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 10221, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 10219, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10214, + "src": "5858:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 10220, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5869:1:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "5858:12:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 10225, + "nodeType": "IfStatement", + "src": "5854:78:51", + "trueBody": { + "id": 10224, + "nodeType": "Block", + "src": "5872:60:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 10222, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5920:1:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 10218, + "id": 10223, + "nodeType": "Return", + "src": "5913:8:51" + } + ] + } + }, + { + "assignments": [ + 10227 + ], + "declarations": [ + { + "constant": false, + "id": 10227, + "name": "overlyingDecimals", + "nodeType": "VariableDeclaration", + "scope": 10253, + "src": "5942:25:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10226, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5942:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10234, + "initialValue": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 10233, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "3130", + "id": 10228, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5970:2:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_10_by_1", + "typeString": "int_const 10" + }, + "value": "10" + }, + "nodeType": "BinaryOperation", + "operator": "**", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 10230, + "name": "decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11716, + "src": "5984:8:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_uint8_$", + "typeString": "function () view returns (uint8)" + } + }, + "id": 10231, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5984:10:51", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + ], + "id": 10229, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "5976:7:51", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 10232, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5976:19:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5970:25:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5942:53:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10248, + "name": "overlyingDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10227, + "src": "6149:17:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 10245, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "3130", + "id": 10243, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6101:2:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_10_by_1", + "typeString": "int_const 10" + }, + "value": "10" + }, + "nodeType": "BinaryOperation", + "operator": "**", + "rightExpression": { + "argumentTypes": null, + "id": 10244, + "name": "underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9918, + "src": "6107:23:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6101:29:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 10239, + "name": "getExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10198, + "src": "6065:15:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_uint256_$", + "typeString": "function () view returns (uint256)" + } + }, + "id": 10240, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6065:17:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 10235, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10214, + "src": "6013:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10236, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "6013:29:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 10237, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6013:31:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10238, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "6013:51:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10241, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6013:70:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10242, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "6013:87:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10246, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6013:118:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10247, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "6013:135:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10249, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6013:154:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10250, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayToWad", + "nodeType": "MemberAccess", + "referencedDeclaration": 9160, + "src": "6013:176:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 10251, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6013:178:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 10218, + "id": 10252, + "nodeType": "Return", + "src": "6006:185:51" + } + ] + }, + "documentation": null, + "id": 10254, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10215, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10214, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 10254, + "src": "5797:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10213, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5797:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5796:17:51" + }, + "returnParameters": { + "id": 10218, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10217, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10254, + "src": "5835:7:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10216, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5835:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5834:9:51" + }, + "scope": 10327, + "src": "5757:441:51", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10284, + "nodeType": "Block", + "src": "6381:304:51", + "statements": [ + { + "assignments": [ + 10264 + ], + "declarations": [ + { + "constant": false, + "id": 10264, + "name": "dataProvider", + "nodeType": "VariableDeclaration", + "scope": 10284, + "src": "6391:36:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + }, + "typeName": { + "contractScope": null, + "id": 10263, + "name": "LendingPoolDataProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 7660, + "src": "6391:23:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10270, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 10266, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9922, + "src": "6454:17:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 10267, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolDataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1191, + "src": "6454:44:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 10268, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6454:46:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10265, + "name": "LendingPoolDataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7660, + "src": "6430:23:51", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolDataProvider_$7660_$", + "typeString": "type(contract LendingPoolDataProvider)" + } + }, + "id": 10269, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6430:71:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6391:110:51" + }, + { + "assignments": [ + 10272 + ], + "declarations": [ + { + "constant": false, + "id": 10272, + "name": "amountUnderlying", + "nodeType": "VariableDeclaration", + "scope": 10284, + "src": "6511:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10271, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6511:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10276, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10274, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10258, + "src": "6569:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10273, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "6538:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10275, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6538:39:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6511:66:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10279, + "name": "underlyingAssetAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9916, + "src": "6630:22:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10280, + "name": "_from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10256, + "src": "6654:5:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10281, + "name": "amountUnderlying", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10272, + "src": "6661:16:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10277, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10264, + "src": "6594:12:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 10278, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceDecreaseAllowed", + "nodeType": "MemberAccess", + "referencedDeclaration": 7168, + "src": "6594:35:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,address,uint256) view external returns (bool)" + } + }, + "id": 10282, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6594:84:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 10262, + "id": 10283, + "nodeType": "Return", + "src": "6587:91:51" + } + ] + }, + "documentation": "@notice Used to validate transfers before actually executing them.*", + "id": 10285, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isTransferAllowed", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10259, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10256, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 10285, + "src": "6322:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10255, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6322:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10258, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 10285, + "src": "6337:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10257, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6337:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6321:32:51" + }, + "returnParameters": { + "id": 10262, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10261, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10285, + "src": "6375:4:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 10260, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "6375:4:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6374:6:51" + }, + "scope": 10327, + "src": "6295:390:51", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10312, + "nodeType": "Block", + "src": "6778:188:51", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 10294, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 10292, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10287, + "src": "6792:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 10293, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6803:1:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "6792:12:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 10298, + "nodeType": "IfStatement", + "src": "6788:78:51", + "trueBody": { + "id": 10297, + "nodeType": "Block", + "src": "6806:60:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 10295, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6854:1:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 10291, + "id": 10296, + "nodeType": "Return", + "src": "6847:8:51" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 10307, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "3130", + "id": 10305, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6918:2:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_10_by_1", + "typeString": "int_const 10" + }, + "value": "10" + }, + "nodeType": "BinaryOperation", + "operator": "**", + "rightExpression": { + "argumentTypes": null, + "id": 10306, + "name": "underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9918, + "src": "6924:23:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6918:29:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 10301, + "name": "getExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10198, + "src": "6895:15:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_uint256_$", + "typeString": "function () view returns (uint256)" + } + }, + "id": 10302, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6895:17:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10299, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10287, + "src": "6883:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10300, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "6883:11:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10303, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6883:30:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10304, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "6883:34:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10308, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6883:65:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10309, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayToWad", + "nodeType": "MemberAccess", + "referencedDeclaration": 9160, + "src": "6883:74:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 10310, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6883:76:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 10291, + "id": 10311, + "nodeType": "Return", + "src": "6876:83:51" + } + ] + }, + "documentation": null, + "id": 10313, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "underlyingAmountToATokenAmount", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10288, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10287, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 10313, + "src": "6731:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10286, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6731:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6730:17:51" + }, + "returnParameters": { + "id": 10291, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10290, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10313, + "src": "6769:7:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10289, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6769:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6768:9:51" + }, + "scope": 10327, + "src": "6691:275:51", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10325, + "nodeType": "Block", + "src": "7212:38:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10321, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10315, + "src": "7228:7:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10322, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10317, + "src": "7237:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10320, + "name": "_burn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11587, + "src": "7222:5:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 10323, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7222:21:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10324, + "nodeType": "ExpressionStatement", + "src": "7222:21:51" + } + ] + }, + "documentation": "@dev burns token in the event of users redeeming the underlying asset from the lending pool\n@dev only lending pools can call this function", + "id": 10326, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "burnOnRedeemInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10318, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10315, + "name": "account", + "nodeType": "VariableDeclaration", + "scope": 10326, + "src": "7171:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10314, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7171:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10317, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 10326, + "src": "7188:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10316, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7188:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7170:32:51" + }, + "returnParameters": { + "id": 10319, + "nodeType": "ParameterList", + "parameters": [], + "src": "7212:0:51" + }, + "scope": 10327, + "src": "7141:109:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 10328, + "src": "574:6678:51" + } + ], + "src": "0:7253:51" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "exportedSymbols": { + "AToken": [ + 10327 + ] + }, + "id": 10328, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9841, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:51" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 9842, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 11141, + "src": "25:59:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "id": 9843, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 11660, + "src": "85:63:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "id": 9844, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 11718, + "src": "149:71:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 9845, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 1358, + "src": "222:59:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol", + "file": "../lendingpool/LendingPool.sol", + "id": 9846, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 4095, + "src": "282:40:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol", + "file": "../lendingpool/LendingPoolDataProvider.sol", + "id": 9847, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 7661, + "src": "323:52:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "../lendingpool/LendingPoolCore.sol", + "id": 9848, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 6683, + "src": "376:44:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 9849, + "nodeType": "ImportDirective", + "scope": 10328, + "sourceUnit": 9175, + "src": "421:37:51", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9850, + "name": "ERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11659, + "src": "593:5:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + }, + "id": 9851, + "nodeType": "InheritanceSpecifier", + "src": "593:5:51" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9852, + "name": "ERC20Detailed", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11717, + "src": "600:13:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + } + }, + "id": 9853, + "nodeType": "InheritanceSpecifier", + "src": "600:13:51" + } + ], + "contractDependencies": [ + 10953, + 11659, + 11717, + 11786 + ], + "contractKind": "contract", + "documentation": "@title Aave ERC20 AToken\n * @dev Implementation of the interest bearing token for the DLP protocol.", + "fullyImplemented": true, + "id": 10327, + "linearizedBaseContracts": [ + 10327, + 11717, + 11659, + 11786, + 10953 + ], + "name": "AToken", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 9856, + "libraryName": { + "contractScope": null, + "id": 9854, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "626:10:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "620:29:51", + "typeName": { + "id": 9855, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "641:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "anonymous": false, + "documentation": null, + "id": 9866, + "name": "Redeem", + "nodeType": "EventDefinition", + "parameters": { + "id": 9865, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9858, + "indexed": true, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9866, + "src": "677:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9857, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "677:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9860, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 9866, + "src": "708:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9859, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "708:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9862, + "indexed": false, + "name": "_underlyingValue", + "nodeType": "VariableDeclaration", + "scope": 9866, + "src": "732:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9861, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "732:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9864, + "indexed": false, + "name": "_fromBalance", + "nodeType": "VariableDeclaration", + "scope": 9866, + "src": "766:20:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9863, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "766:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "667:125:51" + }, + "src": "655:138:51" + }, + { + "anonymous": false, + "documentation": null, + "id": 9876, + "name": "MintOnDeposit", + "nodeType": "EventDefinition", + "parameters": { + "id": 9875, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9868, + "indexed": true, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9876, + "src": "819:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9867, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "819:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9870, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 9876, + "src": "842:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9869, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "842:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9872, + "indexed": false, + "name": "_underlyingValue", + "nodeType": "VariableDeclaration", + "scope": 9876, + "src": "858:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9871, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "858:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9874, + "indexed": false, + "name": "_fromBalance", + "nodeType": "VariableDeclaration", + "scope": 9876, + "src": "884:20:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9873, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "884:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "818:87:51" + }, + "src": "799:107:51" + }, + { + "anonymous": false, + "documentation": null, + "id": 9886, + "name": "BurnOnLiquidation", + "nodeType": "EventDefinition", + "parameters": { + "id": 9885, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9878, + "indexed": true, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9886, + "src": "935:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9877, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "935:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9880, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 9886, + "src": "958:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9879, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "958:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9882, + "indexed": false, + "name": "_underlyingValue", + "nodeType": "VariableDeclaration", + "scope": 9886, + "src": "974:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9881, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "974:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9884, + "indexed": false, + "name": "_fromBalance", + "nodeType": "VariableDeclaration", + "scope": 9886, + "src": "1000:20:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9883, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1000:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "934:87:51" + }, + "src": "911:111:51" + }, + { + "anonymous": false, + "documentation": null, + "id": 9900, + "name": "TransferOnLiquidation", + "nodeType": "EventDefinition", + "parameters": { + "id": 9899, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9888, + "indexed": true, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1064:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9887, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1064:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9890, + "indexed": true, + "name": "_to", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1095:19:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9889, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1095:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9892, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1124:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9891, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1124:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9894, + "indexed": false, + "name": "_underlyingValue", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1148:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9893, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1148:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9896, + "indexed": false, + "name": "_fromBalance", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1182:20:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9895, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1182:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9898, + "indexed": false, + "name": "_toBalance", + "nodeType": "VariableDeclaration", + "scope": 9900, + "src": "1212:18:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9897, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1212:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1054:182:51" + }, + "src": "1027:210:51" + }, + { + "anonymous": false, + "documentation": null, + "id": 9914, + "name": "BalanceTransfer", + "nodeType": "EventDefinition", + "parameters": { + "id": 9913, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9902, + "indexed": true, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1275:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9901, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1275:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9904, + "indexed": true, + "name": "_to", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1306:19:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9903, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1306:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9906, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1335:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9905, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1335:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9908, + "indexed": false, + "name": "_underlyingValue", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1359:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9907, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1359:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9910, + "indexed": false, + "name": "_fromBalance", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1393:20:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9909, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1393:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9912, + "indexed": false, + "name": "_toBalance", + "nodeType": "VariableDeclaration", + "scope": 9914, + "src": "1423:18:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9911, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1423:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1265:182:51" + }, + "src": "1244:204:51" + }, + { + "constant": false, + "id": 9916, + "name": "underlyingAssetAddress", + "nodeType": "VariableDeclaration", + "scope": 10327, + "src": "1454:37:51", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9915, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1454:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": false, + "id": 9918, + "name": "underlyingAssetDecimals", + "nodeType": "VariableDeclaration", + "scope": 10327, + "src": "1497:38:51", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9917, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1497:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": false, + "id": 9920, + "name": "initialExchangeRate", + "nodeType": "VariableDeclaration", + "scope": 10327, + "src": "1541:34:51", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9919, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1541:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": false, + "id": 9922, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 10327, + "src": "1582:54:51", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 9921, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1582:28:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "private" + }, + { + "constant": false, + "id": 9924, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 10327, + "src": "1642:28:51", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 9923, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "1642:15:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "private" + }, + { + "body": { + "id": 9937, + "nodeType": "Block", + "src": "1702:177:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 9932, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 9927, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "1733:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 9928, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1733:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9929, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9922, + "src": "1747:17:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9930, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPool", + "nodeType": "MemberAccess", + "referencedDeclaration": 1058, + "src": "1747:32:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 9931, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1747:34:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1733:48:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206f6620746869732066756e6374696f6e2063616e206f6e6c792062652061206c656e64696e6720706f6f6c", + "id": 9933, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1795:56:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_93ed9b25aafeea7e49d0f8673c2cc037db8607981cc926f3a2b0e9362933797c", + "typeString": "literal_string \"The caller of this function can only be a lending pool\"" + }, + "value": "The caller of this function can only be a lending pool" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_93ed9b25aafeea7e49d0f8673c2cc037db8607981cc926f3a2b0e9362933797c", + "typeString": "literal_string \"The caller of this function can only be a lending pool\"" + } + ], + "id": 9926, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1712:7:51", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 9934, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1712:149:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9935, + "nodeType": "ExpressionStatement", + "src": "1712:149:51" + }, + { + "id": 9936, + "nodeType": "PlaceholderStatement", + "src": "1871:1:51" + } + ] + }, + "documentation": null, + "id": 9938, + "name": "onlyLendingPool", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 9925, + "nodeType": "ParameterList", + "parameters": [], + "src": "1702:0:51" + }, + "src": "1677:202:51", + "visibility": "internal" + }, + { + "body": { + "id": 9953, + "nodeType": "Block", + "src": "1945:101:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9946, + "name": "_from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9940, + "src": "1981:5:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 9947, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9942, + "src": "1988:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9945, + "name": "isTransferAllowed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10285, + "src": "1963:17:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,uint256) view returns (bool)" + } + }, + "id": 9948, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1963:33:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5472616e736665722063616e6e6f7420626520616c6c6f7765642e", + "id": 9949, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1998:29:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_98d6e8a9ecd35361644ac3724939e9463b2ca9166b9de58ad5770d9cfc551ff1", + "typeString": "literal_string \"Transfer cannot be allowed.\"" + }, + "value": "Transfer cannot be allowed." + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_98d6e8a9ecd35361644ac3724939e9463b2ca9166b9de58ad5770d9cfc551ff1", + "typeString": "literal_string \"Transfer cannot be allowed.\"" + } + ], + "id": 9944, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1955:7:51", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 9950, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1955:73:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9951, + "nodeType": "ExpressionStatement", + "src": "1955:73:51" + }, + { + "id": 9952, + "nodeType": "PlaceholderStatement", + "src": "2038:1:51" + } + ] + }, + "documentation": null, + "id": 9954, + "name": "whenTranferAllowed", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 9943, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9940, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 9954, + "src": "1913:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9939, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1913:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9942, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 9954, + "src": "1928:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9941, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1928:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1912:32:51" + }, + "src": "1885:161:51", + "visibility": "internal" + }, + { + "body": { + "id": 10000, + "nodeType": "Block", + "src": "2374:290:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9978, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9976, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9922, + "src": "2384:17:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9977, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9956, + "src": "2404:18:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "2384:38:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9979, + "nodeType": "ExpressionStatement", + "src": "2384:38:51" + }, + { + "expression": { + "argumentTypes": null, + "id": 9986, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9980, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9924, + "src": "2432:4:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9982, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9922, + "src": "2455:17:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9983, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "2455:36:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 9984, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2455:38:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 9981, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "2439:15:51", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 9985, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2439:55:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "src": "2432:62:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 9987, + "nodeType": "ExpressionStatement", + "src": "2432:62:51" + }, + { + "expression": { + "argumentTypes": null, + "id": 9990, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9988, + "name": "initialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9920, + "src": "2504:19:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9989, + "name": "_initialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9968, + "src": "2526:20:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2504:42:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9991, + "nodeType": "ExpressionStatement", + "src": "2504:42:51" + }, + { + "expression": { + "argumentTypes": null, + "id": 9994, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9992, + "name": "underlyingAssetAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9916, + "src": "2556:22:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9993, + "name": "_underlyingAsset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9958, + "src": "2581:16:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "2556:41:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 9995, + "nodeType": "ExpressionStatement", + "src": "2556:41:51" + }, + { + "expression": { + "argumentTypes": null, + "id": 9998, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9996, + "name": "underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9918, + "src": "2607:23:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9997, + "name": "_underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9960, + "src": "2633:24:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2607:50:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9999, + "nodeType": "ExpressionStatement", + "src": "2607:50:51" + } + ] + }, + "documentation": null, + "id": 10001, + "implemented": true, + "kind": "constructor", + "modifiers": [ + { + "arguments": [ + { + "argumentTypes": null, + "id": 9971, + "name": "_name", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9962, + "src": "2347:5:51", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "id": 9972, + "name": "_symbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9964, + "src": "2354:7:51", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "id": 9973, + "name": "_decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9966, + "src": "2363:9:51", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + } + ], + "id": 9974, + "modifierName": { + "argumentTypes": null, + "id": 9970, + "name": "ERC20Detailed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11717, + "src": "2333:13:51", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ERC20Detailed_$11717_$", + "typeString": "type(contract ERC20Detailed)" + } + }, + "nodeType": "ModifierInvocation", + "src": "2333:40:51" + } + ], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9969, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9956, + "name": "_addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2073:47:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 9955, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "2073:28:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9958, + "name": "_underlyingAsset", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2130:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9957, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2130:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9960, + "name": "_underlyingAssetDecimals", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2164:32:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9959, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2164:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9962, + "name": "_name", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2206:19:51", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 9961, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "2206:6:51", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9964, + "name": "_symbol", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2235:21:51", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 9963, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "2235:6:51", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9966, + "name": "_decimals", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2266:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + }, + "typeName": { + "id": 9965, + "name": "uint8", + "nodeType": "ElementaryTypeName", + "src": "2266:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9968, + "name": "_initialExchangeRate", + "nodeType": "VariableDeclaration", + "scope": 10001, + "src": "2291:28:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9967, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2291:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2063:262:51" + }, + "returnParameters": { + "id": 9975, + "nodeType": "ParameterList", + "parameters": [], + "src": "2374:0:51" + }, + "scope": 10327, + "src": "2052:612:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10037, + "nodeType": "Block", + "src": "2978:170:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10017, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10003, + "src": "3004:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10018, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10005, + "src": "3010:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10019, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10007, + "src": "3014:6:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10014, + "name": "super", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12223, + "src": "2988:5:51", + "typeDescriptions": { + "typeIdentifier": "t_super$_AToken_$10327", + "typeString": "contract super AToken" + } + }, + "id": 10016, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "_transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": 11500, + "src": "2988:15:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256)" + } + }, + "id": 10020, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2988:33:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10021, + "nodeType": "ExpressionStatement", + "src": "2988:33:51" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10023, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10003, + "src": "3052:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10024, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10005, + "src": "3058:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10025, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10007, + "src": "3062:6:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10027, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10007, + "src": "3101:6:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10026, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "3070:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10028, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3070:38:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10030, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10003, + "src": "3120:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10029, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "3110:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10031, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3110:15:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10033, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10005, + "src": "3137:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10032, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "3127:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10034, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3127:13:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10022, + "name": "BalanceTransfer", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9914, + "src": "3036:15:51", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256,uint256,uint256)" + } + }, + "id": 10035, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3036:105:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10036, + "nodeType": "EmitStatement", + "src": "3031:110:51" + } + ] + }, + "documentation": "@notice ERC20 implementation internal function backing transfer() and transferFrom()\n@dev validates the transfer before allowing it. NOTE: This is not standard ERC20 behavior", + "id": 10038, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": [ + { + "argumentTypes": null, + "id": 10010, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10003, + "src": "2964:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10011, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10007, + "src": "2970:6:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 10012, + "modifierName": { + "argumentTypes": null, + "id": 10009, + "name": "whenTranferAllowed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9954, + "src": "2945:18:51", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$_t_uint256_$", + "typeString": "modifier (address,uint256)" + } + }, + "nodeType": "ModifierInvocation", + "src": "2945:32:51" + } + ], + "name": "_transfer", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10008, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10003, + "name": "from", + "nodeType": "VariableDeclaration", + "scope": 10038, + "src": "2894:12:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10002, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2894:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10005, + "name": "to", + "nodeType": "VariableDeclaration", + "scope": 10038, + "src": "2908:10:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10004, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2908:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10007, + "name": "amount", + "nodeType": "VariableDeclaration", + "scope": 10038, + "src": "2920:14:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10006, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2920:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2893:42:51" + }, + "returnParameters": { + "id": 10013, + "nodeType": "ParameterList", + "parameters": [], + "src": "2978:0:51" + }, + "scope": 10327, + "src": "2875:273:51", + "stateMutability": "nonpayable", + "superFunction": 11500, + "visibility": "internal" + }, + { + "body": { + "id": 10088, + "nodeType": "Block", + "src": "3307:556:51", + "statements": [ + { + "assignments": [ + 10049 + ], + "declarations": [ + { + "constant": false, + "id": 10049, + "name": "underlyingAmountToRedeem", + "nodeType": "VariableDeclaration", + "scope": 10088, + "src": "3359:32:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10048, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3359:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10053, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10051, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10040, + "src": "3425:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10050, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "3394:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10052, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3394:39:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3359:74:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10055, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "3524:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10056, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3524:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 10057, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10040, + "src": "3536:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10054, + "name": "burnOnRedeemInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10326, + "src": "3503:20:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 10058, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3503:41:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10059, + "nodeType": "ExpressionStatement", + "src": "3503:41:51" + }, + { + "assignments": [ + 10061 + ], + "declarations": [ + { + "constant": false, + "id": 10061, + "name": "pool", + "nodeType": "VariableDeclaration", + "scope": 10088, + "src": "3606:16:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPool_$4094", + "typeString": "contract LendingPool" + }, + "typeName": { + "contractScope": null, + "id": 10060, + "name": "LendingPool", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 4094, + "src": "3606:11:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPool_$4094", + "typeString": "contract LendingPool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10067, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 10063, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9922, + "src": "3637:17:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 10064, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPool", + "nodeType": "MemberAccess", + "referencedDeclaration": 1058, + "src": "3637:32:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 10065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3637:34:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10062, + "name": "LendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4094, + "src": "3625:11:51", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPool_$4094_$", + "typeString": "type(contract LendingPool)" + } + }, + "id": 10066, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3625:47:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPool_$4094", + "typeString": "contract LendingPool" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3606:66:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10071, + "name": "underlyingAssetAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9916, + "src": "3704:22:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10072, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "3728:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10073, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3728:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 10074, + "name": "underlyingAmountToRedeem", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10049, + "src": "3740:24:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10068, + "name": "pool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10061, + "src": "3682:4:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPool_$4094", + "typeString": "contract LendingPool" + } + }, + "id": 10070, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "redeemUnderlying", + "nodeType": "MemberAccess", + "referencedDeclaration": 2596, + "src": "3682:21:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) external" + } + }, + "id": 10075, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3682:83:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10076, + "nodeType": "ExpressionStatement", + "src": "3682:83:51" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10078, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "3787:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10079, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3787:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 10080, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10040, + "src": "3799:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 10081, + "name": "underlyingAmountToRedeem", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10049, + "src": "3808:24:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10083, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "3844:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10084, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3844:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 10082, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "3834:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10085, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3834:21:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10077, + "name": "Redeem", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9866, + "src": "3780:6:51", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256,uint256)" + } + }, + "id": 10086, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3780:76:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10087, + "nodeType": "EmitStatement", + "src": "3775:81:51" + } + ] + }, + "documentation": "@notice redeems aToken for the undelying asset.", + "id": 10089, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10043, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "3286:3:51", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10044, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3286:10:51", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 10045, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10040, + "src": "3298:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 10046, + "modifierName": { + "argumentTypes": null, + "id": 10042, + "name": "whenTranferAllowed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9954, + "src": "3267:18:51", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$_t_uint256_$", + "typeString": "modifier (address,uint256)" + } + }, + "nodeType": "ModifierInvocation", + "src": "3267:39:51" + } + ], + "name": "redeem", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10041, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10040, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 10089, + "src": "3241:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10039, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3241:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3240:17:51" + }, + "returnParameters": { + "id": 10047, + "nodeType": "ParameterList", + "parameters": [], + "src": "3307:0:51" + }, + "scope": 10327, + "src": "3225:638:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 10118, + "nodeType": "Block", + "src": "4135:224:51", + "statements": [ + { + "assignments": [ + 10099 + ], + "declarations": [ + { + "constant": false, + "id": 10099, + "name": "aTokensToMint", + "nodeType": "VariableDeclaration", + "scope": 10118, + "src": "4145:21:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10098, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4145:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10103, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10101, + "name": "_underlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10093, + "src": "4200:17:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10100, + "name": "underlyingAmountToATokenAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10313, + "src": "4169:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10102, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4169:49:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4145:73:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10105, + "name": "_account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10091, + "src": "4235:8:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10106, + "name": "aTokensToMint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10099, + "src": "4245:13:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10104, + "name": "_mint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11543, + "src": "4229:5:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 10107, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4229:30:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10108, + "nodeType": "ExpressionStatement", + "src": "4229:30:51" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10110, + "name": "_account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10091, + "src": "4288:8:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10111, + "name": "aTokensToMint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10099, + "src": "4298:13:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 10112, + "name": "_underlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10093, + "src": "4313:17:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10114, + "name": "_account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10091, + "src": "4342:8:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10113, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "4332:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10115, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4332:19:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10109, + "name": "MintOnDeposit", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9876, + "src": "4274:13:51", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256,uint256)" + } + }, + "id": 10116, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4274:78:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10117, + "nodeType": "EmitStatement", + "src": "4269:83:51" + } + ] + }, + "documentation": "@notice mints token in the event of users depositing the underlying asset into the lending pool\n@dev only lending pools can call this function", + "id": 10119, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 10096, + "modifierName": { + "argumentTypes": null, + "id": 10095, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9938, + "src": "4119:15:51", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4119:15:51" + } + ], + "name": "mintOnDeposit", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10094, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10091, + "name": "_account", + "nodeType": "VariableDeclaration", + "scope": 10119, + "src": "4065:16:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10090, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4065:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10093, + "name": "_underlyingAmount", + "nodeType": "VariableDeclaration", + "scope": 10119, + "src": "4083:25:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10092, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4083:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4064:45:51" + }, + "returnParameters": { + "id": 10097, + "nodeType": "ParameterList", + "parameters": [], + "src": "4135:0:51" + }, + "scope": 10327, + "src": "4042:317:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 10144, + "nodeType": "Block", + "src": "4640:145:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10129, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10121, + "src": "4656:7:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10130, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10123, + "src": "4665:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10128, + "name": "_burn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11587, + "src": "4650:5:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 10131, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4650:21:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10132, + "nodeType": "ExpressionStatement", + "src": "4650:21:51" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10134, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10121, + "src": "4704:7:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10135, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10123, + "src": "4713:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10137, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10123, + "src": "4751:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10136, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "4720:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10138, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4720:37:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10140, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10121, + "src": "4769:7:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10139, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "4759:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10141, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4759:18:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10133, + "name": "BurnOnLiquidation", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9886, + "src": "4686:17:51", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256,uint256)" + } + }, + "id": 10142, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4686:92:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10143, + "nodeType": "EmitStatement", + "src": "4681:97:51" + } + ] + }, + "documentation": "@dev burns token in the event of a borrow being liquidated, in case the liquidators reclaims the underlying asset\n@dev only lending pools can call this function", + "id": 10145, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 10126, + "modifierName": { + "argumentTypes": null, + "id": 10125, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9938, + "src": "4624:15:51", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4624:15:51" + } + ], + "name": "burnOnLiquidation", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10124, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10121, + "name": "account", + "nodeType": "VariableDeclaration", + "scope": 10145, + "src": "4583:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10120, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4583:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10123, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 10145, + "src": "4600:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10122, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4600:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4582:32:51" + }, + "returnParameters": { + "id": 10127, + "nodeType": "ParameterList", + "parameters": [], + "src": "4640:0:51" + }, + "scope": 10327, + "src": "4556:229:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 10179, + "nodeType": "Block", + "src": "5074:173:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10159, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10147, + "src": "5100:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10160, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10149, + "src": "5106:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10161, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10151, + "src": "5110:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10156, + "name": "super", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12223, + "src": "5084:5:51", + "typeDescriptions": { + "typeIdentifier": "t_super$_AToken_$10327", + "typeString": "contract super AToken" + } + }, + "id": 10158, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "_transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": 11500, + "src": "5084:15:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256)" + } + }, + "id": 10162, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5084:32:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10163, + "nodeType": "ExpressionStatement", + "src": "5084:32:51" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10165, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10147, + "src": "5153:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10166, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10149, + "src": "5159:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10167, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10151, + "src": "5163:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10169, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10151, + "src": "5201:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10168, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "5170:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10170, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5170:37:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10172, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10147, + "src": "5219:4:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10171, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "5209:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10173, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5209:15:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10175, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10149, + "src": "5236:2:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10174, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "5226:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10176, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5226:13:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10164, + "name": "TransferOnLiquidation", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9900, + "src": "5131:21:51", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256,uint256,uint256)" + } + }, + "id": 10177, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5131:109:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10178, + "nodeType": "EmitStatement", + "src": "5126:114:51" + } + ] + }, + "documentation": "@dev transfers tokens in the event of a borrow being liquidated, in case the liquidators reclaims the aToken\n@dev only lending pools can call this function", + "id": 10180, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 10154, + "modifierName": { + "argumentTypes": null, + "id": 10153, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9938, + "src": "5058:15:51", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5058:15:51" + } + ], + "name": "transferOnLiquidation", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10152, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10147, + "name": "from", + "nodeType": "VariableDeclaration", + "scope": 10180, + "src": "5008:12:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10146, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5008:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10149, + "name": "to", + "nodeType": "VariableDeclaration", + "scope": 10180, + "src": "5022:10:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10148, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5022:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10151, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 10180, + "src": "5034:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10150, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5034:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5007:41:51" + }, + "returnParameters": { + "id": 10155, + "nodeType": "ParameterList", + "parameters": [], + "src": "5074:0:51" + }, + "scope": 10327, + "src": "4977:270:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 10197, + "nodeType": "Block", + "src": "5402:197:51", + "statements": [ + { + "assignments": [ + 10186 + ], + "declarations": [ + { + "constant": false, + "id": 10186, + "name": "currentNormalizedCumulatedInterest", + "nodeType": "VariableDeclaration", + "scope": 10197, + "src": "5412:42:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10185, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5412:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10191, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10189, + "name": "underlyingAssetAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9916, + "src": "5489:22:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 10187, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9924, + "src": "5457:4:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 10188, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveNormalizedIncome", + "nodeType": "MemberAccess", + "referencedDeclaration": 5521, + "src": "5457:31:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 10190, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5457:55:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5412:100:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10194, + "name": "currentNormalizedCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10186, + "src": "5557:34:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10192, + "name": "initialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9920, + "src": "5530:19:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10193, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "5530:26:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10195, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5530:62:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 10184, + "id": 10196, + "nodeType": "Return", + "src": "5523:69:51" + } + ] + }, + "documentation": "@dev returns the exchange rate of the aToken to the underlying asset", + "id": 10198, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getExchangeRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10181, + "nodeType": "ParameterList", + "parameters": [], + "src": "5369:2:51" + }, + "returnParameters": { + "id": 10184, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10183, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10198, + "src": "5393:7:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10182, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5393:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5392:9:51" + }, + "scope": 10327, + "src": "5345:254:51", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10211, + "nodeType": "Block", + "src": "5679:72:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10207, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10200, + "src": "5737:5:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10206, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11298, + "src": "5727:9:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 10208, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5727:16:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10205, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "5696:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10209, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5696:48:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 10204, + "id": 10210, + "nodeType": "Return", + "src": "5689:55:51" + } + ] + }, + "documentation": null, + "id": 10212, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "balanceOfUnderlying", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10201, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10200, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 10212, + "src": "5634:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10199, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5634:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5633:15:51" + }, + "returnParameters": { + "id": 10204, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10203, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10212, + "src": "5670:7:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10202, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5670:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5669:9:51" + }, + "scope": 10327, + "src": "5605:146:51", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10253, + "nodeType": "Block", + "src": "5844:354:51", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 10221, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 10219, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10214, + "src": "5858:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 10220, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5869:1:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "5858:12:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 10225, + "nodeType": "IfStatement", + "src": "5854:78:51", + "trueBody": { + "id": 10224, + "nodeType": "Block", + "src": "5872:60:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 10222, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5920:1:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 10218, + "id": 10223, + "nodeType": "Return", + "src": "5913:8:51" + } + ] + } + }, + { + "assignments": [ + 10227 + ], + "declarations": [ + { + "constant": false, + "id": 10227, + "name": "overlyingDecimals", + "nodeType": "VariableDeclaration", + "scope": 10253, + "src": "5942:25:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10226, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5942:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10234, + "initialValue": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 10233, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "3130", + "id": 10228, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5970:2:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_10_by_1", + "typeString": "int_const 10" + }, + "value": "10" + }, + "nodeType": "BinaryOperation", + "operator": "**", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 10230, + "name": "decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11716, + "src": "5984:8:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_uint8_$", + "typeString": "function () view returns (uint8)" + } + }, + "id": 10231, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5984:10:51", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + ], + "id": 10229, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "5976:7:51", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 10232, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5976:19:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5970:25:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5942:53:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10248, + "name": "overlyingDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10227, + "src": "6149:17:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 10245, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "3130", + "id": 10243, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6101:2:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_10_by_1", + "typeString": "int_const 10" + }, + "value": "10" + }, + "nodeType": "BinaryOperation", + "operator": "**", + "rightExpression": { + "argumentTypes": null, + "id": 10244, + "name": "underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9918, + "src": "6107:23:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6101:29:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 10239, + "name": "getExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10198, + "src": "6065:15:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_uint256_$", + "typeString": "function () view returns (uint256)" + } + }, + "id": 10240, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6065:17:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 10235, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10214, + "src": "6013:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10236, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "6013:29:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 10237, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6013:31:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10238, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "6013:51:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10241, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6013:70:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10242, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "6013:87:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10246, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6013:118:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10247, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "6013:135:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10249, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6013:154:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10250, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayToWad", + "nodeType": "MemberAccess", + "referencedDeclaration": 9160, + "src": "6013:176:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 10251, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6013:178:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 10218, + "id": 10252, + "nodeType": "Return", + "src": "6006:185:51" + } + ] + }, + "documentation": null, + "id": 10254, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10215, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10214, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 10254, + "src": "5797:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10213, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5797:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5796:17:51" + }, + "returnParameters": { + "id": 10218, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10217, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10254, + "src": "5835:7:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10216, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5835:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5834:9:51" + }, + "scope": 10327, + "src": "5757:441:51", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10284, + "nodeType": "Block", + "src": "6381:304:51", + "statements": [ + { + "assignments": [ + 10264 + ], + "declarations": [ + { + "constant": false, + "id": 10264, + "name": "dataProvider", + "nodeType": "VariableDeclaration", + "scope": 10284, + "src": "6391:36:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + }, + "typeName": { + "contractScope": null, + "id": 10263, + "name": "LendingPoolDataProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 7660, + "src": "6391:23:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10270, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 10266, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9922, + "src": "6454:17:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 10267, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolDataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1191, + "src": "6454:44:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 10268, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6454:46:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 10265, + "name": "LendingPoolDataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7660, + "src": "6430:23:51", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolDataProvider_$7660_$", + "typeString": "type(contract LendingPoolDataProvider)" + } + }, + "id": 10269, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6430:71:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6391:110:51" + }, + { + "assignments": [ + 10272 + ], + "declarations": [ + { + "constant": false, + "id": 10272, + "name": "amountUnderlying", + "nodeType": "VariableDeclaration", + "scope": 10284, + "src": "6511:24:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10271, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6511:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 10276, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10274, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10258, + "src": "6569:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10273, + "name": "aTokenAmountToUnderlyingAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10254, + "src": "6538:30:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view returns (uint256)" + } + }, + "id": 10275, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6538:39:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6511:66:51" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10279, + "name": "underlyingAssetAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9916, + "src": "6630:22:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10280, + "name": "_from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10256, + "src": "6654:5:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10281, + "name": "amountUnderlying", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10272, + "src": "6661:16:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10277, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10264, + "src": "6594:12:51", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 10278, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceDecreaseAllowed", + "nodeType": "MemberAccess", + "referencedDeclaration": 7168, + "src": "6594:35:51", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,address,uint256) view external returns (bool)" + } + }, + "id": 10282, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6594:84:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 10262, + "id": 10283, + "nodeType": "Return", + "src": "6587:91:51" + } + ] + }, + "documentation": "@notice Used to validate transfers before actually executing them.*", + "id": 10285, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isTransferAllowed", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10259, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10256, + "name": "_from", + "nodeType": "VariableDeclaration", + "scope": 10285, + "src": "6322:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10255, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6322:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10258, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 10285, + "src": "6337:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10257, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6337:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6321:32:51" + }, + "returnParameters": { + "id": 10262, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10261, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10285, + "src": "6375:4:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 10260, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "6375:4:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6374:6:51" + }, + "scope": 10327, + "src": "6295:390:51", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10312, + "nodeType": "Block", + "src": "6778:188:51", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 10294, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 10292, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10287, + "src": "6792:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 10293, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6803:1:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "6792:12:51", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 10298, + "nodeType": "IfStatement", + "src": "6788:78:51", + "trueBody": { + "id": 10297, + "nodeType": "Block", + "src": "6806:60:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 10295, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6854:1:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 10291, + "id": 10296, + "nodeType": "Return", + "src": "6847:8:51" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 10307, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "3130", + "id": 10305, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6918:2:51", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_10_by_1", + "typeString": "int_const 10" + }, + "value": "10" + }, + "nodeType": "BinaryOperation", + "operator": "**", + "rightExpression": { + "argumentTypes": null, + "id": 10306, + "name": "underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9918, + "src": "6924:23:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6918:29:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 10301, + "name": "getExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10198, + "src": "6895:15:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_uint256_$", + "typeString": "function () view returns (uint256)" + } + }, + "id": 10302, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6895:17:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 10299, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10287, + "src": "6883:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10300, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "6883:11:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10303, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6883:30:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10304, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "6883:34:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 10308, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6883:65:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 10309, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayToWad", + "nodeType": "MemberAccess", + "referencedDeclaration": 9160, + "src": "6883:74:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 10310, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6883:76:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 10291, + "id": 10311, + "nodeType": "Return", + "src": "6876:83:51" + } + ] + }, + "documentation": null, + "id": 10313, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "underlyingAmountToATokenAmount", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10288, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10287, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 10313, + "src": "6731:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10286, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6731:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6730:17:51" + }, + "returnParameters": { + "id": 10291, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10290, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10313, + "src": "6769:7:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10289, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6769:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6768:9:51" + }, + "scope": 10327, + "src": "6691:275:51", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 10325, + "nodeType": "Block", + "src": "7212:38:51", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10321, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10315, + "src": "7228:7:51", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 10322, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10317, + "src": "7237:5:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 10320, + "name": "_burn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11587, + "src": "7222:5:51", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 10323, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7222:21:51", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10324, + "nodeType": "ExpressionStatement", + "src": "7222:21:51" + } + ] + }, + "documentation": "@dev burns token in the event of users redeeming the underlying asset from the lending pool\n@dev only lending pools can call this function", + "id": 10326, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "burnOnRedeemInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10318, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10315, + "name": "account", + "nodeType": "VariableDeclaration", + "scope": 10326, + "src": "7171:15:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 10314, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7171:7:51", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10317, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 10326, + "src": "7188:13:51", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10316, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7188:7:51", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7170:32:51" + }, + "returnParameters": { + "id": 10319, + "nodeType": "ParameterList", + "parameters": [], + "src": "7212:0:51" + }, + "scope": 10327, + "src": "7141:109:51", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 10328, + "src": "574:6678:51" + } + ], + "src": "0:7253:51" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.921Z", + "devdoc": { + "details": "Implementation of the interest bearing token for the DLP protocol.", + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "burnOnLiquidation(address,uint256)": { + "details": "burns token in the event of a borrow being liquidated, in case the liquidators reclaims the underlying assetonly lending pools can call this function" + }, + "decimals()": { + "details": "Returns the number of decimals used to get its user representation. For example, if `decimals` equals `2`, a balance of `505` tokens should be displayed to a user as `5,05` (`505 / 10 ** 2`). * Tokens usually opt for a value of 18, imitating the relationship between Ether and Wei. * NOTE: This information is only used for _display_ purposes: it in no way affects any of the arithmetic of the contract, including {IERC20-balanceOf} and {IERC20-transfer}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "getExchangeRate()": { + "details": "returns the exchange rate of the aToken to the underlying asset" + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mintOnDeposit(address,uint256)": { + "details": "only lending pools can call this function" + }, + "name()": { + "details": "Returns the name of the token." + }, + "symbol()": { + "details": "Returns the symbol of the token, usually a shorter version of the name." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + }, + "transferOnLiquidation(address,address,uint256)": { + "details": "transfers tokens in the event of a borrow being liquidated, in case the liquidators reclaims the aTokenonly lending pools can call this function" + } + }, + "title": "Aave ERC20 AToken" + }, + "userdoc": { + "methods": { + "isTransferAllowed(address,uint256)": { + "notice": "Used to validate transfers before actually executing them.*" + }, + "mintOnDeposit(address,uint256)": { + "notice": "mints token in the event of users depositing the underlying asset into the lending pool" + }, + "redeem(uint256)": { + "notice": "redeems aToken for the undelying asset." + } + } + } +} \ No newline at end of file diff --git a/client/src/contracts/Address.json b/client/src/contracts/Address.json new file mode 100644 index 0000000..fc4e259 --- /dev/null +++ b/client/src/contracts/Address.json @@ -0,0 +1,2141 @@ +{ + "contractName": "Address", + "abi": [], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"details\":\"Collection of functions related to the address type\",\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"openzeppelin-solidity/contracts/utils/Address.sol\":\"Address\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]}},\"version\":1}", + "bytecode": "0x604c6023600b82828239805160001a607314601657fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea165627a7a72305820d919084c8973262d56c9c011655c926200a2c52372ea39b93c5cb7d9e91d27d20029", + "deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600080fdfea165627a7a72305820d919084c8973262d56c9c011655c926200a2c52372ea39b93c5cb7d9e91d27d20029", + "sourceMap": "93:2919:62:-;;132:2:-1;166:7;155:9;146:7;137:37;255:7;249:14;246:1;241:23;235:4;232:33;222:2;;269:9;222:2;293:9;290:1;283:20;323:4;314:7;306:22;347:7;338;331:24", + "deployedSourceMap": "93:2919:62:-;;;;;;;;", + "source": "pragma solidity ^0.5.5;\n\n/**\n * @dev Collection of functions related to the address type\n */\nlibrary Address {\n /**\n * @dev Returns true if `account` is a contract.\n *\n * This test is non-exhaustive, and there may be false-negatives: during the\n * execution of a contract's constructor, its address will be reported as\n * not containing a contract.\n *\n * IMPORTANT: It is unsafe to assume that an address for which this\n * function returns false is an externally-owned account (EOA) and not a\n * contract.\n */\n function isContract(address account) internal view returns (bool) {\n // This method relies in extcodesize, which returns 0 for contracts in\n // construction, since the code is only stored at the end of the\n // constructor execution.\n\n // According to EIP-1052, 0x0 is the value returned for not-yet created accounts\n // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned\n // for accounts without code, i.e. `keccak256('')`\n bytes32 codehash;\n bytes32 accountHash = 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470;\n // solhint-disable-next-line no-inline-assembly\n assembly { codehash := extcodehash(account) }\n return (codehash != 0x0 && codehash != accountHash);\n }\n\n /**\n * @dev Converts an `address` into `address payable`. Note that this is\n * simply a type cast: the actual underlying value is not changed.\n *\n * _Available since v2.4.0._\n */\n function toPayable(address account) internal pure returns (address payable) {\n return address(uint160(account));\n }\n\n /**\n * @dev Replacement for Solidity's `transfer`: sends `amount` wei to\n * `recipient`, forwarding all available gas and reverting on errors.\n *\n * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost\n * of certain opcodes, possibly making contracts go over the 2300 gas limit\n * imposed by `transfer`, making them unable to receive funds via\n * `transfer`. {sendValue} removes this limitation.\n *\n * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].\n *\n * IMPORTANT: because control is transferred to `recipient`, care must be\n * taken to not create reentrancy vulnerabilities. Consider using\n * {ReentrancyGuard} or the\n * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].\n *\n * _Available since v2.4.0._\n */\n function sendValue(address payable recipient, uint256 amount) internal {\n require(address(this).balance >= amount, \"Address: insufficient balance\");\n\n // solhint-disable-next-line avoid-call-value\n (bool success, ) = recipient.call.value(amount)(\"\");\n require(success, \"Address: unable to send value, recipient may have reverted\");\n }\n}\n", + "sourcePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "ast": { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "exportedSymbols": { + "Address": [ + 12081 + ] + }, + "id": 12082, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 12008, + "literals": [ + "solidity", + "^", + "0.5", + ".5" + ], + "nodeType": "PragmaDirective", + "src": "0:23:62" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "library", + "documentation": "@dev Collection of functions related to the address type", + "fullyImplemented": true, + "id": 12081, + "linearizedBaseContracts": [ + 12081 + ], + "name": "Address", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": { + "id": 12032, + "nodeType": "Block", + "src": "623:731:62", + "statements": [ + { + "assignments": [ + 12016 + ], + "declarations": [ + { + "constant": false, + "id": 12016, + "name": "codehash", + "nodeType": "VariableDeclaration", + "scope": 12032, + "src": "1062:16:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 12015, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1062:7:62", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 12017, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "1062:16:62" + }, + { + "assignments": [ + 12019 + ], + "declarations": [ + { + "constant": false, + "id": 12019, + "name": "accountHash", + "nodeType": "VariableDeclaration", + "scope": 12032, + "src": "1088:19:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 12018, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1088:7:62", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 12021, + "initialValue": { + "argumentTypes": null, + "hexValue": "307863356432343630313836663732333363393237653764623264636337303363306535303062363533636138323237336237626661643830343564383561343730", + "id": 12020, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1110:66:62", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_89477152217924674838424037953991966239322087453347756267410168184682657981552_by_1", + "typeString": "int_const 8947...(69 digits omitted)...1552" + }, + "value": "0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470" + }, + "nodeType": "VariableDeclarationStatement", + "src": "1088:88:62" + }, + { + "externalReferences": [ + { + "codehash": { + "declaration": 12016, + "isOffset": false, + "isSlot": false, + "src": "1253:8:62", + "valueSize": 1 + } + }, + { + "account": { + "declaration": 12010, + "isOffset": false, + "isSlot": false, + "src": "1277:7:62", + "valueSize": 1 + } + } + ], + "id": 12022, + "nodeType": "InlineAssembly", + "operations": "{\n codehash := extcodehash(account)\n}", + "src": "1242:45:62" + }, + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 12029, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "id": 12025, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 12023, + "name": "codehash", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12016, + "src": "1304:8:62", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "hexValue": "307830", + "id": 12024, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1316:3:62", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0x0" + }, + "src": "1304:15:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "&&", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "id": 12028, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 12026, + "name": "codehash", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12016, + "src": "1323:8:62", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 12027, + "name": "accountHash", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12019, + "src": "1335:11:62", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "src": "1323:23:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "1304:42:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "id": 12030, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "1303:44:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 12014, + "id": 12031, + "nodeType": "Return", + "src": "1296:51:62" + } + ] + }, + "documentation": "@dev Returns true if `account` is a contract.\n * This test is non-exhaustive, and there may be false-negatives: during the\nexecution of a contract's constructor, its address will be reported as\nnot containing a contract.\n * IMPORTANT: It is unsafe to assume that an address for which this\nfunction returns false is an externally-owned account (EOA) and not a\ncontract.", + "id": 12033, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isContract", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 12011, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 12010, + "name": "account", + "nodeType": "VariableDeclaration", + "scope": 12033, + "src": "577:15:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 12009, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "577:7:62", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "576:17:62" + }, + "returnParameters": { + "id": 12014, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 12013, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 12033, + "src": "617:4:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 12012, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "617:4:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "616:6:62" + }, + "scope": 12081, + "src": "557:797:62", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 12046, + "nodeType": "Block", + "src": "1639:49:62", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 12042, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12035, + "src": "1672:7:62", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 12041, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1664:7:62", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint160_$", + "typeString": "type(uint160)" + }, + "typeName": "uint160" + }, + "id": 12043, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1664:16:62", + "typeDescriptions": { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + ], + "id": 12040, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1656:7:62", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 12044, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1656:25:62", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "functionReturnParameters": 12039, + "id": 12045, + "nodeType": "Return", + "src": "1649:32:62" + } + ] + }, + "documentation": "@dev Converts an `address` into `address payable`. Note that this is\nsimply a type cast: the actual underlying value is not changed.\n * _Available since v2.4.0._", + "id": 12047, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "toPayable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 12036, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 12035, + "name": "account", + "nodeType": "VariableDeclaration", + "scope": 12047, + "src": "1582:15:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 12034, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1582:7:62", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1581:17:62" + }, + "returnParameters": { + "id": 12039, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 12038, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 12047, + "src": "1622:15:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 12037, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1622:15:62", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1621:17:62" + }, + "scope": 12081, + "src": "1563:125:62", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 12079, + "nodeType": "Block", + "src": "2716:294:62", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 12060, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 12056, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12160, + "src": "2742:4:62", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + ], + "id": 12055, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2734:7:62", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 12057, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2734:13:62", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 12058, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balance", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2734:21:62", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 12059, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12051, + "src": "2759:6:62", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2734:31:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "416464726573733a20696e73756666696369656e742062616c616e6365", + "id": 12061, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2767:31:62", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5597a22abd0ef5332f8053862eb236db7590f17e2b93a53f63a103becfb561f9", + "typeString": "literal_string \"Address: insufficient balance\"" + }, + "value": "Address: insufficient balance" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_5597a22abd0ef5332f8053862eb236db7590f17e2b93a53f63a103becfb561f9", + "typeString": "literal_string \"Address: insufficient balance\"" + } + ], + "id": 12054, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2726:7:62", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 12062, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2726:73:62", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 12063, + "nodeType": "ExpressionStatement", + "src": "2726:73:62" + }, + { + "assignments": [ + 12065, + null + ], + "declarations": [ + { + "constant": false, + "id": 12065, + "name": "success", + "nodeType": "VariableDeclaration", + "scope": 12079, + "src": "2865:12:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 12064, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2865:4:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + null + ], + "id": 12073, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "", + "id": 12071, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2912:2:62", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470", + "typeString": "literal_string \"\"" + }, + "value": "" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470", + "typeString": "literal_string \"\"" + } + ], + "arguments": [ + { + "argumentTypes": null, + "id": 12069, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12051, + "src": "2904:6:62", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 12066, + "name": "recipient", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12049, + "src": "2883:9:62", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 12067, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "call", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2883:14:62", + "typeDescriptions": { + "typeIdentifier": "t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "function (bytes memory) payable returns (bool,bytes memory)" + } + }, + "id": 12068, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2883:20:62", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$value_$", + "typeString": "function (uint256) returns (function (bytes memory) payable returns (bool,bytes memory))" + } + }, + "id": 12070, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2883:28:62", + "typeDescriptions": { + "typeIdentifier": "t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$value", + "typeString": "function (bytes memory) payable returns (bool,bytes memory)" + } + }, + "id": 12072, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2883:32:62", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "tuple(bool,bytes memory)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2864:51:62" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 12075, + "name": "success", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12065, + "src": "2933:7:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "416464726573733a20756e61626c6520746f2073656e642076616c75652c20726563697069656e74206d61792068617665207265766572746564", + "id": 12076, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2942:60:62", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_51ddaa38748c0a1144620fb5bfe8edab31ea437571ad591a7734bbfd0429aeae", + "typeString": "literal_string \"Address: unable to send value, recipient may have reverted\"" + }, + "value": "Address: unable to send value, recipient may have reverted" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_51ddaa38748c0a1144620fb5bfe8edab31ea437571ad591a7734bbfd0429aeae", + "typeString": "literal_string \"Address: unable to send value, recipient may have reverted\"" + } + ], + "id": 12074, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2925:7:62", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 12077, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2925:78:62", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 12078, + "nodeType": "ExpressionStatement", + "src": "2925:78:62" + } + ] + }, + "documentation": "@dev Replacement for Solidity's `transfer`: sends `amount` wei to\n`recipient`, forwarding all available gas and reverting on errors.\n * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost\nof certain opcodes, possibly making contracts go over the 2300 gas limit\nimposed by `transfer`, making them unable to receive funds via\n`transfer`. {sendValue} removes this limitation.\n * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].\n * IMPORTANT: because control is transferred to `recipient`, care must be\ntaken to not create reentrancy vulnerabilities. Consider using\n{ReentrancyGuard} or the\nhttps://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].\n * _Available since v2.4.0._", + "id": 12080, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "sendValue", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 12052, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 12049, + "name": "recipient", + "nodeType": "VariableDeclaration", + "scope": 12080, + "src": "2664:25:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 12048, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2664:15:62", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 12051, + "name": "amount", + "nodeType": "VariableDeclaration", + "scope": 12080, + "src": "2691:14:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 12050, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2691:7:62", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2663:43:62" + }, + "returnParameters": { + "id": 12053, + "nodeType": "ParameterList", + "parameters": [], + "src": "2716:0:62" + }, + "scope": 12081, + "src": "2645:365:62", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 12082, + "src": "93:2919:62" + } + ], + "src": "0:3013:62" + }, + "legacyAST": { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "exportedSymbols": { + "Address": [ + 12081 + ] + }, + "id": 12082, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 12008, + "literals": [ + "solidity", + "^", + "0.5", + ".5" + ], + "nodeType": "PragmaDirective", + "src": "0:23:62" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "library", + "documentation": "@dev Collection of functions related to the address type", + "fullyImplemented": true, + "id": 12081, + "linearizedBaseContracts": [ + 12081 + ], + "name": "Address", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": { + "id": 12032, + "nodeType": "Block", + "src": "623:731:62", + "statements": [ + { + "assignments": [ + 12016 + ], + "declarations": [ + { + "constant": false, + "id": 12016, + "name": "codehash", + "nodeType": "VariableDeclaration", + "scope": 12032, + "src": "1062:16:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 12015, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1062:7:62", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 12017, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "1062:16:62" + }, + { + "assignments": [ + 12019 + ], + "declarations": [ + { + "constant": false, + "id": 12019, + "name": "accountHash", + "nodeType": "VariableDeclaration", + "scope": 12032, + "src": "1088:19:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 12018, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1088:7:62", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 12021, + "initialValue": { + "argumentTypes": null, + "hexValue": "307863356432343630313836663732333363393237653764623264636337303363306535303062363533636138323237336237626661643830343564383561343730", + "id": 12020, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1110:66:62", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_89477152217924674838424037953991966239322087453347756267410168184682657981552_by_1", + "typeString": "int_const 8947...(69 digits omitted)...1552" + }, + "value": "0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470" + }, + "nodeType": "VariableDeclarationStatement", + "src": "1088:88:62" + }, + { + "externalReferences": [ + { + "codehash": { + "declaration": 12016, + "isOffset": false, + "isSlot": false, + "src": "1253:8:62", + "valueSize": 1 + } + }, + { + "account": { + "declaration": 12010, + "isOffset": false, + "isSlot": false, + "src": "1277:7:62", + "valueSize": 1 + } + } + ], + "id": 12022, + "nodeType": "InlineAssembly", + "operations": "{\n codehash := extcodehash(account)\n}", + "src": "1242:45:62" + }, + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 12029, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "id": 12025, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 12023, + "name": "codehash", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12016, + "src": "1304:8:62", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "hexValue": "307830", + "id": 12024, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1316:3:62", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0x0" + }, + "src": "1304:15:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "&&", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "id": 12028, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 12026, + "name": "codehash", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12016, + "src": "1323:8:62", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 12027, + "name": "accountHash", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12019, + "src": "1335:11:62", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "src": "1323:23:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "1304:42:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "id": 12030, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "1303:44:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 12014, + "id": 12031, + "nodeType": "Return", + "src": "1296:51:62" + } + ] + }, + "documentation": "@dev Returns true if `account` is a contract.\n * This test is non-exhaustive, and there may be false-negatives: during the\nexecution of a contract's constructor, its address will be reported as\nnot containing a contract.\n * IMPORTANT: It is unsafe to assume that an address for which this\nfunction returns false is an externally-owned account (EOA) and not a\ncontract.", + "id": 12033, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isContract", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 12011, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 12010, + "name": "account", + "nodeType": "VariableDeclaration", + "scope": 12033, + "src": "577:15:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 12009, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "577:7:62", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "576:17:62" + }, + "returnParameters": { + "id": 12014, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 12013, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 12033, + "src": "617:4:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 12012, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "617:4:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "616:6:62" + }, + "scope": 12081, + "src": "557:797:62", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 12046, + "nodeType": "Block", + "src": "1639:49:62", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 12042, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12035, + "src": "1672:7:62", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 12041, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1664:7:62", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint160_$", + "typeString": "type(uint160)" + }, + "typeName": "uint160" + }, + "id": 12043, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1664:16:62", + "typeDescriptions": { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + ], + "id": 12040, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1656:7:62", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 12044, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1656:25:62", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "functionReturnParameters": 12039, + "id": 12045, + "nodeType": "Return", + "src": "1649:32:62" + } + ] + }, + "documentation": "@dev Converts an `address` into `address payable`. Note that this is\nsimply a type cast: the actual underlying value is not changed.\n * _Available since v2.4.0._", + "id": 12047, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "toPayable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 12036, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 12035, + "name": "account", + "nodeType": "VariableDeclaration", + "scope": 12047, + "src": "1582:15:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 12034, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1582:7:62", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1581:17:62" + }, + "returnParameters": { + "id": 12039, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 12038, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 12047, + "src": "1622:15:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 12037, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1622:15:62", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1621:17:62" + }, + "scope": 12081, + "src": "1563:125:62", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 12079, + "nodeType": "Block", + "src": "2716:294:62", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 12060, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 12056, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12160, + "src": "2742:4:62", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + ], + "id": 12055, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2734:7:62", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 12057, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2734:13:62", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 12058, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balance", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2734:21:62", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 12059, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12051, + "src": "2759:6:62", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2734:31:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "416464726573733a20696e73756666696369656e742062616c616e6365", + "id": 12061, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2767:31:62", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5597a22abd0ef5332f8053862eb236db7590f17e2b93a53f63a103becfb561f9", + "typeString": "literal_string \"Address: insufficient balance\"" + }, + "value": "Address: insufficient balance" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_5597a22abd0ef5332f8053862eb236db7590f17e2b93a53f63a103becfb561f9", + "typeString": "literal_string \"Address: insufficient balance\"" + } + ], + "id": 12054, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2726:7:62", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 12062, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2726:73:62", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 12063, + "nodeType": "ExpressionStatement", + "src": "2726:73:62" + }, + { + "assignments": [ + 12065, + null + ], + "declarations": [ + { + "constant": false, + "id": 12065, + "name": "success", + "nodeType": "VariableDeclaration", + "scope": 12079, + "src": "2865:12:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 12064, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2865:4:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + null + ], + "id": 12073, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "", + "id": 12071, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2912:2:62", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470", + "typeString": "literal_string \"\"" + }, + "value": "" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470", + "typeString": "literal_string \"\"" + } + ], + "arguments": [ + { + "argumentTypes": null, + "id": 12069, + "name": "amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12051, + "src": "2904:6:62", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 12066, + "name": "recipient", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12049, + "src": "2883:9:62", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 12067, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "call", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2883:14:62", + "typeDescriptions": { + "typeIdentifier": "t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "function (bytes memory) payable returns (bool,bytes memory)" + } + }, + "id": 12068, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2883:20:62", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$value_$", + "typeString": "function (uint256) returns (function (bytes memory) payable returns (bool,bytes memory))" + } + }, + "id": 12070, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2883:28:62", + "typeDescriptions": { + "typeIdentifier": "t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$value", + "typeString": "function (bytes memory) payable returns (bool,bytes memory)" + } + }, + "id": 12072, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2883:32:62", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "tuple(bool,bytes memory)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2864:51:62" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 12075, + "name": "success", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12065, + "src": "2933:7:62", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "416464726573733a20756e61626c6520746f2073656e642076616c75652c20726563697069656e74206d61792068617665207265766572746564", + "id": 12076, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2942:60:62", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_51ddaa38748c0a1144620fb5bfe8edab31ea437571ad591a7734bbfd0429aeae", + "typeString": "literal_string \"Address: unable to send value, recipient may have reverted\"" + }, + "value": "Address: unable to send value, recipient may have reverted" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_51ddaa38748c0a1144620fb5bfe8edab31ea437571ad591a7734bbfd0429aeae", + "typeString": "literal_string \"Address: unable to send value, recipient may have reverted\"" + } + ], + "id": 12074, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2925:7:62", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 12077, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2925:78:62", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 12078, + "nodeType": "ExpressionStatement", + "src": "2925:78:62" + } + ] + }, + "documentation": "@dev Replacement for Solidity's `transfer`: sends `amount` wei to\n`recipient`, forwarding all available gas and reverting on errors.\n * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost\nof certain opcodes, possibly making contracts go over the 2300 gas limit\nimposed by `transfer`, making them unable to receive funds via\n`transfer`. {sendValue} removes this limitation.\n * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].\n * IMPORTANT: because control is transferred to `recipient`, care must be\ntaken to not create reentrancy vulnerabilities. Consider using\n{ReentrancyGuard} or the\nhttps://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].\n * _Available since v2.4.0._", + "id": 12080, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "sendValue", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 12052, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 12049, + "name": "recipient", + "nodeType": "VariableDeclaration", + "scope": 12080, + "src": "2664:25:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 12048, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2664:15:62", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 12051, + "name": "amount", + "nodeType": "VariableDeclaration", + "scope": 12080, + "src": "2691:14:62", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 12050, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2691:7:62", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2663:43:62" + }, + "returnParameters": { + "id": 12053, + "nodeType": "ParameterList", + "parameters": [], + "src": "2716:0:62" + }, + "scope": 12081, + "src": "2645:365:62", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 12082, + "src": "93:2919:62" + } + ], + "src": "0:3013:62" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.950Z", + "devdoc": { + "details": "Collection of functions related to the address type", + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/AddressStorage.json b/client/src/contracts/AddressStorage.json new file mode 100644 index 0000000..7482e81 --- /dev/null +++ b/client/src/contracts/AddressStorage.json @@ -0,0 +1,806 @@ +{ + "contractName": "AddressStorage", + "abi": [ + { + "constant": true, + "inputs": [ + { + "name": "_key", + "type": "bytes32" + } + ], + "name": "getAddress", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[{\"name\":\"_key\",\"type\":\"bytes32\"}],\"name\":\"getAddress\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":\"AddressStorage\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]}},\"version\":1}", + "bytecode": "0x608060405234801561001057600080fd5b50610100806100206000396000f3fe6080604052348015600f57600080fd5b506004361060285760003560e01c806321f8a72114602d575b600080fd5b605660048036036020811015604157600080fd5b81019080803590602001909291905050506098565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b600080600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905091905056fea165627a7a72305820b3fee8c6cd7f5530d7b31e4f0c407a899149cd9a56205bdaffd000e2302510820029", + "deployedBytecode": "0x6080604052348015600f57600080fd5b506004361060285760003560e01c806321f8a72114602d575b600080fd5b605660048036036020811015604157600080fd5b81019080803590602001909291905050506098565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b600080600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905091905056fea165627a7a72305820b3fee8c6cd7f5530d7b31e4f0c407a899149cd9a56205bdaffd000e2302510820029", + "sourceMap": "25:295:8:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;25:295:8;;;;;;;", + "deployedSourceMap": "25:295:8:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;25:295:8;;;;;;;;;;;;;;;;;;;107:103;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;107:103:8;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;162:7;188:9;:15;198:4;188:15;;;;;;;;;;;;;;;;;;;;;181:22;;107:103;;;:::o", + "source": "pragma solidity ^0.5.0;\n\ncontract AddressStorage {\n mapping(bytes32 => address) private addresses;\n\n function getAddress(bytes32 _key) public view returns (address) {\n return addresses[_key];\n }\n\n function _setAddress(bytes32 _key, address _value) internal {\n addresses[_key] = _value;\n }\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol", + "exportedSymbols": { + "AddressStorage": [ + 953 + ] + }, + "id": 954, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 922, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:8" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 953, + "linearizedBaseContracts": [ + 953 + ], + "name": "AddressStorage", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 926, + "name": "addresses", + "nodeType": "VariableDeclaration", + "scope": 953, + "src": "55:45:8", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_address_$", + "typeString": "mapping(bytes32 => address)" + }, + "typeName": { + "id": 925, + "keyType": { + "id": 923, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "63:7:8", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "nodeType": "Mapping", + "src": "55:27:8", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_address_$", + "typeString": "mapping(bytes32 => address)" + }, + "valueType": { + "id": 924, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "74:7:8", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + }, + "value": null, + "visibility": "private" + }, + { + "body": { + "id": 937, + "nodeType": "Block", + "src": "171:39:8", + "statements": [ + { + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 933, + "name": "addresses", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 926, + "src": "188:9:8", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_address_$", + "typeString": "mapping(bytes32 => address)" + } + }, + "id": 935, + "indexExpression": { + "argumentTypes": null, + "id": 934, + "name": "_key", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 928, + "src": "198:4:8", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "188:15:8", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 932, + "id": 936, + "nodeType": "Return", + "src": "181:22:8" + } + ] + }, + "documentation": null, + "id": 938, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 929, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 928, + "name": "_key", + "nodeType": "VariableDeclaration", + "scope": 938, + "src": "127:12:8", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 927, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "127:7:8", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "126:14:8" + }, + "returnParameters": { + "id": 932, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 931, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 938, + "src": "162:7:8", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 930, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "162:7:8", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "161:9:8" + }, + "scope": 953, + "src": "107:103:8", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 951, + "nodeType": "Block", + "src": "276:41:8", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 949, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 945, + "name": "addresses", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 926, + "src": "286:9:8", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_address_$", + "typeString": "mapping(bytes32 => address)" + } + }, + "id": 947, + "indexExpression": { + "argumentTypes": null, + "id": 946, + "name": "_key", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 940, + "src": "296:4:8", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "286:15:8", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 948, + "name": "_value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 942, + "src": "304:6:8", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "286:24:8", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 950, + "nodeType": "ExpressionStatement", + "src": "286:24:8" + } + ] + }, + "documentation": null, + "id": 952, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "_setAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 943, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 940, + "name": "_key", + "nodeType": "VariableDeclaration", + "scope": 952, + "src": "237:12:8", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 939, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "237:7:8", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 942, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 952, + "src": "251:14:8", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 941, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "251:7:8", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "236:30:8" + }, + "returnParameters": { + "id": 944, + "nodeType": "ParameterList", + "parameters": [], + "src": "276:0:8" + }, + "scope": 953, + "src": "216:101:8", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 954, + "src": "25:295:8" + } + ], + "src": "0:321:8" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol", + "exportedSymbols": { + "AddressStorage": [ + 953 + ] + }, + "id": 954, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 922, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:8" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 953, + "linearizedBaseContracts": [ + 953 + ], + "name": "AddressStorage", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 926, + "name": "addresses", + "nodeType": "VariableDeclaration", + "scope": 953, + "src": "55:45:8", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_address_$", + "typeString": "mapping(bytes32 => address)" + }, + "typeName": { + "id": 925, + "keyType": { + "id": 923, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "63:7:8", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "nodeType": "Mapping", + "src": "55:27:8", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_address_$", + "typeString": "mapping(bytes32 => address)" + }, + "valueType": { + "id": 924, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "74:7:8", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + }, + "value": null, + "visibility": "private" + }, + { + "body": { + "id": 937, + "nodeType": "Block", + "src": "171:39:8", + "statements": [ + { + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 933, + "name": "addresses", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 926, + "src": "188:9:8", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_address_$", + "typeString": "mapping(bytes32 => address)" + } + }, + "id": 935, + "indexExpression": { + "argumentTypes": null, + "id": 934, + "name": "_key", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 928, + "src": "198:4:8", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "188:15:8", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 932, + "id": 936, + "nodeType": "Return", + "src": "181:22:8" + } + ] + }, + "documentation": null, + "id": 938, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 929, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 928, + "name": "_key", + "nodeType": "VariableDeclaration", + "scope": 938, + "src": "127:12:8", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 927, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "127:7:8", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "126:14:8" + }, + "returnParameters": { + "id": 932, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 931, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 938, + "src": "162:7:8", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 930, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "162:7:8", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "161:9:8" + }, + "scope": 953, + "src": "107:103:8", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 951, + "nodeType": "Block", + "src": "276:41:8", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 949, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 945, + "name": "addresses", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 926, + "src": "286:9:8", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_address_$", + "typeString": "mapping(bytes32 => address)" + } + }, + "id": 947, + "indexExpression": { + "argumentTypes": null, + "id": 946, + "name": "_key", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 940, + "src": "296:4:8", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "286:15:8", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 948, + "name": "_value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 942, + "src": "304:6:8", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "286:24:8", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 950, + "nodeType": "ExpressionStatement", + "src": "286:24:8" + } + ] + }, + "documentation": null, + "id": 952, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "_setAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 943, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 940, + "name": "_key", + "nodeType": "VariableDeclaration", + "scope": 952, + "src": "237:12:8", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 939, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "237:7:8", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 942, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 952, + "src": "251:14:8", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 941, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "251:7:8", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "236:30:8" + }, + "returnParameters": { + "id": 944, + "nodeType": "ParameterList", + "parameters": [], + "src": "276:0:8" + }, + "scope": 953, + "src": "216:101:8", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 954, + "src": "25:295:8" + } + ], + "src": "0:321:8" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.573Z", + "devdoc": { + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/Context.json b/client/src/contracts/Context.json new file mode 100644 index 0000000..c0235cc --- /dev/null +++ b/client/src/contracts/Context.json @@ -0,0 +1,595 @@ +{ + "contractName": "Context", + "abi": [ + { + "inputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"openzeppelin-solidity/contracts/GSN/Context.sol\":\"Context\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\n/*\n * @dev Provides information about the current execution context, including the\n * sender of the transaction and its data. While these are generally available\n * via msg.sender and msg.data, they should not be accessed in such a direct\n * manner, since when dealing with GSN meta-transactions the account sending and\n * paying for execution may not be the actual sender (as far as an application\n * is concerned).\n *\n * This contract is only required for intermediate, library-like contracts.\n */\ncontract Context {\n // Empty internal constructor, to prevent people from mistakenly deploying\n // an instance of this contract, which should be used via inheritance.\n constructor () internal { }\n // solhint-disable-previous-line no-empty-blocks\n\n function _msgSender() internal view returns (address payable) {\n return msg.sender;\n }\n\n function _msgData() internal view returns (bytes memory) {\n this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691\n return msg.data;\n }\n}\n", + "sourcePath": "openzeppelin-solidity/contracts/GSN/Context.sol", + "ast": { + "absolutePath": "openzeppelin-solidity/contracts/GSN/Context.sol", + "exportedSymbols": { + "Context": [ + 10953 + ] + }, + "id": 10954, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 10928, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:55" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 10953, + "linearizedBaseContracts": [ + 10953 + ], + "name": "Context", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": { + "id": 10931, + "nodeType": "Block", + "src": "726:3:55", + "statements": [] + }, + "documentation": null, + "id": 10932, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10929, + "nodeType": "ParameterList", + "parameters": [], + "src": "714:2:55" + }, + "returnParameters": { + "id": 10930, + "nodeType": "ParameterList", + "parameters": [], + "src": "726:0:55" + }, + "scope": 10953, + "src": "702:27:55", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 10940, + "nodeType": "Block", + "src": "850:34:55", + "statements": [ + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10937, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "867:3:55", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10938, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "867:10:55", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "functionReturnParameters": 10936, + "id": 10939, + "nodeType": "Return", + "src": "860:17:55" + } + ] + }, + "documentation": null, + "id": 10941, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "_msgSender", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10933, + "nodeType": "ParameterList", + "parameters": [], + "src": "807:2:55" + }, + "returnParameters": { + "id": 10936, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10935, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10941, + "src": "833:15:55", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 10934, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "833:15:55", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "832:17:55" + }, + "scope": 10953, + "src": "788:96:55", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 10951, + "nodeType": "Block", + "src": "947:165:55", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 10946, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12152, + "src": "957:4:55", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Context_$10953", + "typeString": "contract Context" + } + }, + "id": 10947, + "nodeType": "ExpressionStatement", + "src": "957:4:55" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10948, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "1097:3:55", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10949, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "data", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1097:8:55", + "typeDescriptions": { + "typeIdentifier": "t_bytes_calldata_ptr", + "typeString": "bytes calldata" + } + }, + "functionReturnParameters": 10945, + "id": 10950, + "nodeType": "Return", + "src": "1090:15:55" + } + ] + }, + "documentation": null, + "id": 10952, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "_msgData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10942, + "nodeType": "ParameterList", + "parameters": [], + "src": "907:2:55" + }, + "returnParameters": { + "id": 10945, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10944, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10952, + "src": "933:12:55", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 10943, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "933:5:55", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "932:14:55" + }, + "scope": 10953, + "src": "890:222:55", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 10954, + "src": "525:589:55" + } + ], + "src": "0:1115:55" + }, + "legacyAST": { + "absolutePath": "openzeppelin-solidity/contracts/GSN/Context.sol", + "exportedSymbols": { + "Context": [ + 10953 + ] + }, + "id": 10954, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 10928, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:55" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 10953, + "linearizedBaseContracts": [ + 10953 + ], + "name": "Context", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": { + "id": 10931, + "nodeType": "Block", + "src": "726:3:55", + "statements": [] + }, + "documentation": null, + "id": 10932, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10929, + "nodeType": "ParameterList", + "parameters": [], + "src": "714:2:55" + }, + "returnParameters": { + "id": 10930, + "nodeType": "ParameterList", + "parameters": [], + "src": "726:0:55" + }, + "scope": 10953, + "src": "702:27:55", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 10940, + "nodeType": "Block", + "src": "850:34:55", + "statements": [ + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10937, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "867:3:55", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10938, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "867:10:55", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "functionReturnParameters": 10936, + "id": 10939, + "nodeType": "Return", + "src": "860:17:55" + } + ] + }, + "documentation": null, + "id": 10941, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "_msgSender", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10933, + "nodeType": "ParameterList", + "parameters": [], + "src": "807:2:55" + }, + "returnParameters": { + "id": 10936, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10935, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10941, + "src": "833:15:55", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 10934, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "833:15:55", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "832:17:55" + }, + "scope": 10953, + "src": "788:96:55", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 10951, + "nodeType": "Block", + "src": "947:165:55", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 10946, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12152, + "src": "957:4:55", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Context_$10953", + "typeString": "contract Context" + } + }, + "id": 10947, + "nodeType": "ExpressionStatement", + "src": "957:4:55" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 10948, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "1097:3:55", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 10949, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "data", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1097:8:55", + "typeDescriptions": { + "typeIdentifier": "t_bytes_calldata_ptr", + "typeString": "bytes calldata" + } + }, + "functionReturnParameters": 10945, + "id": 10950, + "nodeType": "Return", + "src": "1090:15:55" + } + ] + }, + "documentation": null, + "id": 10952, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "_msgData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10942, + "nodeType": "ParameterList", + "parameters": [], + "src": "907:2:55" + }, + "returnParameters": { + "id": 10945, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10944, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10952, + "src": "933:12:55", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 10943, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "933:5:55", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "932:14:55" + }, + "scope": 10953, + "src": "890:222:55", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 10954, + "src": "525:589:55" + } + ], + "src": "0:1115:55" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.944Z", + "devdoc": { + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/CoreLibrary.json b/client/src/contracts/CoreLibrary.json new file mode 100644 index 0000000..4f9e4f9 --- /dev/null +++ b/client/src/contracts/CoreLibrary.json @@ -0,0 +1,19439 @@ +{ + "contractName": "CoreLibrary", + "abi": [], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"author\":\"Aave\",\"methods\":{},\"title\":\"CoreLibrary library\"},\"userdoc\":{\"methods\":{\"init(CoreLibrary.ReserveData storage,address,uint256,address)\":{\"notice\":\"inits a reserve\"}},\"notice\":\"***********************************************************************************Defines the data structures of the reserves and the user data************************************************************************************\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol\":\"CoreLibrary\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol\":{\"keccak256\":\"0xb8b4844881a9ea5c3f0f2584061efcbfb6c96863ca3a07b960d2f9d323293cac\",\"urls\":[\"bzzr://8cb1c5dcce198c0f60c21bd9807b361fc214a60d4b3aa3442153b045b51a4325\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]}},\"version\":1}", + "bytecode": "0x6105e2610026600b82828239805160001a60731461001957fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600436106100615760003560e01c806313769cd4146100665780632eb0d006146100eb57806383c165a01461013a578063e5df56a614610175578063f63babbe146101b0575b600080fd5b81801561007257600080fd5b506100e96004803603608081101561008957600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506101f7565b005b8180156100f757600080fd5b506101386004803603606081101561010e57600080fd5b8101908080359060200190929190803590602001909291908035906020019092919050505061038e565b005b81801561014657600080fd5b506101736004803603602081101561015d57600080fd5b810190808035906020019092919050505061044e565b005b81801561018157600080fd5b506101ae6004803603602081101561019857600080fd5b810190808035906020019092919050505061046e565b005b8180156101bc57600080fd5b506101f5600480360360408110156101d357600080fd5b810190808035906020019092919080351515906020019092919050505061048e565b005b600073ffffffffffffffffffffffffffffffffffffffff1684600d0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146102a0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602481526020018061056b6024913960400191505060405180910390fd5b6000846001015414156102be576102b5610556565b84600101819055505b6000846008015414156102dc576102d3610556565b84600801819055505b8284600d0160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508184600c01819055508084600e0160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600184600e01601c6101000a81548160ff02191690831515021790555050505050565b6000151583600e01601a9054906101000a900460ff161515146103fc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602881526020018061058f6028913960400191505060405180910390fd5b600183600e01601a6101000a81548160ff0219169083151502179055508183600901819055508083600a018190555060008360010154141561044957610440610556565b83600101819055505b505050565b600081600e01601a6101000a81548160ff02191690831515021790555050565b600081600e0160196101000a81548160ff02191690831515021790555050565b6000151582600e0160199054906101000a900460ff16151514610519576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f5265736572766520697320616c726561647920656e61626c656400000000000081525060200191505060405180910390fd5b600182600e0160196101000a81548160ff0219169083151502179055508082600e01601b6101000a81548160ff0219169083151502179055505050565b60006b033b2e3c9fd0803ce800000090509056fe526573657276652068617320616c7265616479206265656e20696e697469616c697a65645265736572766520697320616c726561647920656e61626c656420617320636f6c6c61746572616ca165627a7a72305820658be84253451a19262a0050c67b3c96c74935b791e4d886588405119612091e0029", + "deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600436106100615760003560e01c806313769cd4146100665780632eb0d006146100eb57806383c165a01461013a578063e5df56a614610175578063f63babbe146101b0575b600080fd5b81801561007257600080fd5b506100e96004803603608081101561008957600080fd5b8101908080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506101f7565b005b8180156100f757600080fd5b506101386004803603606081101561010e57600080fd5b8101908080359060200190929190803590602001909291908035906020019092919050505061038e565b005b81801561014657600080fd5b506101736004803603602081101561015d57600080fd5b810190808035906020019092919050505061044e565b005b81801561018157600080fd5b506101ae6004803603602081101561019857600080fd5b810190808035906020019092919050505061046e565b005b8180156101bc57600080fd5b506101f5600480360360408110156101d357600080fd5b810190808035906020019092919080351515906020019092919050505061048e565b005b600073ffffffffffffffffffffffffffffffffffffffff1684600d0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146102a0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602481526020018061056b6024913960400191505060405180910390fd5b6000846001015414156102be576102b5610556565b84600101819055505b6000846008015414156102dc576102d3610556565b84600801819055505b8284600d0160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508184600c01819055508084600e0160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600184600e01601c6101000a81548160ff02191690831515021790555050505050565b6000151583600e01601a9054906101000a900460ff161515146103fc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602881526020018061058f6028913960400191505060405180910390fd5b600183600e01601a6101000a81548160ff0219169083151502179055508183600901819055508083600a018190555060008360010154141561044957610440610556565b83600101819055505b505050565b600081600e01601a6101000a81548160ff02191690831515021790555050565b600081600e0160196101000a81548160ff02191690831515021790555050565b6000151582600e0160199054906101000a900460ff16151514610519576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f5265736572766520697320616c726561647920656e61626c656400000000000081525060200191505060405180910390fd5b600182600e0160196101000a81548160ff0219169083151502179055508082600e01601b6101000a81548160ff0219169083151502179055505050565b60006b033b2e3c9fd0803ce800000090509056fe526573657276652068617320616c7265616479206265656e20696e697469616c697a65645265736572766520697320616c726561647920656e61626c656420617320636f6c6c61746572616ca165627a7a72305820658be84253451a19262a0050c67b3c96c74935b791e4d886588405119612091e0029", + "sourceMap": "399:11147:28:-;;132:2:-1;166:7;155:9;146:7;137:37;255:7;249:14;246:1;241:23;235:4;232:33;222:2;;269:9;222:2;293:9;290:1;283:20;323:4;314:7;306:22;347:7;338;331:24", + "deployedSourceMap": "399:11147:28:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5016:753;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5016:753:28;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;5016:753:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;6202:522;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6202:522:28;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6202:522:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;6730:119;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6730:119:28;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6730:119:28;;;;;;;;;;;;;;;;;:::i;:::-;;6088:108;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6088:108:28;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6088:108:28;;;;;;;;;;;;;;;;;:::i;:::-;;5775:307;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5775:307:28;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5775:307:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;5016:753;5195:1;5164:33;;:5;:19;;;;;;;;;;;;:33;;;5156:82;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5291:1;5253:5;:34;;;:39;5249:181;;;5403:16;:14;:16::i;:::-;5366:5;:34;;:53;;;;5249:181;5487:1;5444:5;:39;;;:44;5440:132;;;5545:16;:14;:16::i;:::-;5503:5;:39;;:58;;;;5440:132;5604:14;5582:5;:19;;;:36;;;;;;;;;;;;;;;;;;5645:9;5628:5;:14;;:26;;;;5701:28;5665:5;:33;;;:64;;;;;;;;;;;;;;;;;;5756:4;5739:5;:14;;;:21;;;;;;;;;;;;;;;;;;5016:753;;;;:::o;6202:522::-;6391:5;6357:39;;:5;:30;;;;;;;;;;;;:39;;;6349:92;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6485:4;6452:5;:30;;;:37;;;;;;;;;;;;;;;;;;6527:20;6499:5;:25;;:48;;;;6586:21;6557:5;:26;;:50;;;;6660:1;6622:5;:34;;;:39;6618:98;;;6700:16;:14;:16::i;:::-;6663:5;:34;;:53;;;;6618:98;6202:522;;;:::o;6730:119::-;6837:5;6804;:30;;;:38;;;;;;;;;;;;;;;;;;6730:119;:::o;6088:108::-;6184:5;6159;:22;;;:30;;;;;;;;;;;;;;;;;;6088:108;:::o;5775:307::-;5931:5;5905:31;;:5;:22;;;;;;;;;;;;:31;;;5897:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6003:4;5978:5;:22;;;:29;;;;;;;;;;;;;;;;;;6050:23;6017:5;:30;;;:56;;;;;;;;;;;;;;;;;;5775:307;;:::o;557:74:29:-;595:7;454:4;614:10;;557:74;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\nimport \"./WadRayMath.sol\";\n\n/*************************************************************************************\n@title CoreLibrary library\n@author Aave\n@notice Defines the data structures of the reserves and the user data\n *************************************************************************************/\n\nlibrary CoreLibrary {\n using SafeMath for uint256;\n using WadRayMath for uint256;\n\n enum InterestRateMode {FIXED, VARIABLE}\n\n uint256 constant SECONDS_PER_YEAR = 365 days;\n\n struct UserReserveData {\n //principal amount borrowed by the user\n uint256 principalBorrowBalance;\n //cumulated variable borrow index for the user Bvcu. Refer to the whitepaper for more information\n uint256 lastVariableBorrowCumulativeIndex;\n //origination fee cumulated by the user\n uint256 originationFee;\n // fixed borrow rate at which the user has borrowed\n uint256 fixedBorrowRate;\n\n uint40 lastUpdateTimestamp;\n\n /**\n @dev defines if a specific deposit should or not be used as a collateral in borrows\n */\n bool useAsCollateral;\n }\n\n struct ReserveData {\n /**\n @dev refer to the whitepaper, section 1.1 basic concepts for a formal description of these properties.\n */\n uint256 totalLiquidity;\n uint256 lastLiquidityCumulativeIndex;\n uint256 currentLiquidityRate;\n uint256 totalBorrowsFixed;\n uint256 totalBorrowsVariable;\n uint256 currentVariableBorrowRate;\n uint256 currentFixedBorrowRate;\n uint256 currentAverageFixedBorrowRate;\n uint256 lastVariableBorrowCumulativeIndex;\n uint256 baseLTVasCollateral;\n uint256 liquidationThreshold;\n uint256 liquidationDiscount;\n uint256 decimals;\n /**\n * @dev address of the aToken representing the asset\n */\n address aTokenAddress;\n\n /**\n * @dev address of the interest rate strategy contract\n */\n\n address interestRateStrategyAddress;\n\n uint40 lastUpdateTimestamp;\n\n /**\n @dev borrowingEnabled = true means users can borrow from this reserve\n @dev usageAsCollateral = true means users can use this reserve as collateral\n */\n bool borrowingEnabled;\n bool usageAsCollateralEnabled;\n bool isFixedBorrowRateEnabled;\n bool isActive;\n }\n\n /**\n @notice returns the utilization rate U of a specific reserve\n @dev the utilization rate is in ray (27 decimals precision)\n */\n\n function getReserveUtilizationRate(ReserveData storage _self) internal view returns (uint256) {\n\n if (_self.totalLiquidity == 0) return 0;\n\n uint256 totalBorrows = _self.totalBorrowsFixed.add(_self.totalBorrowsVariable);\n\n return totalBorrows.rayDiv(_self.totalLiquidity);\n }\n\n /**\n @notice returns the utilization rate U of a specific reserve\n @dev the utilization rate is in ray (27 decimals precision)\n */\n function getNormalizedIncome(CoreLibrary.ReserveData storage _reserve)\n internal\n view\n returns (uint256)\n {\n\n uint256 cumulated = calculateCumulatedInterest(\n _reserve.currentLiquidityRate,\n _reserve.lastUpdateTimestamp)\n .rayMul(_reserve.lastLiquidityCumulativeIndex);\n\n return cumulated;\n\n }\n\n /**\n @notice Updates the liquidity cumulative index Ci and variable borrow cumulative index Bvc. Refer to the whitepaper for\n a formal specification.\n @dev Ci and Bvc are in ray (27 decimals precision)\n */\n\n function updateCumulativeIndexes(ReserveData storage _self) internal{\n\n uint256 utilizationRate = getReserveUtilizationRate(_self);\n\n if (utilizationRate > 0) {\n //only cumulating if there is any income being produced\n uint256 cumulatedLiquidityInterest = calculateCumulatedInterest(_self.currentLiquidityRate, _self.lastUpdateTimestamp);\n\n _self.lastLiquidityCumulativeIndex = cumulatedLiquidityInterest.rayMul(\n _self.lastLiquidityCumulativeIndex\n );\n\n uint256 cumulatedVariableBorrowInterest = calculateCumulatedInterest(_self.currentVariableBorrowRate, _self.lastUpdateTimestamp);\n _self.lastVariableBorrowCumulativeIndex = cumulatedVariableBorrowInterest.rayMul(\n _self.lastVariableBorrowCumulativeIndex\n );\n }\n }\n\n function cumulateToLiquidityIndex(ReserveData storage _self, uint256 _amount) internal{\n\n uint256 amountToLiquidityRatio = _amount.wadToRay().rayDiv(_self.totalLiquidity.wadToRay());\n\n uint256 cumulatedLiquidity = amountToLiquidityRatio.add(WadRayMath.ray());\n\n _self.lastLiquidityCumulativeIndex = cumulatedLiquidity.rayMul(\n _self.lastLiquidityCumulativeIndex\n );\n }\n\n /**\n @notice inits a reserve\n */\n\n function init(ReserveData storage _self, address _aTokenAddress, uint256 _decimals, address _interestRateStrategyAddress) external{\n require(_self.aTokenAddress == address(0), \"Reserve has already been initialized\");\n\n if (_self.lastLiquidityCumulativeIndex == 0) {\n //if the reserve has not been initialized yet\n _self.lastLiquidityCumulativeIndex = WadRayMath.ray();\n }\n\n if (_self.lastVariableBorrowCumulativeIndex == 0){\n _self.lastVariableBorrowCumulativeIndex = WadRayMath.ray();\n }\n\n _self.aTokenAddress = _aTokenAddress;\n _self.decimals = _decimals;\n\n _self.interestRateStrategyAddress = _interestRateStrategyAddress;\n _self.isActive = true;\n\n\n }\n\n function enableBorrowing(\n ReserveData storage _self,\n bool _fixedBorrowRateEnabled\n ) external{\n require(_self.borrowingEnabled == false, \"Reserve is already enabled\");\n\n _self.borrowingEnabled = true;\n _self.isFixedBorrowRateEnabled = _fixedBorrowRateEnabled;\n\n\n }\n\n function disableBorrowing(ReserveData storage _self) external{\n _self.borrowingEnabled = false;\n }\n\n function enableAsCollateral(ReserveData storage _self, uint256 _baseLTVasCollateral, uint256 _liquidationThreshold)\n external\n {\n require(_self.usageAsCollateralEnabled == false, \"Reserve is already enabled as collateral\");\n\n _self.usageAsCollateralEnabled = true;\n _self.baseLTVasCollateral = _baseLTVasCollateral;\n _self.liquidationThreshold = _liquidationThreshold;\n\n if (_self.lastLiquidityCumulativeIndex == 0) _self.lastLiquidityCumulativeIndex = WadRayMath.ray();\n\n }\n\n function disableAsCollateral(ReserveData storage _self) external{\n _self.usageAsCollateralEnabled = false;\n }\n\n /**\n @dev user specific functions\n */\n\n function getCompoundedBorrowBalance(\n CoreLibrary.UserReserveData storage _self,\n CoreLibrary.ReserveData storage _reserve)\n internal\n view\n returns(uint256) {\n\n if (_self.principalBorrowBalance == 0) return 0;\n\n uint256 principalBorrowBalanceRay = _self.principalBorrowBalance.wadToRay();\n uint256 compoundedBalance = 0;\n uint256 cumulatedInterest = 0;\n\n if (_self.fixedBorrowRate > 0) {\n cumulatedInterest = calculateCumulatedInterest(_self.fixedBorrowRate, _self.lastUpdateTimestamp);\n }\n else {\n //variable interest\n cumulatedInterest = calculateCumulatedInterest(_reserve.currentVariableBorrowRate, _reserve.lastUpdateTimestamp)\n .rayMul(_reserve.lastVariableBorrowCumulativeIndex)\n .rayDiv(_self.lastVariableBorrowCumulativeIndex);\n }\n\n compoundedBalance = principalBorrowBalanceRay\n .rayMul(cumulatedInterest)\n .rayToWad();\n\n if(compoundedBalance == _self.principalBorrowBalance) {\n\n //no interest cumulation because of the rounding - we add 1 wei\n //as symbolic cumulated interest to avoid interest free loans.\n\n return _self.principalBorrowBalance.add(1 wei);\n }\n\n return compoundedBalance;\n }\n\n function increaseTotalBorrowsFixedAndUpdateAverageRate(ReserveData storage _reserve, uint256 _amount, uint256 _rate) internal{\n uint256 previousTotalBorrowFixed = _reserve.totalBorrowsFixed;\n //updating reserve borrows fixed\n _reserve.totalBorrowsFixed = _reserve.totalBorrowsFixed.add(_amount);\n\n //update the average fixed rate\n //weighted average of all the borrows\n uint256 weightedLastBorrow = _amount.wadToRay().rayMul(_rate);\n uint256 weightedPreviousTotalBorrows = previousTotalBorrowFixed.wadToRay().rayMul(_reserve.currentAverageFixedBorrowRate);\n\n _reserve.currentAverageFixedBorrowRate = weightedLastBorrow.add(weightedPreviousTotalBorrows).rayDiv(\n _reserve.totalBorrowsFixed.wadToRay()\n );\n }\n\n function decreaseTotalBorrowsFixedAndUpdateAverageRate(ReserveData storage _reserve, uint256 _amount, uint256 _rate) internal{\n\n require(_reserve.totalBorrowsFixed >= _amount, \"Invalid amount to decrease\");\n\n uint256 previousTotalBorrowFixed = _reserve.totalBorrowsFixed;\n\n //updating reserve borrows fixed\n _reserve.totalBorrowsFixed = _reserve.totalBorrowsFixed.sub(_amount);\n\n if (_reserve.totalBorrowsFixed == 0) {\n _reserve.currentAverageFixedBorrowRate = 0; //no income if there are no fixed rate borrows\n return;\n }\n\n //update the average fixed rate\n //weighted average of all the borrows\n uint256 weightedLastBorrow = _amount.wadToRay().rayMul(_rate);\n uint256 weightedPreviousTotalBorrows = previousTotalBorrowFixed.wadToRay().rayMul(_reserve.currentAverageFixedBorrowRate);\n\n require(weightedPreviousTotalBorrows >= weightedLastBorrow, \"The amounts to substract don't match\");\n\n _reserve.currentAverageFixedBorrowRate = weightedPreviousTotalBorrows.sub(weightedLastBorrow).rayDiv(\n _reserve.totalBorrowsFixed.wadToRay()\n );\n }\n\n function increaseTotalBorrowsVariable(ReserveData storage _reserve, uint256 _amount) internal{\n _reserve.totalBorrowsVariable = _reserve.totalBorrowsVariable.add(_amount);\n }\n\n function decreaseTotalBorrowsVariable(ReserveData storage _reserve, uint256 _amount) internal{\n require(_reserve.totalBorrowsVariable >= _amount, \"The amount that is being substracted from the variable total borrows is incorrect\");\n _reserve.totalBorrowsVariable = _reserve.totalBorrowsVariable.sub(_amount);\n }\n\n function setLastUpdate(ReserveData storage _reserve) internal{\n //solium-disable-next-line\n _reserve.lastUpdateTimestamp = uint40(block.timestamp);\n }\n\n function getTotalBorrows(CoreLibrary.ReserveData storage reserve) internal view returns (uint256) {\n return reserve.totalBorrowsFixed.add(reserve.totalBorrowsVariable);\n }\n\n\n /**\n @dev function to calculate cumulated interest\n */\n\n function calculateCumulatedInterest(uint256 _rate,uint40 _lastUpdateTimestamp) internal view returns(uint256) {\n\n //solium-disable-next-line\n uint256 timeDifference = block.timestamp.sub(_lastUpdateTimestamp);\n\n uint256 timeDelta = timeDifference.wadToRay().rayDiv(SECONDS_PER_YEAR.wadToRay());\n\n\n return _rate.rayMul(timeDelta).add(WadRayMath.ray());\n }\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "exportedSymbols": { + "CoreLibrary": [ + 8994 + ] + }, + "id": 8995, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 8256, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:28" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 8257, + "nodeType": "ImportDirective", + "scope": 8995, + "sourceUnit": 11141, + "src": "25:59:28", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "./WadRayMath.sol", + "id": 8258, + "nodeType": "ImportDirective", + "scope": 8995, + "sourceUnit": 9175, + "src": "85:26:28", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "library", + "documentation": "***********************************************************************************\n@title CoreLibrary library\n@author Aave\n@notice Defines the data structures of the reserves and the user data************************************************************************************", + "fullyImplemented": true, + "id": 8994, + "linearizedBaseContracts": [ + 8994 + ], + "name": "CoreLibrary", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 8261, + "libraryName": { + "contractScope": null, + "id": 8259, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "431:8:28", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "425:27:28", + "typeName": { + "id": 8260, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "444:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 8264, + "libraryName": { + "contractScope": null, + "id": 8262, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "463:10:28", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "457:29:28", + "typeName": { + "id": 8263, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "478:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "canonicalName": "CoreLibrary.InterestRateMode", + "id": 8267, + "members": [ + { + "id": 8265, + "name": "FIXED", + "nodeType": "EnumValue", + "src": "515:5:28" + }, + { + "id": 8266, + "name": "VARIABLE", + "nodeType": "EnumValue", + "src": "522:8:28" + } + ], + "name": "InterestRateMode", + "nodeType": "EnumDefinition", + "src": "492:39:28" + }, + { + "constant": true, + "id": 8270, + "name": "SECONDS_PER_YEAR", + "nodeType": "VariableDeclaration", + "scope": 8994, + "src": "537:44:28", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8268, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "537:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "333635", + "id": 8269, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "573:8:28", + "subdenomination": "days", + "typeDescriptions": { + "typeIdentifier": "t_rational_31536000_by_1", + "typeString": "int_const 31536000" + }, + "value": "365" + }, + "visibility": "internal" + }, + { + "canonicalName": "CoreLibrary.UserReserveData", + "id": 8283, + "members": [ + { + "constant": false, + "id": 8272, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "669:30:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8271, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "669:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8274, + "name": "lastVariableBorrowCumulativeIndex", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "815:41:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8273, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "815:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8276, + "name": "originationFee", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "914:22:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8275, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "914:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8278, + "name": "fixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "1006:23:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8277, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1006:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8280, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "1040:26:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 8279, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "1040:6:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8282, + "name": "useAsCollateral", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "1193:20:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8281, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "1193:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "UserReserveData", + "nodeType": "StructDefinition", + "scope": 8994, + "src": "588:632:28", + "visibility": "public" + }, + { + "canonicalName": "CoreLibrary.ReserveData", + "id": 8324, + "members": [ + { + "constant": false, + "id": 8285, + "name": "totalLiquidity", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1390:22:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8284, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1390:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8287, + "name": "lastLiquidityCumulativeIndex", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1422:36:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8286, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1422:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8289, + "name": "currentLiquidityRate", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1468:28:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8288, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1468:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8291, + "name": "totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1506:25:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8290, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1506:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8293, + "name": "totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1541:28:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8292, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1541:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8295, + "name": "currentVariableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1579:33:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8294, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1579:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8297, + "name": "currentFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1622:30:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8296, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1622:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8299, + "name": "currentAverageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1662:37:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8298, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1662:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8301, + "name": "lastVariableBorrowCumulativeIndex", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1709:41:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8300, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1709:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8303, + "name": "baseLTVasCollateral", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1760:27:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8302, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1760:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8305, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1797:28:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8304, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1797:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8307, + "name": "liquidationDiscount", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1835:27:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8306, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1835:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8309, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1872:16:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8308, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1872:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8311, + "name": "aTokenAddress", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1982:21:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8310, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1982:7:28", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8313, + "name": "interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2101:35:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8312, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2101:7:28", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8315, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2147:26:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 8314, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "2147:6:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8317, + "name": "borrowingEnabled", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2371:21:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8316, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2371:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8319, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2402:29:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8318, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2402:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8321, + "name": "isFixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2441:29:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8320, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2441:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8323, + "name": "isActive", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2480:13:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8322, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2480:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "ReserveData", + "nodeType": "StructDefinition", + "scope": 8994, + "src": "1226:1274:28", + "visibility": "public" + }, + { + "body": { + "id": 8353, + "nodeType": "Block", + "src": "2746:205:28", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8334, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8331, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8326, + "src": "2761:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8332, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "2761:20:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8333, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2785:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "2761:25:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8337, + "nodeType": "IfStatement", + "src": "2757:39:28", + "trueBody": { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8335, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2795:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 8330, + "id": 8336, + "nodeType": "Return", + "src": "2788:8:28" + } + }, + { + "assignments": [ + 8339 + ], + "declarations": [ + { + "constant": false, + "id": 8339, + "name": "totalBorrows", + "nodeType": "VariableDeclaration", + "scope": 8353, + "src": "2807:20:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8338, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2807:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8346, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8343, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8326, + "src": "2858:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8344, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "2858:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8340, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8326, + "src": "2830:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8341, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "2830:23:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8342, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "2830:27:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8345, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2830:55:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2807:78:28" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8349, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8326, + "src": "2923:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8350, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "2923:20:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8347, + "name": "totalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8339, + "src": "2903:12:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8348, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "2903:19:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8351, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2903:41:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8330, + "id": 8352, + "nodeType": "Return", + "src": "2896:48:28" + } + ] + }, + "documentation": "@notice returns the utilization rate U of a specific reserve\n@dev the utilization rate is in ray (27 decimals precision)", + "id": 8354, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveUtilizationRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8327, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8326, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8354, + "src": "2687:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8325, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "2687:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2686:27:28" + }, + "returnParameters": { + "id": 8330, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8329, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8354, + "src": "2737:7:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8328, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2737:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2736:9:28" + }, + "scope": 8994, + "src": "2652:299:28", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8376, + "nodeType": "Block", + "src": "3233:237:28", + "statements": [ + { + "assignments": [ + 8362 + ], + "declarations": [ + { + "constant": false, + "id": 8362, + "name": "cumulated", + "nodeType": "VariableDeclaration", + "scope": 8376, + "src": "3244:17:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8361, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3244:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8373, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8370, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8356, + "src": "3397:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8371, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "3397:37:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8364, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8356, + "src": "3304:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8365, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8289, + "src": "3304:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8366, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8356, + "src": "3347:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8367, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "3347:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "id": 8363, + "name": "calculateCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8993, + "src": "3264:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint40_$returns$_t_uint256_$", + "typeString": "function (uint256,uint40) view returns (uint256)" + } + }, + "id": 8368, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3264:112:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8369, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "3264:132:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8372, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3264:171:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3244:191:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8374, + "name": "cumulated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8362, + "src": "3453:9:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8360, + "id": 8375, + "nodeType": "Return", + "src": "3446:16:28" + } + ] + }, + "documentation": "@notice returns the utilization rate U of a specific reserve\n@dev the utilization rate is in ray (27 decimals precision)", + "id": 8377, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getNormalizedIncome", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8357, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8356, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8377, + "src": "3131:40:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8355, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "3131:23:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3130:42:28" + }, + "returnParameters": { + "id": 8360, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8359, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8377, + "src": "3220:7:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8358, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3220:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3219:9:28" + }, + "scope": 8994, + "src": "3102:368:28", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8431, + "nodeType": "Block", + "src": "3768:781:28", + "statements": [ + { + "assignments": [ + 8383 + ], + "declarations": [ + { + "constant": false, + "id": 8383, + "name": "utilizationRate", + "nodeType": "VariableDeclaration", + "scope": 8431, + "src": "3779:23:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8382, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3779:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8387, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8385, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "3831:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + ], + "id": 8384, + "name": "getReserveUtilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8354, + "src": "3805:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 8386, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3805:32:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3779:58:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8390, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 8388, + "name": "utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8383, + "src": "3852:15:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8389, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3870:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3852:19:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8430, + "nodeType": "IfStatement", + "src": "3848:695:28", + "trueBody": { + "id": 8429, + "nodeType": "Block", + "src": "3873:670:28", + "statements": [ + { + "assignments": [ + 8392 + ], + "declarations": [ + { + "constant": false, + "id": 8392, + "name": "cumulatedLiquidityInterest", + "nodeType": "VariableDeclaration", + "scope": 8429, + "src": "3955:34:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8391, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3955:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8399, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8394, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4019:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8395, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8289, + "src": "4019:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8396, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4047:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8397, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "4047:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "id": 8393, + "name": "calculateCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8993, + "src": "3992:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint40_$returns$_t_uint256_$", + "typeString": "function (uint256,uint40) view returns (uint256)" + } + }, + "id": 8398, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3992:81:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3955:118:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8408, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8400, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4088:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8402, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "4088:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8405, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4176:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8406, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "4176:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8403, + "name": "cumulatedLiquidityInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8392, + "src": "4125:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8404, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "4125:33:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8407, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4125:99:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4088:136:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8409, + "nodeType": "ExpressionStatement", + "src": "4088:136:28" + }, + { + "assignments": [ + 8411 + ], + "declarations": [ + { + "constant": false, + "id": 8411, + "name": "cumulatedVariableBorrowInterest", + "nodeType": "VariableDeclaration", + "scope": 8429, + "src": "4239:39:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8410, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4239:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8418, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8413, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4308:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8414, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8295, + "src": "4308:31:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8415, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4341:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8416, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "4341:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "id": 8412, + "name": "calculateCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8993, + "src": "4281:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint40_$returns$_t_uint256_$", + "typeString": "function (uint256,uint40) view returns (uint256)" + } + }, + "id": 8417, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4281:86:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4239:128:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8427, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8419, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4381:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8421, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "4381:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8424, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4479:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8425, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "4479:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8422, + "name": "cumulatedVariableBorrowInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8411, + "src": "4423:31:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8423, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "4423:38:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8426, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4423:109:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4381:151:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8428, + "nodeType": "ExpressionStatement", + "src": "4381:151:28" + } + ] + } + } + ] + }, + "documentation": "@notice Updates the liquidity cumulative index Ci and variable borrow cumulative index Bvc. Refer to the whitepaper for\na formal specification.\n@dev Ci and Bvc are in ray (27 decimals precision)", + "id": 8432, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "updateCumulativeIndexes", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8380, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8379, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8432, + "src": "3733:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8378, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "3733:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3732:27:28" + }, + "returnParameters": { + "id": 8381, + "nodeType": "ParameterList", + "parameters": [], + "src": "3768:0:28" + }, + "scope": 8994, + "src": "3700:849:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8470, + "nodeType": "Block", + "src": "4641:324:28", + "statements": [ + { + "assignments": [ + 8440 + ], + "declarations": [ + { + "constant": false, + "id": 8440, + "name": "amountToLiquidityRatio", + "nodeType": "VariableDeclaration", + "scope": 8470, + "src": "4652:30:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8439, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4652:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8450, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8445, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8434, + "src": "4711:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8446, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "4711:20:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8447, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "4711:29:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8448, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4711:31:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8441, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8436, + "src": "4685:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8442, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "4685:16:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8443, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4685:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8444, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "4685:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8449, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4685:58:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4652:91:28" + }, + { + "assignments": [ + 8452 + ], + "declarations": [ + { + "constant": false, + "id": 8452, + "name": "cumulatedLiquidity", + "nodeType": "VariableDeclaration", + "scope": 8470, + "src": "4754:26:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8451, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4754:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8459, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8455, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "4810:10:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 8456, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "4810:14:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 8457, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4810:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8453, + "name": "amountToLiquidityRatio", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8440, + "src": "4783:22:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8454, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "4783:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8458, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4783:44:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4754:73:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8468, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8460, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8434, + "src": "4838:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8462, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "4838:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8465, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8434, + "src": "4914:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8466, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "4914:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8463, + "name": "cumulatedLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8452, + "src": "4875:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8464, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "4875:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8467, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4875:83:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4838:120:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8469, + "nodeType": "ExpressionStatement", + "src": "4838:120:28" + } + ] + }, + "documentation": null, + "id": 8471, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "cumulateToLiquidityIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8437, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8434, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8471, + "src": "4589:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8433, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "4589:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8436, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 8471, + "src": "4616:15:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8435, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4616:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4588:44:28" + }, + "returnParameters": { + "id": 8438, + "nodeType": "ParameterList", + "parameters": [], + "src": "4641:0:28" + }, + "scope": 8994, + "src": "4555:410:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8544, + "nodeType": "Block", + "src": "5146:623:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 8488, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8483, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5164:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8484, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "aTokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8311, + "src": "5164:19:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "30", + "id": 8486, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5195:1:28", + "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": 8485, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "5187:7:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 8487, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5187:10:28", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "5164:33:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "526573657276652068617320616c7265616479206265656e20696e697469616c697a6564", + "id": 8489, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5199:38:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5d0d844954f8672606921cf4eace0c42a4654dbd2d4d0107062db89c87c9eb95", + "typeString": "literal_string \"Reserve has already been initialized\"" + }, + "value": "Reserve has already been initialized" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_5d0d844954f8672606921cf4eace0c42a4654dbd2d4d0107062db89c87c9eb95", + "typeString": "literal_string \"Reserve has already been initialized\"" + } + ], + "id": 8482, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "5156:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8490, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5156:82:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8491, + "nodeType": "ExpressionStatement", + "src": "5156:82:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8495, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8492, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5253:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8493, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "5253:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8494, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5291:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "5253:39:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8505, + "nodeType": "IfStatement", + "src": "5249:181:28", + "trueBody": { + "id": 8504, + "nodeType": "Block", + "src": "5294:136:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8502, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8496, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5366:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8498, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "5366:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8499, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "5403:10:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 8500, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "5403:14:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 8501, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5403:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5366:53:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8503, + "nodeType": "ExpressionStatement", + "src": "5366:53:28" + } + ] + } + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8509, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8506, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5444:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8507, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "5444:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8508, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5487:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "5444:44:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8519, + "nodeType": "IfStatement", + "src": "5440:132:28", + "trueBody": { + "id": 8518, + "nodeType": "Block", + "src": "5489:83:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8516, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8510, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5503:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8512, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "5503:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8513, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "5545:10:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 8514, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "5545:14:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 8515, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5545:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5503:58:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8517, + "nodeType": "ExpressionStatement", + "src": "5503:58:28" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 8524, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8520, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5582:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8522, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "aTokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8311, + "src": "5582:19:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8523, + "name": "_aTokenAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8475, + "src": "5604:14:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "5582:36:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 8525, + "nodeType": "ExpressionStatement", + "src": "5582:36:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8530, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8526, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5628:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8528, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "decimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 8309, + "src": "5628:14:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8529, + "name": "_decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8477, + "src": "5645:9:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5628:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8531, + "nodeType": "ExpressionStatement", + "src": "5628:26:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8536, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8532, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5665:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8534, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "interestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8313, + "src": "5665:33:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8535, + "name": "_interestRateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8479, + "src": "5701:28:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "5665:64:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 8537, + "nodeType": "ExpressionStatement", + "src": "5665:64:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8542, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8538, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5739:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8540, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 8323, + "src": "5739:14:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 8541, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5756:4:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "5739:21:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8543, + "nodeType": "ExpressionStatement", + "src": "5739:21:28" + } + ] + }, + "documentation": "@notice inits a reserve", + "id": 8545, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "init", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8480, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8473, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8545, + "src": "5030:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8472, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "5030:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8475, + "name": "_aTokenAddress", + "nodeType": "VariableDeclaration", + "scope": 8545, + "src": "5057:22:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8474, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5057:7:28", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8477, + "name": "_decimals", + "nodeType": "VariableDeclaration", + "scope": 8545, + "src": "5081:17:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8476, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5081:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8479, + "name": "_interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 8545, + "src": "5100:36:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8478, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5100:7:28", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5029:108:28" + }, + "returnParameters": { + "id": 8481, + "nodeType": "ParameterList", + "parameters": [], + "src": "5146:0:28" + }, + "scope": 8994, + "src": "5016:753:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 8572, + "nodeType": "Block", + "src": "5887:195:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 8556, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8553, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8547, + "src": "5905:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8554, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "5905:22:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 8555, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5931:5:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "5905:31:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5265736572766520697320616c726561647920656e61626c6564", + "id": 8557, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5938:28:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_abb5749947c1294c4ace42bb6cc722aea1d7121c692858ae05e58768b02d0e3a", + "typeString": "literal_string \"Reserve is already enabled\"" + }, + "value": "Reserve is already enabled" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_abb5749947c1294c4ace42bb6cc722aea1d7121c692858ae05e58768b02d0e3a", + "typeString": "literal_string \"Reserve is already enabled\"" + } + ], + "id": 8552, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "5897:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8558, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5897:70:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8559, + "nodeType": "ExpressionStatement", + "src": "5897:70:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8564, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8560, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8547, + "src": "5978:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8562, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "5978:22:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 8563, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6003:4:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "5978:29:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8565, + "nodeType": "ExpressionStatement", + "src": "5978:29:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8570, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8566, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8547, + "src": "6017:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8568, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8321, + "src": "6017:30:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8569, + "name": "_fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8549, + "src": "6050:23:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "6017:56:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8571, + "nodeType": "ExpressionStatement", + "src": "6017:56:28" + } + ] + }, + "documentation": null, + "id": 8573, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "enableBorrowing", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8550, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8547, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8573, + "src": "5809:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8546, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "5809:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8549, + "name": "_fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 8573, + "src": "5844:28:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8548, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "5844:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5799:79:28" + }, + "returnParameters": { + "id": 8551, + "nodeType": "ParameterList", + "parameters": [], + "src": "5887:0:28" + }, + "scope": 8994, + "src": "5775:307:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 8584, + "nodeType": "Block", + "src": "6149:47:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8582, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8578, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8575, + "src": "6159:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8580, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "6159:22:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 8581, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6184:5:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "6159:30:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8583, + "nodeType": "ExpressionStatement", + "src": "6159:30:28" + } + ] + }, + "documentation": null, + "id": 8585, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "disableBorrowing", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8576, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8575, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8585, + "src": "6114:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8574, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "6114:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6113:27:28" + }, + "returnParameters": { + "id": 8577, + "nodeType": "ParameterList", + "parameters": [], + "src": "6149:0:28" + }, + "scope": 8994, + "src": "6088:108:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 8633, + "nodeType": "Block", + "src": "6339:385:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 8598, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8595, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6357:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8596, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "6357:30:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 8597, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6391:5:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "6357:39:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5265736572766520697320616c726561647920656e61626c656420617320636f6c6c61746572616c", + "id": 8599, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6398:42:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_61003634410f8cfd7fb2cfbd42f11d0d4b18e88e405ad25a3c8fa02708decbd6", + "typeString": "literal_string \"Reserve is already enabled as collateral\"" + }, + "value": "Reserve is already enabled as collateral" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_61003634410f8cfd7fb2cfbd42f11d0d4b18e88e405ad25a3c8fa02708decbd6", + "typeString": "literal_string \"Reserve is already enabled as collateral\"" + } + ], + "id": 8594, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "6349:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8600, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6349:92:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8601, + "nodeType": "ExpressionStatement", + "src": "6349:92:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8606, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8602, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6452:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8604, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "6452:30:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 8605, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6485:4:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "6452:37:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8607, + "nodeType": "ExpressionStatement", + "src": "6452:37:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8612, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8608, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6499:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8610, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "baseLTVasCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8303, + "src": "6499:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8611, + "name": "_baseLTVasCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8589, + "src": "6527:20:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6499:48:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8613, + "nodeType": "ExpressionStatement", + "src": "6499:48:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8618, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8614, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6557:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8616, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 8305, + "src": "6557:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8617, + "name": "_liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8591, + "src": "6586:21:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6557:50:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8619, + "nodeType": "ExpressionStatement", + "src": "6557:50:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8623, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8620, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6622:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8621, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "6622:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8622, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6660:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "6622:39:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8632, + "nodeType": "IfStatement", + "src": "6618:98:28", + "trueBody": { + "expression": { + "argumentTypes": null, + "id": 8630, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8624, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6663:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8626, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "6663:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8627, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "6700:10:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 8628, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "6700:14:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 8629, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6700:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6663:53:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8631, + "nodeType": "ExpressionStatement", + "src": "6663:53:28" + } + } + ] + }, + "documentation": null, + "id": 8634, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "enableAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8592, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8587, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8634, + "src": "6230:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8586, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "6230:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8589, + "name": "_baseLTVasCollateral", + "nodeType": "VariableDeclaration", + "scope": 8634, + "src": "6257:28:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8588, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6257:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8591, + "name": "_liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 8634, + "src": "6287:29:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8590, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6287:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6229:88:28" + }, + "returnParameters": { + "id": 8593, + "nodeType": "ParameterList", + "parameters": [], + "src": "6339:0:28" + }, + "scope": 8994, + "src": "6202:522:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 8645, + "nodeType": "Block", + "src": "6794:55:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8643, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8639, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8636, + "src": "6804:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8641, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "6804:30:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 8642, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6837:5:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "6804:38:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8644, + "nodeType": "ExpressionStatement", + "src": "6804:38:28" + } + ] + }, + "documentation": null, + "id": 8646, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "disableAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8637, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8636, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8646, + "src": "6759:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8635, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "6759:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6758:27:28" + }, + "returnParameters": { + "id": 8638, + "nodeType": "ParameterList", + "parameters": [], + "src": "6794:0:28" + }, + "scope": 8994, + "src": "6730:119:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 8733, + "nodeType": "Block", + "src": "7097:1145:28", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8658, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8655, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7112:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8656, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "7112:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8657, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7144:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "7112:33:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8661, + "nodeType": "IfStatement", + "src": "7108:47:28", + "trueBody": { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8659, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7154:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 8654, + "id": 8660, + "nodeType": "Return", + "src": "7147:8:28" + } + }, + { + "assignments": [ + 8663 + ], + "declarations": [ + { + "constant": false, + "id": 8663, + "name": "principalBorrowBalanceRay", + "nodeType": "VariableDeclaration", + "scope": 8733, + "src": "7166:33:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8662, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7166:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8668, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8664, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7202:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8665, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "7202:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8666, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "7202:37:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8667, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7202:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7166:75:28" + }, + { + "assignments": [ + 8670 + ], + "declarations": [ + { + "constant": false, + "id": 8670, + "name": "compoundedBalance", + "nodeType": "VariableDeclaration", + "scope": 8733, + "src": "7251:25:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8669, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7251:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8672, + "initialValue": { + "argumentTypes": null, + "hexValue": "30", + "id": 8671, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7279:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "nodeType": "VariableDeclarationStatement", + "src": "7251:29:28" + }, + { + "assignments": [ + 8674 + ], + "declarations": [ + { + "constant": false, + "id": 8674, + "name": "cumulatedInterest", + "nodeType": "VariableDeclaration", + "scope": 8733, + "src": "7290:25:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8673, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7290:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8676, + "initialValue": { + "argumentTypes": null, + "hexValue": "30", + "id": 8675, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7318:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "nodeType": "VariableDeclarationStatement", + "src": "7290:29:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8680, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8677, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7334:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8678, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "7334:21:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8679, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7358:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "7334:25:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 8708, + "nodeType": "Block", + "src": "7496:298:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8706, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8691, + "name": "cumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8674, + "src": "7538:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8703, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7743:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8704, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8274, + "src": "7743:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8699, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8650, + "src": "7675:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8700, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "7675:42:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8693, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8650, + "src": "7585:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8694, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8295, + "src": "7585:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8695, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8650, + "src": "7621:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8696, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "7621:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "id": 8692, + "name": "calculateCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8993, + "src": "7558:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint40_$returns$_t_uint256_$", + "typeString": "function (uint256,uint40) view returns (uint256)" + } + }, + "id": 8697, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7558:92:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8698, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "7558:116:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8701, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7558:160:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8702, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "7558:184:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8705, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7558:225:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7538:245:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8707, + "nodeType": "ExpressionStatement", + "src": "7538:245:28" + } + ] + }, + "id": 8709, + "nodeType": "IfStatement", + "src": "7330:464:28", + "trueBody": { + "id": 8690, + "nodeType": "Block", + "src": "7361:121:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8688, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8681, + "name": "cumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8674, + "src": "7375:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8683, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7422:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8684, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "7422:21:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8685, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7445:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8686, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8280, + "src": "7445:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "id": 8682, + "name": "calculateCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8993, + "src": "7395:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint40_$returns$_t_uint256_$", + "typeString": "function (uint256,uint40) view returns (uint256)" + } + }, + "id": 8687, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7395:76:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7375:96:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8689, + "nodeType": "ExpressionStatement", + "src": "7375:96:28" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 8717, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8710, + "name": "compoundedBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8670, + "src": "7804:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8713, + "name": "cumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8674, + "src": "7870:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8711, + "name": "principalBorrowBalanceRay", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8663, + "src": "7824:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8712, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "7824:45:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8714, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7824:64:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8715, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayToWad", + "nodeType": "MemberAccess", + "referencedDeclaration": 9160, + "src": "7824:86:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8716, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7824:88:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7804:108:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8718, + "nodeType": "ExpressionStatement", + "src": "7804:108:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8722, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 8719, + "name": "compoundedBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8670, + "src": "7926:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8720, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7947:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8721, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "7947:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7926:49:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8730, + "nodeType": "IfStatement", + "src": "7923:278:28", + "trueBody": { + "id": 8729, + "nodeType": "Block", + "src": "7977:224:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "31", + "id": 8726, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8184:5:28", + "subdenomination": "wei", + "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" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8723, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "8151:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8724, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "8151:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8725, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8151:32:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8727, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8151:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8654, + "id": 8728, + "nodeType": "Return", + "src": "8144:46:28" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 8731, + "name": "compoundedBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8670, + "src": "8218:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8654, + "id": 8732, + "nodeType": "Return", + "src": "8211:24:28" + } + ] + }, + "documentation": "@dev user specific functions", + "id": 8734, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getCompoundedBorrowBalance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8651, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8648, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8734, + "src": "6949:41:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8647, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "6949:27:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8650, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8734, + "src": "7000:40:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8649, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "7000:23:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6939:102:28" + }, + "returnParameters": { + "id": 8654, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8653, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8734, + "src": "7088:7:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8652, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7088:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7087:9:28" + }, + "scope": 8994, + "src": "6904:1338:28", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8792, + "nodeType": "Block", + "src": "8373:658:28", + "statements": [ + { + "assignments": [ + 8744 + ], + "declarations": [ + { + "constant": false, + "id": 8744, + "name": "previousTotalBorrowFixed", + "nodeType": "VariableDeclaration", + "scope": 8792, + "src": "8383:32:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8743, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8383:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8747, + "initialValue": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8745, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8418:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8746, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "8418:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8383:61:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8756, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8748, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8495:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8750, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "8495:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8754, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8738, + "src": "8555:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8751, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8524:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8752, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "8524:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8753, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8524:30:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8755, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8524:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8495:68:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8757, + "nodeType": "ExpressionStatement", + "src": "8495:68:28" + }, + { + "assignments": [ + 8759 + ], + "declarations": [ + { + "constant": false, + "id": 8759, + "name": "weightedLastBorrow", + "nodeType": "VariableDeclaration", + "scope": 8792, + "src": "8660:26:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8758, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8660:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8766, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8764, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8740, + "src": "8715:5:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8760, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8738, + "src": "8689:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8761, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "8689:16:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8762, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8689:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8763, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "8689:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8765, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8689:32:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8660:61:28" + }, + { + "assignments": [ + 8768 + ], + "declarations": [ + { + "constant": false, + "id": 8768, + "name": "weightedPreviousTotalBorrows", + "nodeType": "VariableDeclaration", + "scope": 8792, + "src": "8731:36:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8767, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8731:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8776, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8773, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8813:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8774, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "8813:38:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8769, + "name": "previousTotalBorrowFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8744, + "src": "8770:24:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8770, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "8770:33:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8771, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8770:35:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8772, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "8770:42:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8775, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8770:82:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8731:121:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8790, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8777, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8863:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8779, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "8863:38:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8785, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8977:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8786, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "8977:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8787, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "8977:35:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8788, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8977:37:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8782, + "name": "weightedPreviousTotalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8768, + "src": "8927:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8780, + "name": "weightedLastBorrow", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8759, + "src": "8904:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8781, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8904:22:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8783, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8904:52:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8784, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "8904:59:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8789, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8904:120:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8863:161:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8791, + "nodeType": "ExpressionStatement", + "src": "8863:161:28" + } + ] + }, + "documentation": null, + "id": 8793, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "increaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8741, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8736, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8793, + "src": "8303:28:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8735, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "8303:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8738, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 8793, + "src": "8333:15:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8737, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8333:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8740, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 8793, + "src": "8350:13:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8739, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8350:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8302:62:28" + }, + "returnParameters": { + "id": 8742, + "nodeType": "ParameterList", + "parameters": [], + "src": "8373:0:28" + }, + "scope": 8994, + "src": "8248:783:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8879, + "nodeType": "Block", + "src": "9162:1038:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8806, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8803, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9181:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8804, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "9181:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 8805, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8797, + "src": "9211:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9181:37:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c696420616d6f756e7420746f206465637265617365", + "id": 8807, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9220:28:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c8d0f56d08c490ced93c4429023a928b0880845010be7ece59e5a9b8991fe0bb", + "typeString": "literal_string \"Invalid amount to decrease\"" + }, + "value": "Invalid amount to decrease" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_c8d0f56d08c490ced93c4429023a928b0880845010be7ece59e5a9b8991fe0bb", + "typeString": "literal_string \"Invalid amount to decrease\"" + } + ], + "id": 8802, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "9173:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8808, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9173:76:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8809, + "nodeType": "ExpressionStatement", + "src": "9173:76:28" + }, + { + "assignments": [ + 8811 + ], + "declarations": [ + { + "constant": false, + "id": 8811, + "name": "previousTotalBorrowFixed", + "nodeType": "VariableDeclaration", + "scope": 8879, + "src": "9260:32:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8810, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9260:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8814, + "initialValue": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8812, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9295:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8813, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "9295:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9260:61:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8823, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8815, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9373:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8817, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "9373:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8821, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8797, + "src": "9433:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8818, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9402:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8819, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "9402:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8820, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "9402:30:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8822, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9402:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9373:68:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8824, + "nodeType": "ExpressionStatement", + "src": "9373:68:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8828, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8825, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9456:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8826, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "9456:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8827, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9486:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "9456:31:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8837, + "nodeType": "IfStatement", + "src": "9452:171:28", + "trueBody": { + "id": 8836, + "nodeType": "Block", + "src": "9489:134:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8833, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8829, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9503:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8831, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "9503:38:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "30", + "id": 8832, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9544:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "9503:42:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8834, + "nodeType": "ExpressionStatement", + "src": "9503:42:28" + }, + { + "expression": null, + "functionReturnParameters": 8801, + "id": 8835, + "nodeType": "Return", + "src": "9606:7:28" + } + ] + } + }, + { + "assignments": [ + 8839 + ], + "declarations": [ + { + "constant": false, + "id": 8839, + "name": "weightedLastBorrow", + "nodeType": "VariableDeclaration", + "scope": 8879, + "src": "9719:26:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8838, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9719:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8846, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8844, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8799, + "src": "9774:5:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8840, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8797, + "src": "9748:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8841, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "9748:16:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8842, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9748:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8843, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "9748:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8845, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9748:32:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9719:61:28" + }, + { + "assignments": [ + 8848 + ], + "declarations": [ + { + "constant": false, + "id": 8848, + "name": "weightedPreviousTotalBorrows", + "nodeType": "VariableDeclaration", + "scope": 8879, + "src": "9790:36:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8847, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9790:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8856, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8853, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9872:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8854, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "9872:38:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8849, + "name": "previousTotalBorrowFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8811, + "src": "9829:24:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8850, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "9829:33:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8851, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9829:35:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8852, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "9829:42:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8855, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9829:82:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9790:121:28" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8860, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 8858, + "name": "weightedPreviousTotalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8848, + "src": "9930:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 8859, + "name": "weightedLastBorrow", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8839, + "src": "9962:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9930:50:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520616d6f756e747320746f2073756273747261637420646f6e2774206d61746368", + "id": 8861, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9982:38:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8e54967fa0a6f572bd48cebcb4e70fb3faec6fe98c2f30acd1ffba83338b62eb", + "typeString": "literal_string \"The amounts to substract don't match\"" + }, + "value": "The amounts to substract don't match" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_8e54967fa0a6f572bd48cebcb4e70fb3faec6fe98c2f30acd1ffba83338b62eb", + "typeString": "literal_string \"The amounts to substract don't match\"" + } + ], + "id": 8857, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "9922:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8862, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9922:99:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8863, + "nodeType": "ExpressionStatement", + "src": "9922:99:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8877, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8864, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "10032:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8866, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "10032:38:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8872, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "10146:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8873, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "10146:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8874, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "10146:35:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8875, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10146:37:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8869, + "name": "weightedLastBorrow", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8839, + "src": "10106:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8867, + "name": "weightedPreviousTotalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8848, + "src": "10073:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8868, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "10073:32:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8870, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10073:52:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8871, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "10073:59:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8876, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10073:120:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10032:161:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8878, + "nodeType": "ExpressionStatement", + "src": "10032:161:28" + } + ] + }, + "documentation": null, + "id": 8880, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "decreaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8800, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8795, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8880, + "src": "9092:28:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8794, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "9092:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8797, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 8880, + "src": "9122:15:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8796, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9122:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8799, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 8880, + "src": "9139:13:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8798, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9139:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9091:62:28" + }, + "returnParameters": { + "id": 8801, + "nodeType": "ParameterList", + "parameters": [], + "src": "9162:0:28" + }, + "scope": 8994, + "src": "9037:1163:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8897, + "nodeType": "Block", + "src": "10299:91:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8895, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8887, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8882, + "src": "10309:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8889, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "10309:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8893, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8884, + "src": "10375:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8890, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8882, + "src": "10341:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8891, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "10341:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8892, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "10341:33:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8894, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10341:42:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10309:74:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8896, + "nodeType": "ExpressionStatement", + "src": "10309:74:28" + } + ] + }, + "documentation": null, + "id": 8898, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "increaseTotalBorrowsVariable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8885, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8882, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8898, + "src": "10244:28:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8881, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "10244:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8884, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 8898, + "src": "10274:15:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8883, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10274:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10243:47:28" + }, + "returnParameters": { + "id": 8886, + "nodeType": "ParameterList", + "parameters": [], + "src": "10299:0:28" + }, + "scope": 8994, + "src": "10206:184:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8923, + "nodeType": "Block", + "src": "10489:235:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8909, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8906, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8900, + "src": "10507:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8907, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "10507:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 8908, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8902, + "src": "10540:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10507:40:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520616d6f756e742074686174206973206265696e672073756273747261637465642066726f6d20746865207661726961626c6520746f74616c20626f72726f777320697320696e636f7272656374", + "id": 8910, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "10549:83:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_691c1063918e09d52df2584348154ba2bb9fcfb9dd1d5fe8b9028f3528a10b92", + "typeString": "literal_string \"The amount that is being substracted from the variable total borrows is incorrect\"" + }, + "value": "The amount that is being substracted from the variable total borrows is incorrect" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_691c1063918e09d52df2584348154ba2bb9fcfb9dd1d5fe8b9028f3528a10b92", + "typeString": "literal_string \"The amount that is being substracted from the variable total borrows is incorrect\"" + } + ], + "id": 8905, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "10499:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8911, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10499:134:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8912, + "nodeType": "ExpressionStatement", + "src": "10499:134:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8921, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8913, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8900, + "src": "10643:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8915, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "10643:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8919, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8902, + "src": "10709:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8916, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8900, + "src": "10675:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8917, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "10675:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8918, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "10675:33:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8920, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10675:42:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10643:74:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8922, + "nodeType": "ExpressionStatement", + "src": "10643:74:28" + } + ] + }, + "documentation": null, + "id": 8924, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "decreaseTotalBorrowsVariable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8903, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8900, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8924, + "src": "10434:28:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8899, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "10434:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8902, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 8924, + "src": "10464:15:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8901, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10464:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10433:47:28" + }, + "returnParameters": { + "id": 8904, + "nodeType": "ParameterList", + "parameters": [], + "src": "10489:0:28" + }, + "scope": 8994, + "src": "10396:328:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8938, + "nodeType": "Block", + "src": "10791:106:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8936, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8929, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8926, + "src": "10836:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8931, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "10836:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8933, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "10874:5:28", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 8934, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "10874:15:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 8932, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "10867:6:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint40_$", + "typeString": "type(uint40)" + }, + "typeName": "uint40" + }, + "id": 8935, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10867:23:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "src": "10836:54:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "id": 8937, + "nodeType": "ExpressionStatement", + "src": "10836:54:28" + } + ] + }, + "documentation": null, + "id": 8939, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLastUpdate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8927, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8926, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8939, + "src": "10753:28:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8925, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "10753:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10752:30:28" + }, + "returnParameters": { + "id": 8928, + "nodeType": "ParameterList", + "parameters": [], + "src": "10791:0:28" + }, + "scope": 8994, + "src": "10730:167:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8953, + "nodeType": "Block", + "src": "11001:83:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8949, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8941, + "src": "11048:7:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8950, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "11048:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8946, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8941, + "src": "11018:7:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8947, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "11018:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8948, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "11018:29:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8951, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11018:59:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8945, + "id": 8952, + "nodeType": "Return", + "src": "11011:66:28" + } + ] + }, + "documentation": null, + "id": 8954, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getTotalBorrows", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8942, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8941, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 8954, + "src": "10928:39:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8940, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "10928:23:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10927:41:28" + }, + "returnParameters": { + "id": 8945, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8944, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8954, + "src": "10992:7:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8943, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10992:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10991:9:28" + }, + "scope": 8994, + "src": "10903:181:28", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8992, + "nodeType": "Block", + "src": "11268:275:28", + "statements": [ + { + "assignments": [ + 8964 + ], + "declarations": [ + { + "constant": false, + "id": 8964, + "name": "timeDifference", + "nodeType": "VariableDeclaration", + "scope": 8992, + "src": "11314:22:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8963, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11314:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8970, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8968, + "name": "_lastUpdateTimestamp", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8958, + "src": "11359:20:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8965, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "11339:5:28", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 8966, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11339:15:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8967, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "11339:19:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8969, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11339:41:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "11314:66:28" + }, + { + "assignments": [ + 8972 + ], + "declarations": [ + { + "constant": false, + "id": 8972, + "name": "timeDelta", + "nodeType": "VariableDeclaration", + "scope": 8992, + "src": "11391:17:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8971, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11391:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8981, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8977, + "name": "SECONDS_PER_YEAR", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8270, + "src": "11444:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8978, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "11444:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8979, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11444:27:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8973, + "name": "timeDifference", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8964, + "src": "11411:14:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8974, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "11411:23:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8975, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11411:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8976, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "11411:32:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8980, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11411:61:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "11391:81:28" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8987, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "11519:10:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 8988, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "11519:14:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 8989, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11519:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8984, + "name": "timeDelta", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8972, + "src": "11504:9:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8982, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8956, + "src": "11491:5:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8983, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "11491:12:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8985, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11491:23:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8986, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "11491:27:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8990, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11491:45:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8962, + "id": 8991, + "nodeType": "Return", + "src": "11484:52:28" + } + ] + }, + "documentation": "@dev function to calculate cumulated interest", + "id": 8993, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateCumulatedInterest", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8959, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8956, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 8993, + "src": "11194:13:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8955, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11194:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8958, + "name": "_lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 8993, + "src": "11208:27:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 8957, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "11208:6:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11193:43:28" + }, + "returnParameters": { + "id": 8962, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8961, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8993, + "src": "11259:7:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8960, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11259:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11258:9:28" + }, + "scope": 8994, + "src": "11158:385:28", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 8995, + "src": "399:11147:28" + } + ], + "src": "0:11547:28" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "exportedSymbols": { + "CoreLibrary": [ + 8994 + ] + }, + "id": 8995, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 8256, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:28" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 8257, + "nodeType": "ImportDirective", + "scope": 8995, + "sourceUnit": 11141, + "src": "25:59:28", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "./WadRayMath.sol", + "id": 8258, + "nodeType": "ImportDirective", + "scope": 8995, + "sourceUnit": 9175, + "src": "85:26:28", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "library", + "documentation": "***********************************************************************************\n@title CoreLibrary library\n@author Aave\n@notice Defines the data structures of the reserves and the user data************************************************************************************", + "fullyImplemented": true, + "id": 8994, + "linearizedBaseContracts": [ + 8994 + ], + "name": "CoreLibrary", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 8261, + "libraryName": { + "contractScope": null, + "id": 8259, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "431:8:28", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "425:27:28", + "typeName": { + "id": 8260, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "444:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 8264, + "libraryName": { + "contractScope": null, + "id": 8262, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "463:10:28", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "457:29:28", + "typeName": { + "id": 8263, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "478:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "canonicalName": "CoreLibrary.InterestRateMode", + "id": 8267, + "members": [ + { + "id": 8265, + "name": "FIXED", + "nodeType": "EnumValue", + "src": "515:5:28" + }, + { + "id": 8266, + "name": "VARIABLE", + "nodeType": "EnumValue", + "src": "522:8:28" + } + ], + "name": "InterestRateMode", + "nodeType": "EnumDefinition", + "src": "492:39:28" + }, + { + "constant": true, + "id": 8270, + "name": "SECONDS_PER_YEAR", + "nodeType": "VariableDeclaration", + "scope": 8994, + "src": "537:44:28", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8268, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "537:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "333635", + "id": 8269, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "573:8:28", + "subdenomination": "days", + "typeDescriptions": { + "typeIdentifier": "t_rational_31536000_by_1", + "typeString": "int_const 31536000" + }, + "value": "365" + }, + "visibility": "internal" + }, + { + "canonicalName": "CoreLibrary.UserReserveData", + "id": 8283, + "members": [ + { + "constant": false, + "id": 8272, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "669:30:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8271, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "669:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8274, + "name": "lastVariableBorrowCumulativeIndex", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "815:41:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8273, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "815:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8276, + "name": "originationFee", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "914:22:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8275, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "914:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8278, + "name": "fixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "1006:23:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8277, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1006:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8280, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "1040:26:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 8279, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "1040:6:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8282, + "name": "useAsCollateral", + "nodeType": "VariableDeclaration", + "scope": 8283, + "src": "1193:20:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8281, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "1193:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "UserReserveData", + "nodeType": "StructDefinition", + "scope": 8994, + "src": "588:632:28", + "visibility": "public" + }, + { + "canonicalName": "CoreLibrary.ReserveData", + "id": 8324, + "members": [ + { + "constant": false, + "id": 8285, + "name": "totalLiquidity", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1390:22:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8284, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1390:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8287, + "name": "lastLiquidityCumulativeIndex", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1422:36:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8286, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1422:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8289, + "name": "currentLiquidityRate", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1468:28:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8288, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1468:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8291, + "name": "totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1506:25:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8290, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1506:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8293, + "name": "totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1541:28:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8292, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1541:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8295, + "name": "currentVariableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1579:33:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8294, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1579:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8297, + "name": "currentFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1622:30:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8296, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1622:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8299, + "name": "currentAverageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1662:37:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8298, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1662:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8301, + "name": "lastVariableBorrowCumulativeIndex", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1709:41:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8300, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1709:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8303, + "name": "baseLTVasCollateral", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1760:27:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8302, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1760:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8305, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1797:28:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8304, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1797:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8307, + "name": "liquidationDiscount", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1835:27:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8306, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1835:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8309, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1872:16:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8308, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1872:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8311, + "name": "aTokenAddress", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "1982:21:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8310, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1982:7:28", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8313, + "name": "interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2101:35:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8312, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2101:7:28", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8315, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2147:26:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 8314, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "2147:6:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8317, + "name": "borrowingEnabled", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2371:21:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8316, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2371:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8319, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2402:29:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8318, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2402:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8321, + "name": "isFixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2441:29:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8320, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2441:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8323, + "name": "isActive", + "nodeType": "VariableDeclaration", + "scope": 8324, + "src": "2480:13:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8322, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2480:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "ReserveData", + "nodeType": "StructDefinition", + "scope": 8994, + "src": "1226:1274:28", + "visibility": "public" + }, + { + "body": { + "id": 8353, + "nodeType": "Block", + "src": "2746:205:28", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8334, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8331, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8326, + "src": "2761:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8332, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "2761:20:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8333, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2785:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "2761:25:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8337, + "nodeType": "IfStatement", + "src": "2757:39:28", + "trueBody": { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8335, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2795:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 8330, + "id": 8336, + "nodeType": "Return", + "src": "2788:8:28" + } + }, + { + "assignments": [ + 8339 + ], + "declarations": [ + { + "constant": false, + "id": 8339, + "name": "totalBorrows", + "nodeType": "VariableDeclaration", + "scope": 8353, + "src": "2807:20:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8338, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2807:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8346, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8343, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8326, + "src": "2858:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8344, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "2858:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8340, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8326, + "src": "2830:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8341, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "2830:23:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8342, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "2830:27:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8345, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2830:55:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2807:78:28" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8349, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8326, + "src": "2923:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8350, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "2923:20:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8347, + "name": "totalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8339, + "src": "2903:12:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8348, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "2903:19:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8351, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2903:41:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8330, + "id": 8352, + "nodeType": "Return", + "src": "2896:48:28" + } + ] + }, + "documentation": "@notice returns the utilization rate U of a specific reserve\n@dev the utilization rate is in ray (27 decimals precision)", + "id": 8354, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveUtilizationRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8327, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8326, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8354, + "src": "2687:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8325, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "2687:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2686:27:28" + }, + "returnParameters": { + "id": 8330, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8329, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8354, + "src": "2737:7:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8328, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2737:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2736:9:28" + }, + "scope": 8994, + "src": "2652:299:28", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8376, + "nodeType": "Block", + "src": "3233:237:28", + "statements": [ + { + "assignments": [ + 8362 + ], + "declarations": [ + { + "constant": false, + "id": 8362, + "name": "cumulated", + "nodeType": "VariableDeclaration", + "scope": 8376, + "src": "3244:17:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8361, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3244:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8373, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8370, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8356, + "src": "3397:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8371, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "3397:37:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8364, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8356, + "src": "3304:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8365, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8289, + "src": "3304:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8366, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8356, + "src": "3347:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8367, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "3347:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "id": 8363, + "name": "calculateCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8993, + "src": "3264:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint40_$returns$_t_uint256_$", + "typeString": "function (uint256,uint40) view returns (uint256)" + } + }, + "id": 8368, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3264:112:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8369, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "3264:132:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8372, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3264:171:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3244:191:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8374, + "name": "cumulated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8362, + "src": "3453:9:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8360, + "id": 8375, + "nodeType": "Return", + "src": "3446:16:28" + } + ] + }, + "documentation": "@notice returns the utilization rate U of a specific reserve\n@dev the utilization rate is in ray (27 decimals precision)", + "id": 8377, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getNormalizedIncome", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8357, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8356, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8377, + "src": "3131:40:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8355, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "3131:23:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3130:42:28" + }, + "returnParameters": { + "id": 8360, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8359, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8377, + "src": "3220:7:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8358, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3220:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3219:9:28" + }, + "scope": 8994, + "src": "3102:368:28", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8431, + "nodeType": "Block", + "src": "3768:781:28", + "statements": [ + { + "assignments": [ + 8383 + ], + "declarations": [ + { + "constant": false, + "id": 8383, + "name": "utilizationRate", + "nodeType": "VariableDeclaration", + "scope": 8431, + "src": "3779:23:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8382, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3779:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8387, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8385, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "3831:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + ], + "id": 8384, + "name": "getReserveUtilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8354, + "src": "3805:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 8386, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3805:32:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3779:58:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8390, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 8388, + "name": "utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8383, + "src": "3852:15:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8389, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3870:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3852:19:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8430, + "nodeType": "IfStatement", + "src": "3848:695:28", + "trueBody": { + "id": 8429, + "nodeType": "Block", + "src": "3873:670:28", + "statements": [ + { + "assignments": [ + 8392 + ], + "declarations": [ + { + "constant": false, + "id": 8392, + "name": "cumulatedLiquidityInterest", + "nodeType": "VariableDeclaration", + "scope": 8429, + "src": "3955:34:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8391, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3955:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8399, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8394, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4019:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8395, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8289, + "src": "4019:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8396, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4047:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8397, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "4047:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "id": 8393, + "name": "calculateCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8993, + "src": "3992:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint40_$returns$_t_uint256_$", + "typeString": "function (uint256,uint40) view returns (uint256)" + } + }, + "id": 8398, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3992:81:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3955:118:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8408, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8400, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4088:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8402, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "4088:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8405, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4176:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8406, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "4176:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8403, + "name": "cumulatedLiquidityInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8392, + "src": "4125:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8404, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "4125:33:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8407, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4125:99:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4088:136:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8409, + "nodeType": "ExpressionStatement", + "src": "4088:136:28" + }, + { + "assignments": [ + 8411 + ], + "declarations": [ + { + "constant": false, + "id": 8411, + "name": "cumulatedVariableBorrowInterest", + "nodeType": "VariableDeclaration", + "scope": 8429, + "src": "4239:39:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8410, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4239:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8418, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8413, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4308:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8414, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8295, + "src": "4308:31:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8415, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4341:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8416, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "4341:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "id": 8412, + "name": "calculateCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8993, + "src": "4281:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint40_$returns$_t_uint256_$", + "typeString": "function (uint256,uint40) view returns (uint256)" + } + }, + "id": 8417, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4281:86:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4239:128:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8427, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8419, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4381:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8421, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "4381:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8424, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8379, + "src": "4479:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8425, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "4479:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8422, + "name": "cumulatedVariableBorrowInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8411, + "src": "4423:31:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8423, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "4423:38:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8426, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4423:109:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4381:151:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8428, + "nodeType": "ExpressionStatement", + "src": "4381:151:28" + } + ] + } + } + ] + }, + "documentation": "@notice Updates the liquidity cumulative index Ci and variable borrow cumulative index Bvc. Refer to the whitepaper for\na formal specification.\n@dev Ci and Bvc are in ray (27 decimals precision)", + "id": 8432, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "updateCumulativeIndexes", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8380, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8379, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8432, + "src": "3733:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8378, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "3733:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3732:27:28" + }, + "returnParameters": { + "id": 8381, + "nodeType": "ParameterList", + "parameters": [], + "src": "3768:0:28" + }, + "scope": 8994, + "src": "3700:849:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8470, + "nodeType": "Block", + "src": "4641:324:28", + "statements": [ + { + "assignments": [ + 8440 + ], + "declarations": [ + { + "constant": false, + "id": 8440, + "name": "amountToLiquidityRatio", + "nodeType": "VariableDeclaration", + "scope": 8470, + "src": "4652:30:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8439, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4652:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8450, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8445, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8434, + "src": "4711:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8446, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "4711:20:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8447, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "4711:29:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8448, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4711:31:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8441, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8436, + "src": "4685:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8442, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "4685:16:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8443, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4685:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8444, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "4685:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8449, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4685:58:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4652:91:28" + }, + { + "assignments": [ + 8452 + ], + "declarations": [ + { + "constant": false, + "id": 8452, + "name": "cumulatedLiquidity", + "nodeType": "VariableDeclaration", + "scope": 8470, + "src": "4754:26:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8451, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4754:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8459, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8455, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "4810:10:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 8456, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "4810:14:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 8457, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4810:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8453, + "name": "amountToLiquidityRatio", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8440, + "src": "4783:22:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8454, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "4783:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8458, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4783:44:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4754:73:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8468, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8460, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8434, + "src": "4838:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8462, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "4838:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8465, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8434, + "src": "4914:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8466, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "4914:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8463, + "name": "cumulatedLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8452, + "src": "4875:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8464, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "4875:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8467, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4875:83:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4838:120:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8469, + "nodeType": "ExpressionStatement", + "src": "4838:120:28" + } + ] + }, + "documentation": null, + "id": 8471, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "cumulateToLiquidityIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8437, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8434, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8471, + "src": "4589:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8433, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "4589:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8436, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 8471, + "src": "4616:15:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8435, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4616:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4588:44:28" + }, + "returnParameters": { + "id": 8438, + "nodeType": "ParameterList", + "parameters": [], + "src": "4641:0:28" + }, + "scope": 8994, + "src": "4555:410:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8544, + "nodeType": "Block", + "src": "5146:623:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 8488, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8483, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5164:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8484, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "aTokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8311, + "src": "5164:19:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "30", + "id": 8486, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5195:1:28", + "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": 8485, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "5187:7:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 8487, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5187:10:28", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "5164:33:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "526573657276652068617320616c7265616479206265656e20696e697469616c697a6564", + "id": 8489, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5199:38:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5d0d844954f8672606921cf4eace0c42a4654dbd2d4d0107062db89c87c9eb95", + "typeString": "literal_string \"Reserve has already been initialized\"" + }, + "value": "Reserve has already been initialized" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_5d0d844954f8672606921cf4eace0c42a4654dbd2d4d0107062db89c87c9eb95", + "typeString": "literal_string \"Reserve has already been initialized\"" + } + ], + "id": 8482, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "5156:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8490, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5156:82:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8491, + "nodeType": "ExpressionStatement", + "src": "5156:82:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8495, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8492, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5253:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8493, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "5253:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8494, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5291:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "5253:39:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8505, + "nodeType": "IfStatement", + "src": "5249:181:28", + "trueBody": { + "id": 8504, + "nodeType": "Block", + "src": "5294:136:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8502, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8496, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5366:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8498, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "5366:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8499, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "5403:10:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 8500, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "5403:14:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 8501, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5403:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5366:53:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8503, + "nodeType": "ExpressionStatement", + "src": "5366:53:28" + } + ] + } + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8509, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8506, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5444:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8507, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "5444:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8508, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5487:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "5444:44:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8519, + "nodeType": "IfStatement", + "src": "5440:132:28", + "trueBody": { + "id": 8518, + "nodeType": "Block", + "src": "5489:83:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8516, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8510, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5503:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8512, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "5503:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8513, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "5545:10:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 8514, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "5545:14:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 8515, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5545:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5503:58:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8517, + "nodeType": "ExpressionStatement", + "src": "5503:58:28" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 8524, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8520, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5582:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8522, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "aTokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8311, + "src": "5582:19:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8523, + "name": "_aTokenAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8475, + "src": "5604:14:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "5582:36:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 8525, + "nodeType": "ExpressionStatement", + "src": "5582:36:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8530, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8526, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5628:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8528, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "decimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 8309, + "src": "5628:14:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8529, + "name": "_decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8477, + "src": "5645:9:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5628:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8531, + "nodeType": "ExpressionStatement", + "src": "5628:26:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8536, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8532, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5665:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8534, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "interestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8313, + "src": "5665:33:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8535, + "name": "_interestRateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8479, + "src": "5701:28:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "5665:64:28", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 8537, + "nodeType": "ExpressionStatement", + "src": "5665:64:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8542, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8538, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8473, + "src": "5739:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8540, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 8323, + "src": "5739:14:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 8541, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5756:4:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "5739:21:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8543, + "nodeType": "ExpressionStatement", + "src": "5739:21:28" + } + ] + }, + "documentation": "@notice inits a reserve", + "id": 8545, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "init", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8480, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8473, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8545, + "src": "5030:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8472, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "5030:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8475, + "name": "_aTokenAddress", + "nodeType": "VariableDeclaration", + "scope": 8545, + "src": "5057:22:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8474, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5057:7:28", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8477, + "name": "_decimals", + "nodeType": "VariableDeclaration", + "scope": 8545, + "src": "5081:17:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8476, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5081:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8479, + "name": "_interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 8545, + "src": "5100:36:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8478, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5100:7:28", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5029:108:28" + }, + "returnParameters": { + "id": 8481, + "nodeType": "ParameterList", + "parameters": [], + "src": "5146:0:28" + }, + "scope": 8994, + "src": "5016:753:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 8572, + "nodeType": "Block", + "src": "5887:195:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 8556, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8553, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8547, + "src": "5905:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8554, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "5905:22:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 8555, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5931:5:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "5905:31:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5265736572766520697320616c726561647920656e61626c6564", + "id": 8557, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5938:28:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_abb5749947c1294c4ace42bb6cc722aea1d7121c692858ae05e58768b02d0e3a", + "typeString": "literal_string \"Reserve is already enabled\"" + }, + "value": "Reserve is already enabled" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_abb5749947c1294c4ace42bb6cc722aea1d7121c692858ae05e58768b02d0e3a", + "typeString": "literal_string \"Reserve is already enabled\"" + } + ], + "id": 8552, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "5897:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8558, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5897:70:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8559, + "nodeType": "ExpressionStatement", + "src": "5897:70:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8564, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8560, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8547, + "src": "5978:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8562, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "5978:22:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 8563, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6003:4:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "5978:29:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8565, + "nodeType": "ExpressionStatement", + "src": "5978:29:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8570, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8566, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8547, + "src": "6017:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8568, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8321, + "src": "6017:30:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8569, + "name": "_fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8549, + "src": "6050:23:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "6017:56:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8571, + "nodeType": "ExpressionStatement", + "src": "6017:56:28" + } + ] + }, + "documentation": null, + "id": 8573, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "enableBorrowing", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8550, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8547, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8573, + "src": "5809:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8546, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "5809:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8549, + "name": "_fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 8573, + "src": "5844:28:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 8548, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "5844:4:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5799:79:28" + }, + "returnParameters": { + "id": 8551, + "nodeType": "ParameterList", + "parameters": [], + "src": "5887:0:28" + }, + "scope": 8994, + "src": "5775:307:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 8584, + "nodeType": "Block", + "src": "6149:47:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8582, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8578, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8575, + "src": "6159:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8580, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "6159:22:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 8581, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6184:5:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "6159:30:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8583, + "nodeType": "ExpressionStatement", + "src": "6159:30:28" + } + ] + }, + "documentation": null, + "id": 8585, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "disableBorrowing", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8576, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8575, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8585, + "src": "6114:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8574, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "6114:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6113:27:28" + }, + "returnParameters": { + "id": 8577, + "nodeType": "ParameterList", + "parameters": [], + "src": "6149:0:28" + }, + "scope": 8994, + "src": "6088:108:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 8633, + "nodeType": "Block", + "src": "6339:385:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 8598, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8595, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6357:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8596, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "6357:30:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 8597, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6391:5:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "6357:39:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5265736572766520697320616c726561647920656e61626c656420617320636f6c6c61746572616c", + "id": 8599, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6398:42:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_61003634410f8cfd7fb2cfbd42f11d0d4b18e88e405ad25a3c8fa02708decbd6", + "typeString": "literal_string \"Reserve is already enabled as collateral\"" + }, + "value": "Reserve is already enabled as collateral" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_61003634410f8cfd7fb2cfbd42f11d0d4b18e88e405ad25a3c8fa02708decbd6", + "typeString": "literal_string \"Reserve is already enabled as collateral\"" + } + ], + "id": 8594, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "6349:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8600, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6349:92:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8601, + "nodeType": "ExpressionStatement", + "src": "6349:92:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8606, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8602, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6452:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8604, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "6452:30:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 8605, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6485:4:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "6452:37:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8607, + "nodeType": "ExpressionStatement", + "src": "6452:37:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8612, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8608, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6499:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8610, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "baseLTVasCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8303, + "src": "6499:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8611, + "name": "_baseLTVasCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8589, + "src": "6527:20:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6499:48:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8613, + "nodeType": "ExpressionStatement", + "src": "6499:48:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8618, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8614, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6557:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8616, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 8305, + "src": "6557:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8617, + "name": "_liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8591, + "src": "6586:21:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6557:50:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8619, + "nodeType": "ExpressionStatement", + "src": "6557:50:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8623, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8620, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6622:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8621, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "6622:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8622, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6660:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "6622:39:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8632, + "nodeType": "IfStatement", + "src": "6618:98:28", + "trueBody": { + "expression": { + "argumentTypes": null, + "id": 8630, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8624, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8587, + "src": "6663:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8626, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "6663:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8627, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "6700:10:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 8628, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "6700:14:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 8629, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6700:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6663:53:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8631, + "nodeType": "ExpressionStatement", + "src": "6663:53:28" + } + } + ] + }, + "documentation": null, + "id": 8634, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "enableAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8592, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8587, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8634, + "src": "6230:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8586, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "6230:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8589, + "name": "_baseLTVasCollateral", + "nodeType": "VariableDeclaration", + "scope": 8634, + "src": "6257:28:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8588, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6257:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8591, + "name": "_liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 8634, + "src": "6287:29:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8590, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6287:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6229:88:28" + }, + "returnParameters": { + "id": 8593, + "nodeType": "ParameterList", + "parameters": [], + "src": "6339:0:28" + }, + "scope": 8994, + "src": "6202:522:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 8645, + "nodeType": "Block", + "src": "6794:55:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8643, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8639, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8636, + "src": "6804:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8641, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "6804:30:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 8642, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6837:5:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "6804:38:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 8644, + "nodeType": "ExpressionStatement", + "src": "6804:38:28" + } + ] + }, + "documentation": null, + "id": 8646, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "disableAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8637, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8636, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8646, + "src": "6759:25:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8635, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "6759:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6758:27:28" + }, + "returnParameters": { + "id": 8638, + "nodeType": "ParameterList", + "parameters": [], + "src": "6794:0:28" + }, + "scope": 8994, + "src": "6730:119:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 8733, + "nodeType": "Block", + "src": "7097:1145:28", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8658, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8655, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7112:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8656, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "7112:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8657, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7144:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "7112:33:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8661, + "nodeType": "IfStatement", + "src": "7108:47:28", + "trueBody": { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8659, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7154:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 8654, + "id": 8660, + "nodeType": "Return", + "src": "7147:8:28" + } + }, + { + "assignments": [ + 8663 + ], + "declarations": [ + { + "constant": false, + "id": 8663, + "name": "principalBorrowBalanceRay", + "nodeType": "VariableDeclaration", + "scope": 8733, + "src": "7166:33:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8662, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7166:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8668, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8664, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7202:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8665, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "7202:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8666, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "7202:37:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8667, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7202:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7166:75:28" + }, + { + "assignments": [ + 8670 + ], + "declarations": [ + { + "constant": false, + "id": 8670, + "name": "compoundedBalance", + "nodeType": "VariableDeclaration", + "scope": 8733, + "src": "7251:25:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8669, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7251:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8672, + "initialValue": { + "argumentTypes": null, + "hexValue": "30", + "id": 8671, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7279:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "nodeType": "VariableDeclarationStatement", + "src": "7251:29:28" + }, + { + "assignments": [ + 8674 + ], + "declarations": [ + { + "constant": false, + "id": 8674, + "name": "cumulatedInterest", + "nodeType": "VariableDeclaration", + "scope": 8733, + "src": "7290:25:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8673, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7290:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8676, + "initialValue": { + "argumentTypes": null, + "hexValue": "30", + "id": 8675, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7318:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "nodeType": "VariableDeclarationStatement", + "src": "7290:29:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8680, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8677, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7334:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8678, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "7334:21:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8679, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7358:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "7334:25:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 8708, + "nodeType": "Block", + "src": "7496:298:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8706, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8691, + "name": "cumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8674, + "src": "7538:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8703, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7743:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8704, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8274, + "src": "7743:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8699, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8650, + "src": "7675:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8700, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "7675:42:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8693, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8650, + "src": "7585:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8694, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8295, + "src": "7585:34:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8695, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8650, + "src": "7621:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8696, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "7621:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "id": 8692, + "name": "calculateCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8993, + "src": "7558:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint40_$returns$_t_uint256_$", + "typeString": "function (uint256,uint40) view returns (uint256)" + } + }, + "id": 8697, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7558:92:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8698, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "7558:116:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8701, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7558:160:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8702, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "7558:184:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8705, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7558:225:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7538:245:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8707, + "nodeType": "ExpressionStatement", + "src": "7538:245:28" + } + ] + }, + "id": 8709, + "nodeType": "IfStatement", + "src": "7330:464:28", + "trueBody": { + "id": 8690, + "nodeType": "Block", + "src": "7361:121:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8688, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8681, + "name": "cumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8674, + "src": "7375:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8683, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7422:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8684, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "7422:21:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8685, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7445:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8686, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8280, + "src": "7445:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "id": 8682, + "name": "calculateCumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8993, + "src": "7395:26:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint40_$returns$_t_uint256_$", + "typeString": "function (uint256,uint40) view returns (uint256)" + } + }, + "id": 8687, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7395:76:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7375:96:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8689, + "nodeType": "ExpressionStatement", + "src": "7375:96:28" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 8717, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8710, + "name": "compoundedBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8670, + "src": "7804:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8713, + "name": "cumulatedInterest", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8674, + "src": "7870:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8711, + "name": "principalBorrowBalanceRay", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8663, + "src": "7824:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8712, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "7824:45:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8714, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7824:64:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8715, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayToWad", + "nodeType": "MemberAccess", + "referencedDeclaration": 9160, + "src": "7824:86:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8716, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7824:88:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7804:108:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8718, + "nodeType": "ExpressionStatement", + "src": "7804:108:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8722, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 8719, + "name": "compoundedBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8670, + "src": "7926:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8720, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "7947:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8721, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "7947:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7926:49:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8730, + "nodeType": "IfStatement", + "src": "7923:278:28", + "trueBody": { + "id": 8729, + "nodeType": "Block", + "src": "7977:224:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "31", + "id": 8726, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8184:5:28", + "subdenomination": "wei", + "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" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8723, + "name": "_self", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8648, + "src": "8151:5:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 8724, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "8151:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8725, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8151:32:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8727, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8151:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8654, + "id": 8728, + "nodeType": "Return", + "src": "8144:46:28" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 8731, + "name": "compoundedBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8670, + "src": "8218:17:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8654, + "id": 8732, + "nodeType": "Return", + "src": "8211:24:28" + } + ] + }, + "documentation": "@dev user specific functions", + "id": 8734, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getCompoundedBorrowBalance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8651, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8648, + "name": "_self", + "nodeType": "VariableDeclaration", + "scope": 8734, + "src": "6949:41:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8647, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "6949:27:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8650, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8734, + "src": "7000:40:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8649, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "7000:23:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6939:102:28" + }, + "returnParameters": { + "id": 8654, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8653, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8734, + "src": "7088:7:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8652, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7088:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7087:9:28" + }, + "scope": 8994, + "src": "6904:1338:28", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8792, + "nodeType": "Block", + "src": "8373:658:28", + "statements": [ + { + "assignments": [ + 8744 + ], + "declarations": [ + { + "constant": false, + "id": 8744, + "name": "previousTotalBorrowFixed", + "nodeType": "VariableDeclaration", + "scope": 8792, + "src": "8383:32:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8743, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8383:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8747, + "initialValue": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8745, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8418:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8746, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "8418:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8383:61:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8756, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8748, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8495:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8750, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "8495:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8754, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8738, + "src": "8555:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8751, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8524:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8752, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "8524:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8753, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8524:30:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8755, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8524:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8495:68:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8757, + "nodeType": "ExpressionStatement", + "src": "8495:68:28" + }, + { + "assignments": [ + 8759 + ], + "declarations": [ + { + "constant": false, + "id": 8759, + "name": "weightedLastBorrow", + "nodeType": "VariableDeclaration", + "scope": 8792, + "src": "8660:26:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8758, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8660:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8766, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8764, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8740, + "src": "8715:5:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8760, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8738, + "src": "8689:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8761, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "8689:16:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8762, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8689:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8763, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "8689:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8765, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8689:32:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8660:61:28" + }, + { + "assignments": [ + 8768 + ], + "declarations": [ + { + "constant": false, + "id": 8768, + "name": "weightedPreviousTotalBorrows", + "nodeType": "VariableDeclaration", + "scope": 8792, + "src": "8731:36:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8767, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8731:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8776, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8773, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8813:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8774, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "8813:38:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8769, + "name": "previousTotalBorrowFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8744, + "src": "8770:24:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8770, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "8770:33:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8771, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8770:35:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8772, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "8770:42:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8775, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8770:82:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8731:121:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8790, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8777, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8863:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8779, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "8863:38:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8785, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8736, + "src": "8977:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8786, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "8977:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8787, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "8977:35:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8788, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8977:37:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8782, + "name": "weightedPreviousTotalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8768, + "src": "8927:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8780, + "name": "weightedLastBorrow", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8759, + "src": "8904:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8781, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8904:22:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8783, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8904:52:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8784, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "8904:59:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8789, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8904:120:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8863:161:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8791, + "nodeType": "ExpressionStatement", + "src": "8863:161:28" + } + ] + }, + "documentation": null, + "id": 8793, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "increaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8741, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8736, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8793, + "src": "8303:28:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8735, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "8303:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8738, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 8793, + "src": "8333:15:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8737, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8333:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8740, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 8793, + "src": "8350:13:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8739, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8350:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8302:62:28" + }, + "returnParameters": { + "id": 8742, + "nodeType": "ParameterList", + "parameters": [], + "src": "8373:0:28" + }, + "scope": 8994, + "src": "8248:783:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8879, + "nodeType": "Block", + "src": "9162:1038:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8806, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8803, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9181:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8804, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "9181:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 8805, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8797, + "src": "9211:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9181:37:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c696420616d6f756e7420746f206465637265617365", + "id": 8807, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9220:28:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c8d0f56d08c490ced93c4429023a928b0880845010be7ece59e5a9b8991fe0bb", + "typeString": "literal_string \"Invalid amount to decrease\"" + }, + "value": "Invalid amount to decrease" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_c8d0f56d08c490ced93c4429023a928b0880845010be7ece59e5a9b8991fe0bb", + "typeString": "literal_string \"Invalid amount to decrease\"" + } + ], + "id": 8802, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "9173:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8808, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9173:76:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8809, + "nodeType": "ExpressionStatement", + "src": "9173:76:28" + }, + { + "assignments": [ + 8811 + ], + "declarations": [ + { + "constant": false, + "id": 8811, + "name": "previousTotalBorrowFixed", + "nodeType": "VariableDeclaration", + "scope": 8879, + "src": "9260:32:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8810, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9260:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8814, + "initialValue": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8812, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9295:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8813, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "9295:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9260:61:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8823, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8815, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9373:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8817, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "9373:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8821, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8797, + "src": "9433:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8818, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9402:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8819, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "9402:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8820, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "9402:30:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8822, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9402:39:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9373:68:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8824, + "nodeType": "ExpressionStatement", + "src": "9373:68:28" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8828, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8825, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9456:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8826, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "9456:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 8827, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9486:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "9456:31:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 8837, + "nodeType": "IfStatement", + "src": "9452:171:28", + "trueBody": { + "id": 8836, + "nodeType": "Block", + "src": "9489:134:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8833, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8829, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9503:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8831, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "9503:38:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "30", + "id": 8832, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9544:1:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "9503:42:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8834, + "nodeType": "ExpressionStatement", + "src": "9503:42:28" + }, + { + "expression": null, + "functionReturnParameters": 8801, + "id": 8835, + "nodeType": "Return", + "src": "9606:7:28" + } + ] + } + }, + { + "assignments": [ + 8839 + ], + "declarations": [ + { + "constant": false, + "id": 8839, + "name": "weightedLastBorrow", + "nodeType": "VariableDeclaration", + "scope": 8879, + "src": "9719:26:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8838, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9719:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8846, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8844, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8799, + "src": "9774:5:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8840, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8797, + "src": "9748:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8841, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "9748:16:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8842, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9748:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8843, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "9748:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8845, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9748:32:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9719:61:28" + }, + { + "assignments": [ + 8848 + ], + "declarations": [ + { + "constant": false, + "id": 8848, + "name": "weightedPreviousTotalBorrows", + "nodeType": "VariableDeclaration", + "scope": 8879, + "src": "9790:36:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8847, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9790:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8856, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8853, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "9872:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8854, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "9872:38:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8849, + "name": "previousTotalBorrowFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8811, + "src": "9829:24:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8850, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "9829:33:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8851, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9829:35:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8852, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "9829:42:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8855, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9829:82:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9790:121:28" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8860, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 8858, + "name": "weightedPreviousTotalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8848, + "src": "9930:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 8859, + "name": "weightedLastBorrow", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8839, + "src": "9962:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9930:50:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520616d6f756e747320746f2073756273747261637420646f6e2774206d61746368", + "id": 8861, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9982:38:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8e54967fa0a6f572bd48cebcb4e70fb3faec6fe98c2f30acd1ffba83338b62eb", + "typeString": "literal_string \"The amounts to substract don't match\"" + }, + "value": "The amounts to substract don't match" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_8e54967fa0a6f572bd48cebcb4e70fb3faec6fe98c2f30acd1ffba83338b62eb", + "typeString": "literal_string \"The amounts to substract don't match\"" + } + ], + "id": 8857, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "9922:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8862, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9922:99:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8863, + "nodeType": "ExpressionStatement", + "src": "9922:99:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8877, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8864, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "10032:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8866, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "10032:38:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8872, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8795, + "src": "10146:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8873, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "10146:26:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8874, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "10146:35:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8875, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10146:37:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8869, + "name": "weightedLastBorrow", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8839, + "src": "10106:18:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8867, + "name": "weightedPreviousTotalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8848, + "src": "10073:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8868, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "10073:32:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8870, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10073:52:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8871, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "10073:59:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8876, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10073:120:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10032:161:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8878, + "nodeType": "ExpressionStatement", + "src": "10032:161:28" + } + ] + }, + "documentation": null, + "id": 8880, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "decreaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8800, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8795, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8880, + "src": "9092:28:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8794, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "9092:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8797, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 8880, + "src": "9122:15:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8796, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9122:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8799, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 8880, + "src": "9139:13:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8798, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9139:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9091:62:28" + }, + "returnParameters": { + "id": 8801, + "nodeType": "ParameterList", + "parameters": [], + "src": "9162:0:28" + }, + "scope": 8994, + "src": "9037:1163:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8897, + "nodeType": "Block", + "src": "10299:91:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8895, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8887, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8882, + "src": "10309:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8889, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "10309:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8893, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8884, + "src": "10375:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8890, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8882, + "src": "10341:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8891, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "10341:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8892, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "10341:33:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8894, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10341:42:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10309:74:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8896, + "nodeType": "ExpressionStatement", + "src": "10309:74:28" + } + ] + }, + "documentation": null, + "id": 8898, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "increaseTotalBorrowsVariable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8885, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8882, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8898, + "src": "10244:28:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8881, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "10244:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8884, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 8898, + "src": "10274:15:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8883, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10274:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10243:47:28" + }, + "returnParameters": { + "id": 8886, + "nodeType": "ParameterList", + "parameters": [], + "src": "10299:0:28" + }, + "scope": 8994, + "src": "10206:184:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8923, + "nodeType": "Block", + "src": "10489:235:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8909, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8906, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8900, + "src": "10507:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8907, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "10507:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 8908, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8902, + "src": "10540:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10507:40:28", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520616d6f756e742074686174206973206265696e672073756273747261637465642066726f6d20746865207661726961626c6520746f74616c20626f72726f777320697320696e636f7272656374", + "id": 8910, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "10549:83:28", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_691c1063918e09d52df2584348154ba2bb9fcfb9dd1d5fe8b9028f3528a10b92", + "typeString": "literal_string \"The amount that is being substracted from the variable total borrows is incorrect\"" + }, + "value": "The amount that is being substracted from the variable total borrows is incorrect" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_691c1063918e09d52df2584348154ba2bb9fcfb9dd1d5fe8b9028f3528a10b92", + "typeString": "literal_string \"The amount that is being substracted from the variable total borrows is incorrect\"" + } + ], + "id": 8905, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "10499:7:28", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 8911, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10499:134:28", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8912, + "nodeType": "ExpressionStatement", + "src": "10499:134:28" + }, + { + "expression": { + "argumentTypes": null, + "id": 8921, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8913, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8900, + "src": "10643:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8915, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "10643:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8919, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8902, + "src": "10709:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8916, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8900, + "src": "10675:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8917, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "10675:29:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8918, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "10675:33:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8920, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10675:42:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10643:74:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8922, + "nodeType": "ExpressionStatement", + "src": "10643:74:28" + } + ] + }, + "documentation": null, + "id": 8924, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "decreaseTotalBorrowsVariable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8903, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8900, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8924, + "src": "10434:28:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8899, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "10434:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8902, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 8924, + "src": "10464:15:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8901, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10464:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10433:47:28" + }, + "returnParameters": { + "id": 8904, + "nodeType": "ParameterList", + "parameters": [], + "src": "10489:0:28" + }, + "scope": 8994, + "src": "10396:328:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8938, + "nodeType": "Block", + "src": "10791:106:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8936, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8929, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8926, + "src": "10836:8:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8931, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "10836:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8933, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "10874:5:28", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 8934, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "10874:15:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 8932, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "10867:6:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint40_$", + "typeString": "type(uint40)" + }, + "typeName": "uint40" + }, + "id": 8935, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10867:23:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "src": "10836:54:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "id": 8937, + "nodeType": "ExpressionStatement", + "src": "10836:54:28" + } + ] + }, + "documentation": null, + "id": 8939, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLastUpdate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8927, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8926, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8939, + "src": "10753:28:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8925, + "name": "ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "10753:11:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10752:30:28" + }, + "returnParameters": { + "id": 8928, + "nodeType": "ParameterList", + "parameters": [], + "src": "10791:0:28" + }, + "scope": 8994, + "src": "10730:167:28", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8953, + "nodeType": "Block", + "src": "11001:83:28", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8949, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8941, + "src": "11048:7:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8950, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "11048:28:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8946, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8941, + "src": "11018:7:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 8947, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "11018:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8948, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "11018:29:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8951, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11018:59:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8945, + "id": 8952, + "nodeType": "Return", + "src": "11011:66:28" + } + ] + }, + "documentation": null, + "id": 8954, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getTotalBorrows", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8942, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8941, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 8954, + "src": "10928:39:28", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 8940, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "10928:23:28", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10927:41:28" + }, + "returnParameters": { + "id": 8945, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8944, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8954, + "src": "10992:7:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8943, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10992:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10991:9:28" + }, + "scope": 8994, + "src": "10903:181:28", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 8992, + "nodeType": "Block", + "src": "11268:275:28", + "statements": [ + { + "assignments": [ + 8964 + ], + "declarations": [ + { + "constant": false, + "id": 8964, + "name": "timeDifference", + "nodeType": "VariableDeclaration", + "scope": 8992, + "src": "11314:22:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8963, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11314:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8970, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8968, + "name": "_lastUpdateTimestamp", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8958, + "src": "11359:20:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8965, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "11339:5:28", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 8966, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11339:15:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8967, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "11339:19:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8969, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11339:41:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "11314:66:28" + }, + { + "assignments": [ + 8972 + ], + "declarations": [ + { + "constant": false, + "id": 8972, + "name": "timeDelta", + "nodeType": "VariableDeclaration", + "scope": 8992, + "src": "11391:17:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8971, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11391:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8981, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8977, + "name": "SECONDS_PER_YEAR", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8270, + "src": "11444:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8978, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "11444:25:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8979, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11444:27:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8973, + "name": "timeDifference", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8964, + "src": "11411:14:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8974, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "11411:23:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 8975, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11411:25:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8976, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "11411:32:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8980, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11411:61:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "11391:81:28" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8987, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "11519:10:28", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 8988, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "11519:14:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 8989, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11519:16:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8984, + "name": "timeDelta", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8972, + "src": "11504:9:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8982, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8956, + "src": "11491:5:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8983, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "11491:12:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8985, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11491:23:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8986, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "11491:27:28", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8990, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11491:45:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 8962, + "id": 8991, + "nodeType": "Return", + "src": "11484:52:28" + } + ] + }, + "documentation": "@dev function to calculate cumulated interest", + "id": 8993, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateCumulatedInterest", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8959, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8956, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 8993, + "src": "11194:13:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8955, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11194:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8958, + "name": "_lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 8993, + "src": "11208:27:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 8957, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "11208:6:28", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11193:43:28" + }, + "returnParameters": { + "id": 8962, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8961, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8993, + "src": "11259:7:28", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8960, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11259:7:28", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11258:9:28" + }, + "scope": 8994, + "src": "11158:385:28", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 8995, + "src": "399:11147:28" + } + ], + "src": "0:11547:28" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.817Z", + "devdoc": { + "author": "Aave", + "methods": {}, + "title": "CoreLibrary library" + }, + "userdoc": { + "methods": { + "init(CoreLibrary.ReserveData storage,address,uint256,address)": { + "notice": "inits a reserve" + } + }, + "notice": "***********************************************************************************Defines the data structures of the reserves and the user data************************************************************************************" + } +} \ No newline at end of file diff --git a/client/src/contracts/DefaultReserveInterestRateStrategy.json b/client/src/contracts/DefaultReserveInterestRateStrategy.json new file mode 100644 index 0000000..1c23524 --- /dev/null +++ b/client/src/contracts/DefaultReserveInterestRateStrategy.json @@ -0,0 +1,6548 @@ +{ + "contractName": "DefaultReserveInterestRateStrategy", + "abi": [ + { + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_provider", + "type": "address" + }, + { + "name": "_baseVariableBorrowRate", + "type": "uint256" + }, + { + "name": "_variableBorrowRateScaling", + "type": "uint256" + }, + { + "name": "_fixedBorrowRateScaling", + "type": "uint256" + }, + { + "name": "_borrowToLiquidityRateDelta", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "constant": true, + "inputs": [], + "name": "getBaseVariableBorrowRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getVariableBorrowRateScaling", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getFixedBorrowRateScaling", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBorrowToLiquidityRateDelta", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_utilizationRate", + "type": "uint256" + }, + { + "name": "_totalBorrowsFixed", + "type": "uint256" + }, + { + "name": "_totalBorrowsVariable", + "type": "uint256" + }, + { + "name": "_averageFixedBorrowRate", + "type": "uint256" + } + ], + "name": "calculateInterestRates", + "outputs": [ + { + "name": "currentLiquidityRate", + "type": "uint256" + }, + { + "name": "currentFixedBorrowRate", + "type": "uint256" + }, + { + "name": "currentVariableBorrowRate", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"getBaseVariableBorrowRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getFixedBorrowRateScaling\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_utilizationRate\",\"type\":\"uint256\"},{\"name\":\"_totalBorrowsFixed\",\"type\":\"uint256\"},{\"name\":\"_totalBorrowsVariable\",\"type\":\"uint256\"},{\"name\":\"_averageFixedBorrowRate\",\"type\":\"uint256\"}],\"name\":\"calculateInterestRates\",\"outputs\":[{\"name\":\"currentLiquidityRate\",\"type\":\"uint256\"},{\"name\":\"currentFixedBorrowRate\",\"type\":\"uint256\"},{\"name\":\"currentVariableBorrowRate\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getVariableBorrowRateScaling\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getBorrowToLiquidityRateDelta\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_provider\",\"type\":\"address\"},{\"name\":\"_baseVariableBorrowRate\",\"type\":\"uint256\"},{\"name\":\"_variableBorrowRateScaling\",\"type\":\"uint256\"},{\"name\":\"_fixedBorrowRateScaling\",\"type\":\"uint256\"},{\"name\":\"_borrowToLiquidityRateDelta\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"}],\"devdoc\":{\"methods\":{\"calculateInterestRates(address,uint256,uint256,uint256,uint256)\":{\"details\":\"returns the interest rates, in rays\"},\"getBaseVariableBorrowRate()\":{\"details\":\"accessors\"}},\"title\":\"DefaultReserveInterestRateStrategy contract\"},\"userdoc\":{\"methods\":{},\"notice\":\"implements the calculation of the interest rates based on the reserve parameters.\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/lendingpool/DefaultReserveInterestRateStrategy.sol\":\"DefaultReserveInterestRateStrategy\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x0ae6004410cd58a1c5151e67959167cf58cd5e77e8b625677826e295905fb318\",\"urls\":[\"bzzr://d223bea23f0e9bd70844e9852f490be93d30fc1c31bf114c807d0e4fe07d929b\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":{\"keccak256\":\"0xeeae2b67fa36103fe1c3a4e346b9c04171f9065949953abd00104c357834b0e3\",\"urls\":[\"bzzr://4e3bd29abfa796726532c3e42dd8039ab0f93388d7bbf358428dbc9b0399664a\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x0adf744884b9262f507aba565d1c96c82397f58d399a2dc2c60a452953197574\",\"urls\":[\"bzzr://03099f88c041565b5ac13ea7e645a8f9bff0c29bfa584c7969372ce12c5473f5\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol\":{\"keccak256\":\"0x35a7f1a34259948cdcb03084718f765215fe69559f557b395d9d6e18c63ac823\",\"urls\":[\"bzzr://f529e265dd06192a1d552f1f41c245790419562dfb52e7be9d443c758ccb72d0\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/DefaultReserveInterestRateStrategy.sol\":{\"keccak256\":\"0x3a8b78284c98ad62c633b994994fce602835eeb88dc407710b8b752959b72697\",\"urls\":[\"bzzr://8274f0da0f6eff4e14c17c4e9aebe099d102b90e2cc5e0989fd424f20e45caf5\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol\":{\"keccak256\":\"0xca757f989e0e7519d03d4e3086028e3022306ec4bb7f610fa78bff866f04c998\",\"urls\":[\"bzzr://f381f642ecce43d76d9e0011ea3c7c6218d1eaa2e0d3a7d5aecd55552cc0fb27\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol\":{\"keccak256\":\"0xb8b4844881a9ea5c3f0f2584061efcbfb6c96863ca3a07b960d2f9d323293cac\",\"urls\":[\"bzzr://8cb1c5dcce198c0f60c21bd9807b361fc214a60d4b3aa3442153b045b51a4325\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]}},\"version\":1}", + "bytecode": "0x608060405234801561001057600080fd5b5060405160c080610a7f833981018060405260c081101561003057600080fd5b810190808051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050508473ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156100b957600080fd5b505afa1580156100cd573d6000803e3d6000fd5b505050506040513d60208110156100e357600080fd5b81019080805190602001909291905050506000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508473ffffffffffffffffffffffffffffffffffffffff16633618abba6040518163ffffffff1660e01b815260040160206040518083038186803b15801561017957600080fd5b505afa15801561018d573d6000803e3d6000fd5b505050506040513d60208110156101a357600080fd5b8101908080519060200190929190505050600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508360028190555082600381905550816004819055508060058190555085600660006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505050505050610819806102666000396000f3fe608060405234801561001057600080fd5b50600436106100575760003560e01c806334762ca51461005c57806345e8e1431461007a57806357e37af014610098578063a26a88d314610126578063d7b0c19714610144575b600080fd5b610064610162565b6040518082815260200191505060405180910390f35b61008261016c565b6040518082815260200191505060405180910390f35b610102600480360360a08110156100ae57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291908035906020019092919080359060200190929190505050610176565b60405180848152602001838152602001828152602001935050505060405180910390f35b61012e610307565b6040518082815260200191505060405180910390f35b61014c610311565b6040518082815260200191505060405180910390f35b6000600254905090565b6000600454905090565b6000806000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663bb85c0bb896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561021a57600080fd5b505afa15801561022e573d6000803e3d6000fd5b505050506040513d602081101561024457600080fd5b810190808051906020019092919050505091506acecb8f27f4200f3a0000008711156102b1576102ae61029f61028e6acecb8f27f4200f3a0000008a61031b90919063ffffffff16565b60045461036590919063ffffffff16565b836103c890919063ffffffff16565b91505b6102da6002546102cc6003548a61036590919063ffffffff16565b6103c890919063ffffffff16565b90506102fa876102ec88888589610450565b61036590919063ffffffff16565b9250955095509592505050565b6000600354905090565b6000600554905090565b600061035d83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506104fa565b905092915050565b60006103c06b033b2e3c9fd0803ce80000006103b261038d85876105ba90919063ffffffff16565b60026b033b2e3c9fd0803ce8000000816103a357fe5b046103c890919063ffffffff16565b61064090919063ffffffff16565b905092915050565b600080828401905083811015610446576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b60008061046685876103c890919063ffffffff16565b9050600081141561047b5760009150506104f2565b60006104988561048a8861068a565b61036590919063ffffffff16565b905060006104b7856104a98a61068a565b61036590919063ffffffff16565b905060006104e86104c78561068a565b6104da84866103c890919063ffffffff16565b6106aa90919063ffffffff16565b9050809450505050505b949350505050565b60008383111582906105a7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561056c578082015181840152602081019050610551565b50505050905090810190601f1680156105995780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b6000808314156105cd576000905061063a565b60008284029050828482816105de57fe5b0414610635576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806107cd6021913960400191505060405180910390fd5b809150505b92915050565b600061068283836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250610706565b905092915050565b60006106a3633b9aca00836105ba90919063ffffffff16565b9050919050565b600080600283816106b757fe5b0490506106fd836106ef6106e06b033b2e3c9fd0803ce8000000886105ba90919063ffffffff16565b846103c890919063ffffffff16565b61064090919063ffffffff16565b91505092915050565b600080831182906107b2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561077757808201518184015260208101905061075c565b50505050905090810190601f1680156107a45780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816107be57fe5b04905080915050939250505056fe536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a165627a7a723058203e8e5c3163bdef0026fcde83e74efc05a803183b3b08ad1370c4383bfbfa7d900029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100575760003560e01c806334762ca51461005c57806345e8e1431461007a57806357e37af014610098578063a26a88d314610126578063d7b0c19714610144575b600080fd5b610064610162565b6040518082815260200191505060405180910390f35b61008261016c565b6040518082815260200191505060405180910390f35b610102600480360360a08110156100ae57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291908035906020019092919080359060200190929190505050610176565b60405180848152602001838152602001828152602001935050505060405180910390f35b61012e610307565b6040518082815260200191505060405180910390f35b61014c610311565b6040518082815260200191505060405180910390f35b6000600254905090565b6000600454905090565b6000806000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663bb85c0bb896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561021a57600080fd5b505afa15801561022e573d6000803e3d6000fd5b505050506040513d602081101561024457600080fd5b810190808051906020019092919050505091506acecb8f27f4200f3a0000008711156102b1576102ae61029f61028e6acecb8f27f4200f3a0000008a61031b90919063ffffffff16565b60045461036590919063ffffffff16565b836103c890919063ffffffff16565b91505b6102da6002546102cc6003548a61036590919063ffffffff16565b6103c890919063ffffffff16565b90506102fa876102ec88888589610450565b61036590919063ffffffff16565b9250955095509592505050565b6000600354905090565b6000600554905090565b600061035d83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506104fa565b905092915050565b60006103c06b033b2e3c9fd0803ce80000006103b261038d85876105ba90919063ffffffff16565b60026b033b2e3c9fd0803ce8000000816103a357fe5b046103c890919063ffffffff16565b61064090919063ffffffff16565b905092915050565b600080828401905083811015610446576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b60008061046685876103c890919063ffffffff16565b9050600081141561047b5760009150506104f2565b60006104988561048a8861068a565b61036590919063ffffffff16565b905060006104b7856104a98a61068a565b61036590919063ffffffff16565b905060006104e86104c78561068a565b6104da84866103c890919063ffffffff16565b6106aa90919063ffffffff16565b9050809450505050505b949350505050565b60008383111582906105a7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561056c578082015181840152602081019050610551565b50505050905090810190601f1680156105995780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b6000808314156105cd576000905061063a565b60008284029050828482816105de57fe5b0414610635576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806107cd6021913960400191505060405180910390fd5b809150505b92915050565b600061068283836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250610706565b905092915050565b60006106a3633b9aca00836105ba90919063ffffffff16565b9050919050565b600080600283816106b757fe5b0490506106fd836106ef6106e06b033b2e3c9fd0803ce8000000886105ba90919063ffffffff16565b846103c890919063ffffffff16565b61064090919063ffffffff16565b91505092915050565b600080831182906107b2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561077757808201518184015260208101905061075c565b50505050905090810190601f1680156107a45780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816107be57fe5b04905080915050939250505056fe536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a165627a7a723058203e8e5c3163bdef0026fcde83e74efc05a803183b3b08ad1370c4383bfbfa7d900029", + "sourceMap": "473:3681:22:-;;;970:693;8:9:-1;5:2;;;30:1;27;20:12;5:2;970:693:22;;;;;;;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;970:693:22;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1269:9;:28;;;:30;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1269:30:22;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1269:30:22;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1269:30:22;;;;;;;;;;;;;;;;1246:4;;:54;;;;;;;;;;;;;;;;;;1349:9;:30;;;:32;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1349:32:22;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1349:32:22;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1349:32:22;;;;;;;;;;;;;;;;1310:17;;:72;;;;;;;;;;;;;;;;;;1417:23;1392:22;:48;;;;1478:26;1450:25;:54;;;;1539:23;1514:22;:48;;;;1601:27;1572:26;:56;;;;1648:8;1638:7;;:18;;;;;;;;;;;;;;;;;;970:693;;;;;;473:3681;;;;;;", + "deployedSourceMap": "473:3681:22:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;473:3681:22;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1705:114;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1951;;;:::i;:::-;;;;;;;;;;;;;;;;;;;2262:1022;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;2262:1022:22;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1825:120;;;:::i;:::-;;;;;;;;;;;;;;;;;;;2071:122;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1705:114;1764:7;1790:22;;1783:29;;1705:114;:::o;1951:::-;2010:7;2036:22;;2029:29;;1951:114;:::o;2262:1022::-;2503:28;2533:30;2565:33;2636:17;;;;;;;;;;;:37;;;2674:8;2636:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2636:47:22;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2636:47:22;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2636:47:22;;;;;;;;;;;;;;;;2611:72;;672:8;2697:16;:48;2694:212;;;2785:110;2812:82;2842:51;672:8;2842:16;:20;;:51;;;;:::i;:::-;2812:22;;:29;;:82;;;;:::i;:::-;2785:22;:26;;:110;;;;:::i;:::-;2760:135;;2694:212;2944:101;3013:22;;2944:50;2968:25;;2944:16;:23;;:50;;;;:::i;:::-;:54;;:101;;;;:::i;:::-;2916:129;;3079:197;3259:16;3079:172;3121:18;3153:21;3188:25;3227:23;3079:28;:172::i;:::-;:179;;:197;;;;:::i;:::-;3056:220;;2262:1022;;;;;;;;;:::o;1825:120::-;1887:7;1913:25;;1906:32;;1825:120;:::o;2071:122::-;2134:7;2160:26;;2153:33;;2071:122;:::o;1274:134:56:-;1332:7;1358:43;1362:1;1365;1358:43;;;;;;;;;;;;;;;;;:3;:43::i;:::-;1351:50;;1274:134;;;;:::o;1183:124:29:-;1244:7;1270:30;454:4;1270:21;1282:8;1288:1;1282;:5;;:8;;;;:::i;:::-;506:1;454:4;500:7;;;;;;1270:11;;:21;;;;:::i;:::-;:25;;:30;;;;:::i;:::-;1263:37;;1183:124;;;;:::o;834:176:56:-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;3399:753:22:-;3628:7;3648:20;3671:45;3694:21;3671:18;:22;;:45;;;;:::i;:::-;3648:68;;3747:1;3731:12;:17;3727:31;;;3757:1;3750:8;;;;;3727:31;3769:28;3800:89;3853:26;3800:32;:21;:30;:32::i;:::-;:39;;:89;;;;:::i;:::-;3769:120;;3900:25;3928:68;3965:30;3928:29;:18;:27;:29::i;:::-;:36;;:68;;;;:::i;:::-;3900:96;;4007:25;4035:75;4086:23;:12;:21;:23::i;:::-;4035:43;4060:17;4035:20;:24;;:43;;;;:::i;:::-;:50;;:75;;;;:::i;:::-;4007:103;;4128:17;4121:24;;;;;;3399:753;;;;;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;2159:459::-;2217:7;2463:1;2458;:6;2454:45;;;2487:1;2480:8;;;;2454:45;2509:9;2525:1;2521;:5;2509:17;;2553:1;2548;2544;:5;;;;;;:10;2536:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2610:1;2603:8;;;2159:459;;;;;:::o;3073:130::-;3131:7;3157:39;3161:1;3164;3157:39;;;;;;;;;;;;;;;;;:3;:39::i;:::-;3150:46;;3073:130;;;;:::o;1584:105:29:-;1636:7;1662:20;547:3;1662:1;:5;;:20;;;;:::i;:::-;1655:27;;1584:105;;;:::o;1313:154::-;1374:7;1393:13;1413:1;1409;:5;;;;;;1393:21;;1432:28;1458:1;1432:21;1442:10;454:4;1442:1;:5;;:10;;;;:::i;:::-;1432:5;:9;;:21;;;;:::i;:::-;:25;;:28;;;;:::i;:::-;1425:35;;;1313:154;;;;:::o;3718:338:56:-;3804:7;3901:1;3897;:5;3904:12;3889:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;3889:28:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3927:9;3943:1;3939;:5;;;;;;3927:17;;4048:1;4041:8;;;3718:338;;;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"../interfaces/IReserveInterestRateStrategy.sol\";\nimport \"../libraries/WadRayMath.sol\";\nimport \"../configuration/LendingPoolAddressesProvider.sol\";\nimport \"./LendingPoolCore.sol\";\nimport \"../interfaces/ILendingRateOracle.sol\";\n\n\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\n\n\n\n/**\n@title DefaultReserveInterestRateStrategy contract\n@notice implements the calculation of the interest rates based on the reserve parameters.\n*/\n\ncontract DefaultReserveInterestRateStrategy is IReserveInterestRateStrategy {\n\n using WadRayMath for uint256;\n using SafeMath for uint256;\n\n uint256 constant FIXED_RATE_INCREASE_THRESHOLD = (1e27)/4; // 0.25 ray, 25% of the utilization rate\n\n LendingPoolCore core;\n ILendingRateOracle lendingRateOracle;\n\n uint256 baseVariableBorrowRate;\n uint256 variableBorrowRateScaling;\n uint256 fixedBorrowRateScaling;\n uint256 borrowToLiquidityRateDelta;\n address reserve;\n\n constructor(\n address _reserve,\n LendingPoolAddressesProvider _provider,\n uint256 _baseVariableBorrowRate,\n uint256 _variableBorrowRateScaling,\n uint256 _fixedBorrowRateScaling,\n uint256 _borrowToLiquidityRateDelta) public {\n\n core = LendingPoolCore(_provider.getLendingPoolCore());\n lendingRateOracle = ILendingRateOracle(_provider.getLendingRateOracle());\n baseVariableBorrowRate = _baseVariableBorrowRate;\n variableBorrowRateScaling = _variableBorrowRateScaling;\n fixedBorrowRateScaling = _fixedBorrowRateScaling;\n borrowToLiquidityRateDelta = _borrowToLiquidityRateDelta;\n reserve = _reserve;\n }\n\n /**\n @dev accessors\n */\n\n function getBaseVariableBorrowRate() external view returns(uint256) {\n return baseVariableBorrowRate;\n }\n\n function getVariableBorrowRateScaling() external view returns(uint256) {\n return variableBorrowRateScaling;\n }\n\n function getFixedBorrowRateScaling() external view returns(uint256) {\n return fixedBorrowRateScaling;\n }\n\n function getBorrowToLiquidityRateDelta() external view returns(uint256) {\n return borrowToLiquidityRateDelta;\n }\n\n\n\n /**\n @dev returns the interest rates, in rays\n */\n function calculateInterestRates(\n address _reserve,\n uint256 _utilizationRate,\n uint256 _totalBorrowsFixed,\n uint256 _totalBorrowsVariable,\n uint256 _averageFixedBorrowRate\n ) external view returns (uint256 currentLiquidityRate, uint256 currentFixedBorrowRate, uint256 currentVariableBorrowRate) {\n\n currentFixedBorrowRate = lendingRateOracle.getMarketBorrowRate(_reserve);\n\n if(_utilizationRate > FIXED_RATE_INCREASE_THRESHOLD){\n currentFixedBorrowRate = currentFixedBorrowRate.add(fixedBorrowRateScaling.rayMul(_utilizationRate.sub(FIXED_RATE_INCREASE_THRESHOLD)));\n }\n\n currentVariableBorrowRate = _utilizationRate.rayMul(variableBorrowRateScaling).add(\n baseVariableBorrowRate\n );\n\n currentLiquidityRate = getOverallBorrowRateInternal(\n _totalBorrowsFixed,\n _totalBorrowsVariable,\n currentVariableBorrowRate,\n _averageFixedBorrowRate).rayMul(_utilizationRate);\n\n }\n\n /**\n @dev the weighted average between the fixed interest part and the variable interest part\n */\n function getOverallBorrowRateInternal(\n uint256 _totalBorrowsFixed,\n uint256 _totalBorrowsVariable,\n uint256 _currentVariableBorrowRate,\n uint256 _currentAverageFixedBorrowRate) internal pure returns (uint256) {\n\n uint256 totalBorrows = _totalBorrowsFixed.add(_totalBorrowsVariable);\n\n if (totalBorrows == 0) return 0;\n\n uint256 weightedVariableRate = _totalBorrowsVariable.wadToRay().rayMul(\n _currentVariableBorrowRate\n );\n\n uint256 weightedFixedRate = _totalBorrowsFixed.wadToRay().rayMul(_currentAverageFixedBorrowRate);\n\n uint256 overallBorrowRate = weightedVariableRate.add(weightedFixedRate).rayDiv(totalBorrows.wadToRay());\n\n return overallBorrowRate;\n }\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/DefaultReserveInterestRateStrategy.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/DefaultReserveInterestRateStrategy.sol", + "exportedSymbols": { + "DefaultReserveInterestRateStrategy": [ + 2233 + ] + }, + "id": 2234, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1988, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:22" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol", + "file": "../interfaces/IReserveInterestRateStrategy.sol", + "id": 1989, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 1987, + "src": "25:56:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 1990, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 9175, + "src": "82:37:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 1991, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 1358, + "src": "120:59:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "./LendingPoolCore.sol", + "id": 1992, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 6683, + "src": "180:31:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol", + "file": "../interfaces/ILendingRateOracle.sol", + "id": 1993, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 1910, + "src": "212:46:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 1994, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 11141, + "src": "261:59:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1995, + "name": "IReserveInterestRateStrategy", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1986, + "src": "520:28:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IReserveInterestRateStrategy_$1986", + "typeString": "contract IReserveInterestRateStrategy" + } + }, + "id": 1996, + "nodeType": "InheritanceSpecifier", + "src": "520:28:22" + } + ], + "contractDependencies": [ + 1986 + ], + "contractKind": "contract", + "documentation": "@title DefaultReserveInterestRateStrategy contract\n@notice implements the calculation of the interest rates based on the reserve parameters.", + "fullyImplemented": true, + "id": 2233, + "linearizedBaseContracts": [ + 2233, + 1986 + ], + "name": "DefaultReserveInterestRateStrategy", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 1999, + "libraryName": { + "contractScope": null, + "id": 1997, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "562:10:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "556:29:22", + "typeName": { + "id": 1998, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "577:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 2002, + "libraryName": { + "contractScope": null, + "id": 2000, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "596:8:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "590:27:22", + "typeName": { + "id": 2001, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "609:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "constant": true, + "id": 2008, + "name": "FIXED_RATE_INCREASE_THRESHOLD", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "623:57:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2003, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "623:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_rational_250000000000000000000000000_by_1", + "typeString": "int_const 250000000000000000000000000" + }, + "id": 2007, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "hexValue": "31653237", + "id": 2004, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "673:4:22", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000000000000_by_1", + "typeString": "int_const 1000000000000000000000000000" + }, + "value": "1e27" + } + ], + "id": 2005, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "672:6:22", + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000000000000_by_1", + "typeString": "int_const 1000000000000000000000000000" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "hexValue": "34", + "id": 2006, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "679:1:22", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_4_by_1", + "typeString": "int_const 4" + }, + "value": "4" + }, + "src": "672:8:22", + "typeDescriptions": { + "typeIdentifier": "t_rational_250000000000000000000000000_by_1", + "typeString": "int_const 250000000000000000000000000" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 2010, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "728:20:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 2009, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "728:15:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2012, + "name": "lendingRateOracle", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "754:36:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + }, + "typeName": { + "contractScope": null, + "id": 2011, + "name": "ILendingRateOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1909, + "src": "754:18:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2014, + "name": "baseVariableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "797:30:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2013, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "797:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2016, + "name": "variableBorrowRateScaling", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "833:33:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2015, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "833:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2018, + "name": "fixedBorrowRateScaling", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "872:30:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2017, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "872:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2020, + "name": "borrowToLiquidityRateDelta", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "908:34:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2019, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "908:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2022, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "948:15:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2021, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "948:7:22", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 2073, + "nodeType": "Block", + "src": "1235:428:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2043, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2037, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2010, + "src": "1246:4:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2039, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2026, + "src": "1269:9:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2040, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "1269:28:22", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 2041, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1269:30:22", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 2038, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "1253:15:22", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 2042, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1253:47:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "src": "1246:54:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2044, + "nodeType": "ExpressionStatement", + "src": "1246:54:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2051, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2045, + "name": "lendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2012, + "src": "1310:17:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2047, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2026, + "src": "1349:9:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2048, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingRateOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1291, + "src": "1349:30:22", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 2049, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1349:32:22", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2046, + "name": "ILendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1909, + "src": "1330:18:22", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ILendingRateOracle_$1909_$", + "typeString": "type(contract ILendingRateOracle)" + } + }, + "id": 2050, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1330:52:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "src": "1310:72:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "id": 2052, + "nodeType": "ExpressionStatement", + "src": "1310:72:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2055, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2053, + "name": "baseVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2014, + "src": "1392:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2054, + "name": "_baseVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2028, + "src": "1417:23:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1392:48:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2056, + "nodeType": "ExpressionStatement", + "src": "1392:48:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2059, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2057, + "name": "variableBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2016, + "src": "1450:25:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2058, + "name": "_variableBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2030, + "src": "1478:26:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1450:54:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2060, + "nodeType": "ExpressionStatement", + "src": "1450:54:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2063, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2061, + "name": "fixedBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2018, + "src": "1514:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2062, + "name": "_fixedBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2032, + "src": "1539:23:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1514:48:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2064, + "nodeType": "ExpressionStatement", + "src": "1514:48:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2067, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2065, + "name": "borrowToLiquidityRateDelta", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2020, + "src": "1572:26:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2066, + "name": "_borrowToLiquidityRateDelta", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2034, + "src": "1601:27:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1572:56:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2068, + "nodeType": "ExpressionStatement", + "src": "1572:56:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2071, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2069, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2022, + "src": "1638:7:22", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2070, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2024, + "src": "1648:8:22", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1638:18:22", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 2072, + "nodeType": "ExpressionStatement", + "src": "1638:18:22" + } + ] + }, + "documentation": null, + "id": 2074, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2035, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2024, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "991:16:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2023, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "991:7:22", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2026, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "1017:38:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 2025, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1017:28:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2028, + "name": "_baseVariableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "1065:31:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2027, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1065:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2030, + "name": "_variableBorrowRateScaling", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "1106:34:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2029, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1106:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2032, + "name": "_fixedBorrowRateScaling", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "1150:31:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2031, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1150:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2034, + "name": "_borrowToLiquidityRateDelta", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "1191:35:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2033, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1191:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "981:246:22" + }, + "returnParameters": { + "id": 2036, + "nodeType": "ParameterList", + "parameters": [], + "src": "1235:0:22" + }, + "scope": 2233, + "src": "970:693:22", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 2081, + "nodeType": "Block", + "src": "1773:46:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2079, + "name": "baseVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2014, + "src": "1790:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 2078, + "id": 2080, + "nodeType": "Return", + "src": "1783:29:22" + } + ] + }, + "documentation": "@dev accessors", + "id": 2082, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getBaseVariableBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2075, + "nodeType": "ParameterList", + "parameters": [], + "src": "1739:2:22" + }, + "returnParameters": { + "id": 2078, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2077, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 2082, + "src": "1764:7:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2076, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1764:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1763:9:22" + }, + "scope": 2233, + "src": "1705:114:22", + "stateMutability": "view", + "superFunction": 1966, + "visibility": "external" + }, + { + "body": { + "id": 2089, + "nodeType": "Block", + "src": "1896:49:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2087, + "name": "variableBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2016, + "src": "1913:25:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 2086, + "id": 2088, + "nodeType": "Return", + "src": "1906:32:22" + } + ] + }, + "documentation": null, + "id": 2090, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getVariableBorrowRateScaling", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2083, + "nodeType": "ParameterList", + "parameters": [], + "src": "1862:2:22" + }, + "returnParameters": { + "id": 2086, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2085, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 2090, + "src": "1887:7:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2084, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1887:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1886:9:22" + }, + "scope": 2233, + "src": "1825:120:22", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 2097, + "nodeType": "Block", + "src": "2019:46:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2095, + "name": "fixedBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2018, + "src": "2036:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 2094, + "id": 2096, + "nodeType": "Return", + "src": "2029:29:22" + } + ] + }, + "documentation": null, + "id": 2098, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getFixedBorrowRateScaling", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2091, + "nodeType": "ParameterList", + "parameters": [], + "src": "1985:2:22" + }, + "returnParameters": { + "id": 2094, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2093, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 2098, + "src": "2010:7:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2092, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2010:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2009:9:22" + }, + "scope": 2233, + "src": "1951:114:22", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 2105, + "nodeType": "Block", + "src": "2143:50:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2103, + "name": "borrowToLiquidityRateDelta", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2020, + "src": "2160:26:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 2102, + "id": 2104, + "nodeType": "Return", + "src": "2153:33:22" + } + ] + }, + "documentation": null, + "id": 2106, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getBorrowToLiquidityRateDelta", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2099, + "nodeType": "ParameterList", + "parameters": [], + "src": "2109:2:22" + }, + "returnParameters": { + "id": 2102, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2101, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 2106, + "src": "2134:7:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2100, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2134:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2133:9:22" + }, + "scope": 2233, + "src": "2071:122:22", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 2172, + "nodeType": "Block", + "src": "2600:684:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2130, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2125, + "name": "currentFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2121, + "src": "2611:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2128, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2108, + "src": "2674:8:22", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2126, + "name": "lendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2012, + "src": "2636:17:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "id": 2127, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getMarketBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 1887, + "src": "2636:37:22", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2129, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2636:47:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2611:72:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2131, + "nodeType": "ExpressionStatement", + "src": "2611:72:22" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2134, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2132, + "name": "_utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2110, + "src": "2697:16:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 2133, + "name": "FIXED_RATE_INCREASE_THRESHOLD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2008, + "src": "2716:29:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2697:48:22", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 2149, + "nodeType": "IfStatement", + "src": "2694:212:22", + "trueBody": { + "id": 2148, + "nodeType": "Block", + "src": "2746:160:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2146, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2135, + "name": "currentFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2121, + "src": "2760:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2142, + "name": "FIXED_RATE_INCREASE_THRESHOLD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2008, + "src": "2863:29:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2140, + "name": "_utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2110, + "src": "2842:16:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2141, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "2842:20:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2143, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2842:51:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2138, + "name": "fixedBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2018, + "src": "2812:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2139, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "2812:29:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2144, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2812:82:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2136, + "name": "currentFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2121, + "src": "2785:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2137, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "2785:26:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2145, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2785:110:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2760:135:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2147, + "nodeType": "ExpressionStatement", + "src": "2760:135:22" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 2158, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2150, + "name": "currentVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2123, + "src": "2916:25:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2156, + "name": "baseVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2014, + "src": "3013:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2153, + "name": "variableBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2016, + "src": "2968:25:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2151, + "name": "_utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2110, + "src": "2944:16:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2152, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "2944:23:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2154, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2944:50:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2155, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "2944:54:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2157, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2944:101:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2916:129:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2159, + "nodeType": "ExpressionStatement", + "src": "2916:129:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2170, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2160, + "name": "currentLiquidityRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2119, + "src": "3056:20:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2168, + "name": "_utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2110, + "src": "3259:16:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2162, + "name": "_totalBorrowsFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2112, + "src": "3121:18:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 2163, + "name": "_totalBorrowsVariable", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2114, + "src": "3153:21:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 2164, + "name": "currentVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2123, + "src": "3188:25:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 2165, + "name": "_averageFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2116, + "src": "3227:23:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 2161, + "name": "getOverallBorrowRateInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2232, + "src": "3079:28:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,uint256,uint256) pure returns (uint256)" + } + }, + "id": 2166, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3079:172:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2167, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "3079:179:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2169, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3079:197:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3056:220:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2171, + "nodeType": "ExpressionStatement", + "src": "3056:220:22" + } + ] + }, + "documentation": "@dev returns the interest rates, in rays", + "id": 2173, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateInterestRates", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2117, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2108, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2303:16:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2107, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2303:7:22", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2110, + "name": "_utilizationRate", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2329:24:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2109, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2329:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2112, + "name": "_totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2363:26:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2111, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2363:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2114, + "name": "_totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2399:29:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2113, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2399:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2116, + "name": "_averageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2438:31:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2115, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2438:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2293:186:22" + }, + "returnParameters": { + "id": 2124, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2119, + "name": "currentLiquidityRate", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2503:28:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2118, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2503:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2121, + "name": "currentFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2533:30:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2120, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2533:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2123, + "name": "currentVariableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2565:33:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2122, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2565:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2502:97:22" + }, + "scope": 2233, + "src": "2262:1022:22", + "stateMutability": "view", + "superFunction": 1985, + "visibility": "external" + }, + { + "body": { + "id": 2231, + "nodeType": "Block", + "src": "3637:515:22", + "statements": [ + { + "assignments": [ + 2187 + ], + "declarations": [ + { + "constant": false, + "id": 2187, + "name": "totalBorrows", + "nodeType": "VariableDeclaration", + "scope": 2231, + "src": "3648:20:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2186, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3648:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2192, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2190, + "name": "_totalBorrowsVariable", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2177, + "src": "3694:21:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2188, + "name": "_totalBorrowsFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2175, + "src": "3671:18:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2189, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "3671:22:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2191, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3671:45:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3648:68:22" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2195, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2193, + "name": "totalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2187, + "src": "3731:12:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 2194, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3747:1:22", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3731:17:22", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 2198, + "nodeType": "IfStatement", + "src": "3727:31:22", + "trueBody": { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 2196, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3757:1:22", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 2185, + "id": 2197, + "nodeType": "Return", + "src": "3750:8:22" + } + }, + { + "assignments": [ + 2200 + ], + "declarations": [ + { + "constant": false, + "id": 2200, + "name": "weightedVariableRate", + "nodeType": "VariableDeclaration", + "scope": 2231, + "src": "3769:28:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2199, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3769:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2207, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2205, + "name": "_currentVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2179, + "src": "3853:26:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2201, + "name": "_totalBorrowsVariable", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2177, + "src": "3800:21:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2202, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "3800:30:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 2203, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3800:32:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2204, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "3800:39:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2206, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3800:89:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3769:120:22" + }, + { + "assignments": [ + 2209 + ], + "declarations": [ + { + "constant": false, + "id": 2209, + "name": "weightedFixedRate", + "nodeType": "VariableDeclaration", + "scope": 2231, + "src": "3900:25:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2208, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3900:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2216, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2214, + "name": "_currentAverageFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2181, + "src": "3965:30:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2210, + "name": "_totalBorrowsFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2175, + "src": "3928:18:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2211, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "3928:27:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 2212, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3928:29:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2213, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "3928:36:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2215, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3928:68:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3900:96:22" + }, + { + "assignments": [ + 2218 + ], + "declarations": [ + { + "constant": false, + "id": 2218, + "name": "overallBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2231, + "src": "4007:25:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2217, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4007:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2228, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2224, + "name": "totalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2187, + "src": "4086:12:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2225, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "4086:21:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 2226, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4086:23:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2221, + "name": "weightedFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2209, + "src": "4060:17:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2219, + "name": "weightedVariableRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2200, + "src": "4035:20:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2220, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "4035:24:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2222, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4035:43:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2223, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "4035:50:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2227, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4035:75:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4007:103:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2229, + "name": "overallBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2218, + "src": "4128:17:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 2185, + "id": 2230, + "nodeType": "Return", + "src": "4121:24:22" + } + ] + }, + "documentation": "@dev the weighted average between the fixed interest part and the variable interest part", + "id": 2232, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getOverallBorrowRateInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2182, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2175, + "name": "_totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 2232, + "src": "3446:26:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2174, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3446:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2177, + "name": "_totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 2232, + "src": "3482:29:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2176, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3482:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2179, + "name": "_currentVariableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2232, + "src": "3521:34:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2178, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3521:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2181, + "name": "_currentAverageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2232, + "src": "3565:38:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2180, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3565:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3436:168:22" + }, + "returnParameters": { + "id": 2185, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2184, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 2232, + "src": "3628:7:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2183, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3628:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3627:9:22" + }, + "scope": 2233, + "src": "3399:753:22", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 2234, + "src": "473:3681:22" + } + ], + "src": "0:4155:22" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/DefaultReserveInterestRateStrategy.sol", + "exportedSymbols": { + "DefaultReserveInterestRateStrategy": [ + 2233 + ] + }, + "id": 2234, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1988, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:22" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol", + "file": "../interfaces/IReserveInterestRateStrategy.sol", + "id": 1989, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 1987, + "src": "25:56:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 1990, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 9175, + "src": "82:37:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 1991, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 1358, + "src": "120:59:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "./LendingPoolCore.sol", + "id": 1992, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 6683, + "src": "180:31:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol", + "file": "../interfaces/ILendingRateOracle.sol", + "id": 1993, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 1910, + "src": "212:46:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 1994, + "nodeType": "ImportDirective", + "scope": 2234, + "sourceUnit": 11141, + "src": "261:59:22", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1995, + "name": "IReserveInterestRateStrategy", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1986, + "src": "520:28:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IReserveInterestRateStrategy_$1986", + "typeString": "contract IReserveInterestRateStrategy" + } + }, + "id": 1996, + "nodeType": "InheritanceSpecifier", + "src": "520:28:22" + } + ], + "contractDependencies": [ + 1986 + ], + "contractKind": "contract", + "documentation": "@title DefaultReserveInterestRateStrategy contract\n@notice implements the calculation of the interest rates based on the reserve parameters.", + "fullyImplemented": true, + "id": 2233, + "linearizedBaseContracts": [ + 2233, + 1986 + ], + "name": "DefaultReserveInterestRateStrategy", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 1999, + "libraryName": { + "contractScope": null, + "id": 1997, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "562:10:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "556:29:22", + "typeName": { + "id": 1998, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "577:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 2002, + "libraryName": { + "contractScope": null, + "id": 2000, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "596:8:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "590:27:22", + "typeName": { + "id": 2001, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "609:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "constant": true, + "id": 2008, + "name": "FIXED_RATE_INCREASE_THRESHOLD", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "623:57:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2003, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "623:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_rational_250000000000000000000000000_by_1", + "typeString": "int_const 250000000000000000000000000" + }, + "id": 2007, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "hexValue": "31653237", + "id": 2004, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "673:4:22", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000000000000_by_1", + "typeString": "int_const 1000000000000000000000000000" + }, + "value": "1e27" + } + ], + "id": 2005, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "672:6:22", + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000000000000_by_1", + "typeString": "int_const 1000000000000000000000000000" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "hexValue": "34", + "id": 2006, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "679:1:22", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_4_by_1", + "typeString": "int_const 4" + }, + "value": "4" + }, + "src": "672:8:22", + "typeDescriptions": { + "typeIdentifier": "t_rational_250000000000000000000000000_by_1", + "typeString": "int_const 250000000000000000000000000" + } + }, + "visibility": "internal" + }, + { + "constant": false, + "id": 2010, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "728:20:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 2009, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "728:15:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2012, + "name": "lendingRateOracle", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "754:36:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + }, + "typeName": { + "contractScope": null, + "id": 2011, + "name": "ILendingRateOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1909, + "src": "754:18:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2014, + "name": "baseVariableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "797:30:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2013, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "797:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2016, + "name": "variableBorrowRateScaling", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "833:33:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2015, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "833:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2018, + "name": "fixedBorrowRateScaling", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "872:30:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2017, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "872:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2020, + "name": "borrowToLiquidityRateDelta", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "908:34:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2019, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "908:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2022, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 2233, + "src": "948:15:22", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2021, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "948:7:22", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 2073, + "nodeType": "Block", + "src": "1235:428:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2043, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2037, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2010, + "src": "1246:4:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2039, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2026, + "src": "1269:9:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2040, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "1269:28:22", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 2041, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1269:30:22", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 2038, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "1253:15:22", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 2042, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1253:47:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "src": "1246:54:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2044, + "nodeType": "ExpressionStatement", + "src": "1246:54:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2051, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2045, + "name": "lendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2012, + "src": "1310:17:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2047, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2026, + "src": "1349:9:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2048, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingRateOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1291, + "src": "1349:30:22", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 2049, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1349:32:22", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2046, + "name": "ILendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1909, + "src": "1330:18:22", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ILendingRateOracle_$1909_$", + "typeString": "type(contract ILendingRateOracle)" + } + }, + "id": 2050, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1330:52:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "src": "1310:72:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "id": 2052, + "nodeType": "ExpressionStatement", + "src": "1310:72:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2055, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2053, + "name": "baseVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2014, + "src": "1392:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2054, + "name": "_baseVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2028, + "src": "1417:23:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1392:48:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2056, + "nodeType": "ExpressionStatement", + "src": "1392:48:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2059, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2057, + "name": "variableBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2016, + "src": "1450:25:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2058, + "name": "_variableBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2030, + "src": "1478:26:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1450:54:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2060, + "nodeType": "ExpressionStatement", + "src": "1450:54:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2063, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2061, + "name": "fixedBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2018, + "src": "1514:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2062, + "name": "_fixedBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2032, + "src": "1539:23:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1514:48:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2064, + "nodeType": "ExpressionStatement", + "src": "1514:48:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2067, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2065, + "name": "borrowToLiquidityRateDelta", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2020, + "src": "1572:26:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2066, + "name": "_borrowToLiquidityRateDelta", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2034, + "src": "1601:27:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1572:56:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2068, + "nodeType": "ExpressionStatement", + "src": "1572:56:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2071, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2069, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2022, + "src": "1638:7:22", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2070, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2024, + "src": "1648:8:22", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1638:18:22", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 2072, + "nodeType": "ExpressionStatement", + "src": "1638:18:22" + } + ] + }, + "documentation": null, + "id": 2074, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2035, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2024, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "991:16:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2023, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "991:7:22", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2026, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "1017:38:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 2025, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1017:28:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2028, + "name": "_baseVariableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "1065:31:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2027, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1065:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2030, + "name": "_variableBorrowRateScaling", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "1106:34:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2029, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1106:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2032, + "name": "_fixedBorrowRateScaling", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "1150:31:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2031, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1150:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2034, + "name": "_borrowToLiquidityRateDelta", + "nodeType": "VariableDeclaration", + "scope": 2074, + "src": "1191:35:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2033, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1191:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "981:246:22" + }, + "returnParameters": { + "id": 2036, + "nodeType": "ParameterList", + "parameters": [], + "src": "1235:0:22" + }, + "scope": 2233, + "src": "970:693:22", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 2081, + "nodeType": "Block", + "src": "1773:46:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2079, + "name": "baseVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2014, + "src": "1790:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 2078, + "id": 2080, + "nodeType": "Return", + "src": "1783:29:22" + } + ] + }, + "documentation": "@dev accessors", + "id": 2082, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getBaseVariableBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2075, + "nodeType": "ParameterList", + "parameters": [], + "src": "1739:2:22" + }, + "returnParameters": { + "id": 2078, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2077, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 2082, + "src": "1764:7:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2076, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1764:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1763:9:22" + }, + "scope": 2233, + "src": "1705:114:22", + "stateMutability": "view", + "superFunction": 1966, + "visibility": "external" + }, + { + "body": { + "id": 2089, + "nodeType": "Block", + "src": "1896:49:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2087, + "name": "variableBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2016, + "src": "1913:25:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 2086, + "id": 2088, + "nodeType": "Return", + "src": "1906:32:22" + } + ] + }, + "documentation": null, + "id": 2090, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getVariableBorrowRateScaling", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2083, + "nodeType": "ParameterList", + "parameters": [], + "src": "1862:2:22" + }, + "returnParameters": { + "id": 2086, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2085, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 2090, + "src": "1887:7:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2084, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1887:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1886:9:22" + }, + "scope": 2233, + "src": "1825:120:22", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 2097, + "nodeType": "Block", + "src": "2019:46:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2095, + "name": "fixedBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2018, + "src": "2036:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 2094, + "id": 2096, + "nodeType": "Return", + "src": "2029:29:22" + } + ] + }, + "documentation": null, + "id": 2098, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getFixedBorrowRateScaling", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2091, + "nodeType": "ParameterList", + "parameters": [], + "src": "1985:2:22" + }, + "returnParameters": { + "id": 2094, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2093, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 2098, + "src": "2010:7:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2092, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2010:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2009:9:22" + }, + "scope": 2233, + "src": "1951:114:22", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 2105, + "nodeType": "Block", + "src": "2143:50:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2103, + "name": "borrowToLiquidityRateDelta", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2020, + "src": "2160:26:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 2102, + "id": 2104, + "nodeType": "Return", + "src": "2153:33:22" + } + ] + }, + "documentation": null, + "id": 2106, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getBorrowToLiquidityRateDelta", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2099, + "nodeType": "ParameterList", + "parameters": [], + "src": "2109:2:22" + }, + "returnParameters": { + "id": 2102, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2101, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 2106, + "src": "2134:7:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2100, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2134:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2133:9:22" + }, + "scope": 2233, + "src": "2071:122:22", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 2172, + "nodeType": "Block", + "src": "2600:684:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2130, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2125, + "name": "currentFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2121, + "src": "2611:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2128, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2108, + "src": "2674:8:22", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2126, + "name": "lendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2012, + "src": "2636:17:22", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "id": 2127, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getMarketBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 1887, + "src": "2636:37:22", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2129, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2636:47:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2611:72:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2131, + "nodeType": "ExpressionStatement", + "src": "2611:72:22" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2134, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2132, + "name": "_utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2110, + "src": "2697:16:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 2133, + "name": "FIXED_RATE_INCREASE_THRESHOLD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2008, + "src": "2716:29:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2697:48:22", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 2149, + "nodeType": "IfStatement", + "src": "2694:212:22", + "trueBody": { + "id": 2148, + "nodeType": "Block", + "src": "2746:160:22", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2146, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2135, + "name": "currentFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2121, + "src": "2760:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2142, + "name": "FIXED_RATE_INCREASE_THRESHOLD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2008, + "src": "2863:29:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2140, + "name": "_utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2110, + "src": "2842:16:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2141, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "2842:20:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2143, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2842:51:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2138, + "name": "fixedBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2018, + "src": "2812:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2139, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "2812:29:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2144, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2812:82:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2136, + "name": "currentFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2121, + "src": "2785:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2137, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "2785:26:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2145, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2785:110:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2760:135:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2147, + "nodeType": "ExpressionStatement", + "src": "2760:135:22" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 2158, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2150, + "name": "currentVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2123, + "src": "2916:25:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2156, + "name": "baseVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2014, + "src": "3013:22:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2153, + "name": "variableBorrowRateScaling", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2016, + "src": "2968:25:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2151, + "name": "_utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2110, + "src": "2944:16:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2152, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "2944:23:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2154, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2944:50:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2155, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "2944:54:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2157, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2944:101:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2916:129:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2159, + "nodeType": "ExpressionStatement", + "src": "2916:129:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2170, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2160, + "name": "currentLiquidityRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2119, + "src": "3056:20:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2168, + "name": "_utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2110, + "src": "3259:16:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2162, + "name": "_totalBorrowsFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2112, + "src": "3121:18:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 2163, + "name": "_totalBorrowsVariable", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2114, + "src": "3153:21:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 2164, + "name": "currentVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2123, + "src": "3188:25:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 2165, + "name": "_averageFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2116, + "src": "3227:23:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 2161, + "name": "getOverallBorrowRateInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2232, + "src": "3079:28:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,uint256,uint256) pure returns (uint256)" + } + }, + "id": 2166, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3079:172:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2167, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "3079:179:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2169, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3079:197:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3056:220:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2171, + "nodeType": "ExpressionStatement", + "src": "3056:220:22" + } + ] + }, + "documentation": "@dev returns the interest rates, in rays", + "id": 2173, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateInterestRates", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2117, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2108, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2303:16:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2107, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2303:7:22", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2110, + "name": "_utilizationRate", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2329:24:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2109, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2329:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2112, + "name": "_totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2363:26:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2111, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2363:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2114, + "name": "_totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2399:29:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2113, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2399:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2116, + "name": "_averageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2438:31:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2115, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2438:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2293:186:22" + }, + "returnParameters": { + "id": 2124, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2119, + "name": "currentLiquidityRate", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2503:28:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2118, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2503:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2121, + "name": "currentFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2533:30:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2120, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2533:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2123, + "name": "currentVariableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2173, + "src": "2565:33:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2122, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2565:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2502:97:22" + }, + "scope": 2233, + "src": "2262:1022:22", + "stateMutability": "view", + "superFunction": 1985, + "visibility": "external" + }, + { + "body": { + "id": 2231, + "nodeType": "Block", + "src": "3637:515:22", + "statements": [ + { + "assignments": [ + 2187 + ], + "declarations": [ + { + "constant": false, + "id": 2187, + "name": "totalBorrows", + "nodeType": "VariableDeclaration", + "scope": 2231, + "src": "3648:20:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2186, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3648:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2192, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2190, + "name": "_totalBorrowsVariable", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2177, + "src": "3694:21:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2188, + "name": "_totalBorrowsFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2175, + "src": "3671:18:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2189, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "3671:22:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2191, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3671:45:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3648:68:22" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2195, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2193, + "name": "totalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2187, + "src": "3731:12:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 2194, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3747:1:22", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3731:17:22", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 2198, + "nodeType": "IfStatement", + "src": "3727:31:22", + "trueBody": { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 2196, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3757:1:22", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 2185, + "id": 2197, + "nodeType": "Return", + "src": "3750:8:22" + } + }, + { + "assignments": [ + 2200 + ], + "declarations": [ + { + "constant": false, + "id": 2200, + "name": "weightedVariableRate", + "nodeType": "VariableDeclaration", + "scope": 2231, + "src": "3769:28:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2199, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3769:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2207, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2205, + "name": "_currentVariableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2179, + "src": "3853:26:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2201, + "name": "_totalBorrowsVariable", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2177, + "src": "3800:21:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2202, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "3800:30:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 2203, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3800:32:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2204, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "3800:39:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2206, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3800:89:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3769:120:22" + }, + { + "assignments": [ + 2209 + ], + "declarations": [ + { + "constant": false, + "id": 2209, + "name": "weightedFixedRate", + "nodeType": "VariableDeclaration", + "scope": 2231, + "src": "3900:25:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2208, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3900:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2216, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2214, + "name": "_currentAverageFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2181, + "src": "3965:30:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2210, + "name": "_totalBorrowsFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2175, + "src": "3928:18:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2211, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "3928:27:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 2212, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3928:29:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2213, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "3928:36:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2215, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3928:68:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3900:96:22" + }, + { + "assignments": [ + 2218 + ], + "declarations": [ + { + "constant": false, + "id": 2218, + "name": "overallBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2231, + "src": "4007:25:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2217, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4007:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2228, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2224, + "name": "totalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2187, + "src": "4086:12:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2225, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadToRay", + "nodeType": "MemberAccess", + "referencedDeclaration": 9173, + "src": "4086:21:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256) pure returns (uint256)" + } + }, + "id": 2226, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4086:23:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2221, + "name": "weightedFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2209, + "src": "4060:17:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2219, + "name": "weightedVariableRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2200, + "src": "4035:20:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2220, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "4035:24:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2222, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4035:43:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2223, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9147, + "src": "4035:50:22", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2227, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4035:75:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4007:103:22" + }, + { + "expression": { + "argumentTypes": null, + "id": 2229, + "name": "overallBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2218, + "src": "4128:17:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 2185, + "id": 2230, + "nodeType": "Return", + "src": "4121:24:22" + } + ] + }, + "documentation": "@dev the weighted average between the fixed interest part and the variable interest part", + "id": 2232, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getOverallBorrowRateInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2182, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2175, + "name": "_totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 2232, + "src": "3446:26:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2174, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3446:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2177, + "name": "_totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 2232, + "src": "3482:29:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2176, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3482:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2179, + "name": "_currentVariableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2232, + "src": "3521:34:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2178, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3521:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2181, + "name": "_currentAverageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 2232, + "src": "3565:38:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2180, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3565:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3436:168:22" + }, + "returnParameters": { + "id": 2185, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2184, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 2232, + "src": "3628:7:22", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2183, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3628:7:22", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3627:9:22" + }, + "scope": 2233, + "src": "3399:753:22", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 2234, + "src": "473:3681:22" + } + ], + "src": "0:4155:22" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.598Z", + "devdoc": { + "methods": { + "calculateInterestRates(address,uint256,uint256,uint256,uint256)": { + "details": "returns the interest rates, in rays" + }, + "getBaseVariableBorrowRate()": { + "details": "accessors" + } + }, + "title": "DefaultReserveInterestRateStrategy contract" + }, + "userdoc": { + "methods": {}, + "notice": "implements the calculation of the interest rates based on the reserve parameters." + } +} \ No newline at end of file diff --git a/client/src/contracts/ERC20.json b/client/src/contracts/ERC20.json index fe32a71..81f7a74 100644 --- a/client/src/contracts/ERC20.json +++ b/client/src/contracts/ERC20.json @@ -132,7 +132,7 @@ "type": "address" }, { - "name": "value", + "name": "amount", "type": "uint256" } ], @@ -221,25 +221,25 @@ "type": "function" } ], - "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"details\":\"Implementation of the `IERC20` interface. * This implementation is agnostic to the way tokens are created. This means that a supply mechanism has to be added in a derived contract using `_mint`. For a generic mechanism see `ERC20Mintable`. * *For a detailed writeup see our guide [How to implement supply mechanisms](https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226).* * We have followed general OpenZeppelin guidelines: functions revert instead of returning `false` on failure. This behavior is nonetheless conventional and does not conflict with the expectations of ERC20 applications. * Additionally, an `Approval` event is emitted on calls to `transferFrom`. This allows applications to reconstruct the allowance for all accounts just by listening to said events. Other implementations of the EIP may not emit these events, as it isn't required by the specification. * Finally, the non-standard `decreaseAllowance` and `increaseAllowance` functions have been added to mitigate the well-known issues around setting allowances. See `IERC20.approve`.\",\"methods\":{\"allowance(address,address)\":{\"details\":\"See `IERC20.allowance`.\"},\"approve(address,uint256)\":{\"details\":\"See `IERC20.approve`. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See `IERC20.balanceOf`.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to `approve` that can be used as a mitigation for problems described in `IERC20.approve`. * Emits an `Approval` event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to `approve` that can be used as a mitigation for problems described in `IERC20.approve`. * Emits an `Approval` event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"totalSupply()\":{\"details\":\"See `IERC20.totalSupply`.\"},\"transfer(address,uint256)\":{\"details\":\"See `IERC20.transfer`. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See `IERC20.transferFrom`. * Emits an `Approval` event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of `ERC20`; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `value`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"@openzeppelin/contracts/token/ERC20/ERC20.sol\":\"ERC20\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts/math/SafeMath.sol\":{\"keccak256\":\"0xd1804d04fb39689453f673601429a99a0c68c422a981fc338773df9a59180fe9\",\"urls\":[\"bzzr://a7dfb6fc259d0074da840a848461487567e2a6309105dd5c050a4e025f0fa7cb\"]},\"@openzeppelin/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x852793a3c2f86d336a683b30d688ec3dcfc57451af5a2bf5975cda3b7191a901\",\"urls\":[\"bzzr://07fb42206812a17c1f71e548cfa5cec6f9aa1ae0ca5df870718ca4aa9759d1a5\"]},\"@openzeppelin/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0x90e8c2521653bbb1768b05889c5760031e688d9cd361f167489b89215e201b95\",\"urls\":[\"bzzr://aa8b45b57edafc3d67bc5d916327ea16807fae33f753ca163ae0c4061b789766\"]}},\"version\":1}", - "bytecode": "0x608060405234801561001057600080fd5b50610cf9806100206000396000f3fe608060405234801561001057600080fd5b50600436106100885760003560e01c806370a082311161005b57806370a08231146101fd578063a457c2d714610255578063a9059cbb146102bb578063dd62ed3e1461032157610088565b8063095ea7b31461008d57806318160ddd146100f357806323b872dd146101115780633950935114610197575b600080fd5b6100d9600480360360408110156100a357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610399565b604051808215151515815260200191505060405180910390f35b6100fb6103b0565b6040518082815260200191505060405180910390f35b61017d6004803603606081101561012757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506103ba565b604051808215151515815260200191505060405180910390f35b6101e3600480360360408110156101ad57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061046b565b604051808215151515815260200191505060405180910390f35b61023f6004803603602081101561021357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610510565b6040518082815260200191505060405180910390f35b6102a16004803603604081101561026b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610558565b604051808215151515815260200191505060405180910390f35b610307600480360360408110156102d157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105fd565b604051808215151515815260200191505060405180910390f35b6103836004803603604081101561033757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610614565b6040518082815260200191505060405180910390f35b60006103a633848461069b565b6001905092915050565b6000600254905090565b60006103c7848484610892565b610460843361045b85600160008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b61069b565b600190509392505050565b6000610506338461050185600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb790919063ffffffff16565b61069b565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60006105f333846105ee85600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b61069b565b6001905092915050565b600061060a338484610892565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610721576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526024815260200180610caa6024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156107a7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180610c636022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610918576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526025815260200180610c856025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561099e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180610c406023913960400191505060405180910390fd5b6109ef816000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610a82816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb790919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b600082821115610ba6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601e8152602001807f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525060200191505060405180910390fd5b600082840390508091505092915050565b600080828401905083811015610c35576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b809150509291505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f2061646472657373a165627a7a7230582097f54a97ac3c5b8e65b79194d4724ffbd8bef08a441ca30ff8b704f361e4db9f0029", - "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100885760003560e01c806370a082311161005b57806370a08231146101fd578063a457c2d714610255578063a9059cbb146102bb578063dd62ed3e1461032157610088565b8063095ea7b31461008d57806318160ddd146100f357806323b872dd146101115780633950935114610197575b600080fd5b6100d9600480360360408110156100a357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610399565b604051808215151515815260200191505060405180910390f35b6100fb6103b0565b6040518082815260200191505060405180910390f35b61017d6004803603606081101561012757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506103ba565b604051808215151515815260200191505060405180910390f35b6101e3600480360360408110156101ad57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061046b565b604051808215151515815260200191505060405180910390f35b61023f6004803603602081101561021357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610510565b6040518082815260200191505060405180910390f35b6102a16004803603604081101561026b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610558565b604051808215151515815260200191505060405180910390f35b610307600480360360408110156102d157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105fd565b604051808215151515815260200191505060405180910390f35b6103836004803603604081101561033757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610614565b6040518082815260200191505060405180910390f35b60006103a633848461069b565b6001905092915050565b6000600254905090565b60006103c7848484610892565b610460843361045b85600160008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b61069b565b600190509392505050565b6000610506338461050185600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb790919063ffffffff16565b61069b565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60006105f333846105ee85600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b61069b565b6001905092915050565b600061060a338484610892565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610721576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526024815260200180610caa6024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156107a7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180610c636022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610918576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526025815260200180610c856025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561099e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180610c406023913960400191505060405180910390fd5b6109ef816000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610a82816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb790919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b600082821115610ba6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601e8152602001807f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525060200191505060405180910390fd5b600082840390508091505092915050565b600080828401905083811015610c35576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b809150509291505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f2061646472657373a165627a7a7230582097f54a97ac3c5b8e65b79194d4724ffbd8bef08a441ca30ff8b704f361e4db9f0029", - "sourceMap": "1232:6578:8:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1232:6578:8;;;;;;;", - "deployedSourceMap": "1232:6578:8:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1232:6578:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2453:145;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2453:145:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1514:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3055:252;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3055:252:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;3702:203;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3702:203:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1661:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1661:108:8;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;4392:213;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4392:213:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1972:153;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1972:153:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2183:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2183:132:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;2453:145;2518:4;2534:36;2543:10;2555:7;2564:5;2534:8;:36::i;:::-;2587:4;2580:11;;2453:145;;;;:::o;1514:89::-;1558:7;1584:12;;1577:19;;1514:89;:::o;3055:252::-;3144:4;3160:36;3170:6;3178:9;3189:6;3160:9;:36::i;:::-;3206:73;3215:6;3223:10;3235:43;3271:6;3235:11;:19;3247:6;3235:19;;;;;;;;;;;;;;;:31;3255:10;3235:31;;;;;;;;;;;;;;;;:35;;:43;;;;:::i;:::-;3206:8;:73::i;:::-;3296:4;3289:11;;3055:252;;;;;:::o;3702:203::-;3782:4;3798:79;3807:10;3819:7;3828:48;3865:10;3828:11;:23;3840:10;3828:23;;;;;;;;;;;;;;;:32;3852:7;3828:32;;;;;;;;;;;;;;;;:36;;:48;;;;:::i;:::-;3798:8;:79::i;:::-;3894:4;3887:11;;3702:203;;;;:::o;1661:108::-;1718:7;1744:9;:18;1754:7;1744:18;;;;;;;;;;;;;;;;1737:25;;1661:108;;;:::o;4392:213::-;4477:4;4493:84;4502:10;4514:7;4523:53;4560:15;4523:11;:23;4535:10;4523:23;;;;;;;;;;;;;;;:32;4547:7;4523:32;;;;;;;;;;;;;;;;:36;;:53;;;;:::i;:::-;4493:8;:84::i;:::-;4594:4;4587:11;;4392:213;;;;:::o;1972:153::-;2041:4;2057:40;2067:10;2079:9;2090:6;2057:9;:40::i;:::-;2114:4;2107:11;;1972:153;;;;:::o;2183:132::-;2255:7;2281:11;:18;2293:5;2281:18;;;;;;;;;;;;;;;:27;2300:7;2281:27;;;;;;;;;;;;;;;;2274:34;;2183:132;;;;:::o;7117:329::-;7226:1;7209:19;;:5;:19;;;;7201:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7306:1;7287:21;;:7;:21;;;;7279:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7388:5;7358:11;:18;7370:5;7358:18;;;;;;;;;;;;;;;:27;7377:7;7358:27;;;;;;;;;;;;;;;:35;;;;7424:7;7408:31;;7417:5;7408:31;;;7433:5;7408:31;;;;;;;;;;;;;;;;;;7117:329;;;:::o;5079:422::-;5194:1;5176:20;;:6;:20;;;;5168:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5277:1;5256:23;;:9;:23;;;;5248:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5350:29;5372:6;5350:9;:17;5360:6;5350:17;;;;;;;;;;;;;;;;:21;;:29;;;;:::i;:::-;5330:9;:17;5340:6;5330:17;;;;;;;;;;;;;;;:49;;;;5412:32;5437:6;5412:9;:20;5422:9;5412:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5389:9;:20;5399:9;5389:20;;;;;;;;;;;;;;;:55;;;;5476:9;5459:35;;5468:6;5459:35;;;5487:6;5459:35;;;;;;;;;;;;;;;;;;5079:422;;;:::o;1274:179:7:-;1332:7;1364:1;1359;:6;;1351:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1410:9;1426:1;1422;:5;1410:17;;1445:1;1438:8;;;1274:179;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o", - "source": "pragma solidity ^0.5.0;\n\nimport \"./IERC20.sol\";\nimport \"../../math/SafeMath.sol\";\n\n/**\n * @dev Implementation of the `IERC20` interface.\n *\n * This implementation is agnostic to the way tokens are created. This means\n * that a supply mechanism has to be added in a derived contract using `_mint`.\n * For a generic mechanism see `ERC20Mintable`.\n *\n * *For a detailed writeup see our guide [How to implement supply\n * mechanisms](https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226).*\n *\n * We have followed general OpenZeppelin guidelines: functions revert instead\n * of returning `false` on failure. This behavior is nonetheless conventional\n * and does not conflict with the expectations of ERC20 applications.\n *\n * Additionally, an `Approval` event is emitted on calls to `transferFrom`.\n * This allows applications to reconstruct the allowance for all accounts just\n * by listening to said events. Other implementations of the EIP may not emit\n * these events, as it isn't required by the specification.\n *\n * Finally, the non-standard `decreaseAllowance` and `increaseAllowance`\n * functions have been added to mitigate the well-known issues around setting\n * allowances. See `IERC20.approve`.\n */\ncontract ERC20 is IERC20 {\n using SafeMath for uint256;\n\n mapping (address => uint256) private _balances;\n\n mapping (address => mapping (address => uint256)) private _allowances;\n\n uint256 private _totalSupply;\n\n /**\n * @dev See `IERC20.totalSupply`.\n */\n function totalSupply() public view returns (uint256) {\n return _totalSupply;\n }\n\n /**\n * @dev See `IERC20.balanceOf`.\n */\n function balanceOf(address account) public view returns (uint256) {\n return _balances[account];\n }\n\n /**\n * @dev See `IERC20.transfer`.\n *\n * Requirements:\n *\n * - `recipient` cannot be the zero address.\n * - the caller must have a balance of at least `amount`.\n */\n function transfer(address recipient, uint256 amount) public returns (bool) {\n _transfer(msg.sender, recipient, amount);\n return true;\n }\n\n /**\n * @dev See `IERC20.allowance`.\n */\n function allowance(address owner, address spender) public view returns (uint256) {\n return _allowances[owner][spender];\n }\n\n /**\n * @dev See `IERC20.approve`.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n */\n function approve(address spender, uint256 value) public returns (bool) {\n _approve(msg.sender, spender, value);\n return true;\n }\n\n /**\n * @dev See `IERC20.transferFrom`.\n *\n * Emits an `Approval` event indicating the updated allowance. This is not\n * required by the EIP. See the note at the beginning of `ERC20`;\n *\n * Requirements:\n * - `sender` and `recipient` cannot be the zero address.\n * - `sender` must have a balance of at least `value`.\n * - the caller must have allowance for `sender`'s tokens of at least\n * `amount`.\n */\n function transferFrom(address sender, address recipient, uint256 amount) public returns (bool) {\n _transfer(sender, recipient, amount);\n _approve(sender, msg.sender, _allowances[sender][msg.sender].sub(amount));\n return true;\n }\n\n /**\n * @dev Atomically increases the allowance granted to `spender` by the caller.\n *\n * This is an alternative to `approve` that can be used as a mitigation for\n * problems described in `IERC20.approve`.\n *\n * Emits an `Approval` event indicating the updated allowance.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n */\n function increaseAllowance(address spender, uint256 addedValue) public returns (bool) {\n _approve(msg.sender, spender, _allowances[msg.sender][spender].add(addedValue));\n return true;\n }\n\n /**\n * @dev Atomically decreases the allowance granted to `spender` by the caller.\n *\n * This is an alternative to `approve` that can be used as a mitigation for\n * problems described in `IERC20.approve`.\n *\n * Emits an `Approval` event indicating the updated allowance.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n * - `spender` must have allowance for the caller of at least\n * `subtractedValue`.\n */\n function decreaseAllowance(address spender, uint256 subtractedValue) public returns (bool) {\n _approve(msg.sender, spender, _allowances[msg.sender][spender].sub(subtractedValue));\n return true;\n }\n\n /**\n * @dev Moves tokens `amount` from `sender` to `recipient`.\n *\n * This is internal function is equivalent to `transfer`, and can be used to\n * e.g. implement automatic token fees, slashing mechanisms, etc.\n *\n * Emits a `Transfer` event.\n *\n * Requirements:\n *\n * - `sender` cannot be the zero address.\n * - `recipient` cannot be the zero address.\n * - `sender` must have a balance of at least `amount`.\n */\n function _transfer(address sender, address recipient, uint256 amount) internal {\n require(sender != address(0), \"ERC20: transfer from the zero address\");\n require(recipient != address(0), \"ERC20: transfer to the zero address\");\n\n _balances[sender] = _balances[sender].sub(amount);\n _balances[recipient] = _balances[recipient].add(amount);\n emit Transfer(sender, recipient, amount);\n }\n\n /** @dev Creates `amount` tokens and assigns them to `account`, increasing\n * the total supply.\n *\n * Emits a `Transfer` event with `from` set to the zero address.\n *\n * Requirements\n *\n * - `to` cannot be the zero address.\n */\n function _mint(address account, uint256 amount) internal {\n require(account != address(0), \"ERC20: mint to the zero address\");\n\n _totalSupply = _totalSupply.add(amount);\n _balances[account] = _balances[account].add(amount);\n emit Transfer(address(0), account, amount);\n }\n\n /**\n * @dev Destoys `amount` tokens from `account`, reducing the\n * total supply.\n *\n * Emits a `Transfer` event with `to` set to the zero address.\n *\n * Requirements\n *\n * - `account` cannot be the zero address.\n * - `account` must have at least `amount` tokens.\n */\n function _burn(address account, uint256 value) internal {\n require(account != address(0), \"ERC20: burn from the zero address\");\n\n _totalSupply = _totalSupply.sub(value);\n _balances[account] = _balances[account].sub(value);\n emit Transfer(account, address(0), value);\n }\n\n /**\n * @dev Sets `amount` as the allowance of `spender` over the `owner`s tokens.\n *\n * This is internal function is equivalent to `approve`, and can be used to\n * e.g. set automatic allowances for certain subsystems, etc.\n *\n * Emits an `Approval` event.\n *\n * Requirements:\n *\n * - `owner` cannot be the zero address.\n * - `spender` cannot be the zero address.\n */\n function _approve(address owner, address spender, uint256 value) internal {\n require(owner != address(0), \"ERC20: approve from the zero address\");\n require(spender != address(0), \"ERC20: approve to the zero address\");\n\n _allowances[owner][spender] = value;\n emit Approval(owner, spender, value);\n }\n\n /**\n * @dev Destoys `amount` tokens from `account`.`amount` is then deducted\n * from the caller's allowance.\n *\n * See `_burn` and `_approve`.\n */\n function _burnFrom(address account, uint256 amount) internal {\n _burn(account, amount);\n _approve(account, msg.sender, _allowances[account][msg.sender].sub(amount));\n }\n}\n", - "sourcePath": "@openzeppelin/contracts/token/ERC20/ERC20.sol", + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"details\":\"Implementation of the {IERC20} interface. * This implementation is agnostic to the way tokens are created. This means that a supply mechanism has to be added in a derived contract using {_mint}. For a generic mechanism see {ERC20Mintable}. * TIP: For a detailed writeup see our guide https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How to implement supply mechanisms]. * We have followed general OpenZeppelin guidelines: functions revert instead of returning `false` on failure. This behavior is nonetheless conventional and does not conflict with the expectations of ERC20 applications. * Additionally, an {Approval} event is emitted on calls to {transferFrom}. This allows applications to reconstruct the allowance for all accounts just by listening to said events. Other implementations of the EIP may not emit these events, as it isn't required by the specification. * Finally, the non-standard {decreaseAllowance} and {increaseAllowance} functions have been added to mitigate the well-known issues around setting allowances. See {IERC20-approve}.\",\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":\"ERC20\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x6080604052610e31806100136000396000f3fe608060405234801561001057600080fd5b50600436106100885760003560e01c806370a082311161005b57806370a08231146101fd578063a457c2d714610255578063a9059cbb146102bb578063dd62ed3e1461032157610088565b8063095ea7b31461008d57806318160ddd146100f357806323b872dd146101115780633950935114610197575b600080fd5b6100d9600480360360408110156100a357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610399565b604051808215151515815260200191505060405180910390f35b6100fb6103b7565b6040518082815260200191505060405180910390f35b61017d6004803603606081101561012757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506103c1565b604051808215151515815260200191505060405180910390f35b6101e3600480360360408110156101ad57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061049a565b604051808215151515815260200191505060405180910390f35b61023f6004803603602081101561021357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061054d565b6040518082815260200191505060405180910390f35b6102a16004803603604081101561026b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610595565b604051808215151515815260200191505060405180910390f35b610307600480360360408110156102d157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610662565b604051808215151515815260200191505060405180910390f35b6103836004803603604081101561033757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610680565b6040518082815260200191505060405180910390f35b60006103ad6103a6610707565b848461070f565b6001905092915050565b6000600254905090565b60006103ce848484610906565b61048f846103da610707565b61048a85604051806060016040528060288152602001610d7060289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000610440610707565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bbc9092919063ffffffff16565b61070f565b600190509392505050565b60006105436104a7610707565b8461053e85600160006104b8610707565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610c7c90919063ffffffff16565b61070f565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60006106586105a2610707565b8461065385604051806060016040528060258152602001610de160259139600160006105cc610707565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bbc9092919063ffffffff16565b61070f565b6001905092915050565b600061067661066f610707565b8484610906565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610795576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526024815260200180610dbd6024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561081b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180610d286022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16141561098c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526025815260200180610d986025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610a12576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180610d056023913960400191505060405180910390fd5b610a7d81604051806060016040528060268152602001610d4a602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bbc9092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610b10816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610c7c90919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610c69576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610c2e578082015181840152602081019050610c13565b50505050905090810190601f168015610c5b5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610cfa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b809150509291505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820ebe07ba90496035ea625d5a56d5b09f40b4ca4d173ad0d2be7cffd81c585046c0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100885760003560e01c806370a082311161005b57806370a08231146101fd578063a457c2d714610255578063a9059cbb146102bb578063dd62ed3e1461032157610088565b8063095ea7b31461008d57806318160ddd146100f357806323b872dd146101115780633950935114610197575b600080fd5b6100d9600480360360408110156100a357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610399565b604051808215151515815260200191505060405180910390f35b6100fb6103b7565b6040518082815260200191505060405180910390f35b61017d6004803603606081101561012757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506103c1565b604051808215151515815260200191505060405180910390f35b6101e3600480360360408110156101ad57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061049a565b604051808215151515815260200191505060405180910390f35b61023f6004803603602081101561021357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061054d565b6040518082815260200191505060405180910390f35b6102a16004803603604081101561026b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610595565b604051808215151515815260200191505060405180910390f35b610307600480360360408110156102d157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610662565b604051808215151515815260200191505060405180910390f35b6103836004803603604081101561033757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610680565b6040518082815260200191505060405180910390f35b60006103ad6103a6610707565b848461070f565b6001905092915050565b6000600254905090565b60006103ce848484610906565b61048f846103da610707565b61048a85604051806060016040528060288152602001610d7060289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000610440610707565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bbc9092919063ffffffff16565b61070f565b600190509392505050565b60006105436104a7610707565b8461053e85600160006104b8610707565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610c7c90919063ffffffff16565b61070f565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60006106586105a2610707565b8461065385604051806060016040528060258152602001610de160259139600160006105cc610707565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bbc9092919063ffffffff16565b61070f565b6001905092915050565b600061067661066f610707565b8484610906565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610795576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526024815260200180610dbd6024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561081b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180610d286022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16141561098c576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526025815260200180610d986025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610a12576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180610d056023913960400191505060405180910390fd5b610a7d81604051806060016040528060268152602001610d4a602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bbc9092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610b10816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610c7c90919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610c69576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610c2e578082015181840152602081019050610c13565b50505050905090810190601f168015610c5b5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610cfa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b809150509291505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820ebe07ba90496035ea625d5a56d5b09f40b4ca4d173ad0d2be7cffd81c585046c0029", + "sourceMap": "1268:6824:58:-;;;;;;;;;", + "deployedSourceMap": "1268:6824:58:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1268:6824:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;3802:207;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;4496:258;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;2500:149;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;3802:207::-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;4496:258::-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"../../GSN/Context.sol\";\nimport \"./IERC20.sol\";\nimport \"../../math/SafeMath.sol\";\n\n/**\n * @dev Implementation of the {IERC20} interface.\n *\n * This implementation is agnostic to the way tokens are created. This means\n * that a supply mechanism has to be added in a derived contract using {_mint}.\n * For a generic mechanism see {ERC20Mintable}.\n *\n * TIP: For a detailed writeup see our guide\n * https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How\n * to implement supply mechanisms].\n *\n * We have followed general OpenZeppelin guidelines: functions revert instead\n * of returning `false` on failure. This behavior is nonetheless conventional\n * and does not conflict with the expectations of ERC20 applications.\n *\n * Additionally, an {Approval} event is emitted on calls to {transferFrom}.\n * This allows applications to reconstruct the allowance for all accounts just\n * by listening to said events. Other implementations of the EIP may not emit\n * these events, as it isn't required by the specification.\n *\n * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}\n * functions have been added to mitigate the well-known issues around setting\n * allowances. See {IERC20-approve}.\n */\ncontract ERC20 is Context, IERC20 {\n using SafeMath for uint256;\n\n mapping (address => uint256) private _balances;\n\n mapping (address => mapping (address => uint256)) private _allowances;\n\n uint256 private _totalSupply;\n\n /**\n * @dev See {IERC20-totalSupply}.\n */\n function totalSupply() public view returns (uint256) {\n return _totalSupply;\n }\n\n /**\n * @dev See {IERC20-balanceOf}.\n */\n function balanceOf(address account) public view returns (uint256) {\n return _balances[account];\n }\n\n /**\n * @dev See {IERC20-transfer}.\n *\n * Requirements:\n *\n * - `recipient` cannot be the zero address.\n * - the caller must have a balance of at least `amount`.\n */\n function transfer(address recipient, uint256 amount) public returns (bool) {\n _transfer(_msgSender(), recipient, amount);\n return true;\n }\n\n /**\n * @dev See {IERC20-allowance}.\n */\n function allowance(address owner, address spender) public view returns (uint256) {\n return _allowances[owner][spender];\n }\n\n /**\n * @dev See {IERC20-approve}.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n */\n function approve(address spender, uint256 amount) public returns (bool) {\n _approve(_msgSender(), spender, amount);\n return true;\n }\n\n /**\n * @dev See {IERC20-transferFrom}.\n *\n * Emits an {Approval} event indicating the updated allowance. This is not\n * required by the EIP. See the note at the beginning of {ERC20};\n *\n * Requirements:\n * - `sender` and `recipient` cannot be the zero address.\n * - `sender` must have a balance of at least `amount`.\n * - the caller must have allowance for `sender`'s tokens of at least\n * `amount`.\n */\n function transferFrom(address sender, address recipient, uint256 amount) public returns (bool) {\n _transfer(sender, recipient, amount);\n _approve(sender, _msgSender(), _allowances[sender][_msgSender()].sub(amount, \"ERC20: transfer amount exceeds allowance\"));\n return true;\n }\n\n /**\n * @dev Atomically increases the allowance granted to `spender` by the caller.\n *\n * This is an alternative to {approve} that can be used as a mitigation for\n * problems described in {IERC20-approve}.\n *\n * Emits an {Approval} event indicating the updated allowance.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n */\n function increaseAllowance(address spender, uint256 addedValue) public returns (bool) {\n _approve(_msgSender(), spender, _allowances[_msgSender()][spender].add(addedValue));\n return true;\n }\n\n /**\n * @dev Atomically decreases the allowance granted to `spender` by the caller.\n *\n * This is an alternative to {approve} that can be used as a mitigation for\n * problems described in {IERC20-approve}.\n *\n * Emits an {Approval} event indicating the updated allowance.\n *\n * Requirements:\n *\n * - `spender` cannot be the zero address.\n * - `spender` must have allowance for the caller of at least\n * `subtractedValue`.\n */\n function decreaseAllowance(address spender, uint256 subtractedValue) public returns (bool) {\n _approve(_msgSender(), spender, _allowances[_msgSender()][spender].sub(subtractedValue, \"ERC20: decreased allowance below zero\"));\n return true;\n }\n\n /**\n * @dev Moves tokens `amount` from `sender` to `recipient`.\n *\n * This is internal function is equivalent to {transfer}, and can be used to\n * e.g. implement automatic token fees, slashing mechanisms, etc.\n *\n * Emits a {Transfer} event.\n *\n * Requirements:\n *\n * - `sender` cannot be the zero address.\n * - `recipient` cannot be the zero address.\n * - `sender` must have a balance of at least `amount`.\n */\n function _transfer(address sender, address recipient, uint256 amount) internal {\n require(sender != address(0), \"ERC20: transfer from the zero address\");\n require(recipient != address(0), \"ERC20: transfer to the zero address\");\n\n _balances[sender] = _balances[sender].sub(amount, \"ERC20: transfer amount exceeds balance\");\n _balances[recipient] = _balances[recipient].add(amount);\n emit Transfer(sender, recipient, amount);\n }\n\n /** @dev Creates `amount` tokens and assigns them to `account`, increasing\n * the total supply.\n *\n * Emits a {Transfer} event with `from` set to the zero address.\n *\n * Requirements\n *\n * - `to` cannot be the zero address.\n */\n function _mint(address account, uint256 amount) internal {\n require(account != address(0), \"ERC20: mint to the zero address\");\n\n _totalSupply = _totalSupply.add(amount);\n _balances[account] = _balances[account].add(amount);\n emit Transfer(address(0), account, amount);\n }\n\n /**\n * @dev Destroys `amount` tokens from `account`, reducing the\n * total supply.\n *\n * Emits a {Transfer} event with `to` set to the zero address.\n *\n * Requirements\n *\n * - `account` cannot be the zero address.\n * - `account` must have at least `amount` tokens.\n */\n function _burn(address account, uint256 amount) internal {\n require(account != address(0), \"ERC20: burn from the zero address\");\n\n _balances[account] = _balances[account].sub(amount, \"ERC20: burn amount exceeds balance\");\n _totalSupply = _totalSupply.sub(amount);\n emit Transfer(account, address(0), amount);\n }\n\n /**\n * @dev Sets `amount` as the allowance of `spender` over the `owner`s tokens.\n *\n * This is internal function is equivalent to `approve`, and can be used to\n * e.g. set automatic allowances for certain subsystems, etc.\n *\n * Emits an {Approval} event.\n *\n * Requirements:\n *\n * - `owner` cannot be the zero address.\n * - `spender` cannot be the zero address.\n */\n function _approve(address owner, address spender, uint256 amount) internal {\n require(owner != address(0), \"ERC20: approve from the zero address\");\n require(spender != address(0), \"ERC20: approve to the zero address\");\n\n _allowances[owner][spender] = amount;\n emit Approval(owner, spender, amount);\n }\n\n /**\n * @dev Destroys `amount` tokens from `account`.`amount` is then deducted\n * from the caller's allowance.\n *\n * See {_burn} and {_approve}.\n */\n function _burnFrom(address account, uint256 amount) internal {\n _burn(account, amount);\n _approve(account, _msgSender(), _allowances[account][_msgSender()].sub(amount, \"ERC20: burn amount exceeds allowance\"));\n }\n}\n", + "sourcePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", "ast": { - "absolutePath": "@openzeppelin/contracts/token/ERC20/ERC20.sol", + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", "exportedSymbols": { "ERC20": [ - 1374 + 11659 ] }, - "id": 1375, + "id": 11660, "nodeType": "SourceUnit", "nodes": [ { - "id": 979, + "id": 11256, "literals": [ "solidity", "^", @@ -247,27 +247,38 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:8" + "src": "0:23:58" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/GSN/Context.sol", + "file": "../../GSN/Context.sol", + "id": 11257, + "nodeType": "ImportDirective", + "scope": 11660, + "sourceUnit": 10954, + "src": "25:31:58", + "symbolAliases": [], + "unitAlias": "" }, { - "absolutePath": "@openzeppelin/contracts/token/ERC20/IERC20.sol", + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", "file": "./IERC20.sol", - "id": 980, + "id": 11258, "nodeType": "ImportDirective", - "scope": 1375, - "sourceUnit": 1444, - "src": "25:22:8", + "scope": 11660, + "sourceUnit": 11787, + "src": "57:22:58", "symbolAliases": [], "unitAlias": "" }, { - "absolutePath": "@openzeppelin/contracts/math/SafeMath.sol", + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", "file": "../../math/SafeMath.sol", - "id": 981, + "id": 11259, "nodeType": "ImportDirective", - "scope": 1375, - "sourceUnit": 978, - "src": "48:33:8", + "scope": 11660, + "sourceUnit": 11141, + "src": "80:33:58", "symbolAliases": [], "unitAlias": "" }, @@ -277,56 +288,76 @@ "arguments": null, "baseName": { "contractScope": null, - "id": 982, + "id": 11260, + "name": "Context", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10953, + "src": "1286:7:58", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Context_$10953", + "typeString": "contract Context" + } + }, + "id": 11261, + "nodeType": "InheritanceSpecifier", + "src": "1286:7:58" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 11262, "name": "IERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1443, - "src": "1250:6:8", + "referencedDeclaration": 11786, + "src": "1295:6:58", "typeDescriptions": { - "typeIdentifier": "t_contract$_IERC20_$1443", + "typeIdentifier": "t_contract$_IERC20_$11786", "typeString": "contract IERC20" } }, - "id": 983, + "id": 11263, "nodeType": "InheritanceSpecifier", - "src": "1250:6:8" + "src": "1295:6:58" } ], "contractDependencies": [ - 1443 + 10953, + 11786 ], "contractKind": "contract", - "documentation": "@dev Implementation of the `IERC20` interface.\n * This implementation is agnostic to the way tokens are created. This means\nthat a supply mechanism has to be added in a derived contract using `_mint`.\nFor a generic mechanism see `ERC20Mintable`.\n * *For a detailed writeup see our guide [How to implement supply\nmechanisms](https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226).*\n * We have followed general OpenZeppelin guidelines: functions revert instead\nof returning `false` on failure. This behavior is nonetheless conventional\nand does not conflict with the expectations of ERC20 applications.\n * Additionally, an `Approval` event is emitted on calls to `transferFrom`.\nThis allows applications to reconstruct the allowance for all accounts just\nby listening to said events. Other implementations of the EIP may not emit\nthese events, as it isn't required by the specification.\n * Finally, the non-standard `decreaseAllowance` and `increaseAllowance`\nfunctions have been added to mitigate the well-known issues around setting\nallowances. See `IERC20.approve`.", + "documentation": "@dev Implementation of the {IERC20} interface.\n * This implementation is agnostic to the way tokens are created. This means\nthat a supply mechanism has to be added in a derived contract using {_mint}.\nFor a generic mechanism see {ERC20Mintable}.\n * TIP: For a detailed writeup see our guide\nhttps://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How\nto implement supply mechanisms].\n * We have followed general OpenZeppelin guidelines: functions revert instead\nof returning `false` on failure. This behavior is nonetheless conventional\nand does not conflict with the expectations of ERC20 applications.\n * Additionally, an {Approval} event is emitted on calls to {transferFrom}.\nThis allows applications to reconstruct the allowance for all accounts just\nby listening to said events. Other implementations of the EIP may not emit\nthese events, as it isn't required by the specification.\n * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}\nfunctions have been added to mitigate the well-known issues around setting\nallowances. See {IERC20-approve}.", "fullyImplemented": true, - "id": 1374, + "id": 11659, "linearizedBaseContracts": [ - 1374, - 1443 + 11659, + 11786, + 10953 ], "name": "ERC20", "nodeType": "ContractDefinition", "nodes": [ { - "id": 986, + "id": 11266, "libraryName": { "contractScope": null, - "id": 984, + "id": 11264, "name": "SafeMath", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 977, - "src": "1269:8:8", + "referencedDeclaration": 11140, + "src": "1314:8:58", "typeDescriptions": { - "typeIdentifier": "t_contract$_SafeMath_$977", + "typeIdentifier": "t_contract$_SafeMath_$11140", "typeString": "library SafeMath" } }, "nodeType": "UsingForDirective", - "src": "1263:27:8", + "src": "1308:27:58", "typeName": { - "id": 985, + "id": 11265, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1282:7:8", + "src": "1327:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -335,11 +366,11 @@ }, { "constant": false, - "id": 990, + "id": 11270, "name": "_balances", "nodeType": "VariableDeclaration", - "scope": 1374, - "src": "1296:46:8", + "scope": 11659, + "src": "1341:46:58", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -347,28 +378,28 @@ "typeString": "mapping(address => uint256)" }, "typeName": { - "id": 989, + "id": 11269, "keyType": { - "id": 987, + "id": 11267, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1305:7:8", + "src": "1350:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Mapping", - "src": "1296:28:8", + "src": "1341:28:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" }, "valueType": { - "id": 988, + "id": 11268, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1316:7:8", + "src": "1361:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -380,11 +411,11 @@ }, { "constant": false, - "id": 996, + "id": 11276, "name": "_allowances", "nodeType": "VariableDeclaration", - "scope": 1374, - "src": "1349:69:8", + "scope": 11659, + "src": "1394:69:58", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -392,46 +423,46 @@ "typeString": "mapping(address => mapping(address => uint256))" }, "typeName": { - "id": 995, + "id": 11275, "keyType": { - "id": 991, + "id": 11271, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1358:7:8", + "src": "1403:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Mapping", - "src": "1349:49:8", + "src": "1394:49:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" }, "valueType": { - "id": 994, + "id": 11274, "keyType": { - "id": 992, + "id": 11272, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1378:7:8", + "src": "1423:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Mapping", - "src": "1369:28:8", + "src": "1414:28:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" }, "valueType": { - "id": 993, + "id": 11273, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1389:7:8", + "src": "1434:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -444,11 +475,11 @@ }, { "constant": false, - "id": 998, + "id": 11278, "name": "_totalSupply", "nodeType": "VariableDeclaration", - "scope": 1374, - "src": "1425:28:8", + "scope": 11659, + "src": "1470:28:58", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -456,10 +487,10 @@ "typeString": "uint256" }, "typeName": { - "id": 997, + "id": 11277, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1425:7:8", + "src": "1470:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -470,55 +501,55 @@ }, { "body": { - "id": 1005, + "id": 11285, "nodeType": "Block", - "src": "1567:36:8", + "src": "1612:36:58", "statements": [ { "expression": { "argumentTypes": null, - "id": 1003, + "id": 11283, "name": "_totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 998, - "src": "1584:12:8", + "referencedDeclaration": 11278, + "src": "1629:12:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 1002, - "id": 1004, + "functionReturnParameters": 11282, + "id": 11284, "nodeType": "Return", - "src": "1577:19:8" + "src": "1622:19:58" } ] }, - "documentation": "@dev See `IERC20.totalSupply`.", - "id": 1006, + "documentation": "@dev See {IERC20-totalSupply}.", + "id": 11286, "implemented": true, "kind": "function", "modifiers": [], "name": "totalSupply", "nodeType": "FunctionDefinition", "parameters": { - "id": 999, + "id": 11279, "nodeType": "ParameterList", "parameters": [], - "src": "1534:2:8" + "src": "1579:2:58" }, "returnParameters": { - "id": 1002, + "id": 11282, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1001, + "id": 11281, "name": "", "nodeType": "VariableDeclaration", - "scope": 1006, - "src": "1558:7:8", + "scope": 11286, + "src": "1603:7:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -526,10 +557,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1000, + "id": 11280, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1558:7:8", + "src": "1603:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -539,45 +570,45 @@ "visibility": "internal" } ], - "src": "1557:9:8" + "src": "1602:9:58" }, - "scope": 1374, - "src": "1514:89:8", + "scope": 11659, + "src": "1559:89:58", "stateMutability": "view", - "superFunction": 1381, + "superFunction": 11724, "visibility": "public" }, { "body": { - "id": 1017, + "id": 11297, "nodeType": "Block", - "src": "1727:42:8", + "src": "1772:42:58", "statements": [ { "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1013, + "id": 11293, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "1744:9:8", + "referencedDeclaration": 11270, + "src": "1789:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1015, + "id": 11295, "indexExpression": { "argumentTypes": null, - "id": 1014, + "id": 11294, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1008, - "src": "1754:7:8", + "referencedDeclaration": 11288, + "src": "1799:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -588,37 +619,37 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "1744:18:8", + "src": "1789:18:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 1012, - "id": 1016, + "functionReturnParameters": 11292, + "id": 11296, "nodeType": "Return", - "src": "1737:25:8" + "src": "1782:25:58" } ] }, - "documentation": "@dev See `IERC20.balanceOf`.", - "id": 1018, + "documentation": "@dev See {IERC20-balanceOf}.", + "id": 11298, "implemented": true, "kind": "function", "modifiers": [], "name": "balanceOf", "nodeType": "FunctionDefinition", "parameters": { - "id": 1009, + "id": 11289, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1008, + "id": 11288, "name": "account", "nodeType": "VariableDeclaration", - "scope": 1018, - "src": "1680:15:8", + "scope": 11298, + "src": "1725:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -626,10 +657,10 @@ "typeString": "address" }, "typeName": { - "id": 1007, + "id": 11287, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1680:7:8", + "src": "1725:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -640,19 +671,19 @@ "visibility": "internal" } ], - "src": "1679:17:8" + "src": "1724:17:58" }, "returnParameters": { - "id": 1012, + "id": 11292, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1011, + "id": 11291, "name": "", "nodeType": "VariableDeclaration", - "scope": 1018, - "src": "1718:7:8", + "scope": 11298, + "src": "1763:7:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -660,10 +691,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1010, + "id": 11290, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1718:7:8", + "src": "1763:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -673,19 +704,19 @@ "visibility": "internal" } ], - "src": "1717:9:8" + "src": "1762:9:58" }, - "scope": 1374, - "src": "1661:108:8", + "scope": 11659, + "src": "1706:108:58", "stateMutability": "view", - "superFunction": 1388, + "superFunction": 11731, "visibility": "public" }, { "body": { - "id": 1036, + "id": 11316, "nodeType": "Block", - "src": "2047:78:8", + "src": "2092:80:58", "statements": [ { "expression": { @@ -693,28 +724,29 @@ "arguments": [ { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1028, - "name": "msg", + "argumentTypes": [], + "id": 11308, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2067:3:8", + "referencedDeclaration": 10941, + "src": "2112:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1029, + "id": 11309, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "2067:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "2112:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -722,12 +754,12 @@ }, { "argumentTypes": null, - "id": 1030, + "id": 11310, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1020, - "src": "2079:9:8", + "referencedDeclaration": 11300, + "src": "2126:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -735,12 +767,12 @@ }, { "argumentTypes": null, - "id": 1031, + "id": 11311, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1022, - "src": "2090:6:8", + "referencedDeclaration": 11302, + "src": "2137:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -762,18 +794,18 @@ "typeString": "uint256" } ], - "id": 1027, + "id": 11307, "name": "_transfer", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1217, - "src": "2057:9:8", + "referencedDeclaration": 11500, + "src": "2102:9:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1032, + "id": 11312, "isConstant": false, "isLValue": false, "isPure": false, @@ -781,28 +813,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2057:40:8", + "src": "2102:42:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1033, + "id": 11313, "nodeType": "ExpressionStatement", - "src": "2057:40:8" + "src": "2102:42:58" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", - "id": 1034, + "id": 11314, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", - "src": "2114:4:8", + "src": "2161:4:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", @@ -810,31 +842,31 @@ }, "value": "true" }, - "functionReturnParameters": 1026, - "id": 1035, + "functionReturnParameters": 11306, + "id": 11315, "nodeType": "Return", - "src": "2107:11:8" + "src": "2154:11:58" } ] }, - "documentation": "@dev See `IERC20.transfer`.\n * Requirements:\n * - `recipient` cannot be the zero address.\n- the caller must have a balance of at least `amount`.", - "id": 1037, + "documentation": "@dev See {IERC20-transfer}.\n * Requirements:\n * - `recipient` cannot be the zero address.\n- the caller must have a balance of at least `amount`.", + "id": 11317, "implemented": true, "kind": "function", "modifiers": [], "name": "transfer", "nodeType": "FunctionDefinition", "parameters": { - "id": 1023, + "id": 11303, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1020, + "id": 11300, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 1037, - "src": "1990:17:8", + "scope": 11317, + "src": "2035:17:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -842,10 +874,10 @@ "typeString": "address" }, "typeName": { - "id": 1019, + "id": 11299, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1990:7:8", + "src": "2035:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -857,11 +889,11 @@ }, { "constant": false, - "id": 1022, + "id": 11302, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1037, - "src": "2009:14:8", + "scope": 11317, + "src": "2054:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -869,10 +901,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1021, + "id": 11301, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2009:7:8", + "src": "2054:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -882,19 +914,19 @@ "visibility": "internal" } ], - "src": "1989:35:8" + "src": "2034:35:58" }, "returnParameters": { - "id": 1026, + "id": 11306, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1025, + "id": 11305, "name": "", "nodeType": "VariableDeclaration", - "scope": 1037, - "src": "2041:4:8", + "scope": 11317, + "src": "2086:4:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -902,10 +934,10 @@ "typeString": "bool" }, "typeName": { - "id": 1024, + "id": 11304, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "2041:4:8", + "src": "2086:4:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -915,19 +947,19 @@ "visibility": "internal" } ], - "src": "2040:6:8" + "src": "2085:6:58" }, - "scope": 1374, - "src": "1972:153:8", + "scope": 11659, + "src": "2017:155:58", "stateMutability": "nonpayable", - "superFunction": 1397, + "superFunction": 11740, "visibility": "public" }, { "body": { - "id": 1052, + "id": 11332, "nodeType": "Block", - "src": "2264:51:8", + "src": "2311:51:58", "statements": [ { "expression": { @@ -936,26 +968,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1046, + "id": 11326, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "2281:11:8", + "referencedDeclaration": 11276, + "src": "2328:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1048, + "id": 11328, "indexExpression": { "argumentTypes": null, - "id": 1047, + "id": 11327, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1039, - "src": "2293:5:8", + "referencedDeclaration": 11319, + "src": "2340:5:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -966,21 +998,21 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "2281:18:8", + "src": "2328:18:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1050, + "id": 11330, "indexExpression": { "argumentTypes": null, - "id": 1049, + "id": 11329, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1041, - "src": "2300:7:8", + "referencedDeclaration": 11321, + "src": "2347:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -991,37 +1023,37 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "2281:27:8", + "src": "2328:27:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 1045, - "id": 1051, + "functionReturnParameters": 11325, + "id": 11331, "nodeType": "Return", - "src": "2274:34:8" + "src": "2321:34:58" } ] }, - "documentation": "@dev See `IERC20.allowance`.", - "id": 1053, + "documentation": "@dev See {IERC20-allowance}.", + "id": 11333, "implemented": true, "kind": "function", "modifiers": [], "name": "allowance", "nodeType": "FunctionDefinition", "parameters": { - "id": 1042, + "id": 11322, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1039, + "id": 11319, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 1053, - "src": "2202:13:8", + "scope": 11333, + "src": "2249:13:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1029,10 +1061,10 @@ "typeString": "address" }, "typeName": { - "id": 1038, + "id": 11318, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2202:7:8", + "src": "2249:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1044,11 +1076,11 @@ }, { "constant": false, - "id": 1041, + "id": 11321, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1053, - "src": "2217:15:8", + "scope": 11333, + "src": "2264:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1056,10 +1088,10 @@ "typeString": "address" }, "typeName": { - "id": 1040, + "id": 11320, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2217:7:8", + "src": "2264:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1070,19 +1102,19 @@ "visibility": "internal" } ], - "src": "2201:32:8" + "src": "2248:32:58" }, "returnParameters": { - "id": 1045, + "id": 11325, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1044, + "id": 11324, "name": "", "nodeType": "VariableDeclaration", - "scope": 1053, - "src": "2255:7:8", + "scope": 11333, + "src": "2302:7:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1090,10 +1122,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1043, + "id": 11323, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2255:7:8", + "src": "2302:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1103,19 +1135,19 @@ "visibility": "internal" } ], - "src": "2254:9:8" + "src": "2301:9:58" }, - "scope": 1374, - "src": "2183:132:8", + "scope": 11659, + "src": "2230:132:58", "stateMutability": "view", - "superFunction": 1406, + "superFunction": 11749, "visibility": "public" }, { "body": { - "id": 1071, + "id": 11351, "nodeType": "Block", - "src": "2524:74:8", + "src": "2572:77:58", "statements": [ { "expression": { @@ -1123,28 +1155,29 @@ "arguments": [ { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1063, - "name": "msg", + "argumentTypes": [], + "id": 11343, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2543:3:8", + "referencedDeclaration": 10941, + "src": "2591:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1064, + "id": 11344, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "2543:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "2591:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1152,12 +1185,12 @@ }, { "argumentTypes": null, - "id": 1065, + "id": 11345, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1055, - "src": "2555:7:8", + "referencedDeclaration": 11335, + "src": "2605:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1165,12 +1198,12 @@ }, { "argumentTypes": null, - "id": 1066, - "name": "value", + "id": 11346, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1057, - "src": "2564:5:8", + "referencedDeclaration": 11337, + "src": "2614:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1192,18 +1225,18 @@ "typeString": "uint256" } ], - "id": 1062, + "id": 11342, "name": "_approve", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1345, - "src": "2534:8:8", + "referencedDeclaration": 11629, + "src": "2582:8:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1067, + "id": 11347, "isConstant": false, "isLValue": false, "isPure": false, @@ -1211,28 +1244,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2534:36:8", + "src": "2582:39:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1068, + "id": 11348, "nodeType": "ExpressionStatement", - "src": "2534:36:8" + "src": "2582:39:58" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", - "id": 1069, + "id": 11349, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", - "src": "2587:4:8", + "src": "2638:4:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", @@ -1240,31 +1273,31 @@ }, "value": "true" }, - "functionReturnParameters": 1061, - "id": 1070, + "functionReturnParameters": 11341, + "id": 11350, "nodeType": "Return", - "src": "2580:11:8" + "src": "2631:11:58" } ] }, - "documentation": "@dev See `IERC20.approve`.\n * Requirements:\n * - `spender` cannot be the zero address.", - "id": 1072, + "documentation": "@dev See {IERC20-approve}.\n * Requirements:\n * - `spender` cannot be the zero address.", + "id": 11352, "implemented": true, "kind": "function", "modifiers": [], "name": "approve", "nodeType": "FunctionDefinition", "parameters": { - "id": 1058, + "id": 11338, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1055, + "id": 11335, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1072, - "src": "2470:15:8", + "scope": 11352, + "src": "2517:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1272,10 +1305,10 @@ "typeString": "address" }, "typeName": { - "id": 1054, + "id": 11334, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2470:7:8", + "src": "2517:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1287,11 +1320,11 @@ }, { "constant": false, - "id": 1057, - "name": "value", + "id": 11337, + "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1072, - "src": "2487:13:8", + "scope": 11352, + "src": "2534:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1299,10 +1332,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1056, + "id": 11336, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2487:7:8", + "src": "2534:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1312,19 +1345,19 @@ "visibility": "internal" } ], - "src": "2469:32:8" + "src": "2516:33:58" }, "returnParameters": { - "id": 1061, + "id": 11341, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1060, + "id": 11340, "name": "", "nodeType": "VariableDeclaration", - "scope": 1072, - "src": "2518:4:8", + "scope": 11352, + "src": "2566:4:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1332,10 +1365,10 @@ "typeString": "bool" }, "typeName": { - "id": 1059, + "id": 11339, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "2518:4:8", + "src": "2566:4:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1345,19 +1378,19 @@ "visibility": "internal" } ], - "src": "2517:6:8" + "src": "2565:6:58" }, - "scope": 1374, - "src": "2453:145:8", + "scope": 11659, + "src": "2500:149:58", "stateMutability": "nonpayable", - "superFunction": 1415, + "superFunction": 11758, "visibility": "public" }, { "body": { - "id": 1106, + "id": 11387, "nodeType": "Block", - "src": "3150:157:8", + "src": "3202:205:58", "statements": [ { "expression": { @@ -1365,12 +1398,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1084, + "id": 11364, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1074, - "src": "3170:6:8", + "referencedDeclaration": 11354, + "src": "3222:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1378,12 +1411,12 @@ }, { "argumentTypes": null, - "id": 1085, + "id": 11365, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1076, - "src": "3178:9:8", + "referencedDeclaration": 11356, + "src": "3230:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1391,12 +1424,12 @@ }, { "argumentTypes": null, - "id": 1086, + "id": 11366, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1078, - "src": "3189:6:8", + "referencedDeclaration": 11358, + "src": "3241:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1418,18 +1451,18 @@ "typeString": "uint256" } ], - "id": 1083, + "id": 11363, "name": "_transfer", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1217, - "src": "3160:9:8", + "referencedDeclaration": 11500, + "src": "3212:9:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1087, + "id": 11367, "isConstant": false, "isLValue": false, "isPure": false, @@ -1437,15 +1470,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3160:36:8", + "src": "3212:36:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1088, + "id": 11368, "nodeType": "ExpressionStatement", - "src": "3160:36:8" + "src": "3212:36:58" }, { "expression": { @@ -1453,12 +1486,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1090, + "id": 11370, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1074, - "src": "3215:6:8", + "referencedDeclaration": 11354, + "src": "3267:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1466,28 +1499,29 @@ }, { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1091, - "name": "msg", + "argumentTypes": [], + "id": 11371, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3223:3:8", + "referencedDeclaration": 10941, + "src": "3275:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1092, + "id": 11372, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "3223:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "3275:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1498,16 +1532,34 @@ "arguments": [ { "argumentTypes": null, - "id": 1100, + "id": 11380, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1078, - "src": "3271:6:8", + "referencedDeclaration": 11358, + "src": "3327:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } + }, + { + "argumentTypes": null, + "hexValue": "45524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e6365", + "id": 11381, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3335:42:58", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_974d1b4421da69cc60b481194f0dad36a5bb4e23da810da7a7fb30cdba178330", + "typeString": "literal_string \"ERC20: transfer amount exceeds allowance\"" + }, + "value": "ERC20: transfer amount exceeds allowance" } ], "expression": { @@ -1515,6 +1567,10 @@ { "typeIdentifier": "t_uint256", "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_974d1b4421da69cc60b481194f0dad36a5bb4e23da810da7a7fb30cdba178330", + "typeString": "literal_string \"ERC20: transfer amount exceeds allowance\"" } ], "expression": { @@ -1523,26 +1579,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1093, + "id": 11373, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "3235:11:8", + "referencedDeclaration": 11276, + "src": "3289:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1095, + "id": 11375, "indexExpression": { "argumentTypes": null, - "id": 1094, + "id": 11374, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1074, - "src": "3247:6:8", + "referencedDeclaration": 11354, + "src": "3301:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1553,37 +1609,38 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "3235:19:8", + "src": "3289:19:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1098, + "id": 11378, "indexExpression": { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1096, - "name": "msg", + "argumentTypes": [], + "id": 11376, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3255:3:8", + "referencedDeclaration": 10941, + "src": "3309:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1097, + "id": 11377, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "3255:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "3309:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1594,27 +1651,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "3235:31:8", + "src": "3289:33:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1099, + "id": 11379, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "3235:35:8", + "referencedDeclaration": 11023, + "src": "3289:37:58", "typeDescriptions": { - "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", - "typeString": "function (uint256,uint256) pure returns (uint256)" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 1101, + "id": 11382, "isConstant": false, "isLValue": false, "isPure": false, @@ -1622,7 +1679,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3235:43:8", + "src": "3289:89:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1644,18 +1701,18 @@ "typeString": "uint256" } ], - "id": 1089, + "id": 11369, "name": "_approve", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1345, - "src": "3206:8:8", + "referencedDeclaration": 11629, + "src": "3258:8:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1102, + "id": 11383, "isConstant": false, "isLValue": false, "isPure": false, @@ -1663,28 +1720,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3206:73:8", + "src": "3258:121:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1103, + "id": 11384, "nodeType": "ExpressionStatement", - "src": "3206:73:8" + "src": "3258:121:58" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", - "id": 1104, + "id": 11385, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", - "src": "3296:4:8", + "src": "3396:4:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", @@ -1692,31 +1749,31 @@ }, "value": "true" }, - "functionReturnParameters": 1082, - "id": 1105, + "functionReturnParameters": 11362, + "id": 11386, "nodeType": "Return", - "src": "3289:11:8" + "src": "3389:11:58" } ] }, - "documentation": "@dev See `IERC20.transferFrom`.\n * Emits an `Approval` event indicating the updated allowance. This is not\nrequired by the EIP. See the note at the beginning of `ERC20`;\n * Requirements:\n- `sender` and `recipient` cannot be the zero address.\n- `sender` must have a balance of at least `value`.\n- the caller must have allowance for `sender`'s tokens of at least\n`amount`.", - "id": 1107, + "documentation": "@dev See {IERC20-transferFrom}.\n * Emits an {Approval} event indicating the updated allowance. This is not\nrequired by the EIP. See the note at the beginning of {ERC20};\n * Requirements:\n- `sender` and `recipient` cannot be the zero address.\n- `sender` must have a balance of at least `amount`.\n- the caller must have allowance for `sender`'s tokens of at least\n`amount`.", + "id": 11388, "implemented": true, "kind": "function", "modifiers": [], "name": "transferFrom", "nodeType": "FunctionDefinition", "parameters": { - "id": 1079, + "id": 11359, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1074, + "id": 11354, "name": "sender", "nodeType": "VariableDeclaration", - "scope": 1107, - "src": "3077:14:8", + "scope": 11388, + "src": "3129:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1724,10 +1781,10 @@ "typeString": "address" }, "typeName": { - "id": 1073, + "id": 11353, "name": "address", "nodeType": "ElementaryTypeName", - "src": "3077:7:8", + "src": "3129:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1739,11 +1796,11 @@ }, { "constant": false, - "id": 1076, + "id": 11356, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 1107, - "src": "3093:17:8", + "scope": 11388, + "src": "3145:17:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1751,10 +1808,10 @@ "typeString": "address" }, "typeName": { - "id": 1075, + "id": 11355, "name": "address", "nodeType": "ElementaryTypeName", - "src": "3093:7:8", + "src": "3145:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1766,11 +1823,11 @@ }, { "constant": false, - "id": 1078, + "id": 11358, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1107, - "src": "3112:14:8", + "scope": 11388, + "src": "3164:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1778,10 +1835,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1077, + "id": 11357, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3112:7:8", + "src": "3164:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1791,19 +1848,19 @@ "visibility": "internal" } ], - "src": "3076:51:8" + "src": "3128:51:58" }, "returnParameters": { - "id": 1082, + "id": 11362, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1081, + "id": 11361, "name": "", "nodeType": "VariableDeclaration", - "scope": 1107, - "src": "3144:4:8", + "scope": 11388, + "src": "3196:4:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1811,10 +1868,10 @@ "typeString": "bool" }, "typeName": { - "id": 1080, + "id": 11360, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "3144:4:8", + "src": "3196:4:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1824,19 +1881,19 @@ "visibility": "internal" } ], - "src": "3143:6:8" + "src": "3195:6:58" }, - "scope": 1374, - "src": "3055:252:8", + "scope": 11659, + "src": "3107:300:58", "stateMutability": "nonpayable", - "superFunction": 1426, + "superFunction": 11769, "visibility": "public" }, { "body": { - "id": 1133, + "id": 11414, "nodeType": "Block", - "src": "3788:117:8", + "src": "3888:121:58", "statements": [ { "expression": { @@ -1844,28 +1901,29 @@ "arguments": [ { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1117, - "name": "msg", + "argumentTypes": [], + "id": 11398, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3807:3:8", + "referencedDeclaration": 10941, + "src": "3907:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1118, + "id": 11399, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "3807:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "3907:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1873,12 +1931,12 @@ }, { "argumentTypes": null, - "id": 1119, + "id": 11400, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1109, - "src": "3819:7:8", + "referencedDeclaration": 11390, + "src": "3921:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1889,12 +1947,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1127, + "id": 11408, "name": "addedValue", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1111, - "src": "3865:10:8", + "referencedDeclaration": 11392, + "src": "3969:10:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1914,42 +1972,43 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1120, + "id": 11401, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "3828:11:8", + "referencedDeclaration": 11276, + "src": "3930:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1123, + "id": 11404, "indexExpression": { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1121, - "name": "msg", + "argumentTypes": [], + "id": 11402, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3840:3:8", + "referencedDeclaration": 10941, + "src": "3942:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1122, + "id": 11403, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "3840:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "3942:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1960,21 +2019,21 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "3828:23:8", + "src": "3930:25:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1125, + "id": 11406, "indexExpression": { "argumentTypes": null, - "id": 1124, + "id": 11405, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1109, - "src": "3852:7:8", + "referencedDeclaration": 11390, + "src": "3956:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1985,27 +2044,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "3828:32:8", + "src": "3930:34:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1126, + "id": 11407, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", - "referencedDeclaration": 871, - "src": "3828:36:8", + "referencedDeclaration": 10980, + "src": "3930:38:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", "typeString": "function (uint256,uint256) pure returns (uint256)" } }, - "id": 1128, + "id": 11409, "isConstant": false, "isLValue": false, "isPure": false, @@ -2013,7 +2072,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3828:48:8", + "src": "3930:50:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2035,18 +2094,18 @@ "typeString": "uint256" } ], - "id": 1116, + "id": 11397, "name": "_approve", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1345, - "src": "3798:8:8", + "referencedDeclaration": 11629, + "src": "3898:8:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1129, + "id": 11410, "isConstant": false, "isLValue": false, "isPure": false, @@ -2054,28 +2113,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3798:79:8", + "src": "3898:83:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1130, + "id": 11411, "nodeType": "ExpressionStatement", - "src": "3798:79:8" + "src": "3898:83:58" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", - "id": 1131, + "id": 11412, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", - "src": "3894:4:8", + "src": "3998:4:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", @@ -2083,31 +2142,31 @@ }, "value": "true" }, - "functionReturnParameters": 1115, - "id": 1132, + "functionReturnParameters": 11396, + "id": 11413, "nodeType": "Return", - "src": "3887:11:8" + "src": "3991:11:58" } ] }, - "documentation": "@dev Atomically increases the allowance granted to `spender` by the caller.\n * This is an alternative to `approve` that can be used as a mitigation for\nproblems described in `IERC20.approve`.\n * Emits an `Approval` event indicating the updated allowance.\n * Requirements:\n * - `spender` cannot be the zero address.", - "id": 1134, + "documentation": "@dev Atomically increases the allowance granted to `spender` by the caller.\n * This is an alternative to {approve} that can be used as a mitigation for\nproblems described in {IERC20-approve}.\n * Emits an {Approval} event indicating the updated allowance.\n * Requirements:\n * - `spender` cannot be the zero address.", + "id": 11415, "implemented": true, "kind": "function", "modifiers": [], "name": "increaseAllowance", "nodeType": "FunctionDefinition", "parameters": { - "id": 1112, + "id": 11393, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1109, + "id": 11390, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1134, - "src": "3729:15:8", + "scope": 11415, + "src": "3829:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2115,10 +2174,10 @@ "typeString": "address" }, "typeName": { - "id": 1108, + "id": 11389, "name": "address", "nodeType": "ElementaryTypeName", - "src": "3729:7:8", + "src": "3829:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2130,11 +2189,11 @@ }, { "constant": false, - "id": 1111, + "id": 11392, "name": "addedValue", "nodeType": "VariableDeclaration", - "scope": 1134, - "src": "3746:18:8", + "scope": 11415, + "src": "3846:18:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2142,10 +2201,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1110, + "id": 11391, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3746:7:8", + "src": "3846:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2155,19 +2214,19 @@ "visibility": "internal" } ], - "src": "3728:37:8" + "src": "3828:37:58" }, "returnParameters": { - "id": 1115, + "id": 11396, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1114, + "id": 11395, "name": "", "nodeType": "VariableDeclaration", - "scope": 1134, - "src": "3782:4:8", + "scope": 11415, + "src": "3882:4:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2175,10 +2234,10 @@ "typeString": "bool" }, "typeName": { - "id": 1113, + "id": 11394, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "3782:4:8", + "src": "3882:4:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -2188,19 +2247,19 @@ "visibility": "internal" } ], - "src": "3781:6:8" + "src": "3881:6:58" }, - "scope": 1374, - "src": "3702:203:8", + "scope": 11659, + "src": "3802:207:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 1160, + "id": 11442, "nodeType": "Block", - "src": "4483:122:8", + "src": "4587:167:58", "statements": [ { "expression": { @@ -2208,28 +2267,29 @@ "arguments": [ { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1144, - "name": "msg", + "argumentTypes": [], + "id": 11425, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "4502:3:8", + "referencedDeclaration": 10941, + "src": "4606:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1145, + "id": 11426, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "4502:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "4606:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -2237,12 +2297,12 @@ }, { "argumentTypes": null, - "id": 1146, + "id": 11427, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1136, - "src": "4514:7:8", + "referencedDeclaration": 11417, + "src": "4620:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2253,16 +2313,34 @@ "arguments": [ { "argumentTypes": null, - "id": 1154, + "id": 11435, "name": "subtractedValue", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1138, - "src": "4560:15:8", + "referencedDeclaration": 11419, + "src": "4668:15:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } + }, + { + "argumentTypes": null, + "hexValue": "45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726f", + "id": 11436, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4685:39:58", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_f8b476f7d28209d77d4a4ac1fe36b9f8259aa1bb6bddfa6e89de7e51615cf8a8", + "typeString": "literal_string \"ERC20: decreased allowance below zero\"" + }, + "value": "ERC20: decreased allowance below zero" } ], "expression": { @@ -2270,6 +2348,10 @@ { "typeIdentifier": "t_uint256", "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_f8b476f7d28209d77d4a4ac1fe36b9f8259aa1bb6bddfa6e89de7e51615cf8a8", + "typeString": "literal_string \"ERC20: decreased allowance below zero\"" } ], "expression": { @@ -2278,42 +2360,43 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1147, + "id": 11428, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "4523:11:8", + "referencedDeclaration": 11276, + "src": "4629:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1150, + "id": 11431, "indexExpression": { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1148, - "name": "msg", + "argumentTypes": [], + "id": 11429, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "4535:3:8", + "referencedDeclaration": 10941, + "src": "4641:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1149, + "id": 11430, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "4535:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "4641:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -2324,21 +2407,21 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "4523:23:8", + "src": "4629:25:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1152, + "id": 11433, "indexExpression": { "argumentTypes": null, - "id": 1151, + "id": 11432, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1136, - "src": "4547:7:8", + "referencedDeclaration": 11417, + "src": "4655:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2349,27 +2432,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "4523:32:8", + "src": "4629:34:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1153, + "id": 11434, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "4523:36:8", + "referencedDeclaration": 11023, + "src": "4629:38:58", "typeDescriptions": { - "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", - "typeString": "function (uint256,uint256) pure returns (uint256)" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 1155, + "id": 11437, "isConstant": false, "isLValue": false, "isPure": false, @@ -2377,7 +2460,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "4523:53:8", + "src": "4629:96:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2399,18 +2482,18 @@ "typeString": "uint256" } ], - "id": 1143, + "id": 11424, "name": "_approve", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1345, - "src": "4493:8:8", + "referencedDeclaration": 11629, + "src": "4597:8:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1156, + "id": 11438, "isConstant": false, "isLValue": false, "isPure": false, @@ -2418,28 +2501,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "4493:84:8", + "src": "4597:129:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1157, + "id": 11439, "nodeType": "ExpressionStatement", - "src": "4493:84:8" + "src": "4597:129:58" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", - "id": 1158, + "id": 11440, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", - "src": "4594:4:8", + "src": "4743:4:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", @@ -2447,31 +2530,31 @@ }, "value": "true" }, - "functionReturnParameters": 1142, - "id": 1159, + "functionReturnParameters": 11423, + "id": 11441, "nodeType": "Return", - "src": "4587:11:8" + "src": "4736:11:58" } ] }, - "documentation": "@dev Atomically decreases the allowance granted to `spender` by the caller.\n * This is an alternative to `approve` that can be used as a mitigation for\nproblems described in `IERC20.approve`.\n * Emits an `Approval` event indicating the updated allowance.\n * Requirements:\n * - `spender` cannot be the zero address.\n- `spender` must have allowance for the caller of at least\n`subtractedValue`.", - "id": 1161, + "documentation": "@dev Atomically decreases the allowance granted to `spender` by the caller.\n * This is an alternative to {approve} that can be used as a mitigation for\nproblems described in {IERC20-approve}.\n * Emits an {Approval} event indicating the updated allowance.\n * Requirements:\n * - `spender` cannot be the zero address.\n- `spender` must have allowance for the caller of at least\n`subtractedValue`.", + "id": 11443, "implemented": true, "kind": "function", "modifiers": [], "name": "decreaseAllowance", "nodeType": "FunctionDefinition", "parameters": { - "id": 1139, + "id": 11420, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1136, + "id": 11417, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1161, - "src": "4419:15:8", + "scope": 11443, + "src": "4523:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2479,10 +2562,10 @@ "typeString": "address" }, "typeName": { - "id": 1135, + "id": 11416, "name": "address", "nodeType": "ElementaryTypeName", - "src": "4419:7:8", + "src": "4523:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2494,11 +2577,11 @@ }, { "constant": false, - "id": 1138, + "id": 11419, "name": "subtractedValue", "nodeType": "VariableDeclaration", - "scope": 1161, - "src": "4436:23:8", + "scope": 11443, + "src": "4540:23:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2506,10 +2589,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1137, + "id": 11418, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "4436:7:8", + "src": "4540:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2519,19 +2602,19 @@ "visibility": "internal" } ], - "src": "4418:42:8" + "src": "4522:42:58" }, "returnParameters": { - "id": 1142, + "id": 11423, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1141, + "id": 11422, "name": "", "nodeType": "VariableDeclaration", - "scope": 1161, - "src": "4477:4:8", + "scope": 11443, + "src": "4581:4:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2539,10 +2622,10 @@ "typeString": "bool" }, "typeName": { - "id": 1140, + "id": 11421, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "4477:4:8", + "src": "4581:4:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -2552,19 +2635,19 @@ "visibility": "internal" } ], - "src": "4476:6:8" + "src": "4580:6:58" }, - "scope": 1374, - "src": "4392:213:8", + "scope": 11659, + "src": "4496:258:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 1216, + "id": 11499, "nodeType": "Block", - "src": "5158:343:8", + "src": "5307:385:58", "statements": [ { "expression": { @@ -2576,19 +2659,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1175, + "id": 11457, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1171, + "id": 11453, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1163, - "src": "5176:6:8", + "referencedDeclaration": 11445, + "src": "5325:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2602,14 +2685,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1173, + "id": 11455, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "5194:1:8", + "src": "5343:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -2625,20 +2708,20 @@ "typeString": "int_const 0" } ], - "id": 1172, + "id": 11454, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "5186:7:8", + "src": "5335:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1174, + "id": 11456, "isConstant": false, "isLValue": false, "isPure": true, @@ -2646,13 +2729,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5186:10:8", + "src": "5335:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "5176:20:8", + "src": "5325:20:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -2661,14 +2744,14 @@ { "argumentTypes": null, "hexValue": "45524332303a207472616e736665722066726f6d20746865207a65726f2061646472657373", - "id": 1176, + "id": 11458, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "5198:39:8", + "src": "5347:39:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_baecc556b46f4ed0f2b4cb599d60785ac8563dd2dc0a5bf12edea1c39e5e1fea", @@ -2688,21 +2771,21 @@ "typeString": "literal_string \"ERC20: transfer from the zero address\"" } ], - "id": 1170, + "id": 11452, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "5168:7:8", + "referencedDeclaration": 12132, + "src": "5317:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1177, + "id": 11459, "isConstant": false, "isLValue": false, "isPure": false, @@ -2710,15 +2793,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5168:70:8", + "src": "5317:70:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1178, + "id": 11460, "nodeType": "ExpressionStatement", - "src": "5168:70:8" + "src": "5317:70:58" }, { "expression": { @@ -2730,19 +2813,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1184, + "id": 11466, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1180, + "id": 11462, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1165, - "src": "5256:9:8", + "referencedDeclaration": 11447, + "src": "5405:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2756,14 +2839,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1182, + "id": 11464, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "5277:1:8", + "src": "5426:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -2779,20 +2862,20 @@ "typeString": "int_const 0" } ], - "id": 1181, + "id": 11463, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "5269:7:8", + "src": "5418:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1183, + "id": 11465, "isConstant": false, "isLValue": false, "isPure": true, @@ -2800,13 +2883,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5269:10:8", + "src": "5418:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "5256:23:8", + "src": "5405:23:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -2815,14 +2898,14 @@ { "argumentTypes": null, "hexValue": "45524332303a207472616e7366657220746f20746865207a65726f2061646472657373", - "id": 1185, + "id": 11467, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "5281:37:8", + "src": "5430:37:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_0557e210f7a69a685100a7e4e3d0a7024c546085cee28910fd17d0b081d9516f", @@ -2842,21 +2925,21 @@ "typeString": "literal_string \"ERC20: transfer to the zero address\"" } ], - "id": 1179, + "id": 11461, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "5248:7:8", + "referencedDeclaration": 12132, + "src": "5397:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1186, + "id": 11468, "isConstant": false, "isLValue": false, "isPure": false, @@ -2864,20 +2947,20 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5248:71:8", + "src": "5397:71:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1187, + "id": 11469, "nodeType": "ExpressionStatement", - "src": "5248:71:8" + "src": "5397:71:58" }, { "expression": { "argumentTypes": null, - "id": 1197, + "id": 11480, "isConstant": false, "isLValue": false, "isPure": false, @@ -2886,26 +2969,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1188, + "id": 11470, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5330:9:8", + "referencedDeclaration": 11270, + "src": "5479:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1190, + "id": 11472, "indexExpression": { "argumentTypes": null, - "id": 1189, + "id": 11471, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1163, - "src": "5340:6:8", + "referencedDeclaration": 11445, + "src": "5489:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2916,7 +2999,7 @@ "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", - "src": "5330:17:8", + "src": "5479:17:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2929,16 +3012,34 @@ "arguments": [ { "argumentTypes": null, - "id": 1195, + "id": 11477, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1167, - "src": "5372:6:8", + "referencedDeclaration": 11449, + "src": "5521:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } + }, + { + "argumentTypes": null, + "hexValue": "45524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e6365", + "id": 11478, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5529:40:58", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_4107e8a8b9e94bf8ff83080ddec1c0bffe897ebc2241b89d44f66b3d274088b6", + "typeString": "literal_string \"ERC20: transfer amount exceeds balance\"" + }, + "value": "ERC20: transfer amount exceeds balance" } ], "expression": { @@ -2946,32 +3047,36 @@ { "typeIdentifier": "t_uint256", "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_4107e8a8b9e94bf8ff83080ddec1c0bffe897ebc2241b89d44f66b3d274088b6", + "typeString": "literal_string \"ERC20: transfer amount exceeds balance\"" } ], "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1191, + "id": 11473, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5350:9:8", + "referencedDeclaration": 11270, + "src": "5499:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1193, + "id": 11475, "indexExpression": { "argumentTypes": null, - "id": 1192, + "id": 11474, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1163, - "src": "5360:6:8", + "referencedDeclaration": 11445, + "src": "5509:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2982,27 +3087,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "5350:17:8", + "src": "5499:17:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1194, + "id": 11476, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "5350:21:8", + "referencedDeclaration": 11023, + "src": "5499:21:58", "typeDescriptions": { - "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", - "typeString": "function (uint256,uint256) pure returns (uint256)" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 1196, + "id": 11479, "isConstant": false, "isLValue": false, "isPure": false, @@ -3010,26 +3115,26 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5350:29:8", + "src": "5499:71:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "5330:49:8", + "src": "5479:91:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1198, + "id": 11481, "nodeType": "ExpressionStatement", - "src": "5330:49:8" + "src": "5479:91:58" }, { "expression": { "argumentTypes": null, - "id": 1208, + "id": 11491, "isConstant": false, "isLValue": false, "isPure": false, @@ -3038,26 +3143,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1199, + "id": 11482, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5389:9:8", + "referencedDeclaration": 11270, + "src": "5580:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1201, + "id": 11484, "indexExpression": { "argumentTypes": null, - "id": 1200, + "id": 11483, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1165, - "src": "5399:9:8", + "referencedDeclaration": 11447, + "src": "5590:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3068,7 +3173,7 @@ "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", - "src": "5389:20:8", + "src": "5580:20:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3081,12 +3186,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1206, + "id": 11489, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1167, - "src": "5437:6:8", + "referencedDeclaration": 11449, + "src": "5628:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3104,26 +3209,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1202, + "id": 11485, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5412:9:8", + "referencedDeclaration": 11270, + "src": "5603:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1204, + "id": 11487, "indexExpression": { "argumentTypes": null, - "id": 1203, + "id": 11486, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1165, - "src": "5422:9:8", + "referencedDeclaration": 11447, + "src": "5613:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3134,27 +3239,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "5412:20:8", + "src": "5603:20:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1205, + "id": 11488, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", - "referencedDeclaration": 871, - "src": "5412:24:8", + "referencedDeclaration": 10980, + "src": "5603:24:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", "typeString": "function (uint256,uint256) pure returns (uint256)" } }, - "id": 1207, + "id": 11490, "isConstant": false, "isLValue": false, "isPure": false, @@ -3162,21 +3267,21 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5412:32:8", + "src": "5603:32:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "5389:55:8", + "src": "5580:55:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1209, + "id": 11492, "nodeType": "ExpressionStatement", - "src": "5389:55:8" + "src": "5580:55:58" }, { "eventCall": { @@ -3184,12 +3289,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1211, + "id": 11494, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1163, - "src": "5468:6:8", + "referencedDeclaration": 11445, + "src": "5659:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3197,12 +3302,12 @@ }, { "argumentTypes": null, - "id": 1212, + "id": 11495, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1165, - "src": "5476:9:8", + "referencedDeclaration": 11447, + "src": "5667:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3210,12 +3315,12 @@ }, { "argumentTypes": null, - "id": 1213, + "id": 11496, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1167, - "src": "5487:6:8", + "referencedDeclaration": 11449, + "src": "5678:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3237,18 +3342,18 @@ "typeString": "uint256" } ], - "id": 1210, + "id": 11493, "name": "Transfer", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1434, - "src": "5459:8:8", + "referencedDeclaration": 11777, + "src": "5650:8:58", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1214, + "id": 11497, "isConstant": false, "isLValue": false, "isPure": false, @@ -3256,36 +3361,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5459:35:8", + "src": "5650:35:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1215, + "id": 11498, "nodeType": "EmitStatement", - "src": "5454:40:8" + "src": "5645:40:58" } ] }, - "documentation": "@dev Moves tokens `amount` from `sender` to `recipient`.\n * This is internal function is equivalent to `transfer`, and can be used to\ne.g. implement automatic token fees, slashing mechanisms, etc.\n * Emits a `Transfer` event.\n * Requirements:\n * - `sender` cannot be the zero address.\n- `recipient` cannot be the zero address.\n- `sender` must have a balance of at least `amount`.", - "id": 1217, + "documentation": "@dev Moves tokens `amount` from `sender` to `recipient`.\n * This is internal function is equivalent to {transfer}, and can be used to\ne.g. implement automatic token fees, slashing mechanisms, etc.\n * Emits a {Transfer} event.\n * Requirements:\n * - `sender` cannot be the zero address.\n- `recipient` cannot be the zero address.\n- `sender` must have a balance of at least `amount`.", + "id": 11500, "implemented": true, "kind": "function", "modifiers": [], "name": "_transfer", "nodeType": "FunctionDefinition", "parameters": { - "id": 1168, + "id": 11450, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1163, + "id": 11445, "name": "sender", "nodeType": "VariableDeclaration", - "scope": 1217, - "src": "5098:14:8", + "scope": 11500, + "src": "5247:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3293,10 +3398,10 @@ "typeString": "address" }, "typeName": { - "id": 1162, + "id": 11444, "name": "address", "nodeType": "ElementaryTypeName", - "src": "5098:7:8", + "src": "5247:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3308,11 +3413,11 @@ }, { "constant": false, - "id": 1165, + "id": 11447, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 1217, - "src": "5114:17:8", + "scope": 11500, + "src": "5263:17:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3320,10 +3425,10 @@ "typeString": "address" }, "typeName": { - "id": 1164, + "id": 11446, "name": "address", "nodeType": "ElementaryTypeName", - "src": "5114:7:8", + "src": "5263:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3335,11 +3440,11 @@ }, { "constant": false, - "id": 1167, + "id": 11449, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1217, - "src": "5133:14:8", + "scope": 11500, + "src": "5282:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3347,10 +3452,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1166, + "id": 11448, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "5133:7:8", + "src": "5282:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3360,25 +3465,25 @@ "visibility": "internal" } ], - "src": "5097:51:8" + "src": "5246:51:58" }, "returnParameters": { - "id": 1169, + "id": 11451, "nodeType": "ParameterList", "parameters": [], - "src": "5158:0:8" + "src": "5307:0:58" }, - "scope": 1374, - "src": "5079:422:8", + "scope": 11659, + "src": "5228:464:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 1259, + "id": 11542, "nodeType": "Block", - "src": "5828:245:8", + "src": "6019:245:58", "statements": [ { "expression": { @@ -3390,19 +3495,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1229, + "id": 11512, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1225, + "id": 11508, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1219, - "src": "5846:7:8", + "referencedDeclaration": 11502, + "src": "6037:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3416,14 +3521,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1227, + "id": 11510, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "5865:1:8", + "src": "6056:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -3439,20 +3544,20 @@ "typeString": "int_const 0" } ], - "id": 1226, + "id": 11509, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "5857:7:8", + "src": "6048:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1228, + "id": 11511, "isConstant": false, "isLValue": false, "isPure": true, @@ -3460,13 +3565,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5857:10:8", + "src": "6048:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "5846:21:8", + "src": "6037:21:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -3475,14 +3580,14 @@ { "argumentTypes": null, "hexValue": "45524332303a206d696e7420746f20746865207a65726f2061646472657373", - "id": 1230, + "id": 11513, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "5869:33:8", + "src": "6060:33:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_fc0b381caf0a47702017f3c4b358ebe3d3aff6c60ce819a8bf3ef5a95d4f202e", @@ -3502,21 +3607,21 @@ "typeString": "literal_string \"ERC20: mint to the zero address\"" } ], - "id": 1224, + "id": 11507, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "5838:7:8", + "referencedDeclaration": 12132, + "src": "6029:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1231, + "id": 11514, "isConstant": false, "isLValue": false, "isPure": false, @@ -3524,32 +3629,32 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5838:65:8", + "src": "6029:65:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1232, + "id": 11515, "nodeType": "ExpressionStatement", - "src": "5838:65:8" + "src": "6029:65:58" }, { "expression": { "argumentTypes": null, - "id": 1238, + "id": 11521, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 1233, + "id": 11516, "name": "_totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 998, - "src": "5914:12:8", + "referencedDeclaration": 11278, + "src": "6105:12:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3562,12 +3667,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1236, + "id": 11519, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1221, - "src": "5946:6:8", + "referencedDeclaration": 11504, + "src": "6137:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3583,32 +3688,32 @@ ], "expression": { "argumentTypes": null, - "id": 1234, + "id": 11517, "name": "_totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 998, - "src": "5929:12:8", + "referencedDeclaration": 11278, + "src": "6120:12:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1235, + "id": 11518, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", - "referencedDeclaration": 871, - "src": "5929:16:8", + "referencedDeclaration": 10980, + "src": "6120:16:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", "typeString": "function (uint256,uint256) pure returns (uint256)" } }, - "id": 1237, + "id": 11520, "isConstant": false, "isLValue": false, "isPure": false, @@ -3616,26 +3721,26 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5929:24:8", + "src": "6120:24:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "5914:39:8", + "src": "6105:39:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1239, + "id": 11522, "nodeType": "ExpressionStatement", - "src": "5914:39:8" + "src": "6105:39:58" }, { "expression": { "argumentTypes": null, - "id": 1249, + "id": 11532, "isConstant": false, "isLValue": false, "isPure": false, @@ -3644,26 +3749,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1240, + "id": 11523, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5963:9:8", + "referencedDeclaration": 11270, + "src": "6154:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1242, + "id": 11525, "indexExpression": { "argumentTypes": null, - "id": 1241, + "id": 11524, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1219, - "src": "5973:7:8", + "referencedDeclaration": 11502, + "src": "6164:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3674,7 +3779,7 @@ "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", - "src": "5963:18:8", + "src": "6154:18:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3687,12 +3792,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1247, + "id": 11530, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1221, - "src": "6007:6:8", + "referencedDeclaration": 11504, + "src": "6198:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3710,26 +3815,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1243, + "id": 11526, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5984:9:8", + "referencedDeclaration": 11270, + "src": "6175:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1245, + "id": 11528, "indexExpression": { "argumentTypes": null, - "id": 1244, + "id": 11527, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1219, - "src": "5994:7:8", + "referencedDeclaration": 11502, + "src": "6185:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3740,27 +3845,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "5984:18:8", + "src": "6175:18:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1246, + "id": 11529, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", - "referencedDeclaration": 871, - "src": "5984:22:8", + "referencedDeclaration": 10980, + "src": "6175:22:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", "typeString": "function (uint256,uint256) pure returns (uint256)" } }, - "id": 1248, + "id": 11531, "isConstant": false, "isLValue": false, "isPure": false, @@ -3768,21 +3873,21 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5984:30:8", + "src": "6175:30:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "5963:51:8", + "src": "6154:51:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1250, + "id": 11533, "nodeType": "ExpressionStatement", - "src": "5963:51:8" + "src": "6154:51:58" }, { "eventCall": { @@ -3794,14 +3899,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1253, + "id": 11536, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "6046:1:8", + "src": "6237:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -3817,20 +3922,20 @@ "typeString": "int_const 0" } ], - "id": 1252, + "id": 11535, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "6038:7:8", + "src": "6229:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1254, + "id": 11537, "isConstant": false, "isLValue": false, "isPure": true, @@ -3838,7 +3943,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6038:10:8", + "src": "6229:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -3846,12 +3951,12 @@ }, { "argumentTypes": null, - "id": 1255, + "id": 11538, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1219, - "src": "6050:7:8", + "referencedDeclaration": 11502, + "src": "6241:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3859,12 +3964,12 @@ }, { "argumentTypes": null, - "id": 1256, + "id": 11539, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1221, - "src": "6059:6:8", + "referencedDeclaration": 11504, + "src": "6250:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3886,18 +3991,18 @@ "typeString": "uint256" } ], - "id": 1251, + "id": 11534, "name": "Transfer", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1434, - "src": "6029:8:8", + "referencedDeclaration": 11777, + "src": "6220:8:58", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1257, + "id": 11540, "isConstant": false, "isLValue": false, "isPure": false, @@ -3905,36 +4010,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6029:37:8", + "src": "6220:37:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1258, + "id": 11541, "nodeType": "EmitStatement", - "src": "6024:42:8" + "src": "6215:42:58" } ] }, - "documentation": "@dev Creates `amount` tokens and assigns them to `account`, increasing\nthe total supply.\n * Emits a `Transfer` event with `from` set to the zero address.\n * Requirements\n * - `to` cannot be the zero address.", - "id": 1260, + "documentation": "@dev Creates `amount` tokens and assigns them to `account`, increasing\nthe total supply.\n * Emits a {Transfer} event with `from` set to the zero address.\n * Requirements\n * - `to` cannot be the zero address.", + "id": 11543, "implemented": true, "kind": "function", "modifiers": [], "name": "_mint", "nodeType": "FunctionDefinition", "parameters": { - "id": 1222, + "id": 11505, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1219, + "id": 11502, "name": "account", "nodeType": "VariableDeclaration", - "scope": 1260, - "src": "5786:15:8", + "scope": 11543, + "src": "5977:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3942,10 +4047,10 @@ "typeString": "address" }, "typeName": { - "id": 1218, + "id": 11501, "name": "address", "nodeType": "ElementaryTypeName", - "src": "5786:7:8", + "src": "5977:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3957,11 +4062,11 @@ }, { "constant": false, - "id": 1221, + "id": 11504, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1260, - "src": "5803:14:8", + "scope": 11543, + "src": "5994:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3969,10 +4074,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1220, + "id": 11503, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "5803:7:8", + "src": "5994:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3982,25 +4087,25 @@ "visibility": "internal" } ], - "src": "5785:33:8" + "src": "5976:33:58" }, "returnParameters": { - "id": 1223, + "id": 11506, "nodeType": "ParameterList", "parameters": [], - "src": "5828:0:8" + "src": "6019:0:58" }, - "scope": 1374, - "src": "5771:302:8", + "scope": 11659, + "src": "5962:302:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 1302, + "id": 11586, "nodeType": "Block", - "src": "6448:244:8", + "src": "6641:285:58", "statements": [ { "expression": { @@ -4012,19 +4117,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1272, + "id": 11555, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1268, + "id": 11551, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1262, - "src": "6466:7:8", + "referencedDeclaration": 11545, + "src": "6659:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4038,14 +4143,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1270, + "id": 11553, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "6485:1:8", + "src": "6678:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -4061,20 +4166,20 @@ "typeString": "int_const 0" } ], - "id": 1269, + "id": 11552, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "6477:7:8", + "src": "6670:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1271, + "id": 11554, "isConstant": false, "isLValue": false, "isPure": true, @@ -4082,13 +4187,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6477:10:8", + "src": "6670:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "6466:21:8", + "src": "6659:21:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -4097,14 +4202,14 @@ { "argumentTypes": null, "hexValue": "45524332303a206275726e2066726f6d20746865207a65726f2061646472657373", - "id": 1273, + "id": 11556, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "6489:35:8", + "src": "6682:35:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_b16788493b576042bb52c50ed56189e0b250db113c7bfb1c3897d25cf9632d7f", @@ -4124,21 +4229,21 @@ "typeString": "literal_string \"ERC20: burn from the zero address\"" } ], - "id": 1267, + "id": 11550, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "6458:7:8", + "referencedDeclaration": 12132, + "src": "6651:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1274, + "id": 11557, "isConstant": false, "isLValue": false, "isPure": false, @@ -4146,32 +4251,59 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6458:67:8", + "src": "6651:67:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1275, + "id": 11558, "nodeType": "ExpressionStatement", - "src": "6458:67:8" + "src": "6651:67:58" }, { "expression": { "argumentTypes": null, - "id": 1281, + "id": 11569, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 1276, - "name": "_totalSupply", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 998, - "src": "6536:12:8", + "baseExpression": { + "argumentTypes": null, + "id": 11559, + "name": "_balances", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11270, + "src": "6729:9:58", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 11561, + "indexExpression": { + "argumentTypes": null, + "id": 11560, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11545, + "src": "6739:7:58", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "6729:18:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4184,16 +4316,34 @@ "arguments": [ { "argumentTypes": null, - "id": 1279, - "name": "value", + "id": 11566, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1264, - "src": "6568:5:8", + "referencedDeclaration": 11547, + "src": "6773:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } + }, + { + "argumentTypes": null, + "hexValue": "45524332303a206275726e20616d6f756e7420657863656564732062616c616e6365", + "id": 11567, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6781:36:58", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_149b126e7125232b4200af45303d04fba8b74653b1a295a6a561a528c33fefdd", + "typeString": "literal_string \"ERC20: burn amount exceeds balance\"" + }, + "value": "ERC20: burn amount exceeds balance" } ], "expression": { @@ -4201,36 +4351,67 @@ { "typeIdentifier": "t_uint256", "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_149b126e7125232b4200af45303d04fba8b74653b1a295a6a561a528c33fefdd", + "typeString": "literal_string \"ERC20: burn amount exceeds balance\"" } ], "expression": { "argumentTypes": null, - "id": 1277, - "name": "_totalSupply", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 998, - "src": "6551:12:8", + "baseExpression": { + "argumentTypes": null, + "id": 11562, + "name": "_balances", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11270, + "src": "6750:9:58", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 11564, + "indexExpression": { + "argumentTypes": null, + "id": 11563, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11545, + "src": "6760:7:58", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "6750:18:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1278, + "id": 11565, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "6551:16:8", + "referencedDeclaration": 11023, + "src": "6750:22:58", "typeDescriptions": { - "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", - "typeString": "function (uint256,uint256) pure returns (uint256)" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 1280, + "id": 11568, "isConstant": false, "isLValue": false, "isPure": false, @@ -4238,65 +4419,38 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6551:23:8", + "src": "6750:68:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "6536:38:8", + "src": "6729:89:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1282, + "id": 11570, "nodeType": "ExpressionStatement", - "src": "6536:38:8" + "src": "6729:89:58" }, { "expression": { "argumentTypes": null, - "id": 1292, + "id": 11576, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "baseExpression": { - "argumentTypes": null, - "id": 1283, - "name": "_balances", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "6584:9:8", - "typeDescriptions": { - "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", - "typeString": "mapping(address => uint256)" - } - }, - "id": 1285, - "indexExpression": { - "argumentTypes": null, - "id": 1284, - "name": "account", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 1262, - "src": "6594:7:8", - "typeDescriptions": { - "typeIdentifier": "t_address", - "typeString": "address" - } - }, - "isConstant": false, - "isLValue": true, - "isPure": false, - "lValueRequested": true, - "nodeType": "IndexAccess", - "src": "6584:18:8", + "id": 11571, + "name": "_totalSupply", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11278, + "src": "6828:12:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4309,12 +4463,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1290, - "name": "value", + "id": 11574, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1264, - "src": "6628:5:8", + "referencedDeclaration": 11547, + "src": "6860:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4330,59 +4484,32 @@ ], "expression": { "argumentTypes": null, - "baseExpression": { - "argumentTypes": null, - "id": 1286, - "name": "_balances", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "6605:9:8", - "typeDescriptions": { - "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", - "typeString": "mapping(address => uint256)" - } - }, - "id": 1288, - "indexExpression": { - "argumentTypes": null, - "id": 1287, - "name": "account", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 1262, - "src": "6615:7:8", - "typeDescriptions": { - "typeIdentifier": "t_address", - "typeString": "address" - } - }, - "isConstant": false, - "isLValue": true, - "isPure": false, - "lValueRequested": false, - "nodeType": "IndexAccess", - "src": "6605:18:8", + "id": 11572, + "name": "_totalSupply", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11278, + "src": "6843:12:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1289, + "id": 11573, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "6605:22:8", + "referencedDeclaration": 10996, + "src": "6843:16:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", "typeString": "function (uint256,uint256) pure returns (uint256)" } }, - "id": 1291, + "id": 11575, "isConstant": false, "isLValue": false, "isPure": false, @@ -4390,21 +4517,21 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6605:29:8", + "src": "6843:24:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "6584:50:8", + "src": "6828:39:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1293, + "id": 11577, "nodeType": "ExpressionStatement", - "src": "6584:50:8" + "src": "6828:39:58" }, { "eventCall": { @@ -4412,12 +4539,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1295, + "id": 11579, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1262, - "src": "6658:7:8", + "referencedDeclaration": 11545, + "src": "6891:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4429,14 +4556,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1297, + "id": 11581, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "6675:1:8", + "src": "6908:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -4452,20 +4579,20 @@ "typeString": "int_const 0" } ], - "id": 1296, + "id": 11580, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "6667:7:8", + "src": "6900:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1298, + "id": 11582, "isConstant": false, "isLValue": false, "isPure": true, @@ -4473,7 +4600,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6667:10:8", + "src": "6900:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -4481,12 +4608,12 @@ }, { "argumentTypes": null, - "id": 1299, - "name": "value", + "id": 11583, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1264, - "src": "6679:5:8", + "referencedDeclaration": 11547, + "src": "6912:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4508,18 +4635,18 @@ "typeString": "uint256" } ], - "id": 1294, + "id": 11578, "name": "Transfer", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1434, - "src": "6649:8:8", + "referencedDeclaration": 11777, + "src": "6882:8:58", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1300, + "id": 11584, "isConstant": false, "isLValue": false, "isPure": false, @@ -4527,36 +4654,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6649:36:8", + "src": "6882:37:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1301, + "id": 11585, "nodeType": "EmitStatement", - "src": "6644:41:8" + "src": "6877:42:58" } ] }, - "documentation": "@dev Destoys `amount` tokens from `account`, reducing the\ntotal supply.\n * Emits a `Transfer` event with `to` set to the zero address.\n * Requirements\n * - `account` cannot be the zero address.\n- `account` must have at least `amount` tokens.", - "id": 1303, + "documentation": "@dev Destroys `amount` tokens from `account`, reducing the\ntotal supply.\n * Emits a {Transfer} event with `to` set to the zero address.\n * Requirements\n * - `account` cannot be the zero address.\n- `account` must have at least `amount` tokens.", + "id": 11587, "implemented": true, "kind": "function", "modifiers": [], "name": "_burn", "nodeType": "FunctionDefinition", "parameters": { - "id": 1265, + "id": 11548, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1262, + "id": 11545, "name": "account", "nodeType": "VariableDeclaration", - "scope": 1303, - "src": "6407:15:8", + "scope": 11587, + "src": "6599:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4564,10 +4691,10 @@ "typeString": "address" }, "typeName": { - "id": 1261, + "id": 11544, "name": "address", "nodeType": "ElementaryTypeName", - "src": "6407:7:8", + "src": "6599:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -4579,11 +4706,11 @@ }, { "constant": false, - "id": 1264, - "name": "value", + "id": 11547, + "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1303, - "src": "6424:13:8", + "scope": 11587, + "src": "6616:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4591,10 +4718,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1263, + "id": 11546, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "6424:7:8", + "src": "6616:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4604,25 +4731,25 @@ "visibility": "internal" } ], - "src": "6406:32:8" + "src": "6598:33:58" }, "returnParameters": { - "id": 1266, + "id": 11549, "nodeType": "ParameterList", "parameters": [], - "src": "6448:0:8" + "src": "6641:0:58" }, - "scope": 1374, - "src": "6392:300:8", + "scope": 11659, + "src": "6584:342:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 1344, + "id": 11628, "nodeType": "Block", - "src": "7191:255:8", + "src": "7426:257:58", "statements": [ { "expression": { @@ -4634,19 +4761,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1317, + "id": 11601, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1313, + "id": 11597, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1305, - "src": "7209:5:8", + "referencedDeclaration": 11589, + "src": "7444:5:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4660,14 +4787,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1315, + "id": 11599, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "7226:1:8", + "src": "7461:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -4683,20 +4810,20 @@ "typeString": "int_const 0" } ], - "id": 1314, + "id": 11598, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "7218:7:8", + "src": "7453:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1316, + "id": 11600, "isConstant": false, "isLValue": false, "isPure": true, @@ -4704,13 +4831,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7218:10:8", + "src": "7453:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "7209:19:8", + "src": "7444:19:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -4719,14 +4846,14 @@ { "argumentTypes": null, "hexValue": "45524332303a20617070726f76652066726f6d20746865207a65726f2061646472657373", - "id": 1318, + "id": 11602, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "7230:38:8", + "src": "7465:38:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_c953f4879035ed60e766b34720f656aab5c697b141d924c283124ecedb91c208", @@ -4746,21 +4873,21 @@ "typeString": "literal_string \"ERC20: approve from the zero address\"" } ], - "id": 1312, + "id": 11596, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "7201:7:8", + "referencedDeclaration": 12132, + "src": "7436:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1319, + "id": 11603, "isConstant": false, "isLValue": false, "isPure": false, @@ -4768,15 +4895,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7201:68:8", + "src": "7436:68:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1320, + "id": 11604, "nodeType": "ExpressionStatement", - "src": "7201:68:8" + "src": "7436:68:58" }, { "expression": { @@ -4788,19 +4915,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1326, + "id": 11610, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1322, + "id": 11606, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1307, - "src": "7287:7:8", + "referencedDeclaration": 11591, + "src": "7522:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4814,14 +4941,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1324, + "id": 11608, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "7306:1:8", + "src": "7541:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -4837,20 +4964,20 @@ "typeString": "int_const 0" } ], - "id": 1323, + "id": 11607, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "7298:7:8", + "src": "7533:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1325, + "id": 11609, "isConstant": false, "isLValue": false, "isPure": true, @@ -4858,13 +4985,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7298:10:8", + "src": "7533:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "7287:21:8", + "src": "7522:21:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -4873,14 +5000,14 @@ { "argumentTypes": null, "hexValue": "45524332303a20617070726f766520746f20746865207a65726f2061646472657373", - "id": 1327, + "id": 11611, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "7310:36:8", + "src": "7545:36:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_24883cc5fe64ace9d0df1893501ecb93c77180f0ff69cca79affb3c316dc8029", @@ -4900,21 +5027,21 @@ "typeString": "literal_string \"ERC20: approve to the zero address\"" } ], - "id": 1321, + "id": 11605, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "7279:7:8", + "referencedDeclaration": 12132, + "src": "7514:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1328, + "id": 11612, "isConstant": false, "isLValue": false, "isPure": false, @@ -4922,20 +5049,20 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7279:68:8", + "src": "7514:68:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1329, + "id": 11613, "nodeType": "ExpressionStatement", - "src": "7279:68:8" + "src": "7514:68:58" }, { "expression": { "argumentTypes": null, - "id": 1336, + "id": 11620, "isConstant": false, "isLValue": false, "isPure": false, @@ -4946,26 +5073,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1330, + "id": 11614, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "7358:11:8", + "referencedDeclaration": 11276, + "src": "7593:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1333, + "id": 11617, "indexExpression": { "argumentTypes": null, - "id": 1331, + "id": 11615, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1305, - "src": "7370:5:8", + "referencedDeclaration": 11589, + "src": "7605:5:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4976,21 +5103,21 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "7358:18:8", + "src": "7593:18:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1334, + "id": 11618, "indexExpression": { "argumentTypes": null, - "id": 1332, + "id": 11616, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1307, - "src": "7377:7:8", + "referencedDeclaration": 11591, + "src": "7612:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5001,7 +5128,7 @@ "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", - "src": "7358:27:8", + "src": "7593:27:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5011,26 +5138,26 @@ "operator": "=", "rightHandSide": { "argumentTypes": null, - "id": 1335, - "name": "value", + "id": 11619, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1309, - "src": "7388:5:8", + "referencedDeclaration": 11593, + "src": "7623:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "7358:35:8", + "src": "7593:36:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1337, + "id": 11621, "nodeType": "ExpressionStatement", - "src": "7358:35:8" + "src": "7593:36:58" }, { "eventCall": { @@ -5038,12 +5165,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1339, + "id": 11623, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1305, - "src": "7417:5:8", + "referencedDeclaration": 11589, + "src": "7653:5:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5051,12 +5178,12 @@ }, { "argumentTypes": null, - "id": 1340, + "id": 11624, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1307, - "src": "7424:7:8", + "referencedDeclaration": 11591, + "src": "7660:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5064,12 +5191,12 @@ }, { "argumentTypes": null, - "id": 1341, - "name": "value", + "id": 11625, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1309, - "src": "7433:5:8", + "referencedDeclaration": 11593, + "src": "7669:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5091,18 +5218,18 @@ "typeString": "uint256" } ], - "id": 1338, + "id": 11622, "name": "Approval", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1442, - "src": "7408:8:8", + "referencedDeclaration": 11785, + "src": "7644:8:58", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1342, + "id": 11626, "isConstant": false, "isLValue": false, "isPure": false, @@ -5110,36 +5237,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7408:31:8", + "src": "7644:32:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1343, + "id": 11627, "nodeType": "EmitStatement", - "src": "7403:36:8" + "src": "7639:37:58" } ] }, - "documentation": "@dev Sets `amount` as the allowance of `spender` over the `owner`s tokens.\n * This is internal function is equivalent to `approve`, and can be used to\ne.g. set automatic allowances for certain subsystems, etc.\n * Emits an `Approval` event.\n * Requirements:\n * - `owner` cannot be the zero address.\n- `spender` cannot be the zero address.", - "id": 1345, + "documentation": "@dev Sets `amount` as the allowance of `spender` over the `owner`s tokens.\n * This is internal function is equivalent to `approve`, and can be used to\ne.g. set automatic allowances for certain subsystems, etc.\n * Emits an {Approval} event.\n * Requirements:\n * - `owner` cannot be the zero address.\n- `spender` cannot be the zero address.", + "id": 11629, "implemented": true, "kind": "function", "modifiers": [], "name": "_approve", "nodeType": "FunctionDefinition", "parameters": { - "id": 1310, + "id": 11594, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1305, + "id": 11589, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 1345, - "src": "7135:13:8", + "scope": 11629, + "src": "7369:13:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5147,10 +5274,10 @@ "typeString": "address" }, "typeName": { - "id": 1304, + "id": 11588, "name": "address", "nodeType": "ElementaryTypeName", - "src": "7135:7:8", + "src": "7369:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -5162,11 +5289,11 @@ }, { "constant": false, - "id": 1307, + "id": 11591, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1345, - "src": "7150:15:8", + "scope": 11629, + "src": "7384:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5174,10 +5301,10 @@ "typeString": "address" }, "typeName": { - "id": 1306, + "id": 11590, "name": "address", "nodeType": "ElementaryTypeName", - "src": "7150:7:8", + "src": "7384:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -5189,11 +5316,11 @@ }, { "constant": false, - "id": 1309, - "name": "value", + "id": 11593, + "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1345, - "src": "7167:13:8", + "scope": 11629, + "src": "7401:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5201,10 +5328,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1308, + "id": 11592, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "7167:7:8", + "src": "7401:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5214,25 +5341,25 @@ "visibility": "internal" } ], - "src": "7134:47:8" + "src": "7368:48:58" }, "returnParameters": { - "id": 1311, + "id": 11595, "nodeType": "ParameterList", "parameters": [], - "src": "7191:0:8" + "src": "7426:0:58" }, - "scope": 1374, - "src": "7117:329:8", + "scope": 11659, + "src": "7351:332:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 1372, + "id": 11657, "nodeType": "Block", - "src": "7684:124:8", + "src": "7922:168:58", "statements": [ { "expression": { @@ -5240,12 +5367,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1353, + "id": 11637, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1347, - "src": "7700:7:8", + "referencedDeclaration": 11631, + "src": "7938:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5253,12 +5380,12 @@ }, { "argumentTypes": null, - "id": 1354, + "id": 11638, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1349, - "src": "7709:6:8", + "referencedDeclaration": 11633, + "src": "7947:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5276,18 +5403,18 @@ "typeString": "uint256" } ], - "id": 1352, + "id": 11636, "name": "_burn", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1303, - "src": "7694:5:8", + "referencedDeclaration": 11587, + "src": "7932:5:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,uint256)" } }, - "id": 1355, + "id": 11639, "isConstant": false, "isLValue": false, "isPure": false, @@ -5295,15 +5422,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7694:22:8", + "src": "7932:22:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1356, + "id": 11640, "nodeType": "ExpressionStatement", - "src": "7694:22:8" + "src": "7932:22:58" }, { "expression": { @@ -5311,12 +5438,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1358, + "id": 11642, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1347, - "src": "7735:7:8", + "referencedDeclaration": 11631, + "src": "7973:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5324,28 +5451,29 @@ }, { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1359, - "name": "msg", + "argumentTypes": [], + "id": 11643, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "7744:3:8", + "referencedDeclaration": 10941, + "src": "7982:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1360, + "id": 11644, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "7744:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "7982:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -5356,16 +5484,34 @@ "arguments": [ { "argumentTypes": null, - "id": 1368, + "id": 11652, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1349, - "src": "7793:6:8", + "referencedDeclaration": 11633, + "src": "8035:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } + }, + { + "argumentTypes": null, + "hexValue": "45524332303a206275726e20616d6f756e74206578636565647320616c6c6f77616e6365", + "id": 11653, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8043:38:58", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a287c363786607a1457a2d9d12fa61c0073358e02d76b4035fc2c2d86a19c0db", + "typeString": "literal_string \"ERC20: burn amount exceeds allowance\"" + }, + "value": "ERC20: burn amount exceeds allowance" } ], "expression": { @@ -5373,6 +5519,10 @@ { "typeIdentifier": "t_uint256", "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_a287c363786607a1457a2d9d12fa61c0073358e02d76b4035fc2c2d86a19c0db", + "typeString": "literal_string \"ERC20: burn amount exceeds allowance\"" } ], "expression": { @@ -5381,26 +5531,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1361, + "id": 11645, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "7756:11:8", + "referencedDeclaration": 11276, + "src": "7996:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1363, + "id": 11647, "indexExpression": { "argumentTypes": null, - "id": 1362, + "id": 11646, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1347, - "src": "7768:7:8", + "referencedDeclaration": 11631, + "src": "8008:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5411,37 +5561,38 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "7756:20:8", + "src": "7996:20:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1366, + "id": 11650, "indexExpression": { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1364, - "name": "msg", + "argumentTypes": [], + "id": 11648, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "7777:3:8", + "referencedDeclaration": 10941, + "src": "8017:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1365, + "id": 11649, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "7777:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "8017:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -5452,27 +5603,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "7756:32:8", + "src": "7996:34:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1367, + "id": 11651, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "7756:36:8", + "referencedDeclaration": 11023, + "src": "7996:38:58", "typeDescriptions": { - "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", - "typeString": "function (uint256,uint256) pure returns (uint256)" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 1369, + "id": 11654, "isConstant": false, "isLValue": false, "isPure": false, @@ -5480,7 +5631,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7756:44:8", + "src": "7996:86:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5502,18 +5653,18 @@ "typeString": "uint256" } ], - "id": 1357, + "id": 11641, "name": "_approve", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1345, - "src": "7726:8:8", + "referencedDeclaration": 11629, + "src": "7964:8:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1370, + "id": 11655, "isConstant": false, "isLValue": false, "isPure": false, @@ -5521,36 +5672,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7726:75:8", + "src": "7964:119:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1371, + "id": 11656, "nodeType": "ExpressionStatement", - "src": "7726:75:8" + "src": "7964:119:58" } ] }, - "documentation": "@dev Destoys `amount` tokens from `account`.`amount` is then deducted\nfrom the caller's allowance.\n * See `_burn` and `_approve`.", - "id": 1373, + "documentation": "@dev Destroys `amount` tokens from `account`.`amount` is then deducted\nfrom the caller's allowance.\n * See {_burn} and {_approve}.", + "id": 11658, "implemented": true, "kind": "function", "modifiers": [], "name": "_burnFrom", "nodeType": "FunctionDefinition", "parameters": { - "id": 1350, + "id": 11634, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1347, + "id": 11631, "name": "account", "nodeType": "VariableDeclaration", - "scope": 1373, - "src": "7642:15:8", + "scope": 11658, + "src": "7880:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5558,10 +5709,10 @@ "typeString": "address" }, "typeName": { - "id": 1346, + "id": 11630, "name": "address", "nodeType": "ElementaryTypeName", - "src": "7642:7:8", + "src": "7880:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -5573,11 +5724,11 @@ }, { "constant": false, - "id": 1349, + "id": 11633, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1373, - "src": "7659:14:8", + "scope": 11658, + "src": "7897:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5585,10 +5736,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1348, + "id": 11632, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "7659:7:8", + "src": "7897:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5598,39 +5749,39 @@ "visibility": "internal" } ], - "src": "7641:33:8" + "src": "7879:33:58" }, "returnParameters": { - "id": 1351, + "id": 11635, "nodeType": "ParameterList", "parameters": [], - "src": "7684:0:8" + "src": "7922:0:58" }, - "scope": 1374, - "src": "7623:185:8", + "scope": 11659, + "src": "7861:229:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" } ], - "scope": 1375, - "src": "1232:6578:8" + "scope": 11660, + "src": "1268:6824:58" } ], - "src": "0:7811:8" + "src": "0:8093:58" }, "legacyAST": { - "absolutePath": "@openzeppelin/contracts/token/ERC20/ERC20.sol", + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", "exportedSymbols": { "ERC20": [ - 1374 + 11659 ] }, - "id": 1375, + "id": 11660, "nodeType": "SourceUnit", "nodes": [ { - "id": 979, + "id": 11256, "literals": [ "solidity", "^", @@ -5638,27 +5789,38 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:8" + "src": "0:23:58" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/GSN/Context.sol", + "file": "../../GSN/Context.sol", + "id": 11257, + "nodeType": "ImportDirective", + "scope": 11660, + "sourceUnit": 10954, + "src": "25:31:58", + "symbolAliases": [], + "unitAlias": "" }, { - "absolutePath": "@openzeppelin/contracts/token/ERC20/IERC20.sol", + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", "file": "./IERC20.sol", - "id": 980, + "id": 11258, "nodeType": "ImportDirective", - "scope": 1375, - "sourceUnit": 1444, - "src": "25:22:8", + "scope": 11660, + "sourceUnit": 11787, + "src": "57:22:58", "symbolAliases": [], "unitAlias": "" }, { - "absolutePath": "@openzeppelin/contracts/math/SafeMath.sol", + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", "file": "../../math/SafeMath.sol", - "id": 981, + "id": 11259, "nodeType": "ImportDirective", - "scope": 1375, - "sourceUnit": 978, - "src": "48:33:8", + "scope": 11660, + "sourceUnit": 11141, + "src": "80:33:58", "symbolAliases": [], "unitAlias": "" }, @@ -5668,56 +5830,76 @@ "arguments": null, "baseName": { "contractScope": null, - "id": 982, + "id": 11260, + "name": "Context", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10953, + "src": "1286:7:58", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Context_$10953", + "typeString": "contract Context" + } + }, + "id": 11261, + "nodeType": "InheritanceSpecifier", + "src": "1286:7:58" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 11262, "name": "IERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1443, - "src": "1250:6:8", + "referencedDeclaration": 11786, + "src": "1295:6:58", "typeDescriptions": { - "typeIdentifier": "t_contract$_IERC20_$1443", + "typeIdentifier": "t_contract$_IERC20_$11786", "typeString": "contract IERC20" } }, - "id": 983, + "id": 11263, "nodeType": "InheritanceSpecifier", - "src": "1250:6:8" + "src": "1295:6:58" } ], "contractDependencies": [ - 1443 + 10953, + 11786 ], "contractKind": "contract", - "documentation": "@dev Implementation of the `IERC20` interface.\n * This implementation is agnostic to the way tokens are created. This means\nthat a supply mechanism has to be added in a derived contract using `_mint`.\nFor a generic mechanism see `ERC20Mintable`.\n * *For a detailed writeup see our guide [How to implement supply\nmechanisms](https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226).*\n * We have followed general OpenZeppelin guidelines: functions revert instead\nof returning `false` on failure. This behavior is nonetheless conventional\nand does not conflict with the expectations of ERC20 applications.\n * Additionally, an `Approval` event is emitted on calls to `transferFrom`.\nThis allows applications to reconstruct the allowance for all accounts just\nby listening to said events. Other implementations of the EIP may not emit\nthese events, as it isn't required by the specification.\n * Finally, the non-standard `decreaseAllowance` and `increaseAllowance`\nfunctions have been added to mitigate the well-known issues around setting\nallowances. See `IERC20.approve`.", + "documentation": "@dev Implementation of the {IERC20} interface.\n * This implementation is agnostic to the way tokens are created. This means\nthat a supply mechanism has to be added in a derived contract using {_mint}.\nFor a generic mechanism see {ERC20Mintable}.\n * TIP: For a detailed writeup see our guide\nhttps://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How\nto implement supply mechanisms].\n * We have followed general OpenZeppelin guidelines: functions revert instead\nof returning `false` on failure. This behavior is nonetheless conventional\nand does not conflict with the expectations of ERC20 applications.\n * Additionally, an {Approval} event is emitted on calls to {transferFrom}.\nThis allows applications to reconstruct the allowance for all accounts just\nby listening to said events. Other implementations of the EIP may not emit\nthese events, as it isn't required by the specification.\n * Finally, the non-standard {decreaseAllowance} and {increaseAllowance}\nfunctions have been added to mitigate the well-known issues around setting\nallowances. See {IERC20-approve}.", "fullyImplemented": true, - "id": 1374, + "id": 11659, "linearizedBaseContracts": [ - 1374, - 1443 + 11659, + 11786, + 10953 ], "name": "ERC20", "nodeType": "ContractDefinition", "nodes": [ { - "id": 986, + "id": 11266, "libraryName": { "contractScope": null, - "id": 984, + "id": 11264, "name": "SafeMath", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 977, - "src": "1269:8:8", + "referencedDeclaration": 11140, + "src": "1314:8:58", "typeDescriptions": { - "typeIdentifier": "t_contract$_SafeMath_$977", + "typeIdentifier": "t_contract$_SafeMath_$11140", "typeString": "library SafeMath" } }, "nodeType": "UsingForDirective", - "src": "1263:27:8", + "src": "1308:27:58", "typeName": { - "id": 985, + "id": 11265, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1282:7:8", + "src": "1327:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5726,11 +5908,11 @@ }, { "constant": false, - "id": 990, + "id": 11270, "name": "_balances", "nodeType": "VariableDeclaration", - "scope": 1374, - "src": "1296:46:8", + "scope": 11659, + "src": "1341:46:58", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -5738,28 +5920,28 @@ "typeString": "mapping(address => uint256)" }, "typeName": { - "id": 989, + "id": 11269, "keyType": { - "id": 987, + "id": 11267, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1305:7:8", + "src": "1350:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Mapping", - "src": "1296:28:8", + "src": "1341:28:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" }, "valueType": { - "id": 988, + "id": 11268, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1316:7:8", + "src": "1361:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5771,11 +5953,11 @@ }, { "constant": false, - "id": 996, + "id": 11276, "name": "_allowances", "nodeType": "VariableDeclaration", - "scope": 1374, - "src": "1349:69:8", + "scope": 11659, + "src": "1394:69:58", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -5783,46 +5965,46 @@ "typeString": "mapping(address => mapping(address => uint256))" }, "typeName": { - "id": 995, + "id": 11275, "keyType": { - "id": 991, + "id": 11271, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1358:7:8", + "src": "1403:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Mapping", - "src": "1349:49:8", + "src": "1394:49:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" }, "valueType": { - "id": 994, + "id": 11274, "keyType": { - "id": 992, + "id": 11272, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1378:7:8", + "src": "1423:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, "nodeType": "Mapping", - "src": "1369:28:8", + "src": "1414:28:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" }, "valueType": { - "id": 993, + "id": 11273, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1389:7:8", + "src": "1434:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5835,11 +6017,11 @@ }, { "constant": false, - "id": 998, + "id": 11278, "name": "_totalSupply", "nodeType": "VariableDeclaration", - "scope": 1374, - "src": "1425:28:8", + "scope": 11659, + "src": "1470:28:58", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -5847,10 +6029,10 @@ "typeString": "uint256" }, "typeName": { - "id": 997, + "id": 11277, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1425:7:8", + "src": "1470:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5861,55 +6043,55 @@ }, { "body": { - "id": 1005, + "id": 11285, "nodeType": "Block", - "src": "1567:36:8", + "src": "1612:36:58", "statements": [ { "expression": { "argumentTypes": null, - "id": 1003, + "id": 11283, "name": "_totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 998, - "src": "1584:12:8", + "referencedDeclaration": 11278, + "src": "1629:12:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 1002, - "id": 1004, + "functionReturnParameters": 11282, + "id": 11284, "nodeType": "Return", - "src": "1577:19:8" + "src": "1622:19:58" } ] }, - "documentation": "@dev See `IERC20.totalSupply`.", - "id": 1006, + "documentation": "@dev See {IERC20-totalSupply}.", + "id": 11286, "implemented": true, "kind": "function", "modifiers": [], "name": "totalSupply", "nodeType": "FunctionDefinition", "parameters": { - "id": 999, + "id": 11279, "nodeType": "ParameterList", "parameters": [], - "src": "1534:2:8" + "src": "1579:2:58" }, "returnParameters": { - "id": 1002, + "id": 11282, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1001, + "id": 11281, "name": "", "nodeType": "VariableDeclaration", - "scope": 1006, - "src": "1558:7:8", + "scope": 11286, + "src": "1603:7:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5917,10 +6099,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1000, + "id": 11280, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1558:7:8", + "src": "1603:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5930,45 +6112,45 @@ "visibility": "internal" } ], - "src": "1557:9:8" + "src": "1602:9:58" }, - "scope": 1374, - "src": "1514:89:8", + "scope": 11659, + "src": "1559:89:58", "stateMutability": "view", - "superFunction": 1381, + "superFunction": 11724, "visibility": "public" }, { "body": { - "id": 1017, + "id": 11297, "nodeType": "Block", - "src": "1727:42:8", + "src": "1772:42:58", "statements": [ { "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1013, + "id": 11293, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "1744:9:8", + "referencedDeclaration": 11270, + "src": "1789:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1015, + "id": 11295, "indexExpression": { "argumentTypes": null, - "id": 1014, + "id": 11294, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1008, - "src": "1754:7:8", + "referencedDeclaration": 11288, + "src": "1799:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5979,37 +6161,37 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "1744:18:8", + "src": "1789:18:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 1012, - "id": 1016, + "functionReturnParameters": 11292, + "id": 11296, "nodeType": "Return", - "src": "1737:25:8" + "src": "1782:25:58" } ] }, - "documentation": "@dev See `IERC20.balanceOf`.", - "id": 1018, + "documentation": "@dev See {IERC20-balanceOf}.", + "id": 11298, "implemented": true, "kind": "function", "modifiers": [], "name": "balanceOf", "nodeType": "FunctionDefinition", "parameters": { - "id": 1009, + "id": 11289, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1008, + "id": 11288, "name": "account", "nodeType": "VariableDeclaration", - "scope": 1018, - "src": "1680:15:8", + "scope": 11298, + "src": "1725:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6017,10 +6199,10 @@ "typeString": "address" }, "typeName": { - "id": 1007, + "id": 11287, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1680:7:8", + "src": "1725:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -6031,19 +6213,19 @@ "visibility": "internal" } ], - "src": "1679:17:8" + "src": "1724:17:58" }, "returnParameters": { - "id": 1012, + "id": 11292, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1011, + "id": 11291, "name": "", "nodeType": "VariableDeclaration", - "scope": 1018, - "src": "1718:7:8", + "scope": 11298, + "src": "1763:7:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6051,10 +6233,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1010, + "id": 11290, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1718:7:8", + "src": "1763:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6064,19 +6246,19 @@ "visibility": "internal" } ], - "src": "1717:9:8" + "src": "1762:9:58" }, - "scope": 1374, - "src": "1661:108:8", + "scope": 11659, + "src": "1706:108:58", "stateMutability": "view", - "superFunction": 1388, + "superFunction": 11731, "visibility": "public" }, { "body": { - "id": 1036, + "id": 11316, "nodeType": "Block", - "src": "2047:78:8", + "src": "2092:80:58", "statements": [ { "expression": { @@ -6084,28 +6266,29 @@ "arguments": [ { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1028, - "name": "msg", + "argumentTypes": [], + "id": 11308, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2067:3:8", + "referencedDeclaration": 10941, + "src": "2112:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1029, + "id": 11309, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "2067:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "2112:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -6113,12 +6296,12 @@ }, { "argumentTypes": null, - "id": 1030, + "id": 11310, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1020, - "src": "2079:9:8", + "referencedDeclaration": 11300, + "src": "2126:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -6126,12 +6309,12 @@ }, { "argumentTypes": null, - "id": 1031, + "id": 11311, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1022, - "src": "2090:6:8", + "referencedDeclaration": 11302, + "src": "2137:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6153,18 +6336,18 @@ "typeString": "uint256" } ], - "id": 1027, + "id": 11307, "name": "_transfer", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1217, - "src": "2057:9:8", + "referencedDeclaration": 11500, + "src": "2102:9:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1032, + "id": 11312, "isConstant": false, "isLValue": false, "isPure": false, @@ -6172,28 +6355,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2057:40:8", + "src": "2102:42:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1033, + "id": 11313, "nodeType": "ExpressionStatement", - "src": "2057:40:8" + "src": "2102:42:58" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", - "id": 1034, + "id": 11314, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", - "src": "2114:4:8", + "src": "2161:4:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", @@ -6201,31 +6384,31 @@ }, "value": "true" }, - "functionReturnParameters": 1026, - "id": 1035, + "functionReturnParameters": 11306, + "id": 11315, "nodeType": "Return", - "src": "2107:11:8" + "src": "2154:11:58" } ] }, - "documentation": "@dev See `IERC20.transfer`.\n * Requirements:\n * - `recipient` cannot be the zero address.\n- the caller must have a balance of at least `amount`.", - "id": 1037, + "documentation": "@dev See {IERC20-transfer}.\n * Requirements:\n * - `recipient` cannot be the zero address.\n- the caller must have a balance of at least `amount`.", + "id": 11317, "implemented": true, "kind": "function", "modifiers": [], "name": "transfer", "nodeType": "FunctionDefinition", "parameters": { - "id": 1023, + "id": 11303, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1020, + "id": 11300, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 1037, - "src": "1990:17:8", + "scope": 11317, + "src": "2035:17:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6233,10 +6416,10 @@ "typeString": "address" }, "typeName": { - "id": 1019, + "id": 11299, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1990:7:8", + "src": "2035:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -6248,11 +6431,11 @@ }, { "constant": false, - "id": 1022, + "id": 11302, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1037, - "src": "2009:14:8", + "scope": 11317, + "src": "2054:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6260,10 +6443,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1021, + "id": 11301, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2009:7:8", + "src": "2054:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6273,19 +6456,19 @@ "visibility": "internal" } ], - "src": "1989:35:8" + "src": "2034:35:58" }, "returnParameters": { - "id": 1026, + "id": 11306, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1025, + "id": 11305, "name": "", "nodeType": "VariableDeclaration", - "scope": 1037, - "src": "2041:4:8", + "scope": 11317, + "src": "2086:4:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6293,10 +6476,10 @@ "typeString": "bool" }, "typeName": { - "id": 1024, + "id": 11304, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "2041:4:8", + "src": "2086:4:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -6306,19 +6489,19 @@ "visibility": "internal" } ], - "src": "2040:6:8" + "src": "2085:6:58" }, - "scope": 1374, - "src": "1972:153:8", + "scope": 11659, + "src": "2017:155:58", "stateMutability": "nonpayable", - "superFunction": 1397, + "superFunction": 11740, "visibility": "public" }, { "body": { - "id": 1052, + "id": 11332, "nodeType": "Block", - "src": "2264:51:8", + "src": "2311:51:58", "statements": [ { "expression": { @@ -6327,26 +6510,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1046, + "id": 11326, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "2281:11:8", + "referencedDeclaration": 11276, + "src": "2328:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1048, + "id": 11328, "indexExpression": { "argumentTypes": null, - "id": 1047, + "id": 11327, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1039, - "src": "2293:5:8", + "referencedDeclaration": 11319, + "src": "2340:5:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -6357,21 +6540,21 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "2281:18:8", + "src": "2328:18:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1050, + "id": 11330, "indexExpression": { "argumentTypes": null, - "id": 1049, + "id": 11329, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1041, - "src": "2300:7:8", + "referencedDeclaration": 11321, + "src": "2347:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -6382,37 +6565,37 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "2281:27:8", + "src": "2328:27:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 1045, - "id": 1051, + "functionReturnParameters": 11325, + "id": 11331, "nodeType": "Return", - "src": "2274:34:8" + "src": "2321:34:58" } ] }, - "documentation": "@dev See `IERC20.allowance`.", - "id": 1053, + "documentation": "@dev See {IERC20-allowance}.", + "id": 11333, "implemented": true, "kind": "function", "modifiers": [], "name": "allowance", "nodeType": "FunctionDefinition", "parameters": { - "id": 1042, + "id": 11322, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1039, + "id": 11319, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 1053, - "src": "2202:13:8", + "scope": 11333, + "src": "2249:13:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6420,10 +6603,10 @@ "typeString": "address" }, "typeName": { - "id": 1038, + "id": 11318, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2202:7:8", + "src": "2249:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -6435,11 +6618,11 @@ }, { "constant": false, - "id": 1041, + "id": 11321, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1053, - "src": "2217:15:8", + "scope": 11333, + "src": "2264:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6447,10 +6630,10 @@ "typeString": "address" }, "typeName": { - "id": 1040, + "id": 11320, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2217:7:8", + "src": "2264:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -6461,19 +6644,19 @@ "visibility": "internal" } ], - "src": "2201:32:8" + "src": "2248:32:58" }, "returnParameters": { - "id": 1045, + "id": 11325, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1044, + "id": 11324, "name": "", "nodeType": "VariableDeclaration", - "scope": 1053, - "src": "2255:7:8", + "scope": 11333, + "src": "2302:7:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6481,10 +6664,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1043, + "id": 11323, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2255:7:8", + "src": "2302:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6494,19 +6677,19 @@ "visibility": "internal" } ], - "src": "2254:9:8" + "src": "2301:9:58" }, - "scope": 1374, - "src": "2183:132:8", + "scope": 11659, + "src": "2230:132:58", "stateMutability": "view", - "superFunction": 1406, + "superFunction": 11749, "visibility": "public" }, { "body": { - "id": 1071, + "id": 11351, "nodeType": "Block", - "src": "2524:74:8", + "src": "2572:77:58", "statements": [ { "expression": { @@ -6514,28 +6697,29 @@ "arguments": [ { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1063, - "name": "msg", + "argumentTypes": [], + "id": 11343, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2543:3:8", + "referencedDeclaration": 10941, + "src": "2591:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1064, + "id": 11344, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "2543:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "2591:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -6543,12 +6727,12 @@ }, { "argumentTypes": null, - "id": 1065, + "id": 11345, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1055, - "src": "2555:7:8", + "referencedDeclaration": 11335, + "src": "2605:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -6556,12 +6740,12 @@ }, { "argumentTypes": null, - "id": 1066, - "name": "value", + "id": 11346, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1057, - "src": "2564:5:8", + "referencedDeclaration": 11337, + "src": "2614:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6583,18 +6767,18 @@ "typeString": "uint256" } ], - "id": 1062, + "id": 11342, "name": "_approve", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1345, - "src": "2534:8:8", + "referencedDeclaration": 11629, + "src": "2582:8:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1067, + "id": 11347, "isConstant": false, "isLValue": false, "isPure": false, @@ -6602,28 +6786,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2534:36:8", + "src": "2582:39:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1068, + "id": 11348, "nodeType": "ExpressionStatement", - "src": "2534:36:8" + "src": "2582:39:58" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", - "id": 1069, + "id": 11349, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", - "src": "2587:4:8", + "src": "2638:4:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", @@ -6631,31 +6815,31 @@ }, "value": "true" }, - "functionReturnParameters": 1061, - "id": 1070, + "functionReturnParameters": 11341, + "id": 11350, "nodeType": "Return", - "src": "2580:11:8" + "src": "2631:11:58" } ] }, - "documentation": "@dev See `IERC20.approve`.\n * Requirements:\n * - `spender` cannot be the zero address.", - "id": 1072, + "documentation": "@dev See {IERC20-approve}.\n * Requirements:\n * - `spender` cannot be the zero address.", + "id": 11352, "implemented": true, "kind": "function", "modifiers": [], "name": "approve", "nodeType": "FunctionDefinition", "parameters": { - "id": 1058, + "id": 11338, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1055, + "id": 11335, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1072, - "src": "2470:15:8", + "scope": 11352, + "src": "2517:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6663,10 +6847,10 @@ "typeString": "address" }, "typeName": { - "id": 1054, + "id": 11334, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2470:7:8", + "src": "2517:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -6678,11 +6862,11 @@ }, { "constant": false, - "id": 1057, - "name": "value", + "id": 11337, + "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1072, - "src": "2487:13:8", + "scope": 11352, + "src": "2534:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6690,10 +6874,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1056, + "id": 11336, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2487:7:8", + "src": "2534:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6703,19 +6887,19 @@ "visibility": "internal" } ], - "src": "2469:32:8" + "src": "2516:33:58" }, "returnParameters": { - "id": 1061, + "id": 11341, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1060, + "id": 11340, "name": "", "nodeType": "VariableDeclaration", - "scope": 1072, - "src": "2518:4:8", + "scope": 11352, + "src": "2566:4:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6723,10 +6907,10 @@ "typeString": "bool" }, "typeName": { - "id": 1059, + "id": 11339, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "2518:4:8", + "src": "2566:4:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -6736,19 +6920,19 @@ "visibility": "internal" } ], - "src": "2517:6:8" + "src": "2565:6:58" }, - "scope": 1374, - "src": "2453:145:8", + "scope": 11659, + "src": "2500:149:58", "stateMutability": "nonpayable", - "superFunction": 1415, + "superFunction": 11758, "visibility": "public" }, { "body": { - "id": 1106, + "id": 11387, "nodeType": "Block", - "src": "3150:157:8", + "src": "3202:205:58", "statements": [ { "expression": { @@ -6756,12 +6940,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1084, + "id": 11364, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1074, - "src": "3170:6:8", + "referencedDeclaration": 11354, + "src": "3222:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -6769,12 +6953,12 @@ }, { "argumentTypes": null, - "id": 1085, + "id": 11365, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1076, - "src": "3178:9:8", + "referencedDeclaration": 11356, + "src": "3230:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -6782,12 +6966,12 @@ }, { "argumentTypes": null, - "id": 1086, + "id": 11366, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1078, - "src": "3189:6:8", + "referencedDeclaration": 11358, + "src": "3241:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6809,18 +6993,18 @@ "typeString": "uint256" } ], - "id": 1083, + "id": 11363, "name": "_transfer", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1217, - "src": "3160:9:8", + "referencedDeclaration": 11500, + "src": "3212:9:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1087, + "id": 11367, "isConstant": false, "isLValue": false, "isPure": false, @@ -6828,15 +7012,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3160:36:8", + "src": "3212:36:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1088, + "id": 11368, "nodeType": "ExpressionStatement", - "src": "3160:36:8" + "src": "3212:36:58" }, { "expression": { @@ -6844,12 +7028,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1090, + "id": 11370, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1074, - "src": "3215:6:8", + "referencedDeclaration": 11354, + "src": "3267:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -6857,28 +7041,29 @@ }, { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1091, - "name": "msg", + "argumentTypes": [], + "id": 11371, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3223:3:8", + "referencedDeclaration": 10941, + "src": "3275:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1092, + "id": 11372, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "3223:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "3275:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -6889,16 +7074,34 @@ "arguments": [ { "argumentTypes": null, - "id": 1100, + "id": 11380, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1078, - "src": "3271:6:8", + "referencedDeclaration": 11358, + "src": "3327:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } + }, + { + "argumentTypes": null, + "hexValue": "45524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e6365", + "id": 11381, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3335:42:58", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_974d1b4421da69cc60b481194f0dad36a5bb4e23da810da7a7fb30cdba178330", + "typeString": "literal_string \"ERC20: transfer amount exceeds allowance\"" + }, + "value": "ERC20: transfer amount exceeds allowance" } ], "expression": { @@ -6906,6 +7109,10 @@ { "typeIdentifier": "t_uint256", "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_974d1b4421da69cc60b481194f0dad36a5bb4e23da810da7a7fb30cdba178330", + "typeString": "literal_string \"ERC20: transfer amount exceeds allowance\"" } ], "expression": { @@ -6914,26 +7121,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1093, + "id": 11373, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "3235:11:8", + "referencedDeclaration": 11276, + "src": "3289:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1095, + "id": 11375, "indexExpression": { "argumentTypes": null, - "id": 1094, + "id": 11374, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1074, - "src": "3247:6:8", + "referencedDeclaration": 11354, + "src": "3301:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -6944,37 +7151,38 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "3235:19:8", + "src": "3289:19:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1098, + "id": 11378, "indexExpression": { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1096, - "name": "msg", + "argumentTypes": [], + "id": 11376, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3255:3:8", + "referencedDeclaration": 10941, + "src": "3309:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1097, + "id": 11377, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "3255:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "3309:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -6985,27 +7193,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "3235:31:8", + "src": "3289:33:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1099, + "id": 11379, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "3235:35:8", + "referencedDeclaration": 11023, + "src": "3289:37:58", "typeDescriptions": { - "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", - "typeString": "function (uint256,uint256) pure returns (uint256)" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 1101, + "id": 11382, "isConstant": false, "isLValue": false, "isPure": false, @@ -7013,7 +7221,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3235:43:8", + "src": "3289:89:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -7035,18 +7243,18 @@ "typeString": "uint256" } ], - "id": 1089, + "id": 11369, "name": "_approve", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1345, - "src": "3206:8:8", + "referencedDeclaration": 11629, + "src": "3258:8:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1102, + "id": 11383, "isConstant": false, "isLValue": false, "isPure": false, @@ -7054,28 +7262,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3206:73:8", + "src": "3258:121:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1103, + "id": 11384, "nodeType": "ExpressionStatement", - "src": "3206:73:8" + "src": "3258:121:58" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", - "id": 1104, + "id": 11385, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", - "src": "3296:4:8", + "src": "3396:4:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", @@ -7083,31 +7291,31 @@ }, "value": "true" }, - "functionReturnParameters": 1082, - "id": 1105, + "functionReturnParameters": 11362, + "id": 11386, "nodeType": "Return", - "src": "3289:11:8" + "src": "3389:11:58" } ] }, - "documentation": "@dev See `IERC20.transferFrom`.\n * Emits an `Approval` event indicating the updated allowance. This is not\nrequired by the EIP. See the note at the beginning of `ERC20`;\n * Requirements:\n- `sender` and `recipient` cannot be the zero address.\n- `sender` must have a balance of at least `value`.\n- the caller must have allowance for `sender`'s tokens of at least\n`amount`.", - "id": 1107, + "documentation": "@dev See {IERC20-transferFrom}.\n * Emits an {Approval} event indicating the updated allowance. This is not\nrequired by the EIP. See the note at the beginning of {ERC20};\n * Requirements:\n- `sender` and `recipient` cannot be the zero address.\n- `sender` must have a balance of at least `amount`.\n- the caller must have allowance for `sender`'s tokens of at least\n`amount`.", + "id": 11388, "implemented": true, "kind": "function", "modifiers": [], "name": "transferFrom", "nodeType": "FunctionDefinition", "parameters": { - "id": 1079, + "id": 11359, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1074, + "id": 11354, "name": "sender", "nodeType": "VariableDeclaration", - "scope": 1107, - "src": "3077:14:8", + "scope": 11388, + "src": "3129:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -7115,10 +7323,10 @@ "typeString": "address" }, "typeName": { - "id": 1073, + "id": 11353, "name": "address", "nodeType": "ElementaryTypeName", - "src": "3077:7:8", + "src": "3129:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -7130,11 +7338,11 @@ }, { "constant": false, - "id": 1076, + "id": 11356, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 1107, - "src": "3093:17:8", + "scope": 11388, + "src": "3145:17:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -7142,10 +7350,10 @@ "typeString": "address" }, "typeName": { - "id": 1075, + "id": 11355, "name": "address", "nodeType": "ElementaryTypeName", - "src": "3093:7:8", + "src": "3145:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -7157,11 +7365,11 @@ }, { "constant": false, - "id": 1078, + "id": 11358, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1107, - "src": "3112:14:8", + "scope": 11388, + "src": "3164:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -7169,10 +7377,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1077, + "id": 11357, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3112:7:8", + "src": "3164:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -7182,19 +7390,19 @@ "visibility": "internal" } ], - "src": "3076:51:8" + "src": "3128:51:58" }, "returnParameters": { - "id": 1082, + "id": 11362, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1081, + "id": 11361, "name": "", "nodeType": "VariableDeclaration", - "scope": 1107, - "src": "3144:4:8", + "scope": 11388, + "src": "3196:4:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -7202,10 +7410,10 @@ "typeString": "bool" }, "typeName": { - "id": 1080, + "id": 11360, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "3144:4:8", + "src": "3196:4:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -7215,19 +7423,19 @@ "visibility": "internal" } ], - "src": "3143:6:8" + "src": "3195:6:58" }, - "scope": 1374, - "src": "3055:252:8", + "scope": 11659, + "src": "3107:300:58", "stateMutability": "nonpayable", - "superFunction": 1426, + "superFunction": 11769, "visibility": "public" }, { "body": { - "id": 1133, + "id": 11414, "nodeType": "Block", - "src": "3788:117:8", + "src": "3888:121:58", "statements": [ { "expression": { @@ -7235,28 +7443,29 @@ "arguments": [ { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1117, - "name": "msg", + "argumentTypes": [], + "id": 11398, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3807:3:8", + "referencedDeclaration": 10941, + "src": "3907:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1118, + "id": 11399, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "3807:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "3907:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -7264,12 +7473,12 @@ }, { "argumentTypes": null, - "id": 1119, + "id": 11400, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1109, - "src": "3819:7:8", + "referencedDeclaration": 11390, + "src": "3921:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -7280,12 +7489,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1127, + "id": 11408, "name": "addedValue", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1111, - "src": "3865:10:8", + "referencedDeclaration": 11392, + "src": "3969:10:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -7305,42 +7514,43 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1120, + "id": 11401, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "3828:11:8", + "referencedDeclaration": 11276, + "src": "3930:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1123, + "id": 11404, "indexExpression": { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1121, - "name": "msg", + "argumentTypes": [], + "id": 11402, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3840:3:8", + "referencedDeclaration": 10941, + "src": "3942:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1122, + "id": 11403, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "3840:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "3942:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -7351,21 +7561,21 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "3828:23:8", + "src": "3930:25:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1125, + "id": 11406, "indexExpression": { "argumentTypes": null, - "id": 1124, + "id": 11405, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1109, - "src": "3852:7:8", + "referencedDeclaration": 11390, + "src": "3956:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -7376,27 +7586,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "3828:32:8", + "src": "3930:34:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1126, + "id": 11407, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", - "referencedDeclaration": 871, - "src": "3828:36:8", + "referencedDeclaration": 10980, + "src": "3930:38:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", "typeString": "function (uint256,uint256) pure returns (uint256)" } }, - "id": 1128, + "id": 11409, "isConstant": false, "isLValue": false, "isPure": false, @@ -7404,7 +7614,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3828:48:8", + "src": "3930:50:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -7426,18 +7636,18 @@ "typeString": "uint256" } ], - "id": 1116, + "id": 11397, "name": "_approve", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1345, - "src": "3798:8:8", + "referencedDeclaration": 11629, + "src": "3898:8:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1129, + "id": 11410, "isConstant": false, "isLValue": false, "isPure": false, @@ -7445,28 +7655,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3798:79:8", + "src": "3898:83:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1130, + "id": 11411, "nodeType": "ExpressionStatement", - "src": "3798:79:8" + "src": "3898:83:58" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", - "id": 1131, + "id": 11412, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", - "src": "3894:4:8", + "src": "3998:4:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", @@ -7474,31 +7684,31 @@ }, "value": "true" }, - "functionReturnParameters": 1115, - "id": 1132, + "functionReturnParameters": 11396, + "id": 11413, "nodeType": "Return", - "src": "3887:11:8" + "src": "3991:11:58" } ] }, - "documentation": "@dev Atomically increases the allowance granted to `spender` by the caller.\n * This is an alternative to `approve` that can be used as a mitigation for\nproblems described in `IERC20.approve`.\n * Emits an `Approval` event indicating the updated allowance.\n * Requirements:\n * - `spender` cannot be the zero address.", - "id": 1134, + "documentation": "@dev Atomically increases the allowance granted to `spender` by the caller.\n * This is an alternative to {approve} that can be used as a mitigation for\nproblems described in {IERC20-approve}.\n * Emits an {Approval} event indicating the updated allowance.\n * Requirements:\n * - `spender` cannot be the zero address.", + "id": 11415, "implemented": true, "kind": "function", "modifiers": [], "name": "increaseAllowance", "nodeType": "FunctionDefinition", "parameters": { - "id": 1112, + "id": 11393, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1109, + "id": 11390, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1134, - "src": "3729:15:8", + "scope": 11415, + "src": "3829:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -7506,10 +7716,10 @@ "typeString": "address" }, "typeName": { - "id": 1108, + "id": 11389, "name": "address", "nodeType": "ElementaryTypeName", - "src": "3729:7:8", + "src": "3829:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -7521,11 +7731,11 @@ }, { "constant": false, - "id": 1111, + "id": 11392, "name": "addedValue", "nodeType": "VariableDeclaration", - "scope": 1134, - "src": "3746:18:8", + "scope": 11415, + "src": "3846:18:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -7533,10 +7743,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1110, + "id": 11391, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3746:7:8", + "src": "3846:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -7546,19 +7756,19 @@ "visibility": "internal" } ], - "src": "3728:37:8" + "src": "3828:37:58" }, "returnParameters": { - "id": 1115, + "id": 11396, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1114, + "id": 11395, "name": "", "nodeType": "VariableDeclaration", - "scope": 1134, - "src": "3782:4:8", + "scope": 11415, + "src": "3882:4:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -7566,10 +7776,10 @@ "typeString": "bool" }, "typeName": { - "id": 1113, + "id": 11394, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "3782:4:8", + "src": "3882:4:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -7579,19 +7789,19 @@ "visibility": "internal" } ], - "src": "3781:6:8" + "src": "3881:6:58" }, - "scope": 1374, - "src": "3702:203:8", + "scope": 11659, + "src": "3802:207:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 1160, + "id": 11442, "nodeType": "Block", - "src": "4483:122:8", + "src": "4587:167:58", "statements": [ { "expression": { @@ -7599,28 +7809,29 @@ "arguments": [ { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1144, - "name": "msg", + "argumentTypes": [], + "id": 11425, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "4502:3:8", + "referencedDeclaration": 10941, + "src": "4606:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1145, + "id": 11426, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "4502:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "4606:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -7628,12 +7839,12 @@ }, { "argumentTypes": null, - "id": 1146, + "id": 11427, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1136, - "src": "4514:7:8", + "referencedDeclaration": 11417, + "src": "4620:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -7644,16 +7855,34 @@ "arguments": [ { "argumentTypes": null, - "id": 1154, + "id": 11435, "name": "subtractedValue", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1138, - "src": "4560:15:8", + "referencedDeclaration": 11419, + "src": "4668:15:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } + }, + { + "argumentTypes": null, + "hexValue": "45524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726f", + "id": 11436, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4685:39:58", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_f8b476f7d28209d77d4a4ac1fe36b9f8259aa1bb6bddfa6e89de7e51615cf8a8", + "typeString": "literal_string \"ERC20: decreased allowance below zero\"" + }, + "value": "ERC20: decreased allowance below zero" } ], "expression": { @@ -7661,6 +7890,10 @@ { "typeIdentifier": "t_uint256", "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_f8b476f7d28209d77d4a4ac1fe36b9f8259aa1bb6bddfa6e89de7e51615cf8a8", + "typeString": "literal_string \"ERC20: decreased allowance below zero\"" } ], "expression": { @@ -7669,42 +7902,43 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1147, + "id": 11428, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "4523:11:8", + "referencedDeclaration": 11276, + "src": "4629:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1150, + "id": 11431, "indexExpression": { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1148, - "name": "msg", + "argumentTypes": [], + "id": 11429, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "4535:3:8", + "referencedDeclaration": 10941, + "src": "4641:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1149, + "id": 11430, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "4535:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "4641:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -7715,21 +7949,21 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "4523:23:8", + "src": "4629:25:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1152, + "id": 11433, "indexExpression": { "argumentTypes": null, - "id": 1151, + "id": 11432, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1136, - "src": "4547:7:8", + "referencedDeclaration": 11417, + "src": "4655:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -7740,27 +7974,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "4523:32:8", + "src": "4629:34:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1153, + "id": 11434, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "4523:36:8", + "referencedDeclaration": 11023, + "src": "4629:38:58", "typeDescriptions": { - "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", - "typeString": "function (uint256,uint256) pure returns (uint256)" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 1155, + "id": 11437, "isConstant": false, "isLValue": false, "isPure": false, @@ -7768,7 +8002,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "4523:53:8", + "src": "4629:96:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -7790,18 +8024,18 @@ "typeString": "uint256" } ], - "id": 1143, + "id": 11424, "name": "_approve", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1345, - "src": "4493:8:8", + "referencedDeclaration": 11629, + "src": "4597:8:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1156, + "id": 11438, "isConstant": false, "isLValue": false, "isPure": false, @@ -7809,28 +8043,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "4493:84:8", + "src": "4597:129:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1157, + "id": 11439, "nodeType": "ExpressionStatement", - "src": "4493:84:8" + "src": "4597:129:58" }, { "expression": { "argumentTypes": null, "hexValue": "74727565", - "id": 1158, + "id": 11440, "isConstant": false, "isLValue": false, "isPure": true, "kind": "bool", "lValueRequested": false, "nodeType": "Literal", - "src": "4594:4:8", + "src": "4743:4:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_bool", @@ -7838,31 +8072,31 @@ }, "value": "true" }, - "functionReturnParameters": 1142, - "id": 1159, + "functionReturnParameters": 11423, + "id": 11441, "nodeType": "Return", - "src": "4587:11:8" + "src": "4736:11:58" } ] }, - "documentation": "@dev Atomically decreases the allowance granted to `spender` by the caller.\n * This is an alternative to `approve` that can be used as a mitigation for\nproblems described in `IERC20.approve`.\n * Emits an `Approval` event indicating the updated allowance.\n * Requirements:\n * - `spender` cannot be the zero address.\n- `spender` must have allowance for the caller of at least\n`subtractedValue`.", - "id": 1161, + "documentation": "@dev Atomically decreases the allowance granted to `spender` by the caller.\n * This is an alternative to {approve} that can be used as a mitigation for\nproblems described in {IERC20-approve}.\n * Emits an {Approval} event indicating the updated allowance.\n * Requirements:\n * - `spender` cannot be the zero address.\n- `spender` must have allowance for the caller of at least\n`subtractedValue`.", + "id": 11443, "implemented": true, "kind": "function", "modifiers": [], "name": "decreaseAllowance", "nodeType": "FunctionDefinition", "parameters": { - "id": 1139, + "id": 11420, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1136, + "id": 11417, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1161, - "src": "4419:15:8", + "scope": 11443, + "src": "4523:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -7870,10 +8104,10 @@ "typeString": "address" }, "typeName": { - "id": 1135, + "id": 11416, "name": "address", "nodeType": "ElementaryTypeName", - "src": "4419:7:8", + "src": "4523:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -7885,11 +8119,11 @@ }, { "constant": false, - "id": 1138, + "id": 11419, "name": "subtractedValue", "nodeType": "VariableDeclaration", - "scope": 1161, - "src": "4436:23:8", + "scope": 11443, + "src": "4540:23:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -7897,10 +8131,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1137, + "id": 11418, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "4436:7:8", + "src": "4540:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -7910,19 +8144,19 @@ "visibility": "internal" } ], - "src": "4418:42:8" + "src": "4522:42:58" }, "returnParameters": { - "id": 1142, + "id": 11423, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1141, + "id": 11422, "name": "", "nodeType": "VariableDeclaration", - "scope": 1161, - "src": "4477:4:8", + "scope": 11443, + "src": "4581:4:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -7930,10 +8164,10 @@ "typeString": "bool" }, "typeName": { - "id": 1140, + "id": 11421, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "4477:4:8", + "src": "4581:4:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -7943,19 +8177,19 @@ "visibility": "internal" } ], - "src": "4476:6:8" + "src": "4580:6:58" }, - "scope": 1374, - "src": "4392:213:8", + "scope": 11659, + "src": "4496:258:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 1216, + "id": 11499, "nodeType": "Block", - "src": "5158:343:8", + "src": "5307:385:58", "statements": [ { "expression": { @@ -7967,19 +8201,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1175, + "id": 11457, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1171, + "id": 11453, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1163, - "src": "5176:6:8", + "referencedDeclaration": 11445, + "src": "5325:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -7993,14 +8227,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1173, + "id": 11455, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "5194:1:8", + "src": "5343:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -8016,20 +8250,20 @@ "typeString": "int_const 0" } ], - "id": 1172, + "id": 11454, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "5186:7:8", + "src": "5335:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1174, + "id": 11456, "isConstant": false, "isLValue": false, "isPure": true, @@ -8037,13 +8271,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5186:10:8", + "src": "5335:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "5176:20:8", + "src": "5325:20:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -8052,14 +8286,14 @@ { "argumentTypes": null, "hexValue": "45524332303a207472616e736665722066726f6d20746865207a65726f2061646472657373", - "id": 1176, + "id": 11458, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "5198:39:8", + "src": "5347:39:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_baecc556b46f4ed0f2b4cb599d60785ac8563dd2dc0a5bf12edea1c39e5e1fea", @@ -8079,21 +8313,21 @@ "typeString": "literal_string \"ERC20: transfer from the zero address\"" } ], - "id": 1170, + "id": 11452, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "5168:7:8", + "referencedDeclaration": 12132, + "src": "5317:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1177, + "id": 11459, "isConstant": false, "isLValue": false, "isPure": false, @@ -8101,15 +8335,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5168:70:8", + "src": "5317:70:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1178, + "id": 11460, "nodeType": "ExpressionStatement", - "src": "5168:70:8" + "src": "5317:70:58" }, { "expression": { @@ -8121,19 +8355,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1184, + "id": 11466, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1180, + "id": 11462, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1165, - "src": "5256:9:8", + "referencedDeclaration": 11447, + "src": "5405:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -8147,14 +8381,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1182, + "id": 11464, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "5277:1:8", + "src": "5426:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -8170,20 +8404,20 @@ "typeString": "int_const 0" } ], - "id": 1181, + "id": 11463, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "5269:7:8", + "src": "5418:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1183, + "id": 11465, "isConstant": false, "isLValue": false, "isPure": true, @@ -8191,13 +8425,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5269:10:8", + "src": "5418:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "5256:23:8", + "src": "5405:23:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -8206,14 +8440,14 @@ { "argumentTypes": null, "hexValue": "45524332303a207472616e7366657220746f20746865207a65726f2061646472657373", - "id": 1185, + "id": 11467, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "5281:37:8", + "src": "5430:37:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_0557e210f7a69a685100a7e4e3d0a7024c546085cee28910fd17d0b081d9516f", @@ -8233,21 +8467,21 @@ "typeString": "literal_string \"ERC20: transfer to the zero address\"" } ], - "id": 1179, + "id": 11461, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "5248:7:8", + "referencedDeclaration": 12132, + "src": "5397:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1186, + "id": 11468, "isConstant": false, "isLValue": false, "isPure": false, @@ -8255,20 +8489,20 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5248:71:8", + "src": "5397:71:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1187, + "id": 11469, "nodeType": "ExpressionStatement", - "src": "5248:71:8" + "src": "5397:71:58" }, { "expression": { "argumentTypes": null, - "id": 1197, + "id": 11480, "isConstant": false, "isLValue": false, "isPure": false, @@ -8277,26 +8511,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1188, + "id": 11470, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5330:9:8", + "referencedDeclaration": 11270, + "src": "5479:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1190, + "id": 11472, "indexExpression": { "argumentTypes": null, - "id": 1189, + "id": 11471, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1163, - "src": "5340:6:8", + "referencedDeclaration": 11445, + "src": "5489:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -8307,7 +8541,7 @@ "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", - "src": "5330:17:8", + "src": "5479:17:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -8320,16 +8554,34 @@ "arguments": [ { "argumentTypes": null, - "id": 1195, + "id": 11477, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1167, - "src": "5372:6:8", + "referencedDeclaration": 11449, + "src": "5521:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } + }, + { + "argumentTypes": null, + "hexValue": "45524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e6365", + "id": 11478, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5529:40:58", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_4107e8a8b9e94bf8ff83080ddec1c0bffe897ebc2241b89d44f66b3d274088b6", + "typeString": "literal_string \"ERC20: transfer amount exceeds balance\"" + }, + "value": "ERC20: transfer amount exceeds balance" } ], "expression": { @@ -8337,32 +8589,36 @@ { "typeIdentifier": "t_uint256", "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_4107e8a8b9e94bf8ff83080ddec1c0bffe897ebc2241b89d44f66b3d274088b6", + "typeString": "literal_string \"ERC20: transfer amount exceeds balance\"" } ], "expression": { "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1191, + "id": 11473, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5350:9:8", + "referencedDeclaration": 11270, + "src": "5499:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1193, + "id": 11475, "indexExpression": { "argumentTypes": null, - "id": 1192, + "id": 11474, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1163, - "src": "5360:6:8", + "referencedDeclaration": 11445, + "src": "5509:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -8373,27 +8629,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "5350:17:8", + "src": "5499:17:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1194, + "id": 11476, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "5350:21:8", + "referencedDeclaration": 11023, + "src": "5499:21:58", "typeDescriptions": { - "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", - "typeString": "function (uint256,uint256) pure returns (uint256)" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 1196, + "id": 11479, "isConstant": false, "isLValue": false, "isPure": false, @@ -8401,26 +8657,26 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5350:29:8", + "src": "5499:71:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "5330:49:8", + "src": "5479:91:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1198, + "id": 11481, "nodeType": "ExpressionStatement", - "src": "5330:49:8" + "src": "5479:91:58" }, { "expression": { "argumentTypes": null, - "id": 1208, + "id": 11491, "isConstant": false, "isLValue": false, "isPure": false, @@ -8429,26 +8685,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1199, + "id": 11482, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5389:9:8", + "referencedDeclaration": 11270, + "src": "5580:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1201, + "id": 11484, "indexExpression": { "argumentTypes": null, - "id": 1200, + "id": 11483, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1165, - "src": "5399:9:8", + "referencedDeclaration": 11447, + "src": "5590:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -8459,7 +8715,7 @@ "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", - "src": "5389:20:8", + "src": "5580:20:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -8472,12 +8728,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1206, + "id": 11489, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1167, - "src": "5437:6:8", + "referencedDeclaration": 11449, + "src": "5628:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -8495,26 +8751,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1202, + "id": 11485, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5412:9:8", + "referencedDeclaration": 11270, + "src": "5603:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1204, + "id": 11487, "indexExpression": { "argumentTypes": null, - "id": 1203, + "id": 11486, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1165, - "src": "5422:9:8", + "referencedDeclaration": 11447, + "src": "5613:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -8525,27 +8781,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "5412:20:8", + "src": "5603:20:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1205, + "id": 11488, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", - "referencedDeclaration": 871, - "src": "5412:24:8", + "referencedDeclaration": 10980, + "src": "5603:24:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", "typeString": "function (uint256,uint256) pure returns (uint256)" } }, - "id": 1207, + "id": 11490, "isConstant": false, "isLValue": false, "isPure": false, @@ -8553,21 +8809,21 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5412:32:8", + "src": "5603:32:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "5389:55:8", + "src": "5580:55:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1209, + "id": 11492, "nodeType": "ExpressionStatement", - "src": "5389:55:8" + "src": "5580:55:58" }, { "eventCall": { @@ -8575,12 +8831,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1211, + "id": 11494, "name": "sender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1163, - "src": "5468:6:8", + "referencedDeclaration": 11445, + "src": "5659:6:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -8588,12 +8844,12 @@ }, { "argumentTypes": null, - "id": 1212, + "id": 11495, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1165, - "src": "5476:9:8", + "referencedDeclaration": 11447, + "src": "5667:9:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -8601,12 +8857,12 @@ }, { "argumentTypes": null, - "id": 1213, + "id": 11496, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1167, - "src": "5487:6:8", + "referencedDeclaration": 11449, + "src": "5678:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -8628,18 +8884,18 @@ "typeString": "uint256" } ], - "id": 1210, + "id": 11493, "name": "Transfer", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1434, - "src": "5459:8:8", + "referencedDeclaration": 11777, + "src": "5650:8:58", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1214, + "id": 11497, "isConstant": false, "isLValue": false, "isPure": false, @@ -8647,36 +8903,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5459:35:8", + "src": "5650:35:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1215, + "id": 11498, "nodeType": "EmitStatement", - "src": "5454:40:8" + "src": "5645:40:58" } ] }, - "documentation": "@dev Moves tokens `amount` from `sender` to `recipient`.\n * This is internal function is equivalent to `transfer`, and can be used to\ne.g. implement automatic token fees, slashing mechanisms, etc.\n * Emits a `Transfer` event.\n * Requirements:\n * - `sender` cannot be the zero address.\n- `recipient` cannot be the zero address.\n- `sender` must have a balance of at least `amount`.", - "id": 1217, + "documentation": "@dev Moves tokens `amount` from `sender` to `recipient`.\n * This is internal function is equivalent to {transfer}, and can be used to\ne.g. implement automatic token fees, slashing mechanisms, etc.\n * Emits a {Transfer} event.\n * Requirements:\n * - `sender` cannot be the zero address.\n- `recipient` cannot be the zero address.\n- `sender` must have a balance of at least `amount`.", + "id": 11500, "implemented": true, "kind": "function", "modifiers": [], "name": "_transfer", "nodeType": "FunctionDefinition", "parameters": { - "id": 1168, + "id": 11450, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1163, + "id": 11445, "name": "sender", "nodeType": "VariableDeclaration", - "scope": 1217, - "src": "5098:14:8", + "scope": 11500, + "src": "5247:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -8684,10 +8940,10 @@ "typeString": "address" }, "typeName": { - "id": 1162, + "id": 11444, "name": "address", "nodeType": "ElementaryTypeName", - "src": "5098:7:8", + "src": "5247:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -8699,11 +8955,11 @@ }, { "constant": false, - "id": 1165, + "id": 11447, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 1217, - "src": "5114:17:8", + "scope": 11500, + "src": "5263:17:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -8711,10 +8967,10 @@ "typeString": "address" }, "typeName": { - "id": 1164, + "id": 11446, "name": "address", "nodeType": "ElementaryTypeName", - "src": "5114:7:8", + "src": "5263:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -8726,11 +8982,11 @@ }, { "constant": false, - "id": 1167, + "id": 11449, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1217, - "src": "5133:14:8", + "scope": 11500, + "src": "5282:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -8738,10 +8994,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1166, + "id": 11448, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "5133:7:8", + "src": "5282:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -8751,25 +9007,25 @@ "visibility": "internal" } ], - "src": "5097:51:8" + "src": "5246:51:58" }, "returnParameters": { - "id": 1169, + "id": 11451, "nodeType": "ParameterList", "parameters": [], - "src": "5158:0:8" + "src": "5307:0:58" }, - "scope": 1374, - "src": "5079:422:8", + "scope": 11659, + "src": "5228:464:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 1259, + "id": 11542, "nodeType": "Block", - "src": "5828:245:8", + "src": "6019:245:58", "statements": [ { "expression": { @@ -8781,19 +9037,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1229, + "id": 11512, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1225, + "id": 11508, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1219, - "src": "5846:7:8", + "referencedDeclaration": 11502, + "src": "6037:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -8807,14 +9063,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1227, + "id": 11510, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "5865:1:8", + "src": "6056:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -8830,20 +9086,20 @@ "typeString": "int_const 0" } ], - "id": 1226, + "id": 11509, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "5857:7:8", + "src": "6048:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1228, + "id": 11511, "isConstant": false, "isLValue": false, "isPure": true, @@ -8851,13 +9107,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5857:10:8", + "src": "6048:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "5846:21:8", + "src": "6037:21:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -8866,14 +9122,14 @@ { "argumentTypes": null, "hexValue": "45524332303a206d696e7420746f20746865207a65726f2061646472657373", - "id": 1230, + "id": 11513, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "5869:33:8", + "src": "6060:33:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_fc0b381caf0a47702017f3c4b358ebe3d3aff6c60ce819a8bf3ef5a95d4f202e", @@ -8893,21 +9149,21 @@ "typeString": "literal_string \"ERC20: mint to the zero address\"" } ], - "id": 1224, + "id": 11507, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "5838:7:8", + "referencedDeclaration": 12132, + "src": "6029:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1231, + "id": 11514, "isConstant": false, "isLValue": false, "isPure": false, @@ -8915,32 +9171,32 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5838:65:8", + "src": "6029:65:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1232, + "id": 11515, "nodeType": "ExpressionStatement", - "src": "5838:65:8" + "src": "6029:65:58" }, { "expression": { "argumentTypes": null, - "id": 1238, + "id": 11521, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 1233, + "id": 11516, "name": "_totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 998, - "src": "5914:12:8", + "referencedDeclaration": 11278, + "src": "6105:12:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -8953,12 +9209,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1236, + "id": 11519, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1221, - "src": "5946:6:8", + "referencedDeclaration": 11504, + "src": "6137:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -8974,32 +9230,32 @@ ], "expression": { "argumentTypes": null, - "id": 1234, + "id": 11517, "name": "_totalSupply", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 998, - "src": "5929:12:8", + "referencedDeclaration": 11278, + "src": "6120:12:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1235, + "id": 11518, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", - "referencedDeclaration": 871, - "src": "5929:16:8", + "referencedDeclaration": 10980, + "src": "6120:16:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", "typeString": "function (uint256,uint256) pure returns (uint256)" } }, - "id": 1237, + "id": 11520, "isConstant": false, "isLValue": false, "isPure": false, @@ -9007,26 +9263,26 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5929:24:8", + "src": "6120:24:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "5914:39:8", + "src": "6105:39:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1239, + "id": 11522, "nodeType": "ExpressionStatement", - "src": "5914:39:8" + "src": "6105:39:58" }, { "expression": { "argumentTypes": null, - "id": 1249, + "id": 11532, "isConstant": false, "isLValue": false, "isPure": false, @@ -9035,26 +9291,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1240, + "id": 11523, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5963:9:8", + "referencedDeclaration": 11270, + "src": "6154:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1242, + "id": 11525, "indexExpression": { "argumentTypes": null, - "id": 1241, + "id": 11524, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1219, - "src": "5973:7:8", + "referencedDeclaration": 11502, + "src": "6164:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -9065,7 +9321,7 @@ "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", - "src": "5963:18:8", + "src": "6154:18:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -9078,12 +9334,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1247, + "id": 11530, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1221, - "src": "6007:6:8", + "referencedDeclaration": 11504, + "src": "6198:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -9101,26 +9357,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1243, + "id": 11526, "name": "_balances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "5984:9:8", + "referencedDeclaration": 11270, + "src": "6175:9:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1245, + "id": 11528, "indexExpression": { "argumentTypes": null, - "id": 1244, + "id": 11527, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1219, - "src": "5994:7:8", + "referencedDeclaration": 11502, + "src": "6185:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -9131,27 +9387,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "5984:18:8", + "src": "6175:18:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1246, + "id": 11529, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "add", "nodeType": "MemberAccess", - "referencedDeclaration": 871, - "src": "5984:22:8", + "referencedDeclaration": 10980, + "src": "6175:22:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", "typeString": "function (uint256,uint256) pure returns (uint256)" } }, - "id": 1248, + "id": 11531, "isConstant": false, "isLValue": false, "isPure": false, @@ -9159,21 +9415,21 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "5984:30:8", + "src": "6175:30:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "5963:51:8", + "src": "6154:51:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1250, + "id": 11533, "nodeType": "ExpressionStatement", - "src": "5963:51:8" + "src": "6154:51:58" }, { "eventCall": { @@ -9185,14 +9441,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1253, + "id": 11536, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "6046:1:8", + "src": "6237:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -9208,20 +9464,20 @@ "typeString": "int_const 0" } ], - "id": 1252, + "id": 11535, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "6038:7:8", + "src": "6229:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1254, + "id": 11537, "isConstant": false, "isLValue": false, "isPure": true, @@ -9229,7 +9485,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6038:10:8", + "src": "6229:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -9237,12 +9493,12 @@ }, { "argumentTypes": null, - "id": 1255, + "id": 11538, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1219, - "src": "6050:7:8", + "referencedDeclaration": 11502, + "src": "6241:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -9250,12 +9506,12 @@ }, { "argumentTypes": null, - "id": 1256, + "id": 11539, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1221, - "src": "6059:6:8", + "referencedDeclaration": 11504, + "src": "6250:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -9277,18 +9533,18 @@ "typeString": "uint256" } ], - "id": 1251, + "id": 11534, "name": "Transfer", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1434, - "src": "6029:8:8", + "referencedDeclaration": 11777, + "src": "6220:8:58", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1257, + "id": 11540, "isConstant": false, "isLValue": false, "isPure": false, @@ -9296,36 +9552,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6029:37:8", + "src": "6220:37:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1258, + "id": 11541, "nodeType": "EmitStatement", - "src": "6024:42:8" + "src": "6215:42:58" } ] }, - "documentation": "@dev Creates `amount` tokens and assigns them to `account`, increasing\nthe total supply.\n * Emits a `Transfer` event with `from` set to the zero address.\n * Requirements\n * - `to` cannot be the zero address.", - "id": 1260, + "documentation": "@dev Creates `amount` tokens and assigns them to `account`, increasing\nthe total supply.\n * Emits a {Transfer} event with `from` set to the zero address.\n * Requirements\n * - `to` cannot be the zero address.", + "id": 11543, "implemented": true, "kind": "function", "modifiers": [], "name": "_mint", "nodeType": "FunctionDefinition", "parameters": { - "id": 1222, + "id": 11505, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1219, + "id": 11502, "name": "account", "nodeType": "VariableDeclaration", - "scope": 1260, - "src": "5786:15:8", + "scope": 11543, + "src": "5977:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -9333,10 +9589,10 @@ "typeString": "address" }, "typeName": { - "id": 1218, + "id": 11501, "name": "address", "nodeType": "ElementaryTypeName", - "src": "5786:7:8", + "src": "5977:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -9348,11 +9604,11 @@ }, { "constant": false, - "id": 1221, + "id": 11504, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1260, - "src": "5803:14:8", + "scope": 11543, + "src": "5994:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -9360,10 +9616,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1220, + "id": 11503, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "5803:7:8", + "src": "5994:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -9373,25 +9629,25 @@ "visibility": "internal" } ], - "src": "5785:33:8" + "src": "5976:33:58" }, "returnParameters": { - "id": 1223, + "id": 11506, "nodeType": "ParameterList", "parameters": [], - "src": "5828:0:8" + "src": "6019:0:58" }, - "scope": 1374, - "src": "5771:302:8", + "scope": 11659, + "src": "5962:302:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 1302, + "id": 11586, "nodeType": "Block", - "src": "6448:244:8", + "src": "6641:285:58", "statements": [ { "expression": { @@ -9403,19 +9659,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1272, + "id": 11555, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1268, + "id": 11551, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1262, - "src": "6466:7:8", + "referencedDeclaration": 11545, + "src": "6659:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -9429,14 +9685,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1270, + "id": 11553, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "6485:1:8", + "src": "6678:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -9452,20 +9708,20 @@ "typeString": "int_const 0" } ], - "id": 1269, + "id": 11552, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "6477:7:8", + "src": "6670:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1271, + "id": 11554, "isConstant": false, "isLValue": false, "isPure": true, @@ -9473,13 +9729,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6477:10:8", + "src": "6670:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "6466:21:8", + "src": "6659:21:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -9488,14 +9744,14 @@ { "argumentTypes": null, "hexValue": "45524332303a206275726e2066726f6d20746865207a65726f2061646472657373", - "id": 1273, + "id": 11556, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "6489:35:8", + "src": "6682:35:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_b16788493b576042bb52c50ed56189e0b250db113c7bfb1c3897d25cf9632d7f", @@ -9515,21 +9771,21 @@ "typeString": "literal_string \"ERC20: burn from the zero address\"" } ], - "id": 1267, + "id": 11550, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "6458:7:8", + "referencedDeclaration": 12132, + "src": "6651:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1274, + "id": 11557, "isConstant": false, "isLValue": false, "isPure": false, @@ -9537,32 +9793,59 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6458:67:8", + "src": "6651:67:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1275, + "id": 11558, "nodeType": "ExpressionStatement", - "src": "6458:67:8" + "src": "6651:67:58" }, { "expression": { "argumentTypes": null, - "id": 1281, + "id": 11569, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 1276, - "name": "_totalSupply", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 998, - "src": "6536:12:8", + "baseExpression": { + "argumentTypes": null, + "id": 11559, + "name": "_balances", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11270, + "src": "6729:9:58", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 11561, + "indexExpression": { + "argumentTypes": null, + "id": 11560, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11545, + "src": "6739:7:58", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "6729:18:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -9575,16 +9858,34 @@ "arguments": [ { "argumentTypes": null, - "id": 1279, - "name": "value", + "id": 11566, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1264, - "src": "6568:5:8", + "referencedDeclaration": 11547, + "src": "6773:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } + }, + { + "argumentTypes": null, + "hexValue": "45524332303a206275726e20616d6f756e7420657863656564732062616c616e6365", + "id": 11567, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6781:36:58", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_149b126e7125232b4200af45303d04fba8b74653b1a295a6a561a528c33fefdd", + "typeString": "literal_string \"ERC20: burn amount exceeds balance\"" + }, + "value": "ERC20: burn amount exceeds balance" } ], "expression": { @@ -9592,36 +9893,67 @@ { "typeIdentifier": "t_uint256", "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_149b126e7125232b4200af45303d04fba8b74653b1a295a6a561a528c33fefdd", + "typeString": "literal_string \"ERC20: burn amount exceeds balance\"" } ], "expression": { "argumentTypes": null, - "id": 1277, - "name": "_totalSupply", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 998, - "src": "6551:12:8", + "baseExpression": { + "argumentTypes": null, + "id": 11562, + "name": "_balances", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11270, + "src": "6750:9:58", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 11564, + "indexExpression": { + "argumentTypes": null, + "id": 11563, + "name": "account", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11545, + "src": "6760:7:58", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "6750:18:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1278, + "id": 11565, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "6551:16:8", + "referencedDeclaration": 11023, + "src": "6750:22:58", "typeDescriptions": { - "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", - "typeString": "function (uint256,uint256) pure returns (uint256)" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 1280, + "id": 11568, "isConstant": false, "isLValue": false, "isPure": false, @@ -9629,65 +9961,38 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6551:23:8", + "src": "6750:68:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "6536:38:8", + "src": "6729:89:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1282, + "id": 11570, "nodeType": "ExpressionStatement", - "src": "6536:38:8" + "src": "6729:89:58" }, { "expression": { "argumentTypes": null, - "id": 1292, + "id": 11576, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "baseExpression": { - "argumentTypes": null, - "id": 1283, - "name": "_balances", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "6584:9:8", - "typeDescriptions": { - "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", - "typeString": "mapping(address => uint256)" - } - }, - "id": 1285, - "indexExpression": { - "argumentTypes": null, - "id": 1284, - "name": "account", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 1262, - "src": "6594:7:8", - "typeDescriptions": { - "typeIdentifier": "t_address", - "typeString": "address" - } - }, - "isConstant": false, - "isLValue": true, - "isPure": false, - "lValueRequested": true, - "nodeType": "IndexAccess", - "src": "6584:18:8", + "id": 11571, + "name": "_totalSupply", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11278, + "src": "6828:12:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -9700,12 +10005,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1290, - "name": "value", + "id": 11574, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1264, - "src": "6628:5:8", + "referencedDeclaration": 11547, + "src": "6860:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -9721,59 +10026,32 @@ ], "expression": { "argumentTypes": null, - "baseExpression": { - "argumentTypes": null, - "id": 1286, - "name": "_balances", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 990, - "src": "6605:9:8", - "typeDescriptions": { - "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", - "typeString": "mapping(address => uint256)" - } - }, - "id": 1288, - "indexExpression": { - "argumentTypes": null, - "id": 1287, - "name": "account", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 1262, - "src": "6615:7:8", - "typeDescriptions": { - "typeIdentifier": "t_address", - "typeString": "address" - } - }, - "isConstant": false, - "isLValue": true, - "isPure": false, - "lValueRequested": false, - "nodeType": "IndexAccess", - "src": "6605:18:8", + "id": 11572, + "name": "_totalSupply", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11278, + "src": "6843:12:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1289, + "id": 11573, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "6605:22:8", + "referencedDeclaration": 10996, + "src": "6843:16:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", "typeString": "function (uint256,uint256) pure returns (uint256)" } }, - "id": 1291, + "id": 11575, "isConstant": false, "isLValue": false, "isPure": false, @@ -9781,21 +10059,21 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6605:29:8", + "src": "6843:24:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "6584:50:8", + "src": "6828:39:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1293, + "id": 11577, "nodeType": "ExpressionStatement", - "src": "6584:50:8" + "src": "6828:39:58" }, { "eventCall": { @@ -9803,12 +10081,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1295, + "id": 11579, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1262, - "src": "6658:7:8", + "referencedDeclaration": 11545, + "src": "6891:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -9820,14 +10098,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1297, + "id": 11581, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "6675:1:8", + "src": "6908:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -9843,20 +10121,20 @@ "typeString": "int_const 0" } ], - "id": 1296, + "id": 11580, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "6667:7:8", + "src": "6900:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1298, + "id": 11582, "isConstant": false, "isLValue": false, "isPure": true, @@ -9864,7 +10142,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6667:10:8", + "src": "6900:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -9872,12 +10150,12 @@ }, { "argumentTypes": null, - "id": 1299, - "name": "value", + "id": 11583, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1264, - "src": "6679:5:8", + "referencedDeclaration": 11547, + "src": "6912:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -9899,18 +10177,18 @@ "typeString": "uint256" } ], - "id": 1294, + "id": 11578, "name": "Transfer", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1434, - "src": "6649:8:8", + "referencedDeclaration": 11777, + "src": "6882:8:58", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1300, + "id": 11584, "isConstant": false, "isLValue": false, "isPure": false, @@ -9918,36 +10196,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "6649:36:8", + "src": "6882:37:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1301, + "id": 11585, "nodeType": "EmitStatement", - "src": "6644:41:8" + "src": "6877:42:58" } ] }, - "documentation": "@dev Destoys `amount` tokens from `account`, reducing the\ntotal supply.\n * Emits a `Transfer` event with `to` set to the zero address.\n * Requirements\n * - `account` cannot be the zero address.\n- `account` must have at least `amount` tokens.", - "id": 1303, + "documentation": "@dev Destroys `amount` tokens from `account`, reducing the\ntotal supply.\n * Emits a {Transfer} event with `to` set to the zero address.\n * Requirements\n * - `account` cannot be the zero address.\n- `account` must have at least `amount` tokens.", + "id": 11587, "implemented": true, "kind": "function", "modifiers": [], "name": "_burn", "nodeType": "FunctionDefinition", "parameters": { - "id": 1265, + "id": 11548, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1262, + "id": 11545, "name": "account", "nodeType": "VariableDeclaration", - "scope": 1303, - "src": "6407:15:8", + "scope": 11587, + "src": "6599:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -9955,10 +10233,10 @@ "typeString": "address" }, "typeName": { - "id": 1261, + "id": 11544, "name": "address", "nodeType": "ElementaryTypeName", - "src": "6407:7:8", + "src": "6599:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -9970,11 +10248,11 @@ }, { "constant": false, - "id": 1264, - "name": "value", + "id": 11547, + "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1303, - "src": "6424:13:8", + "scope": 11587, + "src": "6616:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -9982,10 +10260,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1263, + "id": 11546, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "6424:7:8", + "src": "6616:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -9995,25 +10273,25 @@ "visibility": "internal" } ], - "src": "6406:32:8" + "src": "6598:33:58" }, "returnParameters": { - "id": 1266, + "id": 11549, "nodeType": "ParameterList", "parameters": [], - "src": "6448:0:8" + "src": "6641:0:58" }, - "scope": 1374, - "src": "6392:300:8", + "scope": 11659, + "src": "6584:342:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 1344, + "id": 11628, "nodeType": "Block", - "src": "7191:255:8", + "src": "7426:257:58", "statements": [ { "expression": { @@ -10025,19 +10303,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1317, + "id": 11601, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1313, + "id": 11597, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1305, - "src": "7209:5:8", + "referencedDeclaration": 11589, + "src": "7444:5:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -10051,14 +10329,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1315, + "id": 11599, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "7226:1:8", + "src": "7461:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -10074,20 +10352,20 @@ "typeString": "int_const 0" } ], - "id": 1314, + "id": 11598, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "7218:7:8", + "src": "7453:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1316, + "id": 11600, "isConstant": false, "isLValue": false, "isPure": true, @@ -10095,13 +10373,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7218:10:8", + "src": "7453:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "7209:19:8", + "src": "7444:19:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -10110,14 +10388,14 @@ { "argumentTypes": null, "hexValue": "45524332303a20617070726f76652066726f6d20746865207a65726f2061646472657373", - "id": 1318, + "id": 11602, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "7230:38:8", + "src": "7465:38:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_c953f4879035ed60e766b34720f656aab5c697b141d924c283124ecedb91c208", @@ -10137,21 +10415,21 @@ "typeString": "literal_string \"ERC20: approve from the zero address\"" } ], - "id": 1312, + "id": 11596, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "7201:7:8", + "referencedDeclaration": 12132, + "src": "7436:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1319, + "id": 11603, "isConstant": false, "isLValue": false, "isPure": false, @@ -10159,15 +10437,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7201:68:8", + "src": "7436:68:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1320, + "id": 11604, "nodeType": "ExpressionStatement", - "src": "7201:68:8" + "src": "7436:68:58" }, { "expression": { @@ -10179,19 +10457,19 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 1326, + "id": 11610, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 1322, + "id": 11606, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1307, - "src": "7287:7:8", + "referencedDeclaration": 11591, + "src": "7522:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -10205,14 +10483,14 @@ { "argumentTypes": null, "hexValue": "30", - "id": 1324, + "id": 11608, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "7306:1:8", + "src": "7541:1:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -10228,20 +10506,20 @@ "typeString": "int_const 0" } ], - "id": 1323, + "id": 11607, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "7298:7:8", + "src": "7533:7:58", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 1325, + "id": 11609, "isConstant": false, "isLValue": false, "isPure": true, @@ -10249,13 +10527,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7298:10:8", + "src": "7533:10:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "7287:21:8", + "src": "7522:21:58", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -10264,14 +10542,14 @@ { "argumentTypes": null, "hexValue": "45524332303a20617070726f766520746f20746865207a65726f2061646472657373", - "id": 1327, + "id": 11611, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "7310:36:8", + "src": "7545:36:58", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_24883cc5fe64ace9d0df1893501ecb93c77180f0ff69cca79affb3c316dc8029", @@ -10291,21 +10569,21 @@ "typeString": "literal_string \"ERC20: approve to the zero address\"" } ], - "id": 1321, + "id": 11605, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "7279:7:8", + "referencedDeclaration": 12132, + "src": "7514:7:58", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 1328, + "id": 11612, "isConstant": false, "isLValue": false, "isPure": false, @@ -10313,20 +10591,20 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7279:68:8", + "src": "7514:68:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1329, + "id": 11613, "nodeType": "ExpressionStatement", - "src": "7279:68:8" + "src": "7514:68:58" }, { "expression": { "argumentTypes": null, - "id": 1336, + "id": 11620, "isConstant": false, "isLValue": false, "isPure": false, @@ -10337,26 +10615,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1330, + "id": 11614, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "7358:11:8", + "referencedDeclaration": 11276, + "src": "7593:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1333, + "id": 11617, "indexExpression": { "argumentTypes": null, - "id": 1331, + "id": 11615, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1305, - "src": "7370:5:8", + "referencedDeclaration": 11589, + "src": "7605:5:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -10367,21 +10645,21 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "7358:18:8", + "src": "7593:18:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1334, + "id": 11618, "indexExpression": { "argumentTypes": null, - "id": 1332, + "id": 11616, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1307, - "src": "7377:7:8", + "referencedDeclaration": 11591, + "src": "7612:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -10392,7 +10670,7 @@ "isPure": false, "lValueRequested": true, "nodeType": "IndexAccess", - "src": "7358:27:8", + "src": "7593:27:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -10402,26 +10680,26 @@ "operator": "=", "rightHandSide": { "argumentTypes": null, - "id": 1335, - "name": "value", + "id": 11619, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1309, - "src": "7388:5:8", + "referencedDeclaration": 11593, + "src": "7623:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "7358:35:8", + "src": "7593:36:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1337, + "id": 11621, "nodeType": "ExpressionStatement", - "src": "7358:35:8" + "src": "7593:36:58" }, { "eventCall": { @@ -10429,12 +10707,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1339, + "id": 11623, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1305, - "src": "7417:5:8", + "referencedDeclaration": 11589, + "src": "7653:5:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -10442,12 +10720,12 @@ }, { "argumentTypes": null, - "id": 1340, + "id": 11624, "name": "spender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1307, - "src": "7424:7:8", + "referencedDeclaration": 11591, + "src": "7660:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -10455,12 +10733,12 @@ }, { "argumentTypes": null, - "id": 1341, - "name": "value", + "id": 11625, + "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1309, - "src": "7433:5:8", + "referencedDeclaration": 11593, + "src": "7669:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -10482,18 +10760,18 @@ "typeString": "uint256" } ], - "id": 1338, + "id": 11622, "name": "Approval", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1442, - "src": "7408:8:8", + "referencedDeclaration": 11785, + "src": "7644:8:58", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1342, + "id": 11626, "isConstant": false, "isLValue": false, "isPure": false, @@ -10501,36 +10779,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7408:31:8", + "src": "7644:32:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1343, + "id": 11627, "nodeType": "EmitStatement", - "src": "7403:36:8" + "src": "7639:37:58" } ] }, - "documentation": "@dev Sets `amount` as the allowance of `spender` over the `owner`s tokens.\n * This is internal function is equivalent to `approve`, and can be used to\ne.g. set automatic allowances for certain subsystems, etc.\n * Emits an `Approval` event.\n * Requirements:\n * - `owner` cannot be the zero address.\n- `spender` cannot be the zero address.", - "id": 1345, + "documentation": "@dev Sets `amount` as the allowance of `spender` over the `owner`s tokens.\n * This is internal function is equivalent to `approve`, and can be used to\ne.g. set automatic allowances for certain subsystems, etc.\n * Emits an {Approval} event.\n * Requirements:\n * - `owner` cannot be the zero address.\n- `spender` cannot be the zero address.", + "id": 11629, "implemented": true, "kind": "function", "modifiers": [], "name": "_approve", "nodeType": "FunctionDefinition", "parameters": { - "id": 1310, + "id": 11594, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1305, + "id": 11589, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 1345, - "src": "7135:13:8", + "scope": 11629, + "src": "7369:13:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -10538,10 +10816,10 @@ "typeString": "address" }, "typeName": { - "id": 1304, + "id": 11588, "name": "address", "nodeType": "ElementaryTypeName", - "src": "7135:7:8", + "src": "7369:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -10553,11 +10831,11 @@ }, { "constant": false, - "id": 1307, + "id": 11591, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1345, - "src": "7150:15:8", + "scope": 11629, + "src": "7384:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -10565,10 +10843,10 @@ "typeString": "address" }, "typeName": { - "id": 1306, + "id": 11590, "name": "address", "nodeType": "ElementaryTypeName", - "src": "7150:7:8", + "src": "7384:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -10580,11 +10858,11 @@ }, { "constant": false, - "id": 1309, - "name": "value", + "id": 11593, + "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1345, - "src": "7167:13:8", + "scope": 11629, + "src": "7401:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -10592,10 +10870,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1308, + "id": 11592, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "7167:7:8", + "src": "7401:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -10605,25 +10883,25 @@ "visibility": "internal" } ], - "src": "7134:47:8" + "src": "7368:48:58" }, "returnParameters": { - "id": 1311, + "id": 11595, "nodeType": "ParameterList", "parameters": [], - "src": "7191:0:8" + "src": "7426:0:58" }, - "scope": 1374, - "src": "7117:329:8", + "scope": 11659, + "src": "7351:332:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 1372, + "id": 11657, "nodeType": "Block", - "src": "7684:124:8", + "src": "7922:168:58", "statements": [ { "expression": { @@ -10631,12 +10909,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1353, + "id": 11637, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1347, - "src": "7700:7:8", + "referencedDeclaration": 11631, + "src": "7938:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -10644,12 +10922,12 @@ }, { "argumentTypes": null, - "id": 1354, + "id": 11638, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1349, - "src": "7709:6:8", + "referencedDeclaration": 11633, + "src": "7947:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -10667,18 +10945,18 @@ "typeString": "uint256" } ], - "id": 1352, + "id": 11636, "name": "_burn", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1303, - "src": "7694:5:8", + "referencedDeclaration": 11587, + "src": "7932:5:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,uint256)" } }, - "id": 1355, + "id": 11639, "isConstant": false, "isLValue": false, "isPure": false, @@ -10686,15 +10964,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7694:22:8", + "src": "7932:22:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1356, + "id": 11640, "nodeType": "ExpressionStatement", - "src": "7694:22:8" + "src": "7932:22:58" }, { "expression": { @@ -10702,12 +10980,12 @@ "arguments": [ { "argumentTypes": null, - "id": 1358, + "id": 11642, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1347, - "src": "7735:7:8", + "referencedDeclaration": 11631, + "src": "7973:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -10715,28 +10993,29 @@ }, { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1359, - "name": "msg", + "argumentTypes": [], + "id": 11643, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "7744:3:8", + "referencedDeclaration": 10941, + "src": "7982:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1360, + "id": 11644, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "7744:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "7982:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -10747,16 +11026,34 @@ "arguments": [ { "argumentTypes": null, - "id": 1368, + "id": 11652, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1349, - "src": "7793:6:8", + "referencedDeclaration": 11633, + "src": "8035:6:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } + }, + { + "argumentTypes": null, + "hexValue": "45524332303a206275726e20616d6f756e74206578636565647320616c6c6f77616e6365", + "id": 11653, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8043:38:58", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a287c363786607a1457a2d9d12fa61c0073358e02d76b4035fc2c2d86a19c0db", + "typeString": "literal_string \"ERC20: burn amount exceeds allowance\"" + }, + "value": "ERC20: burn amount exceeds allowance" } ], "expression": { @@ -10764,6 +11061,10 @@ { "typeIdentifier": "t_uint256", "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_a287c363786607a1457a2d9d12fa61c0073358e02d76b4035fc2c2d86a19c0db", + "typeString": "literal_string \"ERC20: burn amount exceeds allowance\"" } ], "expression": { @@ -10772,26 +11073,26 @@ "argumentTypes": null, "baseExpression": { "argumentTypes": null, - "id": 1361, + "id": 11645, "name": "_allowances", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 996, - "src": "7756:11:8", + "referencedDeclaration": 11276, + "src": "7996:11:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_uint256_$_$", "typeString": "mapping(address => mapping(address => uint256))" } }, - "id": 1363, + "id": 11647, "indexExpression": { "argumentTypes": null, - "id": 1362, + "id": 11646, "name": "account", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1347, - "src": "7768:7:8", + "referencedDeclaration": 11631, + "src": "8008:7:58", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -10802,37 +11103,38 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "7756:20:8", + "src": "7996:20:58", "typeDescriptions": { "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", "typeString": "mapping(address => uint256)" } }, - "id": 1366, + "id": 11650, "indexExpression": { "argumentTypes": null, + "arguments": [], "expression": { - "argumentTypes": null, - "id": 1364, - "name": "msg", + "argumentTypes": [], + "id": 11648, + "name": "_msgSender", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "7777:3:8", + "referencedDeclaration": 10941, + "src": "8017:10:58", "typeDescriptions": { - "typeIdentifier": "t_magic_message", - "typeString": "msg" + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" } }, - "id": 1365, + "id": 11649, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "memberName": "sender", - "nodeType": "MemberAccess", - "referencedDeclaration": null, - "src": "7777:10:8", + "names": [], + "nodeType": "FunctionCall", + "src": "8017:12:58", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -10843,27 +11145,27 @@ "isPure": false, "lValueRequested": false, "nodeType": "IndexAccess", - "src": "7756:32:8", + "src": "7996:34:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 1367, + "id": 11651, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "sub", "nodeType": "MemberAccess", - "referencedDeclaration": 896, - "src": "7756:36:8", + "referencedDeclaration": 11023, + "src": "7996:38:58", "typeDescriptions": { - "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", - "typeString": "function (uint256,uint256) pure returns (uint256)" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 1369, + "id": 11654, "isConstant": false, "isLValue": false, "isPure": false, @@ -10871,7 +11173,7 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7756:44:8", + "src": "7996:86:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -10893,18 +11195,18 @@ "typeString": "uint256" } ], - "id": 1357, + "id": 11641, "name": "_approve", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1345, - "src": "7726:8:8", + "referencedDeclaration": 11629, + "src": "7964:8:58", "typeDescriptions": { "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", "typeString": "function (address,address,uint256)" } }, - "id": 1370, + "id": 11655, "isConstant": false, "isLValue": false, "isPure": false, @@ -10912,36 +11214,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "7726:75:8", + "src": "7964:119:58", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 1371, + "id": 11656, "nodeType": "ExpressionStatement", - "src": "7726:75:8" + "src": "7964:119:58" } ] }, - "documentation": "@dev Destoys `amount` tokens from `account`.`amount` is then deducted\nfrom the caller's allowance.\n * See `_burn` and `_approve`.", - "id": 1373, + "documentation": "@dev Destroys `amount` tokens from `account`.`amount` is then deducted\nfrom the caller's allowance.\n * See {_burn} and {_approve}.", + "id": 11658, "implemented": true, "kind": "function", "modifiers": [], "name": "_burnFrom", "nodeType": "FunctionDefinition", "parameters": { - "id": 1350, + "id": 11634, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1347, + "id": 11631, "name": "account", "nodeType": "VariableDeclaration", - "scope": 1373, - "src": "7642:15:8", + "scope": 11658, + "src": "7880:15:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -10949,10 +11251,10 @@ "typeString": "address" }, "typeName": { - "id": 1346, + "id": 11630, "name": "address", "nodeType": "ElementaryTypeName", - "src": "7642:7:8", + "src": "7880:7:58", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -10964,11 +11266,11 @@ }, { "constant": false, - "id": 1349, + "id": 11633, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1373, - "src": "7659:14:8", + "scope": 11658, + "src": "7897:14:58", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -10976,10 +11278,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1348, + "id": 11632, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "7659:7:8", + "src": "7897:7:58", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -10989,26 +11291,26 @@ "visibility": "internal" } ], - "src": "7641:33:8" + "src": "7879:33:58" }, "returnParameters": { - "id": 1351, + "id": 11635, "nodeType": "ParameterList", "parameters": [], - "src": "7684:0:8" + "src": "7922:0:58" }, - "scope": 1374, - "src": "7623:185:8", + "scope": 11659, + "src": "7861:229:58", "stateMutability": "nonpayable", "superFunction": null, "visibility": "internal" } ], - "scope": 1375, - "src": "1232:6578:8" + "scope": 11660, + "src": "1268:6824:58" } ], - "src": "0:7811:8" + "src": "0:8093:58" }, "compiler": { "name": "solc", @@ -11016,33 +11318,33 @@ }, "networks": {}, "schemaVersion": "3.0.16", - "updatedAt": "2019-11-04T18:56:07.494Z", + "updatedAt": "2019-11-07T14:57:54.936Z", "devdoc": { - "details": "Implementation of the `IERC20` interface. * This implementation is agnostic to the way tokens are created. This means that a supply mechanism has to be added in a derived contract using `_mint`. For a generic mechanism see `ERC20Mintable`. * *For a detailed writeup see our guide [How to implement supply mechanisms](https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226).* * We have followed general OpenZeppelin guidelines: functions revert instead of returning `false` on failure. This behavior is nonetheless conventional and does not conflict with the expectations of ERC20 applications. * Additionally, an `Approval` event is emitted on calls to `transferFrom`. This allows applications to reconstruct the allowance for all accounts just by listening to said events. Other implementations of the EIP may not emit these events, as it isn't required by the specification. * Finally, the non-standard `decreaseAllowance` and `increaseAllowance` functions have been added to mitigate the well-known issues around setting allowances. See `IERC20.approve`.", + "details": "Implementation of the {IERC20} interface. * This implementation is agnostic to the way tokens are created. This means that a supply mechanism has to be added in a derived contract using {_mint}. For a generic mechanism see {ERC20Mintable}. * TIP: For a detailed writeup see our guide https://forum.zeppelin.solutions/t/how-to-implement-erc20-supply-mechanisms/226[How to implement supply mechanisms]. * We have followed general OpenZeppelin guidelines: functions revert instead of returning `false` on failure. This behavior is nonetheless conventional and does not conflict with the expectations of ERC20 applications. * Additionally, an {Approval} event is emitted on calls to {transferFrom}. This allows applications to reconstruct the allowance for all accounts just by listening to said events. Other implementations of the EIP may not emit these events, as it isn't required by the specification. * Finally, the non-standard {decreaseAllowance} and {increaseAllowance} functions have been added to mitigate the well-known issues around setting allowances. See {IERC20-approve}.", "methods": { "allowance(address,address)": { - "details": "See `IERC20.allowance`." + "details": "See {IERC20-allowance}." }, "approve(address,uint256)": { - "details": "See `IERC20.approve`. * Requirements: * - `spender` cannot be the zero address." + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." }, "balanceOf(address)": { - "details": "See `IERC20.balanceOf`." + "details": "See {IERC20-balanceOf}." }, "decreaseAllowance(address,uint256)": { - "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to `approve` that can be used as a mitigation for problems described in `IERC20.approve`. * Emits an `Approval` event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." }, "increaseAllowance(address,uint256)": { - "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to `approve` that can be used as a mitigation for problems described in `IERC20.approve`. * Emits an `Approval` event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." }, "totalSupply()": { - "details": "See `IERC20.totalSupply`." + "details": "See {IERC20-totalSupply}." }, "transfer(address,uint256)": { - "details": "See `IERC20.transfer`. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." }, "transferFrom(address,address,uint256)": { - "details": "See `IERC20.transferFrom`. * Emits an `Approval` event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of `ERC20`; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `value`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." } } }, diff --git a/client/src/contracts/ERC20Detailed.json b/client/src/contracts/ERC20Detailed.json new file mode 100644 index 0000000..8d5556f --- /dev/null +++ b/client/src/contracts/ERC20Detailed.json @@ -0,0 +1,1569 @@ +{ + "contractName": "ERC20Detailed", + "abi": [ + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "name": "name", + "type": "string" + }, + { + "name": "symbol", + "type": "string" + }, + { + "name": "decimals", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint8\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"name\",\"type\":\"string\"},{\"name\":\"symbol\",\"type\":\"string\"},{\"name\":\"decimals\",\"type\":\"uint8\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"details\":\"Optional functions from the ERC20 standard.\",\"methods\":{\"allowance(address,address)\":{\"details\":\"Returns the remaining number of tokens that `spender` will be allowed to spend on behalf of `owner` through {transferFrom}. This is zero by default. * This value changes when {approve} or {transferFrom} are called.\"},\"approve(address,uint256)\":{\"details\":\"Sets `amount` as the allowance of `spender` over the caller's tokens. * Returns a boolean value indicating whether the operation succeeded. * IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * Emits an {Approval} event.\"},\"balanceOf(address)\":{\"details\":\"Returns the amount of tokens owned by `account`.\"},\"constructor\":{\"details\":\"Sets the values for `name`, `symbol`, and `decimals`. All three of these values are immutable: they can only be set once during construction.\"},\"decimals()\":{\"details\":\"Returns the number of decimals used to get its user representation. For example, if `decimals` equals `2`, a balance of `505` tokens should be displayed to a user as `5,05` (`505 / 10 ** 2`). * Tokens usually opt for a value of 18, imitating the relationship between Ether and Wei. * NOTE: This information is only used for _display_ purposes: it in no way affects any of the arithmetic of the contract, including {IERC20-balanceOf} and {IERC20-transfer}.\"},\"name()\":{\"details\":\"Returns the name of the token.\"},\"symbol()\":{\"details\":\"Returns the symbol of the token, usually a shorter version of the name.\"},\"totalSupply()\":{\"details\":\"Returns the amount of tokens in existence.\"},\"transfer(address,uint256)\":{\"details\":\"Moves `amount` tokens from the caller's account to `recipient`. * Returns a boolean value indicating whether the operation succeeded. * Emits a {Transfer} event.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"Moves `amount` tokens from `sender` to `recipient` using the allowance mechanism. `amount` is then deducted from the caller's allowance. * Returns a boolean value indicating whether the operation succeeded. * Emits a {Transfer} event.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol\":\"ERC20Detailed\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol\":{\"keccak256\":\"0x4a3a810b7ebe742e897e1fd428b3eeed2196d3acea58eaf9c566ed10d545d2ed\",\"urls\":[\"bzzr://729aefb3f89f616c954a0735f8b4dd8804bdd0351e96f8e904fdb3e78a109b6c\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\nimport \"./IERC20.sol\";\n\n/**\n * @dev Optional functions from the ERC20 standard.\n */\ncontract ERC20Detailed is IERC20 {\n string private _name;\n string private _symbol;\n uint8 private _decimals;\n\n /**\n * @dev Sets the values for `name`, `symbol`, and `decimals`. All three of\n * these values are immutable: they can only be set once during\n * construction.\n */\n constructor (string memory name, string memory symbol, uint8 decimals) public {\n _name = name;\n _symbol = symbol;\n _decimals = decimals;\n }\n\n /**\n * @dev Returns the name of the token.\n */\n function name() public view returns (string memory) {\n return _name;\n }\n\n /**\n * @dev Returns the symbol of the token, usually a shorter version of the\n * name.\n */\n function symbol() public view returns (string memory) {\n return _symbol;\n }\n\n /**\n * @dev Returns the number of decimals used to get its user representation.\n * For example, if `decimals` equals `2`, a balance of `505` tokens should\n * be displayed to a user as `5,05` (`505 / 10 ** 2`).\n *\n * Tokens usually opt for a value of 18, imitating the relationship between\n * Ether and Wei.\n *\n * NOTE: This information is only used for _display_ purposes: it in\n * no way affects any of the arithmetic of the contract, including\n * {IERC20-balanceOf} and {IERC20-transfer}.\n */\n function decimals() public view returns (uint8) {\n return _decimals;\n }\n}\n", + "sourcePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "ast": { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "exportedSymbols": { + "ERC20Detailed": [ + 11717 + ] + }, + "id": 11718, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 11661, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:59" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "./IERC20.sol", + "id": 11662, + "nodeType": "ImportDirective", + "scope": 11718, + "sourceUnit": 11787, + "src": "25:22:59", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 11663, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "135:6:59", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11664, + "nodeType": "InheritanceSpecifier", + "src": "135:6:59" + } + ], + "contractDependencies": [ + 11786 + ], + "contractKind": "contract", + "documentation": "@dev Optional functions from the ERC20 standard.", + "fullyImplemented": false, + "id": 11717, + "linearizedBaseContracts": [ + 11717, + 11786 + ], + "name": "ERC20Detailed", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 11666, + "name": "_name", + "nodeType": "VariableDeclaration", + "scope": 11717, + "src": "148:20:59", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 11665, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "148:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "private" + }, + { + "constant": false, + "id": 11668, + "name": "_symbol", + "nodeType": "VariableDeclaration", + "scope": 11717, + "src": "174:22:59", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 11667, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "174:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "private" + }, + { + "constant": false, + "id": 11670, + "name": "_decimals", + "nodeType": "VariableDeclaration", + "scope": 11717, + "src": "202:23:59", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + }, + "typeName": { + "id": 11669, + "name": "uint8", + "nodeType": "ElementaryTypeName", + "src": "202:5:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "value": null, + "visibility": "private" + }, + { + "body": { + "id": 11691, + "nodeType": "Block", + "src": "494:85:59", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11681, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11679, + "name": "_name", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11666, + "src": "504:5:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 11680, + "name": "name", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11672, + "src": "512:4:59", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + "src": "504:12:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "id": 11682, + "nodeType": "ExpressionStatement", + "src": "504:12:59" + }, + { + "expression": { + "argumentTypes": null, + "id": 11685, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11683, + "name": "_symbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11668, + "src": "526:7:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 11684, + "name": "symbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11674, + "src": "536:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + "src": "526:16:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "id": 11686, + "nodeType": "ExpressionStatement", + "src": "526:16:59" + }, + { + "expression": { + "argumentTypes": null, + "id": 11689, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11687, + "name": "_decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11670, + "src": "552:9:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 11688, + "name": "decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11676, + "src": "564:8:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "src": "552:20:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "id": 11690, + "nodeType": "ExpressionStatement", + "src": "552:20:59" + } + ] + }, + "documentation": "@dev Sets the values for `name`, `symbol`, and `decimals`. All three of\nthese values are immutable: they can only be set once during\nconstruction.", + "id": 11692, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11677, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11672, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 11692, + "src": "429:18:59", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11671, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "429:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11674, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 11692, + "src": "449:20:59", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11673, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "449:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11676, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 11692, + "src": "471:14:59", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + }, + "typeName": { + "id": 11675, + "name": "uint8", + "nodeType": "ElementaryTypeName", + "src": "471:5:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "428:58:59" + }, + "returnParameters": { + "id": 11678, + "nodeType": "ParameterList", + "parameters": [], + "src": "494:0:59" + }, + "scope": 11717, + "src": "416:163:59", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11699, + "nodeType": "Block", + "src": "696:29:59", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11697, + "name": "_name", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11666, + "src": "713:5:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "functionReturnParameters": 11696, + "id": 11698, + "nodeType": "Return", + "src": "706:12:59" + } + ] + }, + "documentation": "@dev Returns the name of the token.", + "id": 11700, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "name", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11693, + "nodeType": "ParameterList", + "parameters": [], + "src": "657:2:59" + }, + "returnParameters": { + "id": 11696, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11695, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11700, + "src": "681:13:59", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11694, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "681:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "680:15:59" + }, + "scope": 11717, + "src": "644:81:59", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11707, + "nodeType": "Block", + "src": "892:31:59", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11705, + "name": "_symbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11668, + "src": "909:7:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "functionReturnParameters": 11704, + "id": 11706, + "nodeType": "Return", + "src": "902:14:59" + } + ] + }, + "documentation": "@dev Returns the symbol of the token, usually a shorter version of the\nname.", + "id": 11708, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "symbol", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11701, + "nodeType": "ParameterList", + "parameters": [], + "src": "853:2:59" + }, + "returnParameters": { + "id": 11704, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11703, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11708, + "src": "877:13:59", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11702, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "877:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "876:15:59" + }, + "scope": 11717, + "src": "838:85:59", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11715, + "nodeType": "Block", + "src": "1520:33:59", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11713, + "name": "_decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11670, + "src": "1537:9:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "functionReturnParameters": 11712, + "id": 11714, + "nodeType": "Return", + "src": "1530:16:59" + } + ] + }, + "documentation": "@dev Returns the number of decimals used to get its user representation.\nFor example, if `decimals` equals `2`, a balance of `505` tokens should\nbe displayed to a user as `5,05` (`505 / 10 ** 2`).\n * Tokens usually opt for a value of 18, imitating the relationship between\nEther and Wei.\n * NOTE: This information is only used for _display_ purposes: it in\nno way affects any of the arithmetic of the contract, including\n{IERC20-balanceOf} and {IERC20-transfer}.", + "id": 11716, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "decimals", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11709, + "nodeType": "ParameterList", + "parameters": [], + "src": "1489:2:59" + }, + "returnParameters": { + "id": 11712, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11711, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11716, + "src": "1513:5:59", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + }, + "typeName": { + "id": 11710, + "name": "uint8", + "nodeType": "ElementaryTypeName", + "src": "1513:5:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1512:7:59" + }, + "scope": 11717, + "src": "1472:81:59", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + } + ], + "scope": 11718, + "src": "109:1446:59" + } + ], + "src": "0:1556:59" + }, + "legacyAST": { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "exportedSymbols": { + "ERC20Detailed": [ + 11717 + ] + }, + "id": 11718, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 11661, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:59" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "./IERC20.sol", + "id": 11662, + "nodeType": "ImportDirective", + "scope": 11718, + "sourceUnit": 11787, + "src": "25:22:59", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 11663, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "135:6:59", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11664, + "nodeType": "InheritanceSpecifier", + "src": "135:6:59" + } + ], + "contractDependencies": [ + 11786 + ], + "contractKind": "contract", + "documentation": "@dev Optional functions from the ERC20 standard.", + "fullyImplemented": false, + "id": 11717, + "linearizedBaseContracts": [ + 11717, + 11786 + ], + "name": "ERC20Detailed", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 11666, + "name": "_name", + "nodeType": "VariableDeclaration", + "scope": 11717, + "src": "148:20:59", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 11665, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "148:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "private" + }, + { + "constant": false, + "id": 11668, + "name": "_symbol", + "nodeType": "VariableDeclaration", + "scope": 11717, + "src": "174:22:59", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 11667, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "174:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "private" + }, + { + "constant": false, + "id": 11670, + "name": "_decimals", + "nodeType": "VariableDeclaration", + "scope": 11717, + "src": "202:23:59", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + }, + "typeName": { + "id": 11669, + "name": "uint8", + "nodeType": "ElementaryTypeName", + "src": "202:5:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "value": null, + "visibility": "private" + }, + { + "body": { + "id": 11691, + "nodeType": "Block", + "src": "494:85:59", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11681, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11679, + "name": "_name", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11666, + "src": "504:5:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 11680, + "name": "name", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11672, + "src": "512:4:59", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + "src": "504:12:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "id": 11682, + "nodeType": "ExpressionStatement", + "src": "504:12:59" + }, + { + "expression": { + "argumentTypes": null, + "id": 11685, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11683, + "name": "_symbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11668, + "src": "526:7:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 11684, + "name": "symbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11674, + "src": "536:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + "src": "526:16:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "id": 11686, + "nodeType": "ExpressionStatement", + "src": "526:16:59" + }, + { + "expression": { + "argumentTypes": null, + "id": 11689, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11687, + "name": "_decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11670, + "src": "552:9:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 11688, + "name": "decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11676, + "src": "564:8:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "src": "552:20:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "id": 11690, + "nodeType": "ExpressionStatement", + "src": "552:20:59" + } + ] + }, + "documentation": "@dev Sets the values for `name`, `symbol`, and `decimals`. All three of\nthese values are immutable: they can only be set once during\nconstruction.", + "id": 11692, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11677, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11672, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 11692, + "src": "429:18:59", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11671, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "429:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11674, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 11692, + "src": "449:20:59", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11673, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "449:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11676, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 11692, + "src": "471:14:59", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + }, + "typeName": { + "id": 11675, + "name": "uint8", + "nodeType": "ElementaryTypeName", + "src": "471:5:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "428:58:59" + }, + "returnParameters": { + "id": 11678, + "nodeType": "ParameterList", + "parameters": [], + "src": "494:0:59" + }, + "scope": 11717, + "src": "416:163:59", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11699, + "nodeType": "Block", + "src": "696:29:59", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11697, + "name": "_name", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11666, + "src": "713:5:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "functionReturnParameters": 11696, + "id": 11698, + "nodeType": "Return", + "src": "706:12:59" + } + ] + }, + "documentation": "@dev Returns the name of the token.", + "id": 11700, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "name", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11693, + "nodeType": "ParameterList", + "parameters": [], + "src": "657:2:59" + }, + "returnParameters": { + "id": 11696, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11695, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11700, + "src": "681:13:59", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11694, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "681:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "680:15:59" + }, + "scope": 11717, + "src": "644:81:59", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11707, + "nodeType": "Block", + "src": "892:31:59", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11705, + "name": "_symbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11668, + "src": "909:7:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string storage ref" + } + }, + "functionReturnParameters": 11704, + "id": 11706, + "nodeType": "Return", + "src": "902:14:59" + } + ] + }, + "documentation": "@dev Returns the symbol of the token, usually a shorter version of the\nname.", + "id": 11708, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "symbol", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11701, + "nodeType": "ParameterList", + "parameters": [], + "src": "853:2:59" + }, + "returnParameters": { + "id": 11704, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11703, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11708, + "src": "877:13:59", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11702, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "877:6:59", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "876:15:59" + }, + "scope": 11717, + "src": "838:85:59", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11715, + "nodeType": "Block", + "src": "1520:33:59", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11713, + "name": "_decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11670, + "src": "1537:9:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "functionReturnParameters": 11712, + "id": 11714, + "nodeType": "Return", + "src": "1530:16:59" + } + ] + }, + "documentation": "@dev Returns the number of decimals used to get its user representation.\nFor example, if `decimals` equals `2`, a balance of `505` tokens should\nbe displayed to a user as `5,05` (`505 / 10 ** 2`).\n * Tokens usually opt for a value of 18, imitating the relationship between\nEther and Wei.\n * NOTE: This information is only used for _display_ purposes: it in\nno way affects any of the arithmetic of the contract, including\n{IERC20-balanceOf} and {IERC20-transfer}.", + "id": 11716, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "decimals", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11709, + "nodeType": "ParameterList", + "parameters": [], + "src": "1489:2:59" + }, + "returnParameters": { + "id": 11712, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11711, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11716, + "src": "1513:5:59", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + }, + "typeName": { + "id": 11710, + "name": "uint8", + "nodeType": "ElementaryTypeName", + "src": "1513:5:59", + "typeDescriptions": { + "typeIdentifier": "t_uint8", + "typeString": "uint8" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1512:7:59" + }, + "scope": 11717, + "src": "1472:81:59", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + } + ], + "scope": 11718, + "src": "109:1446:59" + } + ], + "src": "0:1556:59" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.946Z", + "devdoc": { + "details": "Optional functions from the ERC20 standard.", + "methods": { + "allowance(address,address)": { + "details": "Returns the remaining number of tokens that `spender` will be allowed to spend on behalf of `owner` through {transferFrom}. This is zero by default. * This value changes when {approve} or {transferFrom} are called." + }, + "approve(address,uint256)": { + "details": "Sets `amount` as the allowance of `spender` over the caller's tokens. * Returns a boolean value indicating whether the operation succeeded. * IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * Emits an {Approval} event." + }, + "balanceOf(address)": { + "details": "Returns the amount of tokens owned by `account`." + }, + "constructor": { + "details": "Sets the values for `name`, `symbol`, and `decimals`. All three of these values are immutable: they can only be set once during construction." + }, + "decimals()": { + "details": "Returns the number of decimals used to get its user representation. For example, if `decimals` equals `2`, a balance of `505` tokens should be displayed to a user as `5,05` (`505 / 10 ** 2`). * Tokens usually opt for a value of 18, imitating the relationship between Ether and Wei. * NOTE: This information is only used for _display_ purposes: it in no way affects any of the arithmetic of the contract, including {IERC20-balanceOf} and {IERC20-transfer}." + }, + "name()": { + "details": "Returns the name of the token." + }, + "symbol()": { + "details": "Returns the symbol of the token, usually a shorter version of the name." + }, + "totalSupply()": { + "details": "Returns the amount of tokens in existence." + }, + "transfer(address,uint256)": { + "details": "Moves `amount` tokens from the caller's account to `recipient`. * Returns a boolean value indicating whether the operation succeeded. * Emits a {Transfer} event." + }, + "transferFrom(address,address,uint256)": { + "details": "Moves `amount` tokens from `sender` to `recipient` using the allowance mechanism. `amount` is then deducted from the caller's allowance. * Returns a boolean value indicating whether the operation succeeded. * Emits a {Transfer} event." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/ERC20Token.json b/client/src/contracts/ERC20Token.json index aba1af3..873615b 100644 --- a/client/src/contracts/ERC20Token.json +++ b/client/src/contracts/ERC20Token.json @@ -225,7 +225,7 @@ "bytecode": "0x608060405234801561001057600080fd5b50610cf9806100206000396000f3fe608060405234801561001057600080fd5b50600436106100885760003560e01c806370a082311161005b57806370a08231146101fd578063a457c2d714610255578063a9059cbb146102bb578063dd62ed3e1461032157610088565b8063095ea7b31461008d57806318160ddd146100f357806323b872dd146101115780633950935114610197575b600080fd5b6100d9600480360360408110156100a357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610399565b604051808215151515815260200191505060405180910390f35b6100fb6103b0565b6040518082815260200191505060405180910390f35b61017d6004803603606081101561012757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506103ba565b604051808215151515815260200191505060405180910390f35b6101e3600480360360408110156101ad57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061046b565b604051808215151515815260200191505060405180910390f35b61023f6004803603602081101561021357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610510565b6040518082815260200191505060405180910390f35b6102a16004803603604081101561026b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610558565b604051808215151515815260200191505060405180910390f35b610307600480360360408110156102d157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105fd565b604051808215151515815260200191505060405180910390f35b6103836004803603604081101561033757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610614565b6040518082815260200191505060405180910390f35b60006103a633848461069b565b6001905092915050565b6000600254905090565b60006103c7848484610892565b610460843361045b85600160008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b61069b565b600190509392505050565b6000610506338461050185600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb790919063ffffffff16565b61069b565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60006105f333846105ee85600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b61069b565b6001905092915050565b600061060a338484610892565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610721576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526024815260200180610caa6024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156107a7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180610c636022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610918576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526025815260200180610c856025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561099e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180610c406023913960400191505060405180910390fd5b6109ef816000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610a82816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb790919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b600082821115610ba6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601e8152602001807f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525060200191505060405180910390fd5b600082840390508091505092915050565b600080828401905083811015610c35576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b809150509291505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f2061646472657373a165627a7a72305820d66a294bc66e01fa6aa4048efe9e78b3edb0544432977d084d7ec07592f375380029", "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100885760003560e01c806370a082311161005b57806370a08231146101fd578063a457c2d714610255578063a9059cbb146102bb578063dd62ed3e1461032157610088565b8063095ea7b31461008d57806318160ddd146100f357806323b872dd146101115780633950935114610197575b600080fd5b6100d9600480360360408110156100a357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610399565b604051808215151515815260200191505060405180910390f35b6100fb6103b0565b6040518082815260200191505060405180910390f35b61017d6004803603606081101561012757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506103ba565b604051808215151515815260200191505060405180910390f35b6101e3600480360360408110156101ad57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061046b565b604051808215151515815260200191505060405180910390f35b61023f6004803603602081101561021357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610510565b6040518082815260200191505060405180910390f35b6102a16004803603604081101561026b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610558565b604051808215151515815260200191505060405180910390f35b610307600480360360408110156102d157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105fd565b604051808215151515815260200191505060405180910390f35b6103836004803603604081101561033757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610614565b6040518082815260200191505060405180910390f35b60006103a633848461069b565b6001905092915050565b6000600254905090565b60006103c7848484610892565b610460843361045b85600160008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b61069b565b600190509392505050565b6000610506338461050185600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb790919063ffffffff16565b61069b565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60006105f333846105ee85600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b61069b565b6001905092915050565b600061060a338484610892565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610721576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526024815260200180610caa6024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156107a7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180610c636022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610918576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526025815260200180610c856025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141561099e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180610c406023913960400191505060405180910390fd5b6109ef816000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610b2e90919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610a82816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610bb790919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b600082821115610ba6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601e8152602001807f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525060200191505060405180910390fd5b600082840390508091505092915050565b600080828401905083811015610c35576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b809150509291505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f2061646472657373a165627a7a72305820d66a294bc66e01fa6aa4048efe9e78b3edb0544432977d084d7ec07592f375380029", "sourceMap": "82:33:0:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;82:33:0;;;;;;;", - "deployedSourceMap": "82:33:0:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;82:33:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2453:145:8;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2453:145:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1514:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3055:252;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3055:252:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;3702:203;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3702:203:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1661:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1661:108:8;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;4392:213;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4392:213:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1972:153;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1972:153:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2183:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2183:132:8;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;2453:145;2518:4;2534:36;2543:10;2555:7;2564:5;2534:8;:36::i;:::-;2587:4;2580:11;;2453:145;;;;:::o;1514:89::-;1558:7;1584:12;;1577:19;;1514:89;:::o;3055:252::-;3144:4;3160:36;3170:6;3178:9;3189:6;3160:9;:36::i;:::-;3206:73;3215:6;3223:10;3235:43;3271:6;3235:11;:19;3247:6;3235:19;;;;;;;;;;;;;;;:31;3255:10;3235:31;;;;;;;;;;;;;;;;:35;;:43;;;;:::i;:::-;3206:8;:73::i;:::-;3296:4;3289:11;;3055:252;;;;;:::o;3702:203::-;3782:4;3798:79;3807:10;3819:7;3828:48;3865:10;3828:11;:23;3840:10;3828:23;;;;;;;;;;;;;;;:32;3852:7;3828:32;;;;;;;;;;;;;;;;:36;;:48;;;;:::i;:::-;3798:8;:79::i;:::-;3894:4;3887:11;;3702:203;;;;:::o;1661:108::-;1718:7;1744:9;:18;1754:7;1744:18;;;;;;;;;;;;;;;;1737:25;;1661:108;;;:::o;4392:213::-;4477:4;4493:84;4502:10;4514:7;4523:53;4560:15;4523:11;:23;4535:10;4523:23;;;;;;;;;;;;;;;:32;4547:7;4523:32;;;;;;;;;;;;;;;;:36;;:53;;;;:::i;:::-;4493:8;:84::i;:::-;4594:4;4587:11;;4392:213;;;;:::o;1972:153::-;2041:4;2057:40;2067:10;2079:9;2090:6;2057:9;:40::i;:::-;2114:4;2107:11;;1972:153;;;;:::o;2183:132::-;2255:7;2281:11;:18;2293:5;2281:18;;;;;;;;;;;;;;;:27;2300:7;2281:27;;;;;;;;;;;;;;;;2274:34;;2183:132;;;;:::o;7117:329::-;7226:1;7209:19;;:5;:19;;;;7201:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7306:1;7287:21;;:7;:21;;;;7279:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7388:5;7358:11;:18;7370:5;7358:18;;;;;;;;;;;;;;;:27;7377:7;7358:27;;;;;;;;;;;;;;;:35;;;;7424:7;7408:31;;7417:5;7408:31;;;7433:5;7408:31;;;;;;;;;;;;;;;;;;7117:329;;;:::o;5079:422::-;5194:1;5176:20;;:6;:20;;;;5168:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5277:1;5256:23;;:9;:23;;;;5248:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5350:29;5372:6;5350:9;:17;5360:6;5350:17;;;;;;;;;;;;;;;;:21;;:29;;;;:::i;:::-;5330:9;:17;5340:6;5330:17;;;;;;;;;;;;;;;:49;;;;5412:32;5437:6;5412:9;:20;5422:9;5412:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5389:9;:20;5399:9;5389:20;;;;;;;;;;;;;;;:55;;;;5476:9;5459:35;;5468:6;5459:35;;;5487:6;5459:35;;;;;;;;;;;;;;;;;;5079:422;;;:::o;1274:179:7:-;1332:7;1364:1;1359;:6;;1351:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1410:9;1426:1;1422;:5;1410:17;;1445:1;1438:8;;;1274:179;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o", + "deployedSourceMap": "82:33:0:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;82:33:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2453:145:53;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2453:145:53;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1514:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3055:252;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3055:252:53;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;3702:203;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3702:203:53;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1661:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1661:108:53;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;4392:213;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4392:213:53;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1972:153;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1972:153:53;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2183:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2183:132:53;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;2453:145;2518:4;2534:36;2543:10;2555:7;2564:5;2534:8;:36::i;:::-;2587:4;2580:11;;2453:145;;;;:::o;1514:89::-;1558:7;1584:12;;1577:19;;1514:89;:::o;3055:252::-;3144:4;3160:36;3170:6;3178:9;3189:6;3160:9;:36::i;:::-;3206:73;3215:6;3223:10;3235:43;3271:6;3235:11;:19;3247:6;3235:19;;;;;;;;;;;;;;;:31;3255:10;3235:31;;;;;;;;;;;;;;;;:35;;:43;;;;:::i;:::-;3206:8;:73::i;:::-;3296:4;3289:11;;3055:252;;;;;:::o;3702:203::-;3782:4;3798:79;3807:10;3819:7;3828:48;3865:10;3828:11;:23;3840:10;3828:23;;;;;;;;;;;;;;;:32;3852:7;3828:32;;;;;;;;;;;;;;;;:36;;:48;;;;:::i;:::-;3798:8;:79::i;:::-;3894:4;3887:11;;3702:203;;;;:::o;1661:108::-;1718:7;1744:9;:18;1754:7;1744:18;;;;;;;;;;;;;;;;1737:25;;1661:108;;;:::o;4392:213::-;4477:4;4493:84;4502:10;4514:7;4523:53;4560:15;4523:11;:23;4535:10;4523:23;;;;;;;;;;;;;;;:32;4547:7;4523:32;;;;;;;;;;;;;;;;:36;;:53;;;;:::i;:::-;4493:8;:84::i;:::-;4594:4;4587:11;;4392:213;;;;:::o;1972:153::-;2041:4;2057:40;2067:10;2079:9;2090:6;2057:9;:40::i;:::-;2114:4;2107:11;;1972:153;;;;:::o;2183:132::-;2255:7;2281:11;:18;2293:5;2281:18;;;;;;;;;;;;;;;:27;2300:7;2281:27;;;;;;;;;;;;;;;;2274:34;;2183:132;;;;:::o;7117:329::-;7226:1;7209:19;;:5;:19;;;;7201:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7306:1;7287:21;;:7;:21;;;;7279:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7388:5;7358:11;:18;7370:5;7358:18;;;;;;;;;;;;;;;:27;7377:7;7358:27;;;;;;;;;;;;;;;:35;;;;7424:7;7408:31;;7417:5;7408:31;;;7433:5;7408:31;;;;;;;;;;;;;;;;;;7117:329;;;:::o;5079:422::-;5194:1;5176:20;;:6;:20;;;;5168:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5277:1;5256:23;;:9;:23;;;;5248:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5350:29;5372:6;5350:9;:17;5360:6;5350:17;;;;;;;;;;;;;;;;:21;;:29;;;;:::i;:::-;5330:9;:17;5340:6;5330:17;;;;;;;;;;;;;;;:49;;;;5412:32;5437:6;5412:9;:20;5422:9;5412:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5389:9;:20;5399:9;5389:20;;;;;;;;;;;;;;;:55;;;;5476:9;5459:35;;5468:6;5459:35;;;5487:6;5459:35;;;;;;;;;;;;;;;;;;5079:422;;;:::o;1274:179:52:-;1332:7;1364:1;1359;:6;;1351:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1410:9;1426:1;1422;:5;1410:17;;1445:1;1438:8;;;1274:179;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o", "source": "pragma solidity ^0.5.0;\n\nimport \"@openzeppelin/contracts/token/ERC20/ERC20.sol\";\n\ncontract ERC20Token is ERC20 {\n\n}\n", "sourcePath": "/Users/jg/Documents/aaveBot/contracts/ERC20Token.sol", "ast": { @@ -255,7 +255,7 @@ "id": 2, "nodeType": "ImportDirective", "scope": 6, - "sourceUnit": 1375, + "sourceUnit": 10858, "src": "25:55:0", "symbolAliases": [], "unitAlias": "" @@ -269,10 +269,10 @@ "id": 3, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, + "referencedDeclaration": 10857, "src": "105:5:0", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -282,8 +282,8 @@ } ], "contractDependencies": [ - 1374, - 1443 + 10857, + 10926 ], "contractKind": "contract", "documentation": null, @@ -291,8 +291,8 @@ "id": 5, "linearizedBaseContracts": [ 5, - 1374, - 1443 + 10857, + 10926 ], "name": "ERC20Token", "nodeType": "ContractDefinition", @@ -330,7 +330,7 @@ "id": 2, "nodeType": "ImportDirective", "scope": 6, - "sourceUnit": 1375, + "sourceUnit": 10858, "src": "25:55:0", "symbolAliases": [], "unitAlias": "" @@ -344,10 +344,10 @@ "id": 3, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, + "referencedDeclaration": 10857, "src": "105:5:0", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -357,8 +357,8 @@ } ], "contractDependencies": [ - 1374, - 1443 + 10857, + 10926 ], "contractKind": "contract", "documentation": null, @@ -366,8 +366,8 @@ "id": 5, "linearizedBaseContracts": [ 5, - 1374, - 1443 + 10857, + 10926 ], "name": "ERC20Token", "nodeType": "ContractDefinition", @@ -384,7 +384,7 @@ }, "networks": {}, "schemaVersion": "3.0.16", - "updatedAt": "2019-11-04T18:56:07.453Z", + "updatedAt": "2019-11-07T15:21:05.383Z", "devdoc": { "methods": { "allowance(address,address)": { diff --git a/client/src/contracts/FeeProvider.json b/client/src/contracts/FeeProvider.json new file mode 100644 index 0000000..e354cc9 --- /dev/null +++ b/client/src/contracts/FeeProvider.json @@ -0,0 +1,2179 @@ +{ + "contractName": "FeeProvider", + "abi": [ + { + "constant": false, + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isOwner", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "name": "_feesCollectionAddress", + "type": "address" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "constant": true, + "inputs": [ + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "calculateLoanOriginationFee", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_percentage", + "type": "uint256" + } + ], + "name": "setLoanOriginationFeePercentage", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLoanOriginationFeePercentage", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_feesCollectionAddress", + "type": "address" + } + ], + "name": "setFeesCollectionAddress", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getFeesCollectionAddress", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isOwner\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getFeesCollectionAddress\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLoanOriginationFeePercentage\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_percentage\",\"type\":\"uint256\"}],\"name\":\"setLoanOriginationFeePercentage\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_feesCollectionAddress\",\"type\":\"address\"}],\"name\":\"setFeesCollectionAddress\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"calculateLoanOriginationFee\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_feesCollectionAddress\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"calculateLoanOriginationFee(address,uint256)\":{\"details\":\"_user can be used in the future to apply discount to the origination fee based on the _user account (eg. stake AAVE tokens in the lending pool, or deposit > 1M USD etc.)\"},\"isOwner()\":{\"details\":\"Returns true if the caller is the current owner.\"},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/fees/FeeProvider.sol\":\"FeeProvider\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/fees/FeeProvider.sol\":{\"keccak256\":\"0x07483d8e84b680f2eb7ca7a99a92370fe2bc5493f25c502901371aa8af6d7a3a\",\"urls\":[\"bzzr://893dde8f9b875e663c518cb9b8b97648e758e8db099680e4c65953a241453b78\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol\":{\"keccak256\":\"0xdf72f6345d96ca2731656811b508db7f8e4975776d6de39ab24dbe4a13794fd8\",\"urls\":[\"bzzr://687ac9b4f396f264af2645041f5532b6881ec8c92dad3e505ca96477957c784d\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]}},\"version\":1}", + "bytecode": "0x608060405234801561001057600080fd5b50604051602080610c178339810180604052602081101561003057600080fd5b810190808051906020019092919050505061004f61015f60201b60201c565b6000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506608e1bc9bf0400060018190555050610167565b600033905090565b610aa1806101766000396000f3fe608060405234801561001057600080fd5b50600436106100935760003560e01c8063c211f9a411610066578063c211f9a414610158578063c26a533914610176578063e1518136146101a4578063e563a7d0146101e8578063f2fde38b1461024a57610093565b8063715018a6146100985780638da5cb5b146100a25780638f32d59b146100ec578063bc6156681461010e575b600080fd5b6100a061028e565b005b6100aa6103c7565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6100f46103f0565b604051808215151515815260200191505060405180910390f35b61011661044e565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610160610478565b6040518082815260200191505060405180910390f35b6101a26004803603602081101561018c57600080fd5b8101908080359060200190929190505050610482565b005b6101e6600480360360208110156101ba57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610506565b005b610234600480360360408110156101fe57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105c4565b6040518082815260200191505060405180910390f35b61028c6004803603602081101561026057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506105e3565b005b6102966103f0565b610308576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610432610669565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b6000600154905090565b61048a6103f0565b6104fc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b8060018190555050565b61050e6103f0565b610580576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b80600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60006105db6001548361067190919063ffffffff16565b905092915050565b6105eb6103f0565b61065d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b610666816106cc565b50565b600033905090565b60006106c4670de0b6b3a76400006106b6610695858761081090919063ffffffff16565b6002670de0b6b3a7640000816106a757fe5b0461089690919063ffffffff16565b61091e90919063ffffffff16565b905092915050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415610752576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180610a2f6026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6000808314156108235760009050610890565b600082840290508284828161083457fe5b041461088b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180610a556021913960400191505060405180910390fd5b809150505b92915050565b600080828401905083811015610914576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600061096083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250610968565b905092915050565b60008083118290610a14576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156109d95780820151818401526020810190506109be565b50505050905090810190601f168015610a065780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b506000838581610a2057fe5b04905080915050939250505056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a165627a7a72305820aaf62aa5edf6b201479191951b924e63fe4821153aeb9f48712d5a1ddb36e79e0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100935760003560e01c8063c211f9a411610066578063c211f9a414610158578063c26a533914610176578063e1518136146101a4578063e563a7d0146101e8578063f2fde38b1461024a57610093565b8063715018a6146100985780638da5cb5b146100a25780638f32d59b146100ec578063bc6156681461010e575b600080fd5b6100a061028e565b005b6100aa6103c7565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6100f46103f0565b604051808215151515815260200191505060405180910390f35b61011661044e565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610160610478565b6040518082815260200191505060405180910390f35b6101a26004803603602081101561018c57600080fd5b8101908080359060200190929190505050610482565b005b6101e6600480360360208110156101ba57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610506565b005b610234600480360360408110156101fe57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105c4565b6040518082815260200191505060405180910390f35b61028c6004803603602081101561026057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506105e3565b005b6102966103f0565b610308576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610432610669565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b6000600154905090565b61048a6103f0565b6104fc576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b8060018190555050565b61050e6103f0565b610580576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b80600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60006105db6001548361067190919063ffffffff16565b905092915050565b6105eb6103f0565b61065d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b610666816106cc565b50565b600033905090565b60006106c4670de0b6b3a76400006106b6610695858761081090919063ffffffff16565b6002670de0b6b3a7640000816106a757fe5b0461089690919063ffffffff16565b61091e90919063ffffffff16565b905092915050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415610752576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180610a2f6026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b6000808314156108235760009050610890565b600082840290508284828161083457fe5b041461088b576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180610a556021913960400191505060405180910390fd5b809150505b92915050565b600080828401905083811015610914576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600061096083836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250610968565b905092915050565b60008083118290610a14576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156109d95780820151818401526020810190506109be565b50505050905090810190601f168015610a065780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b506000838581610a2057fe5b04905080915050939250505056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a165627a7a72305820aaf62aa5edf6b201479191951b924e63fe4821153aeb9f48712d5a1ddb36e79e0029", + "sourceMap": "215:1364:13:-;;;376:286;8:9:-1;5:2;;;30:1;27;20:12;5:2;376:286:13;;;;;;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;376:286:13;;;;;;;;;;;;;;;;707:12:57;:10;;;:12;;:::i;:::-;698:6;;:21;;;;;;;;;;;;;;;;;;767:6;;;;;;;;;;;734:40;;763:1;734:40;;;;;;;;;;;;461:22:13;437:21;;:46;;;;;;;;;;;;;;;;;;642:13;615:24;:40;;;;376:286;215:1364;;788:96:55;833:15;867:10;860:17;;788:96;:::o;215:1364:13:-;;;;;;;", + "deployedSourceMap": "215:1364:13:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;215:1364:13;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1642:137:57;;;:::i;:::-;;857:77;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1208:92;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1463:113:13;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1180:123;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1038:136;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1038:136:13;;;;;;;;;;;;;;;;;:::i;:::-;;1309:148;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1309:148:13;;;;;;;;;;;;;;;;;;;:::i;:::-;;867:165;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;867:165:13;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1928:107:57;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1928:107:57;;;;;;;;;;;;;;;;;;;:::i;:::-;;1642:137;1061:9;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1740:1;1703:40;;1724:6;;;;;;;;;;;1703:40;;;;;;;;;;;;1770:1;1753:6;;:19;;;;;;;;;;;;;;;;;;1642:137::o;857:77::-;895:7;921:6;;;;;;;;;;;914:13;;857:77;:::o;1208:92::-;1248:4;1287:6;;;;;;;;;;;1271:22;;:12;:10;:12::i;:::-;:22;;;1264:29;;1208:92;:::o;1463:113:13:-;1522:7;1548:21;;;;;;;;;;;1541:28;;1463:113;:::o;1180:123::-;1246:7;1272:24;;1265:31;;1180:123;:::o;1038:136::-;1061:9:57;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1156:11:13;1129:24;:38;;;;1038:136;:::o;1309:148::-;1061:9:57;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1428:22:13;1404:21;;:46;;;;;;;;;;;;;;;;;;1309:148;:::o;867:165::-;959:7;985:40;1000:24;;985:7;:14;;:40;;;;:::i;:::-;978:47;;867:165;;;;:::o;1928:107:57:-;1061:9;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2000:28;2019:8;2000:18;:28::i;:::-;1928:107;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;893:124:29:-;954:7;980:30;362:4;980:21;992:8;998:1;992;:5;;:8;;;;:::i;:::-;414:1;362:4;408:7;;;;;;980:11;;:21;;;;:::i;:::-;:25;;:30;;;;:::i;:::-;973:37;;893:124;;;;:::o;2136:225:57:-;2229:1;2209:22;;:8;:22;;;;2201:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2318:8;2289:38;;2310:6;;;;;;;;;;;2289:38;;;;;;;;;;;;2346:8;2337:6;;:17;;;;;;;;;;;;;;;;;;2136:225;:::o;2159:459:56:-;2217:7;2463:1;2458;:6;2454:45;;;2487:1;2480:8;;;;2454:45;2509:9;2525:1;2521;:5;2509:17;;2553:1;2548;2544;:5;;;;;;:10;2536:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2610:1;2603:8;;;2159:459;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;3073:130::-;3131:7;3157:39;3161:1;3164;3157:39;;;;;;;;;;;;;;;;;:3;:39::i;:::-;3150:46;;3073:130;;;;:::o;3718:338::-;3804:7;3901:1;3897;:5;3904:12;3889:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;3889:28:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3927:9;3943:1;3939;:5;;;;;;3927:17;;4048:1;4041:8;;;3718:338;;;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/ownership/Ownable.sol\";\nimport \"../interfaces/IFeeProvider.sol\";\nimport \"../libraries/WadRayMath.sol\";\n\n// TODO: move Ownable to governance based ACR\ncontract FeeProvider is IFeeProvider, Ownable {\n using WadRayMath for uint256;\n\n uint256 originationFeePercentage;\n address feesCollectionAddress;\n\n constructor(address _feesCollectionAddress) public {\n feesCollectionAddress = _feesCollectionAddress;\n\n /**\n @notice origination fee is set as default as 25 basis points of the loan amount (0.0025%)\n */\n originationFeePercentage = 0.0025 * 1e18;\n }\n\n /**\n @dev _user can be used in the future to apply discount to the origination fee based on the\n _user account (eg. stake AAVE tokens in the lending pool, or deposit > 1M USD etc.)\n */\n function calculateLoanOriginationFee(address _user, uint256 _amount) external view returns (uint256) {\n return _amount.wadMul(originationFeePercentage);\n }\n\n function setLoanOriginationFeePercentage(uint256 _percentage) external onlyOwner {\n originationFeePercentage = _percentage;\n }\n\n function getLoanOriginationFeePercentage() external view returns (uint256) {\n return originationFeePercentage;\n }\n\n function setFeesCollectionAddress(address _feesCollectionAddress) external onlyOwner {\n feesCollectionAddress = _feesCollectionAddress;\n }\n\n function getFeesCollectionAddress() external view returns (address) {\n return feesCollectionAddress;\n }\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/fees/FeeProvider.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/fees/FeeProvider.sol", + "exportedSymbols": { + "FeeProvider": [ + 1599 + ] + }, + "id": 1600, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1513, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:13" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "id": 1514, + "nodeType": "ImportDirective", + "scope": 1600, + "sourceUnit": 11255, + "src": "25:63:13", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "file": "../interfaces/IFeeProvider.sol", + "id": 1515, + "nodeType": "ImportDirective", + "scope": 1600, + "sourceUnit": 1766, + "src": "89:40:13", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 1516, + "nodeType": "ImportDirective", + "scope": 1600, + "sourceUnit": 9175, + "src": "130:37:13", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1517, + "name": "IFeeProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1765, + "src": "239:12:13", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFeeProvider_$1765", + "typeString": "contract IFeeProvider" + } + }, + "id": 1518, + "nodeType": "InheritanceSpecifier", + "src": "239:12:13" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1519, + "name": "Ownable", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11254, + "src": "253:7:13", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Ownable_$11254", + "typeString": "contract Ownable" + } + }, + "id": 1520, + "nodeType": "InheritanceSpecifier", + "src": "253:7:13" + } + ], + "contractDependencies": [ + 1765, + 10953, + 11254 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 1599, + "linearizedBaseContracts": [ + 1599, + 11254, + 10953, + 1765 + ], + "name": "FeeProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 1523, + "libraryName": { + "contractScope": null, + "id": 1521, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "273:10:13", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "267:29:13", + "typeName": { + "id": 1522, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "288:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "constant": false, + "id": 1525, + "name": "originationFeePercentage", + "nodeType": "VariableDeclaration", + "scope": 1599, + "src": "302:32:13", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1524, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "302:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1527, + "name": "feesCollectionAddress", + "nodeType": "VariableDeclaration", + "scope": 1599, + "src": "340:29:13", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1526, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "340:7:13", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 1542, + "nodeType": "Block", + "src": "427:235:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1534, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 1532, + "name": "feesCollectionAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1527, + "src": "437:21:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 1533, + "name": "_feesCollectionAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1529, + "src": "461:22:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "437:46:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 1535, + "nodeType": "ExpressionStatement", + "src": "437:46:13" + }, + { + "expression": { + "argumentTypes": null, + "id": 1540, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 1536, + "name": "originationFeePercentage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1525, + "src": "615:24:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_rational_2500000000000000_by_1", + "typeString": "int_const 2500000000000000" + }, + "id": 1539, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "302e30303235", + "id": 1537, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "642:6:13", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1_by_400", + "typeString": "rational_const 1 / 400" + }, + "value": "0.0025" + }, + "nodeType": "BinaryOperation", + "operator": "*", + "rightExpression": { + "argumentTypes": null, + "hexValue": "31653138", + "id": 1538, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "651:4:13", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000_by_1", + "typeString": "int_const 1000000000000000000" + }, + "value": "1e18" + }, + "src": "642:13:13", + "typeDescriptions": { + "typeIdentifier": "t_rational_2500000000000000_by_1", + "typeString": "int_const 2500000000000000" + } + }, + "src": "615:40:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 1541, + "nodeType": "ExpressionStatement", + "src": "615:40:13" + } + ] + }, + "documentation": null, + "id": 1543, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1530, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1529, + "name": "_feesCollectionAddress", + "nodeType": "VariableDeclaration", + "scope": 1543, + "src": "388:30:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1528, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "388:7:13", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "387:32:13" + }, + "returnParameters": { + "id": 1531, + "nodeType": "ParameterList", + "parameters": [], + "src": "427:0:13" + }, + "scope": 1599, + "src": "376:286:13", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 1557, + "nodeType": "Block", + "src": "968:64:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1554, + "name": "originationFeePercentage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1525, + "src": "1000:24:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 1552, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1547, + "src": "985:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 1553, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9072, + "src": "985:14:13", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 1555, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "985:40:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1551, + "id": 1556, + "nodeType": "Return", + "src": "978:47:13" + } + ] + }, + "documentation": "@dev _user can be used in the future to apply discount to the origination fee based on the\n_user account (eg. stake AAVE tokens in the lending pool, or deposit > 1M USD etc.)", + "id": 1558, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateLoanOriginationFee", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1548, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1545, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 1558, + "src": "904:13:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1544, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "904:7:13", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1547, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1558, + "src": "919:15:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1546, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "919:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "903:32:13" + }, + "returnParameters": { + "id": 1551, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1550, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1558, + "src": "959:7:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1549, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "959:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "958:9:13" + }, + "scope": 1599, + "src": "867:165:13", + "stateMutability": "view", + "superFunction": 1744, + "visibility": "external" + }, + { + "body": { + "id": 1569, + "nodeType": "Block", + "src": "1119:55:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1567, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 1565, + "name": "originationFeePercentage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1525, + "src": "1129:24:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 1566, + "name": "_percentage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1560, + "src": "1156:11:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1129:38:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 1568, + "nodeType": "ExpressionStatement", + "src": "1129:38:13" + } + ] + }, + "documentation": null, + "id": 1570, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 1563, + "modifierName": { + "argumentTypes": null, + "id": 1562, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "1109:9:13", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "1109:9:13" + } + ], + "name": "setLoanOriginationFeePercentage", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1561, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1560, + "name": "_percentage", + "nodeType": "VariableDeclaration", + "scope": 1570, + "src": "1079:19:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1559, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1079:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1078:21:13" + }, + "returnParameters": { + "id": 1564, + "nodeType": "ParameterList", + "parameters": [], + "src": "1119:0:13" + }, + "scope": 1599, + "src": "1038:136:13", + "stateMutability": "nonpayable", + "superFunction": 1749, + "visibility": "external" + }, + { + "body": { + "id": 1577, + "nodeType": "Block", + "src": "1255:48:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1575, + "name": "originationFeePercentage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1525, + "src": "1272:24:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1574, + "id": 1576, + "nodeType": "Return", + "src": "1265:31:13" + } + ] + }, + "documentation": null, + "id": 1578, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLoanOriginationFeePercentage", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1571, + "nodeType": "ParameterList", + "parameters": [], + "src": "1220:2:13" + }, + "returnParameters": { + "id": 1574, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1573, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1578, + "src": "1246:7:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1572, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1246:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1245:9:13" + }, + "scope": 1599, + "src": "1180:123:13", + "stateMutability": "view", + "superFunction": 1754, + "visibility": "external" + }, + { + "body": { + "id": 1589, + "nodeType": "Block", + "src": "1394:63:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1587, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 1585, + "name": "feesCollectionAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1527, + "src": "1404:21:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 1586, + "name": "_feesCollectionAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1580, + "src": "1428:22:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1404:46:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 1588, + "nodeType": "ExpressionStatement", + "src": "1404:46:13" + } + ] + }, + "documentation": null, + "id": 1590, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 1583, + "modifierName": { + "argumentTypes": null, + "id": 1582, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "1384:9:13", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "1384:9:13" + } + ], + "name": "setFeesCollectionAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1581, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1580, + "name": "_feesCollectionAddress", + "nodeType": "VariableDeclaration", + "scope": 1590, + "src": "1343:30:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1579, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1343:7:13", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1342:32:13" + }, + "returnParameters": { + "id": 1584, + "nodeType": "ParameterList", + "parameters": [], + "src": "1394:0:13" + }, + "scope": 1599, + "src": "1309:148:13", + "stateMutability": "nonpayable", + "superFunction": 1759, + "visibility": "external" + }, + { + "body": { + "id": 1597, + "nodeType": "Block", + "src": "1531:45:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1595, + "name": "feesCollectionAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1527, + "src": "1548:21:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1594, + "id": 1596, + "nodeType": "Return", + "src": "1541:28:13" + } + ] + }, + "documentation": null, + "id": 1598, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getFeesCollectionAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1591, + "nodeType": "ParameterList", + "parameters": [], + "src": "1496:2:13" + }, + "returnParameters": { + "id": 1594, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1593, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1598, + "src": "1522:7:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1592, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1522:7:13", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1521:9:13" + }, + "scope": 1599, + "src": "1463:113:13", + "stateMutability": "view", + "superFunction": 1764, + "visibility": "external" + } + ], + "scope": 1600, + "src": "215:1364:13" + } + ], + "src": "0:1580:13" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/fees/FeeProvider.sol", + "exportedSymbols": { + "FeeProvider": [ + 1599 + ] + }, + "id": 1600, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1513, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:13" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "id": 1514, + "nodeType": "ImportDirective", + "scope": 1600, + "sourceUnit": 11255, + "src": "25:63:13", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "file": "../interfaces/IFeeProvider.sol", + "id": 1515, + "nodeType": "ImportDirective", + "scope": 1600, + "sourceUnit": 1766, + "src": "89:40:13", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 1516, + "nodeType": "ImportDirective", + "scope": 1600, + "sourceUnit": 9175, + "src": "130:37:13", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1517, + "name": "IFeeProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1765, + "src": "239:12:13", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFeeProvider_$1765", + "typeString": "contract IFeeProvider" + } + }, + "id": 1518, + "nodeType": "InheritanceSpecifier", + "src": "239:12:13" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1519, + "name": "Ownable", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11254, + "src": "253:7:13", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Ownable_$11254", + "typeString": "contract Ownable" + } + }, + "id": 1520, + "nodeType": "InheritanceSpecifier", + "src": "253:7:13" + } + ], + "contractDependencies": [ + 1765, + 10953, + 11254 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 1599, + "linearizedBaseContracts": [ + 1599, + 11254, + 10953, + 1765 + ], + "name": "FeeProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 1523, + "libraryName": { + "contractScope": null, + "id": 1521, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "273:10:13", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "267:29:13", + "typeName": { + "id": 1522, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "288:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "constant": false, + "id": 1525, + "name": "originationFeePercentage", + "nodeType": "VariableDeclaration", + "scope": 1599, + "src": "302:32:13", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1524, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "302:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1527, + "name": "feesCollectionAddress", + "nodeType": "VariableDeclaration", + "scope": 1599, + "src": "340:29:13", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1526, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "340:7:13", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 1542, + "nodeType": "Block", + "src": "427:235:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1534, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 1532, + "name": "feesCollectionAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1527, + "src": "437:21:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 1533, + "name": "_feesCollectionAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1529, + "src": "461:22:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "437:46:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 1535, + "nodeType": "ExpressionStatement", + "src": "437:46:13" + }, + { + "expression": { + "argumentTypes": null, + "id": 1540, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 1536, + "name": "originationFeePercentage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1525, + "src": "615:24:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_rational_2500000000000000_by_1", + "typeString": "int_const 2500000000000000" + }, + "id": 1539, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "302e30303235", + "id": 1537, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "642:6:13", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1_by_400", + "typeString": "rational_const 1 / 400" + }, + "value": "0.0025" + }, + "nodeType": "BinaryOperation", + "operator": "*", + "rightExpression": { + "argumentTypes": null, + "hexValue": "31653138", + "id": 1538, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "651:4:13", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000_by_1", + "typeString": "int_const 1000000000000000000" + }, + "value": "1e18" + }, + "src": "642:13:13", + "typeDescriptions": { + "typeIdentifier": "t_rational_2500000000000000_by_1", + "typeString": "int_const 2500000000000000" + } + }, + "src": "615:40:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 1541, + "nodeType": "ExpressionStatement", + "src": "615:40:13" + } + ] + }, + "documentation": null, + "id": 1543, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1530, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1529, + "name": "_feesCollectionAddress", + "nodeType": "VariableDeclaration", + "scope": 1543, + "src": "388:30:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1528, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "388:7:13", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "387:32:13" + }, + "returnParameters": { + "id": 1531, + "nodeType": "ParameterList", + "parameters": [], + "src": "427:0:13" + }, + "scope": 1599, + "src": "376:286:13", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 1557, + "nodeType": "Block", + "src": "968:64:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1554, + "name": "originationFeePercentage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1525, + "src": "1000:24:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 1552, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1547, + "src": "985:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 1553, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9072, + "src": "985:14:13", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 1555, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "985:40:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1551, + "id": 1556, + "nodeType": "Return", + "src": "978:47:13" + } + ] + }, + "documentation": "@dev _user can be used in the future to apply discount to the origination fee based on the\n_user account (eg. stake AAVE tokens in the lending pool, or deposit > 1M USD etc.)", + "id": 1558, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateLoanOriginationFee", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1548, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1545, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 1558, + "src": "904:13:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1544, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "904:7:13", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1547, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1558, + "src": "919:15:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1546, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "919:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "903:32:13" + }, + "returnParameters": { + "id": 1551, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1550, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1558, + "src": "959:7:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1549, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "959:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "958:9:13" + }, + "scope": 1599, + "src": "867:165:13", + "stateMutability": "view", + "superFunction": 1744, + "visibility": "external" + }, + { + "body": { + "id": 1569, + "nodeType": "Block", + "src": "1119:55:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1567, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 1565, + "name": "originationFeePercentage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1525, + "src": "1129:24:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 1566, + "name": "_percentage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1560, + "src": "1156:11:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1129:38:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 1568, + "nodeType": "ExpressionStatement", + "src": "1129:38:13" + } + ] + }, + "documentation": null, + "id": 1570, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 1563, + "modifierName": { + "argumentTypes": null, + "id": 1562, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "1109:9:13", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "1109:9:13" + } + ], + "name": "setLoanOriginationFeePercentage", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1561, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1560, + "name": "_percentage", + "nodeType": "VariableDeclaration", + "scope": 1570, + "src": "1079:19:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1559, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1079:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1078:21:13" + }, + "returnParameters": { + "id": 1564, + "nodeType": "ParameterList", + "parameters": [], + "src": "1119:0:13" + }, + "scope": 1599, + "src": "1038:136:13", + "stateMutability": "nonpayable", + "superFunction": 1749, + "visibility": "external" + }, + { + "body": { + "id": 1577, + "nodeType": "Block", + "src": "1255:48:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1575, + "name": "originationFeePercentage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1525, + "src": "1272:24:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1574, + "id": 1576, + "nodeType": "Return", + "src": "1265:31:13" + } + ] + }, + "documentation": null, + "id": 1578, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLoanOriginationFeePercentage", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1571, + "nodeType": "ParameterList", + "parameters": [], + "src": "1220:2:13" + }, + "returnParameters": { + "id": 1574, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1573, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1578, + "src": "1246:7:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1572, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1246:7:13", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1245:9:13" + }, + "scope": 1599, + "src": "1180:123:13", + "stateMutability": "view", + "superFunction": 1754, + "visibility": "external" + }, + { + "body": { + "id": 1589, + "nodeType": "Block", + "src": "1394:63:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1587, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 1585, + "name": "feesCollectionAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1527, + "src": "1404:21:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 1586, + "name": "_feesCollectionAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1580, + "src": "1428:22:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1404:46:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 1588, + "nodeType": "ExpressionStatement", + "src": "1404:46:13" + } + ] + }, + "documentation": null, + "id": 1590, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 1583, + "modifierName": { + "argumentTypes": null, + "id": 1582, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "1384:9:13", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "1384:9:13" + } + ], + "name": "setFeesCollectionAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1581, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1580, + "name": "_feesCollectionAddress", + "nodeType": "VariableDeclaration", + "scope": 1590, + "src": "1343:30:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1579, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1343:7:13", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1342:32:13" + }, + "returnParameters": { + "id": 1584, + "nodeType": "ParameterList", + "parameters": [], + "src": "1394:0:13" + }, + "scope": 1599, + "src": "1309:148:13", + "stateMutability": "nonpayable", + "superFunction": 1759, + "visibility": "external" + }, + { + "body": { + "id": 1597, + "nodeType": "Block", + "src": "1531:45:13", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1595, + "name": "feesCollectionAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1527, + "src": "1548:21:13", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1594, + "id": 1596, + "nodeType": "Return", + "src": "1541:28:13" + } + ] + }, + "documentation": null, + "id": 1598, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getFeesCollectionAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1591, + "nodeType": "ParameterList", + "parameters": [], + "src": "1496:2:13" + }, + "returnParameters": { + "id": 1594, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1593, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1598, + "src": "1522:7:13", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1592, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1522:7:13", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1521:9:13" + }, + "scope": 1599, + "src": "1463:113:13", + "stateMutability": "view", + "superFunction": 1764, + "visibility": "external" + } + ], + "scope": 1600, + "src": "215:1364:13" + } + ], + "src": "0:1580:13" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.586Z", + "devdoc": { + "methods": { + "calculateLoanOriginationFee(address,uint256)": { + "details": "_user can be used in the future to apply discount to the origination fee based on the _user account (eg. stake AAVE tokens in the lending pool, or deposit > 1M USD etc.)" + }, + "isOwner()": { + "details": "Returns true if the caller is the current owner." + }, + "owner()": { + "details": "Returns the address of the current owner." + }, + "renounceOwnership()": { + "details": "Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner." + }, + "transferOwnership(address)": { + "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/FlashLoanReceiverBase.json b/client/src/contracts/FlashLoanReceiverBase.json new file mode 100644 index 0000000..a4ddf38 --- /dev/null +++ b/client/src/contracts/FlashLoanReceiverBase.json @@ -0,0 +1,3072 @@ +{ + "contractName": "FlashLoanReceiverBase", + "abi": [ + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + }, + { + "name": "_fee", + "type": "uint256" + } + ], + "name": "executeOperation", + "outputs": [ + { + "name": "returnedAmount", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "name": "_provider", + "type": "address" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_fee\",\"type\":\"uint256\"}],\"name\":\"executeOperation\",\"outputs\":[{\"name\":\"returnedAmount\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_provider\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"fallback\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol\":\"FlashLoanReceiverBase\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol\":{\"keccak256\":\"0xa05bc60cdbae1ae13832a9e45726487f20de2ef8f2cdf7ccbbdab69e782b867d\",\"urls\":[\"bzzr://31b41cf73f764af450fdb49b224012e1100302b84ba7ec0596f97417361b6f24\"]},\"/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol\":{\"keccak256\":\"0x3b825dc98b6a7aa21e9c9b05e1951bec7b5d7c84b7a0e8de0750069ccb31ebac\",\"urls\":[\"bzzr://8a616caca158d63de8db6037a2162c1effaaa71f6d7095a11516e03f7ea391d0\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\";\nimport \"../interfaces/IFlashLoanReceiver.sol\";\nimport \"../../interfaces/ILendingPoolAddressesProvider.sol\";\nimport \"../../interfaces/INetworkMetadataProvider.sol\";\n\ncontract FlashLoanReceiverBase is IFlashLoanReceiver {\n\n using SafeERC20 for IERC20;\n using SafeMath for uint256;\n\n ILendingPoolAddressesProvider addressesProvider;\n\n constructor(ILendingPoolAddressesProvider _provider) public {\n addressesProvider = _provider;\n }\n\n function () external payable {\n }\n\n function transferFundsBackToPoolInternal(address _reserve, uint _amount) internal {\n\n address payable core = addressesProvider.getLendingPoolCore();\n\n transferInternal(core,_reserve, _amount);\n }\n\n function transferInternal(address payable _destination, address _reserve, uint _amount) internal {\n if(_reserve == INetworkMetadataProvider(addressesProvider.getNetworkMetadataProvider()).getEthereumAddress()) {\n _destination.transfer(_amount);\n return;\n }\n\n IERC20(_reserve).safeTransfer(_destination, _amount);\n\n\n }\n\n function getBalanceInternal(address _target, address _reserve) internal view returns(uint256) {\n if(_reserve == INetworkMetadataProvider(addressesProvider.getNetworkMetadataProvider()).getEthereumAddress()) {\n\n return _target.balance;\n }\n\n return IERC20(_reserve).balanceOf(_target);\n\n }\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol", + "exportedSymbols": { + "FlashLoanReceiverBase": [ + 1719 + ] + }, + "id": 1720, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1601, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:14" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 1602, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 11141, + "src": "25:59:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "id": 1603, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 11787, + "src": "85:64:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "id": 1604, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 12007, + "src": "150:67:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol", + "file": "../interfaces/IFlashLoanReceiver.sol", + "id": 1605, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 1734, + "src": "218:46:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol", + "file": "../../interfaces/ILendingPoolAddressesProvider.sol", + "id": 1606, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 1879, + "src": "265:60:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "file": "../../interfaces/INetworkMetadataProvider.sol", + "id": 1607, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 1933, + "src": "326:55:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1608, + "name": "IFlashLoanReceiver", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1733, + "src": "417:18:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFlashLoanReceiver_$1733", + "typeString": "contract IFlashLoanReceiver" + } + }, + "id": 1609, + "nodeType": "InheritanceSpecifier", + "src": "417:18:14" + } + ], + "contractDependencies": [ + 1733 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": false, + "id": 1719, + "linearizedBaseContracts": [ + 1719, + 1733 + ], + "name": "FlashLoanReceiverBase", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 1612, + "libraryName": { + "contractScope": null, + "id": 1610, + "name": "SafeERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12006, + "src": "449:9:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + }, + "nodeType": "UsingForDirective", + "src": "443:27:14", + "typeName": { + "contractScope": null, + "id": 1611, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "463:6:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + } + }, + { + "id": 1615, + "libraryName": { + "contractScope": null, + "id": 1613, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "481:8:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "475:27:14", + "typeName": { + "id": 1614, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "494:7:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "constant": false, + "id": 1617, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 1719, + "src": "508:47:14", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 1616, + "name": "ILendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1878, + "src": "508:29:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 1626, + "nodeType": "Block", + "src": "622:46:14", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1624, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 1622, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1617, + "src": "632:17:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 1623, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1619, + "src": "652:9:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "src": "632:29:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 1625, + "nodeType": "ExpressionStatement", + "src": "632:29:14" + } + ] + }, + "documentation": null, + "id": 1627, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1620, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1619, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 1627, + "src": "574:39:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 1618, + "name": "ILendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1878, + "src": "574:29:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "573:41:14" + }, + "returnParameters": { + "id": 1621, + "nodeType": "ParameterList", + "parameters": [], + "src": "622:0:14" + }, + "scope": 1719, + "src": "562:106:14", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 1630, + "nodeType": "Block", + "src": "703:7:14", + "statements": [] + }, + "documentation": null, + "id": 1631, + "implemented": true, + "kind": "fallback", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1628, + "nodeType": "ParameterList", + "parameters": [], + "src": "683:2:14" + }, + "returnParameters": { + "id": 1629, + "nodeType": "ParameterList", + "parameters": [], + "src": "703:0:14" + }, + "scope": 1719, + "src": "674:36:14", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 1650, + "nodeType": "Block", + "src": "798:130:14", + "statements": [ + { + "assignments": [ + 1639 + ], + "declarations": [ + { + "constant": false, + "id": 1639, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 1650, + "src": "809:20:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 1638, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "809:15:14", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 1643, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 1640, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1617, + "src": "832:17:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 1641, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1782, + "src": "832:36:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 1642, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "832:38:14", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "809:61:14" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1645, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1639, + "src": "898:4:14", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 1646, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1633, + "src": "903:8:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 1647, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1635, + "src": "913:7:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 1644, + "name": "transferInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1687, + "src": "881:16:14", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_payable_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address payable,address,uint256)" + } + }, + "id": 1648, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "881:40:14", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1649, + "nodeType": "ExpressionStatement", + "src": "881:40:14" + } + ] + }, + "documentation": null, + "id": 1651, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "transferFundsBackToPoolInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1636, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1633, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 1651, + "src": "757:16:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1632, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "757:7:14", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1635, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1651, + "src": "775:12:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1634, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "775:4:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "756:32:14" + }, + "returnParameters": { + "id": 1637, + "nodeType": "ParameterList", + "parameters": [], + "src": "798:0:14" + }, + "scope": 1719, + "src": "716:212:14", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 1686, + "nodeType": "Block", + "src": "1032:266:14", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 1668, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 1660, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1655, + "src": "1045:8:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 1662, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1617, + "src": "1082:17:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 1663, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1822, + "src": "1082:44:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 1664, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1082:46:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1661, + "name": "INetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1932, + "src": "1057:24:14", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_INetworkMetadataProvider_$1932_$", + "typeString": "type(contract INetworkMetadataProvider)" + } + }, + "id": 1665, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1057:72:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 1666, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1926, + "src": "1057:91:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 1667, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1057:93:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1045:105:14", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 1677, + "nodeType": "IfStatement", + "src": "1042:185:14", + "trueBody": { + "id": 1676, + "nodeType": "Block", + "src": "1152:75:14", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1672, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1657, + "src": "1188:7:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 1669, + "name": "_destination", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1653, + "src": "1166:12:14", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 1671, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1166:21:14", + "typeDescriptions": { + "typeIdentifier": "t_function_transfer_nonpayable$_t_uint256_$returns$__$", + "typeString": "function (uint256)" + } + }, + "id": 1673, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1166:30:14", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1674, + "nodeType": "ExpressionStatement", + "src": "1166:30:14" + }, + { + "expression": null, + "functionReturnParameters": 1659, + "id": 1675, + "nodeType": "Return", + "src": "1210:7:14" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1682, + "name": "_destination", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1653, + "src": "1267:12:14", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 1683, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1657, + "src": "1281:7:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1679, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1655, + "src": "1244:8:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1678, + "name": "IERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11786, + "src": "1237:6:14", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IERC20_$11786_$", + "typeString": "type(contract IERC20)" + } + }, + "id": 1680, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1237:16:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 1681, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "safeTransfer", + "nodeType": "MemberAccess", + "referencedDeclaration": 11819, + "src": "1237:29:14", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$11786_$", + "typeString": "function (contract IERC20,address,uint256)" + } + }, + "id": 1684, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1237:52:14", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1685, + "nodeType": "ExpressionStatement", + "src": "1237:52:14" + } + ] + }, + "documentation": null, + "id": 1687, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "transferInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1658, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1653, + "name": "_destination", + "nodeType": "VariableDeclaration", + "scope": 1687, + "src": "960:28:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 1652, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "960:15:14", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1655, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 1687, + "src": "990:16:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1654, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "990:7:14", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1657, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1687, + "src": "1008:13:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1656, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "1008:4:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "959:63:14" + }, + "returnParameters": { + "id": 1659, + "nodeType": "ParameterList", + "parameters": [], + "src": "1032:0:14" + }, + "scope": 1719, + "src": "934:364:14", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 1717, + "nodeType": "Block", + "src": "1398:228:14", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 1704, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 1696, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1691, + "src": "1411:8:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 1698, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1617, + "src": "1448:17:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 1699, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1822, + "src": "1448:44:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 1700, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1448:46:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1697, + "name": "INetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1932, + "src": "1423:24:14", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_INetworkMetadataProvider_$1932_$", + "typeString": "type(contract INetworkMetadataProvider)" + } + }, + "id": 1701, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1423:72:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 1702, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1926, + "src": "1423:91:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 1703, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1423:93:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1411:105:14", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 1709, + "nodeType": "IfStatement", + "src": "1408:158:14", + "trueBody": { + "id": 1708, + "nodeType": "Block", + "src": "1518:48:14", + "statements": [ + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 1705, + "name": "_target", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1689, + "src": "1540:7:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 1706, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balance", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1540:15:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1695, + "id": 1707, + "nodeType": "Return", + "src": "1533:22:14" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1714, + "name": "_target", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1689, + "src": "1610:7:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1711, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1691, + "src": "1590:8:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1710, + "name": "IERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11786, + "src": "1583:6:14", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IERC20_$11786_$", + "typeString": "type(contract IERC20)" + } + }, + "id": 1712, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1583:16:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 1713, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOf", + "nodeType": "MemberAccess", + "referencedDeclaration": 11731, + "src": "1583:26:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 1715, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1583:35:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1695, + "id": 1716, + "nodeType": "Return", + "src": "1576:42:14" + } + ] + }, + "documentation": null, + "id": 1718, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getBalanceInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1692, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1689, + "name": "_target", + "nodeType": "VariableDeclaration", + "scope": 1718, + "src": "1332:15:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1688, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1332:7:14", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1691, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 1718, + "src": "1349:16:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1690, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1349:7:14", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1331:35:14" + }, + "returnParameters": { + "id": 1695, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1694, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1718, + "src": "1389:7:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1693, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1389:7:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1388:9:14" + }, + "scope": 1719, + "src": "1304:322:14", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 1720, + "src": "383:1245:14" + } + ], + "src": "0:1628:14" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol", + "exportedSymbols": { + "FlashLoanReceiverBase": [ + 1719 + ] + }, + "id": 1720, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1601, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:14" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 1602, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 11141, + "src": "25:59:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "id": 1603, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 11787, + "src": "85:64:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "id": 1604, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 12007, + "src": "150:67:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol", + "file": "../interfaces/IFlashLoanReceiver.sol", + "id": 1605, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 1734, + "src": "218:46:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol", + "file": "../../interfaces/ILendingPoolAddressesProvider.sol", + "id": 1606, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 1879, + "src": "265:60:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "file": "../../interfaces/INetworkMetadataProvider.sol", + "id": 1607, + "nodeType": "ImportDirective", + "scope": 1720, + "sourceUnit": 1933, + "src": "326:55:14", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1608, + "name": "IFlashLoanReceiver", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1733, + "src": "417:18:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFlashLoanReceiver_$1733", + "typeString": "contract IFlashLoanReceiver" + } + }, + "id": 1609, + "nodeType": "InheritanceSpecifier", + "src": "417:18:14" + } + ], + "contractDependencies": [ + 1733 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": false, + "id": 1719, + "linearizedBaseContracts": [ + 1719, + 1733 + ], + "name": "FlashLoanReceiverBase", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 1612, + "libraryName": { + "contractScope": null, + "id": 1610, + "name": "SafeERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12006, + "src": "449:9:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + }, + "nodeType": "UsingForDirective", + "src": "443:27:14", + "typeName": { + "contractScope": null, + "id": 1611, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "463:6:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + } + }, + { + "id": 1615, + "libraryName": { + "contractScope": null, + "id": 1613, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "481:8:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "475:27:14", + "typeName": { + "id": 1614, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "494:7:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "constant": false, + "id": 1617, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 1719, + "src": "508:47:14", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 1616, + "name": "ILendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1878, + "src": "508:29:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 1626, + "nodeType": "Block", + "src": "622:46:14", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1624, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 1622, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1617, + "src": "632:17:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 1623, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1619, + "src": "652:9:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "src": "632:29:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 1625, + "nodeType": "ExpressionStatement", + "src": "632:29:14" + } + ] + }, + "documentation": null, + "id": 1627, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1620, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1619, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 1627, + "src": "574:39:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 1618, + "name": "ILendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1878, + "src": "574:29:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "573:41:14" + }, + "returnParameters": { + "id": 1621, + "nodeType": "ParameterList", + "parameters": [], + "src": "622:0:14" + }, + "scope": 1719, + "src": "562:106:14", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 1630, + "nodeType": "Block", + "src": "703:7:14", + "statements": [] + }, + "documentation": null, + "id": 1631, + "implemented": true, + "kind": "fallback", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1628, + "nodeType": "ParameterList", + "parameters": [], + "src": "683:2:14" + }, + "returnParameters": { + "id": 1629, + "nodeType": "ParameterList", + "parameters": [], + "src": "703:0:14" + }, + "scope": 1719, + "src": "674:36:14", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 1650, + "nodeType": "Block", + "src": "798:130:14", + "statements": [ + { + "assignments": [ + 1639 + ], + "declarations": [ + { + "constant": false, + "id": 1639, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 1650, + "src": "809:20:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 1638, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "809:15:14", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 1643, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 1640, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1617, + "src": "832:17:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 1641, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1782, + "src": "832:36:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 1642, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "832:38:14", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "809:61:14" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1645, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1639, + "src": "898:4:14", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 1646, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1633, + "src": "903:8:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 1647, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1635, + "src": "913:7:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 1644, + "name": "transferInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1687, + "src": "881:16:14", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_payable_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address payable,address,uint256)" + } + }, + "id": 1648, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "881:40:14", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1649, + "nodeType": "ExpressionStatement", + "src": "881:40:14" + } + ] + }, + "documentation": null, + "id": 1651, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "transferFundsBackToPoolInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1636, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1633, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 1651, + "src": "757:16:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1632, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "757:7:14", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1635, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1651, + "src": "775:12:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1634, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "775:4:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "756:32:14" + }, + "returnParameters": { + "id": 1637, + "nodeType": "ParameterList", + "parameters": [], + "src": "798:0:14" + }, + "scope": 1719, + "src": "716:212:14", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 1686, + "nodeType": "Block", + "src": "1032:266:14", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 1668, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 1660, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1655, + "src": "1045:8:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 1662, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1617, + "src": "1082:17:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 1663, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1822, + "src": "1082:44:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 1664, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1082:46:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1661, + "name": "INetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1932, + "src": "1057:24:14", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_INetworkMetadataProvider_$1932_$", + "typeString": "type(contract INetworkMetadataProvider)" + } + }, + "id": 1665, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1057:72:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 1666, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1926, + "src": "1057:91:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 1667, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1057:93:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1045:105:14", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 1677, + "nodeType": "IfStatement", + "src": "1042:185:14", + "trueBody": { + "id": 1676, + "nodeType": "Block", + "src": "1152:75:14", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1672, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1657, + "src": "1188:7:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 1669, + "name": "_destination", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1653, + "src": "1166:12:14", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 1671, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1166:21:14", + "typeDescriptions": { + "typeIdentifier": "t_function_transfer_nonpayable$_t_uint256_$returns$__$", + "typeString": "function (uint256)" + } + }, + "id": 1673, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1166:30:14", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1674, + "nodeType": "ExpressionStatement", + "src": "1166:30:14" + }, + { + "expression": null, + "functionReturnParameters": 1659, + "id": 1675, + "nodeType": "Return", + "src": "1210:7:14" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1682, + "name": "_destination", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1653, + "src": "1267:12:14", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 1683, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1657, + "src": "1281:7:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1679, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1655, + "src": "1244:8:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1678, + "name": "IERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11786, + "src": "1237:6:14", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IERC20_$11786_$", + "typeString": "type(contract IERC20)" + } + }, + "id": 1680, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1237:16:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 1681, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "safeTransfer", + "nodeType": "MemberAccess", + "referencedDeclaration": 11819, + "src": "1237:29:14", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$11786_$", + "typeString": "function (contract IERC20,address,uint256)" + } + }, + "id": 1684, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1237:52:14", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1685, + "nodeType": "ExpressionStatement", + "src": "1237:52:14" + } + ] + }, + "documentation": null, + "id": 1687, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "transferInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1658, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1653, + "name": "_destination", + "nodeType": "VariableDeclaration", + "scope": 1687, + "src": "960:28:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 1652, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "960:15:14", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1655, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 1687, + "src": "990:16:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1654, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "990:7:14", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1657, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1687, + "src": "1008:13:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1656, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "1008:4:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "959:63:14" + }, + "returnParameters": { + "id": 1659, + "nodeType": "ParameterList", + "parameters": [], + "src": "1032:0:14" + }, + "scope": 1719, + "src": "934:364:14", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 1717, + "nodeType": "Block", + "src": "1398:228:14", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 1704, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 1696, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1691, + "src": "1411:8:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 1698, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1617, + "src": "1448:17:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 1699, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1822, + "src": "1448:44:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 1700, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1448:46:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1697, + "name": "INetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1932, + "src": "1423:24:14", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_INetworkMetadataProvider_$1932_$", + "typeString": "type(contract INetworkMetadataProvider)" + } + }, + "id": 1701, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1423:72:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 1702, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1926, + "src": "1423:91:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 1703, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1423:93:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1411:105:14", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 1709, + "nodeType": "IfStatement", + "src": "1408:158:14", + "trueBody": { + "id": 1708, + "nodeType": "Block", + "src": "1518:48:14", + "statements": [ + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 1705, + "name": "_target", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1689, + "src": "1540:7:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 1706, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balance", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1540:15:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1695, + "id": 1707, + "nodeType": "Return", + "src": "1533:22:14" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1714, + "name": "_target", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1689, + "src": "1610:7:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1711, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1691, + "src": "1590:8:14", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1710, + "name": "IERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11786, + "src": "1583:6:14", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IERC20_$11786_$", + "typeString": "type(contract IERC20)" + } + }, + "id": 1712, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1583:16:14", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 1713, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOf", + "nodeType": "MemberAccess", + "referencedDeclaration": 11731, + "src": "1583:26:14", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 1715, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1583:35:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1695, + "id": 1716, + "nodeType": "Return", + "src": "1576:42:14" + } + ] + }, + "documentation": null, + "id": 1718, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getBalanceInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1692, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1689, + "name": "_target", + "nodeType": "VariableDeclaration", + "scope": 1718, + "src": "1332:15:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1688, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1332:7:14", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1691, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 1718, + "src": "1349:16:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1690, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1349:7:14", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1331:35:14" + }, + "returnParameters": { + "id": 1695, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1694, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1718, + "src": "1389:7:14", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1693, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1389:7:14", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1388:9:14" + }, + "scope": 1719, + "src": "1304:322:14", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 1720, + "src": "383:1245:14" + } + ], + "src": "0:1628:14" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.588Z", + "devdoc": { + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/FlashLoanReceiverExample.json b/client/src/contracts/FlashLoanReceiverExample.json new file mode 100644 index 0000000..c2c4883 --- /dev/null +++ b/client/src/contracts/FlashLoanReceiverExample.json @@ -0,0 +1,2155 @@ +{ + "contractName": "FlashLoanReceiverExample", + "abi": [ + { + "inputs": [ + { + "name": "_provider", + "type": "address" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "name": "_reserve", + "type": "address" + }, + { + "indexed": false, + "name": "_amount", + "type": "uint256" + }, + { + "indexed": false, + "name": "_value", + "type": "uint256" + } + ], + "name": "borrowMade", + "type": "event" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + }, + { + "name": "_fee", + "type": "uint256" + } + ], + "name": "executeOperation", + "outputs": [ + { + "name": "returnedAmount", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_fee\",\"type\":\"uint256\"}],\"name\":\"executeOperation\",\"outputs\":[{\"name\":\"returnedAmount\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_provider\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"fallback\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_value\",\"type\":\"uint256\"}],\"name\":\"borrowMade\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/FlashLoanReceiverExample.sol\":\"FlashLoanReceiverExample\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/FlashLoanReceiverExample.sol\":{\"keccak256\":\"0xede7212c540fa88511c9c22103ac02315abb3f69f4304dccd71c1579e8714c75\",\"urls\":[\"bzzr://5c6c3329385111a21fa025c9a71a0482765029459aa04a78477c135a26f9cc6d\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x0ae6004410cd58a1c5151e67959167cf58cd5e77e8b625677826e295905fb318\",\"urls\":[\"bzzr://d223bea23f0e9bd70844e9852f490be93d30fc1c31bf114c807d0e4fe07d929b\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol\":{\"keccak256\":\"0x479a8627304b58f37a4adbe06a72c7a056ad7ce6793a4ea66deeba04c6e443c8\",\"urls\":[\"bzzr://92bb0ae9b38ab361638c71c81f650ff8115da42cb4f50a0ee7a6fb5e03e5e640\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol\":{\"keccak256\":\"0x3f74e899243a66d556c0fa81875ab95ed1e3af1909b0281d03fe89590b95121f\",\"urls\":[\"bzzr://ef6ed6edeb1ec124bf1749991346f0708214f7e12c353175d36b491bce45d7a4\"]},\"/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol\":{\"keccak256\":\"0xa05bc60cdbae1ae13832a9e45726487f20de2ef8f2cdf7ccbbdab69e782b867d\",\"urls\":[\"bzzr://31b41cf73f764af450fdb49b224012e1100302b84ba7ec0596f97417361b6f24\"]},\"/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol\":{\"keccak256\":\"0x3b825dc98b6a7aa21e9c9b05e1951bec7b5d7c84b7a0e8de0750069ccb31ebac\",\"urls\":[\"bzzr://8a616caca158d63de8db6037a2162c1effaaa71f6d7095a11516e03f7ea391d0\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]}},\"version\":1}", + "bytecode": "0x608060405234801561001057600080fd5b50604051602080610b738339810180604052602081101561003057600080fd5b810190808051906020019092919050505080806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505050610ae0806100936000396000f3fe60806040526004361061001e5760003560e01c80638b514f8c14610020575b005b34801561002c57600080fd5b506100836004803603606081101561004357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190505050610099565b6040518082815260200191505060405180910390f35b60006100a530856101dc565b83111561011a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f496e76616c69642062616c616e636520666f722074686520636f6e747261637481525060200191505060405180910390fd5b7fcd8f01cf11df8ac6e385851ab2495f5370eff19deb3c99a29b542b49d32ba0ba84843073ffffffffffffffffffffffffffffffffffffffff1631604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a16101c0846101bb848661041390919063ffffffff16565b61049b565b6101d3828461041390919063ffffffff16565b90509392505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b15801561024557600080fd5b505afa158015610259573d6000803e3d6000fd5b505050506040513d602081101561026f57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b1580156102c557600080fd5b505afa1580156102d9573d6000803e3d6000fd5b505050506040513d60208110156102ef57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610352578273ffffffffffffffffffffffffffffffffffffffff1631905061040d565b8173ffffffffffffffffffffffffffffffffffffffff166370a08231846040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156103cf57600080fd5b505afa1580156103e3573d6000803e3d6000fd5b505050506040513d60208110156103f957600080fd5b810190808051906020019092919050505090505b92915050565b600080828401905083811015610491576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801561050457600080fd5b505afa158015610518573d6000803e3d6000fd5b505050506040513d602081101561052e57600080fd5b8101908080519060200190929190505050905061054c818484610551565b505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b1580156105b857600080fd5b505afa1580156105cc573d6000803e3d6000fd5b505050506040513d60208110156105e257600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b15801561063857600080fd5b505afa15801561064c573d6000803e3d6000fd5b505050506040513d602081101561066257600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156106f2578273ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f193505050501580156106ec573d6000803e3d6000fd5b5061071e565b61071d83828473ffffffffffffffffffffffffffffffffffffffff166107239092919063ffffffff16565b5b505050565b6107ef838473ffffffffffffffffffffffffffffffffffffffff1663a9059cbb905060e01b8484604051602401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506107f4565b505050565b6108138273ffffffffffffffffffffffffffffffffffffffff16610a3f565b610885576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e74726163740081525060200191505060405180910390fd5b600060608373ffffffffffffffffffffffffffffffffffffffff16836040518082805190602001908083835b602083106108d457805182526020820191506020810190506020830392506108b1565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114610936576040519150601f19603f3d011682016040523d82523d6000602084013e61093b565b606091505b5091509150816109b3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656481525060200191505060405180910390fd5b600081511115610a39578080602001905160208110156109d257600080fd5b8101908080519060200190929190505050610a38576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180610a8b602a913960400191505060405180910390fd5b5b50505050565b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f91506000801b8214158015610a815750808214155b9250505091905056fe5361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a165627a7a72305820e64a0003cedcb75bf531d1d01eee07219361068080e5d8463dc21afcbfdf56150029", + "deployedBytecode": "0x60806040526004361061001e5760003560e01c80638b514f8c14610020575b005b34801561002c57600080fd5b506100836004803603606081101561004357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190505050610099565b6040518082815260200191505060405180910390f35b60006100a530856101dc565b83111561011a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f496e76616c69642062616c616e636520666f722074686520636f6e747261637481525060200191505060405180910390fd5b7fcd8f01cf11df8ac6e385851ab2495f5370eff19deb3c99a29b542b49d32ba0ba84843073ffffffffffffffffffffffffffffffffffffffff1631604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a16101c0846101bb848661041390919063ffffffff16565b61049b565b6101d3828461041390919063ffffffff16565b90509392505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b15801561024557600080fd5b505afa158015610259573d6000803e3d6000fd5b505050506040513d602081101561026f57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b1580156102c557600080fd5b505afa1580156102d9573d6000803e3d6000fd5b505050506040513d60208110156102ef57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610352578273ffffffffffffffffffffffffffffffffffffffff1631905061040d565b8173ffffffffffffffffffffffffffffffffffffffff166370a08231846040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156103cf57600080fd5b505afa1580156103e3573d6000803e3d6000fd5b505050506040513d60208110156103f957600080fd5b810190808051906020019092919050505090505b92915050565b600080828401905083811015610491576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801561050457600080fd5b505afa158015610518573d6000803e3d6000fd5b505050506040513d602081101561052e57600080fd5b8101908080519060200190929190505050905061054c818484610551565b505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b1580156105b857600080fd5b505afa1580156105cc573d6000803e3d6000fd5b505050506040513d60208110156105e257600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b15801561063857600080fd5b505afa15801561064c573d6000803e3d6000fd5b505050506040513d602081101561066257600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156106f2578273ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f193505050501580156106ec573d6000803e3d6000fd5b5061071e565b61071d83828473ffffffffffffffffffffffffffffffffffffffff166107239092919063ffffffff16565b5b505050565b6107ef838473ffffffffffffffffffffffffffffffffffffffff1663a9059cbb905060e01b8484604051602401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506107f4565b505050565b6108138273ffffffffffffffffffffffffffffffffffffffff16610a3f565b610885576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e74726163740081525060200191505060405180910390fd5b600060608373ffffffffffffffffffffffffffffffffffffffff16836040518082805190602001908083835b602083106108d457805182526020820191506020810190506020830392506108b1565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114610936576040519150601f19603f3d011682016040523d82523d6000602084013e61093b565b606091505b5091509150816109b3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656481525060200191505060405180910390fd5b600081511115610a39578080602001905160208110156109d257600080fd5b8101908080519060200190929190505050610a38576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180610a8b602a913960400191505060405180910390fd5b5b50505050565b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f91506000801b8214158015610a815750808214155b9250505091905056fe5361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a165627a7a72305820e64a0003cedcb75bf531d1d01eee07219361068080e5d8463dc21afcbfdf56150029", + "sourceMap": "296:885:1:-;;;485:102;8:9:-1;5:2;;;30:1;27;20:12;5:2;485:102:1;;;;;;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;485:102:1;;;;;;;;;;;;;;;;559:9;652::14;632:17;;:29;;;;;;;;;;;;;;;;;;562:106;485:102:1;296:885;;;;;;", + "deployedSourceMap": "296:885:1:-;;;;;;;;;;;;;;;;;;;594:585;;8:9:-1;5:2;;;30:1;27;20:12;5:2;594:585:1;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;594:585:1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;711:22;820:43;847:4;854:8;820:18;:43::i;:::-;809:7;:54;;801:111;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1014:53;1025:8;1035:7;1053:4;1045:21;;;1014:53;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1078:60;1110:8;1120:17;1132:4;1120:7;:11;;:17;;;;:::i;:::-;1078:31;:60::i;:::-;1155:17;1167:4;1155:7;:11;;:17;;;;:::i;:::-;1148:24;;594:585;;;;;:::o;1304:322:14:-;1389:7;1448:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1448:46:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1448:46:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1448:46:14;;;;;;;;;;;;;;;;1423:91;;;:93;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1423:93:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1423:93:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1423:93:14;;;;;;;;;;;;;;;;1411:105;;:8;:105;;;1408:158;;;1540:7;:15;;;1533:22;;;;1408:158;1590:8;1583:26;;;1610:7;1583:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1583:35:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1583:35:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1583:35:14;;;;;;;;;;;;;;;;1576:42;;1304:322;;;;;:::o;834:176:56:-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;716:212:14:-;809:20;832:17;;;;;;;;;;;:36;;;:38;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;832:38:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;832:38:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;832:38:14;;;;;;;;;;;;;;;;809:61;;881:40;898:4;903:8;913:7;881:16;:40::i;:::-;716:212;;;:::o;934:364::-;1082:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1082:46:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1082:46:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1082:46:14;;;;;;;;;;;;;;;;1057:91;;;:93;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1057:93:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1057:93:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1057:93:14;;;;;;;;;;;;;;;;1045:105;;:8;:105;;;1042:185;;;1166:12;:21;;:30;1188:7;1166:30;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1166:30:14;1210:7;;1042:185;1237:52;1267:12;1281:7;1244:8;1237:29;;;;:52;;;;;:::i;:::-;934:364;;;;:::o;662:174:61:-;744:85;763:5;793;:14;;;:23;;;;818:2;822:5;770:58;;;;;;;;;;;;;;;;;;;;;;;;;49:4:-1;39:7;30;26:21;22:32;13:7;6:49;770:58:61;;;;;;;38:4:-1;29:7;25:18;67:10;61:17;96:58;199:8;192:4;186;182:15;179:29;167:10;160:49;0:215;;;770:58:61;744:18;:85::i;:::-;662:174;;;:::o;2666:1095::-;3261:27;3269:5;3261:25;;;:27::i;:::-;3253:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3395:12;3409:23;3444:5;3436:19;;3456:4;3436:25;;;;;;;;;;;;;36:153:-1;66:2;61:3;58:11;36:153;;182:3;176:10;171:3;164:23;98:2;93:3;89:12;82:19;;123:2;118:3;114:12;107:19;;148:2;143:3;139:12;132:19;;36:153;;;274:1;267:3;263:2;259:12;254:3;250:22;246:30;315:4;311:9;305:3;299:10;295:26;356:4;350:3;344:10;340:21;389:7;380;377:20;372:3;365:33;3:399;;;3436:25:61;;;;;;;;;;;;;;;;;;;;;;;;14:1:-1;21;16:31;;;;75:4;69:11;64:16;;144:4;140:9;133:4;115:16;111:27;107:43;104:1;100:51;94:4;87:65;169:16;166:1;159:27;225:16;222:1;215:4;212:1;208:12;193:49;7:242;;16:31;36:4;31:9;;7:242;;3394:67:61;;;;3479:7;3471:52;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3558:1;3538:10;:17;:21;3534:221;;;3678:10;3667:30;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3667:30:61;;;;;;;;;;;;;;;;3659:85;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3534:221;2666:1095;;;;:::o;557:797:62:-;617:4;1062:16;1088:19;1110:66;1088:88;;;;1277:7;1265:20;1253:32;;1316:3;1304:15;;:8;:15;;:42;;;;;1335:11;1323:8;:23;;1304:42;1296:51;;;;557:797;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\n\nimport \"./mocks/tokens/MintableERC20.sol\";\nimport \"./flashloan/base/FlashLoanReceiverBase.sol\";\nimport \"./configuration/LendingPoolAddressesProvider.sol\";\nimport \"./configuration/NetworkMetadataProvider.sol\";\n\ncontract FlashLoanReceiverExample is FlashLoanReceiverBase {\n\n using SafeMath for uint256;\n\n // Events\n event borrowMade(address _reserve, uint256 _amount , uint256 _value);\n\n\n constructor(LendingPoolAddressesProvider _provider) FlashLoanReceiverBase(_provider)\n public {}\n\n\n function executeOperation(\n address _reserve,\n uint256 _amount,\n uint256 _fee) external returns(uint256 returnedAmount) {\n\n //check the contract has the specified balance\n require(_amount <= getBalanceInternal(address(this), _reserve),\n \"Invalid balance for the contract\");\n\n /**\n\n CUSTOM ACTION TO PERFORM WITH THE BORROWED LIQUIDITY\n\n */\n emit borrowMade(_reserve, _amount , address(this).balance);\n\n transferFundsBackToPoolInternal(_reserve, _amount.add(_fee));\n return _amount.add(_fee);\n }\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/FlashLoanReceiverExample.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/FlashLoanReceiverExample.sol", + "exportedSymbols": { + "FlashLoanReceiverExample": [ + 81 + ] + }, + "id": 82, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 7, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:1" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 8, + "nodeType": "ImportDirective", + "scope": 82, + "sourceUnit": 11141, + "src": "25:59:1", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./mocks/tokens/MintableERC20.sol", + "id": 9, + "nodeType": "ImportDirective", + "scope": 82, + "sourceUnit": 9600, + "src": "86:42:1", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol", + "file": "./flashloan/base/FlashLoanReceiverBase.sol", + "id": 10, + "nodeType": "ImportDirective", + "scope": 82, + "sourceUnit": 1720, + "src": "129:52:1", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "./configuration/LendingPoolAddressesProvider.sol", + "id": 11, + "nodeType": "ImportDirective", + "scope": 82, + "sourceUnit": 1358, + "src": "182:58:1", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "file": "./configuration/NetworkMetadataProvider.sol", + "id": 12, + "nodeType": "ImportDirective", + "scope": 82, + "sourceUnit": 1479, + "src": "241:53:1", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 13, + "name": "FlashLoanReceiverBase", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1719, + "src": "333:21:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_FlashLoanReceiverBase_$1719", + "typeString": "contract FlashLoanReceiverBase" + } + }, + "id": 14, + "nodeType": "InheritanceSpecifier", + "src": "333:21:1" + } + ], + "contractDependencies": [ + 1719, + 1733 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 81, + "linearizedBaseContracts": [ + 81, + 1719, + 1733 + ], + "name": "FlashLoanReceiverExample", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 17, + "libraryName": { + "contractScope": null, + "id": 15, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "368:8:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "362:27:1", + "typeName": { + "id": 16, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "381:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "anonymous": false, + "documentation": null, + "id": 25, + "name": "borrowMade", + "nodeType": "EventDefinition", + "parameters": { + "id": 24, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 19, + "indexed": false, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 25, + "src": "426:16:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 18, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "426:7:1", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 21, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 25, + "src": "444:15:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 20, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "444:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 23, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 25, + "src": "462:14:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 22, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "462:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "425:52:1" + }, + "src": "409:69:1" + }, + { + "body": { + "id": 33, + "nodeType": "Block", + "src": "585:2:1", + "statements": [] + }, + "documentation": null, + "id": 34, + "implemented": true, + "kind": "constructor", + "modifiers": [ + { + "arguments": [ + { + "argumentTypes": null, + "id": 30, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 27, + "src": "559:9:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + } + ], + "id": 31, + "modifierName": { + "argumentTypes": null, + "id": 29, + "name": "FlashLoanReceiverBase", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1719, + "src": "537:21:1", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_FlashLoanReceiverBase_$1719_$", + "typeString": "type(contract FlashLoanReceiverBase)" + } + }, + "nodeType": "ModifierInvocation", + "src": "537:32:1" + } + ], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 28, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 27, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 34, + "src": "497:38:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 26, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "497:28:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "496:40:1" + }, + "returnParameters": { + "id": 32, + "nodeType": "ParameterList", + "parameters": [], + "src": "585:0:1" + }, + "scope": 81, + "src": "485:102:1", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 79, + "nodeType": "Block", + "src": "735:444:1", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 53, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 46, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 38, + "src": "809:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<=", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 49, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12180, + "src": "847:4:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_FlashLoanReceiverExample_$81", + "typeString": "contract FlashLoanReceiverExample" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_FlashLoanReceiverExample_$81", + "typeString": "contract FlashLoanReceiverExample" + } + ], + "id": 48, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "839:7:1", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 50, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "839:13:1", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 51, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 36, + "src": "854:8:1", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 47, + "name": "getBalanceInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1718, + "src": "820:18:1", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view returns (uint256)" + } + }, + "id": 52, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "820:43:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "809:54:1", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c69642062616c616e636520666f722074686520636f6e7472616374", + "id": 54, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "877:34:1", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_b7eb1acc2a916521532d41db798e862e3bc634b536ffa4062c39b663132b6869", + "typeString": "literal_string \"Invalid balance for the contract\"" + }, + "value": "Invalid balance for the contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_b7eb1acc2a916521532d41db798e862e3bc634b536ffa4062c39b663132b6869", + "typeString": "literal_string \"Invalid balance for the contract\"" + } + ], + "id": 45, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "801:7:1", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 55, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "801:111:1", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 56, + "nodeType": "ExpressionStatement", + "src": "801:111:1" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 58, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 36, + "src": "1025:8:1", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 59, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 38, + "src": "1035:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 61, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12180, + "src": "1053:4:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_FlashLoanReceiverExample_$81", + "typeString": "contract FlashLoanReceiverExample" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_FlashLoanReceiverExample_$81", + "typeString": "contract FlashLoanReceiverExample" + } + ], + "id": 60, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1045:7:1", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 62, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1045:13:1", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 63, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balance", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1045:21:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 57, + "name": "borrowMade", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 25, + "src": "1014:10:1", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256)" + } + }, + "id": 64, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1014:53:1", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 65, + "nodeType": "EmitStatement", + "src": "1009:58:1" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 67, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 36, + "src": "1110:8:1", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 70, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 40, + "src": "1132:4:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 68, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 38, + "src": "1120:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 69, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1120:11:1", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 71, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1120:17:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 66, + "name": "transferFundsBackToPoolInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1651, + "src": "1078:31:1", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 72, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1078:60:1", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 73, + "nodeType": "ExpressionStatement", + "src": "1078:60:1" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 76, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 40, + "src": "1167:4:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 74, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 38, + "src": "1155:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 75, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1155:11:1", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 77, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1155:17:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 44, + "id": 78, + "nodeType": "Return", + "src": "1148:24:1" + } + ] + }, + "documentation": null, + "id": 80, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "executeOperation", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 41, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 36, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 80, + "src": "629:16:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "629:7:1", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 38, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 80, + "src": "655:15:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 37, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "655:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 40, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 80, + "src": "680:12:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 39, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "680:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "619:74:1" + }, + "returnParameters": { + "id": 44, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 43, + "name": "returnedAmount", + "nodeType": "VariableDeclaration", + "scope": 80, + "src": "711:22:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 42, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "711:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "710:24:1" + }, + "scope": 81, + "src": "594:585:1", + "stateMutability": "nonpayable", + "superFunction": 1732, + "visibility": "external" + } + ], + "scope": 82, + "src": "296:885:1" + } + ], + "src": "0:1182:1" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/FlashLoanReceiverExample.sol", + "exportedSymbols": { + "FlashLoanReceiverExample": [ + 81 + ] + }, + "id": 82, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 7, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:1" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 8, + "nodeType": "ImportDirective", + "scope": 82, + "sourceUnit": 11141, + "src": "25:59:1", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./mocks/tokens/MintableERC20.sol", + "id": 9, + "nodeType": "ImportDirective", + "scope": 82, + "sourceUnit": 9600, + "src": "86:42:1", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol", + "file": "./flashloan/base/FlashLoanReceiverBase.sol", + "id": 10, + "nodeType": "ImportDirective", + "scope": 82, + "sourceUnit": 1720, + "src": "129:52:1", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "./configuration/LendingPoolAddressesProvider.sol", + "id": 11, + "nodeType": "ImportDirective", + "scope": 82, + "sourceUnit": 1358, + "src": "182:58:1", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "file": "./configuration/NetworkMetadataProvider.sol", + "id": 12, + "nodeType": "ImportDirective", + "scope": 82, + "sourceUnit": 1479, + "src": "241:53:1", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 13, + "name": "FlashLoanReceiverBase", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1719, + "src": "333:21:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_FlashLoanReceiverBase_$1719", + "typeString": "contract FlashLoanReceiverBase" + } + }, + "id": 14, + "nodeType": "InheritanceSpecifier", + "src": "333:21:1" + } + ], + "contractDependencies": [ + 1719, + 1733 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 81, + "linearizedBaseContracts": [ + 81, + 1719, + 1733 + ], + "name": "FlashLoanReceiverExample", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 17, + "libraryName": { + "contractScope": null, + "id": 15, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "368:8:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "362:27:1", + "typeName": { + "id": 16, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "381:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "anonymous": false, + "documentation": null, + "id": 25, + "name": "borrowMade", + "nodeType": "EventDefinition", + "parameters": { + "id": 24, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 19, + "indexed": false, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 25, + "src": "426:16:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 18, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "426:7:1", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 21, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 25, + "src": "444:15:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 20, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "444:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 23, + "indexed": false, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 25, + "src": "462:14:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 22, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "462:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "425:52:1" + }, + "src": "409:69:1" + }, + { + "body": { + "id": 33, + "nodeType": "Block", + "src": "585:2:1", + "statements": [] + }, + "documentation": null, + "id": 34, + "implemented": true, + "kind": "constructor", + "modifiers": [ + { + "arguments": [ + { + "argumentTypes": null, + "id": 30, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 27, + "src": "559:9:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + } + ], + "id": 31, + "modifierName": { + "argumentTypes": null, + "id": 29, + "name": "FlashLoanReceiverBase", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1719, + "src": "537:21:1", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_FlashLoanReceiverBase_$1719_$", + "typeString": "type(contract FlashLoanReceiverBase)" + } + }, + "nodeType": "ModifierInvocation", + "src": "537:32:1" + } + ], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 28, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 27, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 34, + "src": "497:38:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 26, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "497:28:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "496:40:1" + }, + "returnParameters": { + "id": 32, + "nodeType": "ParameterList", + "parameters": [], + "src": "585:0:1" + }, + "scope": 81, + "src": "485:102:1", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 79, + "nodeType": "Block", + "src": "735:444:1", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 53, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 46, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 38, + "src": "809:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<=", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 49, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12180, + "src": "847:4:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_FlashLoanReceiverExample_$81", + "typeString": "contract FlashLoanReceiverExample" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_FlashLoanReceiverExample_$81", + "typeString": "contract FlashLoanReceiverExample" + } + ], + "id": 48, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "839:7:1", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 50, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "839:13:1", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 51, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 36, + "src": "854:8:1", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 47, + "name": "getBalanceInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1718, + "src": "820:18:1", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view returns (uint256)" + } + }, + "id": 52, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "820:43:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "809:54:1", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c69642062616c616e636520666f722074686520636f6e7472616374", + "id": 54, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "877:34:1", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_b7eb1acc2a916521532d41db798e862e3bc634b536ffa4062c39b663132b6869", + "typeString": "literal_string \"Invalid balance for the contract\"" + }, + "value": "Invalid balance for the contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_b7eb1acc2a916521532d41db798e862e3bc634b536ffa4062c39b663132b6869", + "typeString": "literal_string \"Invalid balance for the contract\"" + } + ], + "id": 45, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "801:7:1", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 55, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "801:111:1", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 56, + "nodeType": "ExpressionStatement", + "src": "801:111:1" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 58, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 36, + "src": "1025:8:1", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 59, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 38, + "src": "1035:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 61, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12180, + "src": "1053:4:1", + "typeDescriptions": { + "typeIdentifier": "t_contract$_FlashLoanReceiverExample_$81", + "typeString": "contract FlashLoanReceiverExample" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_FlashLoanReceiverExample_$81", + "typeString": "contract FlashLoanReceiverExample" + } + ], + "id": 60, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1045:7:1", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 62, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1045:13:1", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 63, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balance", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1045:21:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 57, + "name": "borrowMade", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 25, + "src": "1014:10:1", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256)" + } + }, + "id": 64, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1014:53:1", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 65, + "nodeType": "EmitStatement", + "src": "1009:58:1" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 67, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 36, + "src": "1110:8:1", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 70, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 40, + "src": "1132:4:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 68, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 38, + "src": "1120:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 69, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1120:11:1", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 71, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1120:17:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 66, + "name": "transferFundsBackToPoolInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1651, + "src": "1078:31:1", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 72, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1078:60:1", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 73, + "nodeType": "ExpressionStatement", + "src": "1078:60:1" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 76, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 40, + "src": "1167:4:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 74, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 38, + "src": "1155:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 75, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1155:11:1", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 77, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1155:17:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 44, + "id": 78, + "nodeType": "Return", + "src": "1148:24:1" + } + ] + }, + "documentation": null, + "id": 80, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "executeOperation", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 41, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 36, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 80, + "src": "629:16:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 35, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "629:7:1", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 38, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 80, + "src": "655:15:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 37, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "655:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 40, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 80, + "src": "680:12:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 39, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "680:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "619:74:1" + }, + "returnParameters": { + "id": 44, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 43, + "name": "returnedAmount", + "nodeType": "VariableDeclaration", + "scope": 80, + "src": "711:22:1", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 42, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "711:7:1", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "710:24:1" + }, + "scope": 81, + "src": "594:585:1", + "stateMutability": "nonpayable", + "superFunction": 1732, + "visibility": "external" + } + ], + "scope": 82, + "src": "296:885:1" + } + ], + "src": "0:1182:1" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": { + "42": { + "events": { + "0xcd8f01cf11df8ac6e385851ab2495f5370eff19deb3c99a29b542b49d32ba0ba": { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "name": "_reserve", + "type": "address" + }, + { + "indexed": false, + "name": "_amount", + "type": "uint256" + }, + { + "indexed": false, + "name": "_value", + "type": "uint256" + } + ], + "name": "borrowMade", + "type": "event", + "signature": "0xcd8f01cf11df8ac6e385851ab2495f5370eff19deb3c99a29b542b49d32ba0ba" + } + }, + "links": {}, + "address": "0xb544f44905dBc94e096576898debAD22b6A2F3C1", + "transactionHash": "0xe49876124c964382bd8707ec9f7c816d14c38b23383d3ea543049d38b1ba9718" + } + }, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T15:21:05.389Z", + "devdoc": { + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/IERC20.json b/client/src/contracts/IERC20.json index a9667ba..611a754 100644 --- a/client/src/contracts/IERC20.json +++ b/client/src/contracts/IERC20.json @@ -175,25 +175,25 @@ "type": "function" } ], - "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"details\":\"Interface of the ERC20 standard as defined in the EIP. Does not include the optional functions; to access them see `ERC20Detailed`.\",\"methods\":{\"allowance(address,address)\":{\"details\":\"Returns the remaining number of tokens that `spender` will be allowed to spend on behalf of `owner` through `transferFrom`. This is zero by default. * This value changes when `approve` or `transferFrom` are called.\"},\"approve(address,uint256)\":{\"details\":\"Sets `amount` as the allowance of `spender` over the caller's tokens. * Returns a boolean value indicating whether the operation succeeded. * > Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * Emits an `Approval` event.\"},\"balanceOf(address)\":{\"details\":\"Returns the amount of tokens owned by `account`.\"},\"totalSupply()\":{\"details\":\"Returns the amount of tokens in existence.\"},\"transfer(address,uint256)\":{\"details\":\"Moves `amount` tokens from the caller's account to `recipient`. * Returns a boolean value indicating whether the operation succeeded. * Emits a `Transfer` event.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"Moves `amount` tokens from `sender` to `recipient` using the allowance mechanism. `amount` is then deducted from the caller's allowance. * Returns a boolean value indicating whether the operation succeeded. * Emits a `Transfer` event.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"@openzeppelin/contracts/token/ERC20/IERC20.sol\":\"IERC20\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0x90e8c2521653bbb1768b05889c5760031e688d9cd361f167489b89215e201b95\",\"urls\":[\"bzzr://aa8b45b57edafc3d67bc5d916327ea16807fae33f753ca163ae0c4061b789766\"]}},\"version\":1}", + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"details\":\"Interface of the ERC20 standard as defined in the EIP. Does not include the optional functions; to access them see {ERC20Detailed}.\",\"methods\":{\"allowance(address,address)\":{\"details\":\"Returns the remaining number of tokens that `spender` will be allowed to spend on behalf of `owner` through {transferFrom}. This is zero by default. * This value changes when {approve} or {transferFrom} are called.\"},\"approve(address,uint256)\":{\"details\":\"Sets `amount` as the allowance of `spender` over the caller's tokens. * Returns a boolean value indicating whether the operation succeeded. * IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * Emits an {Approval} event.\"},\"balanceOf(address)\":{\"details\":\"Returns the amount of tokens owned by `account`.\"},\"totalSupply()\":{\"details\":\"Returns the amount of tokens in existence.\"},\"transfer(address,uint256)\":{\"details\":\"Moves `amount` tokens from the caller's account to `recipient`. * Returns a boolean value indicating whether the operation succeeded. * Emits a {Transfer} event.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"Moves `amount` tokens from `sender` to `recipient` using the allowance mechanism. `amount` is then deducted from the caller's allowance. * Returns a boolean value indicating whether the operation succeeded. * Emits a {Transfer} event.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":\"IERC20\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", "bytecode": "0x", "deployedBytecode": "0x", "sourceMap": "", "deployedSourceMap": "", - "source": "pragma solidity ^0.5.0;\n\n/**\n * @dev Interface of the ERC20 standard as defined in the EIP. Does not include\n * the optional functions; to access them see `ERC20Detailed`.\n */\ninterface IERC20 {\n /**\n * @dev Returns the amount of tokens in existence.\n */\n function totalSupply() external view returns (uint256);\n\n /**\n * @dev Returns the amount of tokens owned by `account`.\n */\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * @dev Moves `amount` tokens from the caller's account to `recipient`.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * Emits a `Transfer` event.\n */\n function transfer(address recipient, uint256 amount) external returns (bool);\n\n /**\n * @dev Returns the remaining number of tokens that `spender` will be\n * allowed to spend on behalf of `owner` through `transferFrom`. This is\n * zero by default.\n *\n * This value changes when `approve` or `transferFrom` are called.\n */\n function allowance(address owner, address spender) external view returns (uint256);\n\n /**\n * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * > Beware that changing an allowance with this method brings the risk\n * that someone may use both the old and the new allowance by unfortunate\n * transaction ordering. One possible solution to mitigate this race\n * condition is to first reduce the spender's allowance to 0 and set the\n * desired value afterwards:\n * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729\n *\n * Emits an `Approval` event.\n */\n function approve(address spender, uint256 amount) external returns (bool);\n\n /**\n * @dev Moves `amount` tokens from `sender` to `recipient` using the\n * allowance mechanism. `amount` is then deducted from the caller's\n * allowance.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * Emits a `Transfer` event.\n */\n function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);\n\n /**\n * @dev Emitted when `value` tokens are moved from one account (`from`) to\n * another (`to`).\n *\n * Note that `value` may be zero.\n */\n event Transfer(address indexed from, address indexed to, uint256 value);\n\n /**\n * @dev Emitted when the allowance of a `spender` for an `owner` is set by\n * a call to `approve`. `value` is the new allowance.\n */\n event Approval(address indexed owner, address indexed spender, uint256 value);\n}\n", - "sourcePath": "@openzeppelin/contracts/token/ERC20/IERC20.sol", + "source": "pragma solidity ^0.5.0;\n\n/**\n * @dev Interface of the ERC20 standard as defined in the EIP. Does not include\n * the optional functions; to access them see {ERC20Detailed}.\n */\ninterface IERC20 {\n /**\n * @dev Returns the amount of tokens in existence.\n */\n function totalSupply() external view returns (uint256);\n\n /**\n * @dev Returns the amount of tokens owned by `account`.\n */\n function balanceOf(address account) external view returns (uint256);\n\n /**\n * @dev Moves `amount` tokens from the caller's account to `recipient`.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * Emits a {Transfer} event.\n */\n function transfer(address recipient, uint256 amount) external returns (bool);\n\n /**\n * @dev Returns the remaining number of tokens that `spender` will be\n * allowed to spend on behalf of `owner` through {transferFrom}. This is\n * zero by default.\n *\n * This value changes when {approve} or {transferFrom} are called.\n */\n function allowance(address owner, address spender) external view returns (uint256);\n\n /**\n * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * IMPORTANT: Beware that changing an allowance with this method brings the risk\n * that someone may use both the old and the new allowance by unfortunate\n * transaction ordering. One possible solution to mitigate this race\n * condition is to first reduce the spender's allowance to 0 and set the\n * desired value afterwards:\n * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729\n *\n * Emits an {Approval} event.\n */\n function approve(address spender, uint256 amount) external returns (bool);\n\n /**\n * @dev Moves `amount` tokens from `sender` to `recipient` using the\n * allowance mechanism. `amount` is then deducted from the caller's\n * allowance.\n *\n * Returns a boolean value indicating whether the operation succeeded.\n *\n * Emits a {Transfer} event.\n */\n function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);\n\n /**\n * @dev Emitted when `value` tokens are moved from one account (`from`) to\n * another (`to`).\n *\n * Note that `value` may be zero.\n */\n event Transfer(address indexed from, address indexed to, uint256 value);\n\n /**\n * @dev Emitted when the allowance of a `spender` for an `owner` is set by\n * a call to {approve}. `value` is the new allowance.\n */\n event Approval(address indexed owner, address indexed spender, uint256 value);\n}\n", + "sourcePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", "ast": { - "absolutePath": "@openzeppelin/contracts/token/ERC20/IERC20.sol", + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", "exportedSymbols": { "IERC20": [ - 1443 + 11786 ] }, - "id": 1444, + "id": 11787, "nodeType": "SourceUnit", "nodes": [ { - "id": 1376, + "id": 11719, "literals": [ "solidity", "^", @@ -201,17 +201,17 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:9" + "src": "0:23:60" }, { "baseContracts": [], "contractDependencies": [], "contractKind": "interface", - "documentation": "@dev Interface of the ERC20 standard as defined in the EIP. Does not include\nthe optional functions; to access them see `ERC20Detailed`.", + "documentation": "@dev Interface of the ERC20 standard as defined in the EIP. Does not include\nthe optional functions; to access them see {ERC20Detailed}.", "fullyImplemented": false, - "id": 1443, + "id": 11786, "linearizedBaseContracts": [ - 1443 + 11786 ], "name": "IERC20", "nodeType": "ContractDefinition", @@ -219,29 +219,29 @@ { "body": null, "documentation": "@dev Returns the amount of tokens in existence.", - "id": 1381, + "id": 11724, "implemented": false, "kind": "function", "modifiers": [], "name": "totalSupply", "nodeType": "FunctionDefinition", "parameters": { - "id": 1377, + "id": 11720, "nodeType": "ParameterList", "parameters": [], - "src": "290:2:9" + "src": "290:2:60" }, "returnParameters": { - "id": 1380, + "id": 11723, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1379, + "id": 11722, "name": "", "nodeType": "VariableDeclaration", - "scope": 1381, - "src": "316:7:9", + "scope": 11724, + "src": "316:7:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -249,10 +249,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1378, + "id": 11721, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "316:7:9", + "src": "316:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -262,10 +262,10 @@ "visibility": "internal" } ], - "src": "315:9:9" + "src": "315:9:60" }, - "scope": 1443, - "src": "270:55:9", + "scope": 11786, + "src": "270:55:60", "stateMutability": "view", "superFunction": null, "visibility": "external" @@ -273,23 +273,23 @@ { "body": null, "documentation": "@dev Returns the amount of tokens owned by `account`.", - "id": 1388, + "id": 11731, "implemented": false, "kind": "function", "modifiers": [], "name": "balanceOf", "nodeType": "FunctionDefinition", "parameters": { - "id": 1384, + "id": 11727, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1383, + "id": 11726, "name": "account", "nodeType": "VariableDeclaration", - "scope": 1388, - "src": "427:15:9", + "scope": 11731, + "src": "427:15:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -297,10 +297,10 @@ "typeString": "address" }, "typeName": { - "id": 1382, + "id": 11725, "name": "address", "nodeType": "ElementaryTypeName", - "src": "427:7:9", + "src": "427:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -311,19 +311,19 @@ "visibility": "internal" } ], - "src": "426:17:9" + "src": "426:17:60" }, "returnParameters": { - "id": 1387, + "id": 11730, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1386, + "id": 11729, "name": "", "nodeType": "VariableDeclaration", - "scope": 1388, - "src": "467:7:9", + "scope": 11731, + "src": "467:7:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -331,10 +331,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1385, + "id": 11728, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "467:7:9", + "src": "467:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -344,34 +344,34 @@ "visibility": "internal" } ], - "src": "466:9:9" + "src": "466:9:60" }, - "scope": 1443, - "src": "408:68:9", + "scope": 11786, + "src": "408:68:60", "stateMutability": "view", "superFunction": null, "visibility": "external" }, { "body": null, - "documentation": "@dev Moves `amount` tokens from the caller's account to `recipient`.\n * Returns a boolean value indicating whether the operation succeeded.\n * Emits a `Transfer` event.", - "id": 1397, + "documentation": "@dev Moves `amount` tokens from the caller's account to `recipient`.\n * Returns a boolean value indicating whether the operation succeeded.\n * Emits a {Transfer} event.", + "id": 11740, "implemented": false, "kind": "function", "modifiers": [], "name": "transfer", "nodeType": "FunctionDefinition", "parameters": { - "id": 1393, + "id": 11736, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1390, + "id": 11733, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 1397, - "src": "714:17:9", + "scope": 11740, + "src": "714:17:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -379,10 +379,10 @@ "typeString": "address" }, "typeName": { - "id": 1389, + "id": 11732, "name": "address", "nodeType": "ElementaryTypeName", - "src": "714:7:9", + "src": "714:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -394,11 +394,11 @@ }, { "constant": false, - "id": 1392, + "id": 11735, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1397, - "src": "733:14:9", + "scope": 11740, + "src": "733:14:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -406,10 +406,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1391, + "id": 11734, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "733:7:9", + "src": "733:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -419,19 +419,19 @@ "visibility": "internal" } ], - "src": "713:35:9" + "src": "713:35:60" }, "returnParameters": { - "id": 1396, + "id": 11739, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1395, + "id": 11738, "name": "", "nodeType": "VariableDeclaration", - "scope": 1397, - "src": "767:4:9", + "scope": 11740, + "src": "767:4:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -439,10 +439,10 @@ "typeString": "bool" }, "typeName": { - "id": 1394, + "id": 11737, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "767:4:9", + "src": "767:4:60", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -452,34 +452,34 @@ "visibility": "internal" } ], - "src": "766:6:9" + "src": "766:6:60" }, - "scope": 1443, - "src": "696:77:9", + "scope": 11786, + "src": "696:77:60", "stateMutability": "nonpayable", "superFunction": null, "visibility": "external" }, { "body": null, - "documentation": "@dev Returns the remaining number of tokens that `spender` will be\nallowed to spend on behalf of `owner` through `transferFrom`. This is\nzero by default.\n * This value changes when `approve` or `transferFrom` are called.", - "id": 1406, + "documentation": "@dev Returns the remaining number of tokens that `spender` will be\nallowed to spend on behalf of `owner` through {transferFrom}. This is\nzero by default.\n * This value changes when {approve} or {transferFrom} are called.", + "id": 11749, "implemented": false, "kind": "function", "modifiers": [], "name": "allowance", "nodeType": "FunctionDefinition", "parameters": { - "id": 1402, + "id": 11745, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1399, + "id": 11742, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 1406, - "src": "1067:13:9", + "scope": 11749, + "src": "1067:13:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -487,10 +487,10 @@ "typeString": "address" }, "typeName": { - "id": 1398, + "id": 11741, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1067:7:9", + "src": "1067:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -502,11 +502,11 @@ }, { "constant": false, - "id": 1401, + "id": 11744, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1406, - "src": "1082:15:9", + "scope": 11749, + "src": "1082:15:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -514,10 +514,10 @@ "typeString": "address" }, "typeName": { - "id": 1400, + "id": 11743, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1082:7:9", + "src": "1082:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -528,19 +528,19 @@ "visibility": "internal" } ], - "src": "1066:32:9" + "src": "1066:32:60" }, "returnParameters": { - "id": 1405, + "id": 11748, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1404, + "id": 11747, "name": "", "nodeType": "VariableDeclaration", - "scope": 1406, - "src": "1122:7:9", + "scope": 11749, + "src": "1122:7:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -548,10 +548,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1403, + "id": 11746, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1122:7:9", + "src": "1122:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -561,34 +561,34 @@ "visibility": "internal" } ], - "src": "1121:9:9" + "src": "1121:9:60" }, - "scope": 1443, - "src": "1048:83:9", + "scope": 11786, + "src": "1048:83:60", "stateMutability": "view", "superFunction": null, "visibility": "external" }, { "body": null, - "documentation": "@dev Sets `amount` as the allowance of `spender` over the caller's tokens.\n * Returns a boolean value indicating whether the operation succeeded.\n * > Beware that changing an allowance with this method brings the risk\nthat someone may use both the old and the new allowance by unfortunate\ntransaction ordering. One possible solution to mitigate this race\ncondition is to first reduce the spender's allowance to 0 and set the\ndesired value afterwards:\nhttps://github.com/ethereum/EIPs/issues/20#issuecomment-263524729\n * Emits an `Approval` event.", - "id": 1415, + "documentation": "@dev Sets `amount` as the allowance of `spender` over the caller's tokens.\n * Returns a boolean value indicating whether the operation succeeded.\n * IMPORTANT: Beware that changing an allowance with this method brings the risk\nthat someone may use both the old and the new allowance by unfortunate\ntransaction ordering. One possible solution to mitigate this race\ncondition is to first reduce the spender's allowance to 0 and set the\ndesired value afterwards:\nhttps://github.com/ethereum/EIPs/issues/20#issuecomment-263524729\n * Emits an {Approval} event.", + "id": 11758, "implemented": false, "kind": "function", "modifiers": [], "name": "approve", "nodeType": "FunctionDefinition", "parameters": { - "id": 1411, + "id": 11754, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1408, + "id": 11751, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1415, - "src": "1792:15:9", + "scope": 11758, + "src": "1801:15:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -596,10 +596,10 @@ "typeString": "address" }, "typeName": { - "id": 1407, + "id": 11750, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1792:7:9", + "src": "1801:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -611,11 +611,11 @@ }, { "constant": false, - "id": 1410, + "id": 11753, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1415, - "src": "1809:14:9", + "scope": 11758, + "src": "1818:14:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -623,10 +623,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1409, + "id": 11752, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1809:7:9", + "src": "1818:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -636,19 +636,19 @@ "visibility": "internal" } ], - "src": "1791:33:9" + "src": "1800:33:60" }, "returnParameters": { - "id": 1414, + "id": 11757, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1413, + "id": 11756, "name": "", "nodeType": "VariableDeclaration", - "scope": 1415, - "src": "1843:4:9", + "scope": 11758, + "src": "1852:4:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -656,10 +656,10 @@ "typeString": "bool" }, "typeName": { - "id": 1412, + "id": 11755, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "1843:4:9", + "src": "1852:4:60", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -669,34 +669,34 @@ "visibility": "internal" } ], - "src": "1842:6:9" + "src": "1851:6:60" }, - "scope": 1443, - "src": "1775:74:9", + "scope": 11786, + "src": "1784:74:60", "stateMutability": "nonpayable", "superFunction": null, "visibility": "external" }, { "body": null, - "documentation": "@dev Moves `amount` tokens from `sender` to `recipient` using the\nallowance mechanism. `amount` is then deducted from the caller's\nallowance.\n * Returns a boolean value indicating whether the operation succeeded.\n * Emits a `Transfer` event.", - "id": 1426, + "documentation": "@dev Moves `amount` tokens from `sender` to `recipient` using the\nallowance mechanism. `amount` is then deducted from the caller's\nallowance.\n * Returns a boolean value indicating whether the operation succeeded.\n * Emits a {Transfer} event.", + "id": 11769, "implemented": false, "kind": "function", "modifiers": [], "name": "transferFrom", "nodeType": "FunctionDefinition", "parameters": { - "id": 1422, + "id": 11765, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1417, + "id": 11760, "name": "sender", "nodeType": "VariableDeclaration", - "scope": 1426, - "src": "2178:14:9", + "scope": 11769, + "src": "2187:14:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -704,10 +704,10 @@ "typeString": "address" }, "typeName": { - "id": 1416, + "id": 11759, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2178:7:9", + "src": "2187:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -719,11 +719,11 @@ }, { "constant": false, - "id": 1419, + "id": 11762, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 1426, - "src": "2194:17:9", + "scope": 11769, + "src": "2203:17:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -731,10 +731,10 @@ "typeString": "address" }, "typeName": { - "id": 1418, + "id": 11761, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2194:7:9", + "src": "2203:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -746,11 +746,11 @@ }, { "constant": false, - "id": 1421, + "id": 11764, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1426, - "src": "2213:14:9", + "scope": 11769, + "src": "2222:14:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -758,10 +758,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1420, + "id": 11763, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2213:7:9", + "src": "2222:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -771,19 +771,19 @@ "visibility": "internal" } ], - "src": "2177:51:9" + "src": "2186:51:60" }, "returnParameters": { - "id": 1425, + "id": 11768, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1424, + "id": 11767, "name": "", "nodeType": "VariableDeclaration", - "scope": 1426, - "src": "2247:4:9", + "scope": 11769, + "src": "2256:4:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -791,10 +791,10 @@ "typeString": "bool" }, "typeName": { - "id": 1423, + "id": 11766, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "2247:4:9", + "src": "2256:4:60", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -804,10 +804,10 @@ "visibility": "internal" } ], - "src": "2246:6:9" + "src": "2255:6:60" }, - "scope": 1443, - "src": "2156:97:9", + "scope": 11786, + "src": "2165:97:60", "stateMutability": "nonpayable", "superFunction": null, "visibility": "external" @@ -815,21 +815,21 @@ { "anonymous": false, "documentation": "@dev Emitted when `value` tokens are moved from one account (`from`) to\nanother (`to`).\n * Note that `value` may be zero.", - "id": 1434, + "id": 11777, "name": "Transfer", "nodeType": "EventDefinition", "parameters": { - "id": 1433, + "id": 11776, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1428, + "id": 11771, "indexed": true, "name": "from", "nodeType": "VariableDeclaration", - "scope": 1434, - "src": "2437:20:9", + "scope": 11777, + "src": "2446:20:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -837,10 +837,10 @@ "typeString": "address" }, "typeName": { - "id": 1427, + "id": 11770, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2437:7:9", + "src": "2446:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -852,12 +852,12 @@ }, { "constant": false, - "id": 1430, + "id": 11773, "indexed": true, "name": "to", "nodeType": "VariableDeclaration", - "scope": 1434, - "src": "2459:18:9", + "scope": 11777, + "src": "2468:18:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -865,10 +865,10 @@ "typeString": "address" }, "typeName": { - "id": 1429, + "id": 11772, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2459:7:9", + "src": "2468:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -880,12 +880,12 @@ }, { "constant": false, - "id": 1432, + "id": 11775, "indexed": false, "name": "value", "nodeType": "VariableDeclaration", - "scope": 1434, - "src": "2479:13:9", + "scope": 11777, + "src": "2488:13:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -893,10 +893,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1431, + "id": 11774, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2479:7:9", + "src": "2488:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -906,28 +906,28 @@ "visibility": "internal" } ], - "src": "2436:57:9" + "src": "2445:57:60" }, - "src": "2422:72:9" + "src": "2431:72:60" }, { "anonymous": false, - "documentation": "@dev Emitted when the allowance of a `spender` for an `owner` is set by\na call to `approve`. `value` is the new allowance.", - "id": 1442, + "documentation": "@dev Emitted when the allowance of a `spender` for an `owner` is set by\na call to {approve}. `value` is the new allowance.", + "id": 11785, "name": "Approval", "nodeType": "EventDefinition", "parameters": { - "id": 1441, + "id": 11784, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1436, + "id": 11779, "indexed": true, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 1442, - "src": "2668:21:9", + "scope": 11785, + "src": "2677:21:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -935,10 +935,10 @@ "typeString": "address" }, "typeName": { - "id": 1435, + "id": 11778, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2668:7:9", + "src": "2677:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -950,12 +950,12 @@ }, { "constant": false, - "id": 1438, + "id": 11781, "indexed": true, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1442, - "src": "2691:23:9", + "scope": 11785, + "src": "2700:23:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -963,10 +963,10 @@ "typeString": "address" }, "typeName": { - "id": 1437, + "id": 11780, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2691:7:9", + "src": "2700:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -978,12 +978,12 @@ }, { "constant": false, - "id": 1440, + "id": 11783, "indexed": false, "name": "value", "nodeType": "VariableDeclaration", - "scope": 1442, - "src": "2716:13:9", + "scope": 11785, + "src": "2725:13:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -991,10 +991,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1439, + "id": 11782, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2716:7:9", + "src": "2725:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1004,29 +1004,29 @@ "visibility": "internal" } ], - "src": "2667:63:9" + "src": "2676:63:60" }, - "src": "2653:78:9" + "src": "2662:78:60" } ], - "scope": 1444, - "src": "176:2557:9" + "scope": 11787, + "src": "176:2566:60" } ], - "src": "0:2734:9" + "src": "0:2743:60" }, "legacyAST": { - "absolutePath": "@openzeppelin/contracts/token/ERC20/IERC20.sol", + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", "exportedSymbols": { "IERC20": [ - 1443 + 11786 ] }, - "id": 1444, + "id": 11787, "nodeType": "SourceUnit", "nodes": [ { - "id": 1376, + "id": 11719, "literals": [ "solidity", "^", @@ -1034,17 +1034,17 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:9" + "src": "0:23:60" }, { "baseContracts": [], "contractDependencies": [], "contractKind": "interface", - "documentation": "@dev Interface of the ERC20 standard as defined in the EIP. Does not include\nthe optional functions; to access them see `ERC20Detailed`.", + "documentation": "@dev Interface of the ERC20 standard as defined in the EIP. Does not include\nthe optional functions; to access them see {ERC20Detailed}.", "fullyImplemented": false, - "id": 1443, + "id": 11786, "linearizedBaseContracts": [ - 1443 + 11786 ], "name": "IERC20", "nodeType": "ContractDefinition", @@ -1052,29 +1052,29 @@ { "body": null, "documentation": "@dev Returns the amount of tokens in existence.", - "id": 1381, + "id": 11724, "implemented": false, "kind": "function", "modifiers": [], "name": "totalSupply", "nodeType": "FunctionDefinition", "parameters": { - "id": 1377, + "id": 11720, "nodeType": "ParameterList", "parameters": [], - "src": "290:2:9" + "src": "290:2:60" }, "returnParameters": { - "id": 1380, + "id": 11723, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1379, + "id": 11722, "name": "", "nodeType": "VariableDeclaration", - "scope": 1381, - "src": "316:7:9", + "scope": 11724, + "src": "316:7:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1082,10 +1082,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1378, + "id": 11721, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "316:7:9", + "src": "316:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1095,10 +1095,10 @@ "visibility": "internal" } ], - "src": "315:9:9" + "src": "315:9:60" }, - "scope": 1443, - "src": "270:55:9", + "scope": 11786, + "src": "270:55:60", "stateMutability": "view", "superFunction": null, "visibility": "external" @@ -1106,23 +1106,23 @@ { "body": null, "documentation": "@dev Returns the amount of tokens owned by `account`.", - "id": 1388, + "id": 11731, "implemented": false, "kind": "function", "modifiers": [], "name": "balanceOf", "nodeType": "FunctionDefinition", "parameters": { - "id": 1384, + "id": 11727, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1383, + "id": 11726, "name": "account", "nodeType": "VariableDeclaration", - "scope": 1388, - "src": "427:15:9", + "scope": 11731, + "src": "427:15:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1130,10 +1130,10 @@ "typeString": "address" }, "typeName": { - "id": 1382, + "id": 11725, "name": "address", "nodeType": "ElementaryTypeName", - "src": "427:7:9", + "src": "427:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1144,19 +1144,19 @@ "visibility": "internal" } ], - "src": "426:17:9" + "src": "426:17:60" }, "returnParameters": { - "id": 1387, + "id": 11730, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1386, + "id": 11729, "name": "", "nodeType": "VariableDeclaration", - "scope": 1388, - "src": "467:7:9", + "scope": 11731, + "src": "467:7:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1164,10 +1164,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1385, + "id": 11728, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "467:7:9", + "src": "467:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1177,34 +1177,34 @@ "visibility": "internal" } ], - "src": "466:9:9" + "src": "466:9:60" }, - "scope": 1443, - "src": "408:68:9", + "scope": 11786, + "src": "408:68:60", "stateMutability": "view", "superFunction": null, "visibility": "external" }, { "body": null, - "documentation": "@dev Moves `amount` tokens from the caller's account to `recipient`.\n * Returns a boolean value indicating whether the operation succeeded.\n * Emits a `Transfer` event.", - "id": 1397, + "documentation": "@dev Moves `amount` tokens from the caller's account to `recipient`.\n * Returns a boolean value indicating whether the operation succeeded.\n * Emits a {Transfer} event.", + "id": 11740, "implemented": false, "kind": "function", "modifiers": [], "name": "transfer", "nodeType": "FunctionDefinition", "parameters": { - "id": 1393, + "id": 11736, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1390, + "id": 11733, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 1397, - "src": "714:17:9", + "scope": 11740, + "src": "714:17:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1212,10 +1212,10 @@ "typeString": "address" }, "typeName": { - "id": 1389, + "id": 11732, "name": "address", "nodeType": "ElementaryTypeName", - "src": "714:7:9", + "src": "714:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1227,11 +1227,11 @@ }, { "constant": false, - "id": 1392, + "id": 11735, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1397, - "src": "733:14:9", + "scope": 11740, + "src": "733:14:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1239,10 +1239,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1391, + "id": 11734, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "733:7:9", + "src": "733:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1252,19 +1252,19 @@ "visibility": "internal" } ], - "src": "713:35:9" + "src": "713:35:60" }, "returnParameters": { - "id": 1396, + "id": 11739, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1395, + "id": 11738, "name": "", "nodeType": "VariableDeclaration", - "scope": 1397, - "src": "767:4:9", + "scope": 11740, + "src": "767:4:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1272,10 +1272,10 @@ "typeString": "bool" }, "typeName": { - "id": 1394, + "id": 11737, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "767:4:9", + "src": "767:4:60", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1285,34 +1285,34 @@ "visibility": "internal" } ], - "src": "766:6:9" + "src": "766:6:60" }, - "scope": 1443, - "src": "696:77:9", + "scope": 11786, + "src": "696:77:60", "stateMutability": "nonpayable", "superFunction": null, "visibility": "external" }, { "body": null, - "documentation": "@dev Returns the remaining number of tokens that `spender` will be\nallowed to spend on behalf of `owner` through `transferFrom`. This is\nzero by default.\n * This value changes when `approve` or `transferFrom` are called.", - "id": 1406, + "documentation": "@dev Returns the remaining number of tokens that `spender` will be\nallowed to spend on behalf of `owner` through {transferFrom}. This is\nzero by default.\n * This value changes when {approve} or {transferFrom} are called.", + "id": 11749, "implemented": false, "kind": "function", "modifiers": [], "name": "allowance", "nodeType": "FunctionDefinition", "parameters": { - "id": 1402, + "id": 11745, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1399, + "id": 11742, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 1406, - "src": "1067:13:9", + "scope": 11749, + "src": "1067:13:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1320,10 +1320,10 @@ "typeString": "address" }, "typeName": { - "id": 1398, + "id": 11741, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1067:7:9", + "src": "1067:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1335,11 +1335,11 @@ }, { "constant": false, - "id": 1401, + "id": 11744, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1406, - "src": "1082:15:9", + "scope": 11749, + "src": "1082:15:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1347,10 +1347,10 @@ "typeString": "address" }, "typeName": { - "id": 1400, + "id": 11743, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1082:7:9", + "src": "1082:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1361,19 +1361,19 @@ "visibility": "internal" } ], - "src": "1066:32:9" + "src": "1066:32:60" }, "returnParameters": { - "id": 1405, + "id": 11748, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1404, + "id": 11747, "name": "", "nodeType": "VariableDeclaration", - "scope": 1406, - "src": "1122:7:9", + "scope": 11749, + "src": "1122:7:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1381,10 +1381,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1403, + "id": 11746, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1122:7:9", + "src": "1122:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1394,34 +1394,34 @@ "visibility": "internal" } ], - "src": "1121:9:9" + "src": "1121:9:60" }, - "scope": 1443, - "src": "1048:83:9", + "scope": 11786, + "src": "1048:83:60", "stateMutability": "view", "superFunction": null, "visibility": "external" }, { "body": null, - "documentation": "@dev Sets `amount` as the allowance of `spender` over the caller's tokens.\n * Returns a boolean value indicating whether the operation succeeded.\n * > Beware that changing an allowance with this method brings the risk\nthat someone may use both the old and the new allowance by unfortunate\ntransaction ordering. One possible solution to mitigate this race\ncondition is to first reduce the spender's allowance to 0 and set the\ndesired value afterwards:\nhttps://github.com/ethereum/EIPs/issues/20#issuecomment-263524729\n * Emits an `Approval` event.", - "id": 1415, + "documentation": "@dev Sets `amount` as the allowance of `spender` over the caller's tokens.\n * Returns a boolean value indicating whether the operation succeeded.\n * IMPORTANT: Beware that changing an allowance with this method brings the risk\nthat someone may use both the old and the new allowance by unfortunate\ntransaction ordering. One possible solution to mitigate this race\ncondition is to first reduce the spender's allowance to 0 and set the\ndesired value afterwards:\nhttps://github.com/ethereum/EIPs/issues/20#issuecomment-263524729\n * Emits an {Approval} event.", + "id": 11758, "implemented": false, "kind": "function", "modifiers": [], "name": "approve", "nodeType": "FunctionDefinition", "parameters": { - "id": 1411, + "id": 11754, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1408, + "id": 11751, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1415, - "src": "1792:15:9", + "scope": 11758, + "src": "1801:15:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1429,10 +1429,10 @@ "typeString": "address" }, "typeName": { - "id": 1407, + "id": 11750, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1792:7:9", + "src": "1801:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1444,11 +1444,11 @@ }, { "constant": false, - "id": 1410, + "id": 11753, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1415, - "src": "1809:14:9", + "scope": 11758, + "src": "1818:14:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1456,10 +1456,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1409, + "id": 11752, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1809:7:9", + "src": "1818:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1469,19 +1469,19 @@ "visibility": "internal" } ], - "src": "1791:33:9" + "src": "1800:33:60" }, "returnParameters": { - "id": 1414, + "id": 11757, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1413, + "id": 11756, "name": "", "nodeType": "VariableDeclaration", - "scope": 1415, - "src": "1843:4:9", + "scope": 11758, + "src": "1852:4:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1489,10 +1489,10 @@ "typeString": "bool" }, "typeName": { - "id": 1412, + "id": 11755, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "1843:4:9", + "src": "1852:4:60", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1502,34 +1502,34 @@ "visibility": "internal" } ], - "src": "1842:6:9" + "src": "1851:6:60" }, - "scope": 1443, - "src": "1775:74:9", + "scope": 11786, + "src": "1784:74:60", "stateMutability": "nonpayable", "superFunction": null, "visibility": "external" }, { "body": null, - "documentation": "@dev Moves `amount` tokens from `sender` to `recipient` using the\nallowance mechanism. `amount` is then deducted from the caller's\nallowance.\n * Returns a boolean value indicating whether the operation succeeded.\n * Emits a `Transfer` event.", - "id": 1426, + "documentation": "@dev Moves `amount` tokens from `sender` to `recipient` using the\nallowance mechanism. `amount` is then deducted from the caller's\nallowance.\n * Returns a boolean value indicating whether the operation succeeded.\n * Emits a {Transfer} event.", + "id": 11769, "implemented": false, "kind": "function", "modifiers": [], "name": "transferFrom", "nodeType": "FunctionDefinition", "parameters": { - "id": 1422, + "id": 11765, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1417, + "id": 11760, "name": "sender", "nodeType": "VariableDeclaration", - "scope": 1426, - "src": "2178:14:9", + "scope": 11769, + "src": "2187:14:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1537,10 +1537,10 @@ "typeString": "address" }, "typeName": { - "id": 1416, + "id": 11759, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2178:7:9", + "src": "2187:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1552,11 +1552,11 @@ }, { "constant": false, - "id": 1419, + "id": 11762, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 1426, - "src": "2194:17:9", + "scope": 11769, + "src": "2203:17:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1564,10 +1564,10 @@ "typeString": "address" }, "typeName": { - "id": 1418, + "id": 11761, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2194:7:9", + "src": "2203:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1579,11 +1579,11 @@ }, { "constant": false, - "id": 1421, + "id": 11764, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 1426, - "src": "2213:14:9", + "scope": 11769, + "src": "2222:14:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1591,10 +1591,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1420, + "id": 11763, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2213:7:9", + "src": "2222:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1604,19 +1604,19 @@ "visibility": "internal" } ], - "src": "2177:51:9" + "src": "2186:51:60" }, "returnParameters": { - "id": 1425, + "id": 11768, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1424, + "id": 11767, "name": "", "nodeType": "VariableDeclaration", - "scope": 1426, - "src": "2247:4:9", + "scope": 11769, + "src": "2256:4:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1624,10 +1624,10 @@ "typeString": "bool" }, "typeName": { - "id": 1423, + "id": 11766, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "2247:4:9", + "src": "2256:4:60", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1637,10 +1637,10 @@ "visibility": "internal" } ], - "src": "2246:6:9" + "src": "2255:6:60" }, - "scope": 1443, - "src": "2156:97:9", + "scope": 11786, + "src": "2165:97:60", "stateMutability": "nonpayable", "superFunction": null, "visibility": "external" @@ -1648,21 +1648,21 @@ { "anonymous": false, "documentation": "@dev Emitted when `value` tokens are moved from one account (`from`) to\nanother (`to`).\n * Note that `value` may be zero.", - "id": 1434, + "id": 11777, "name": "Transfer", "nodeType": "EventDefinition", "parameters": { - "id": 1433, + "id": 11776, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1428, + "id": 11771, "indexed": true, "name": "from", "nodeType": "VariableDeclaration", - "scope": 1434, - "src": "2437:20:9", + "scope": 11777, + "src": "2446:20:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1670,10 +1670,10 @@ "typeString": "address" }, "typeName": { - "id": 1427, + "id": 11770, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2437:7:9", + "src": "2446:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1685,12 +1685,12 @@ }, { "constant": false, - "id": 1430, + "id": 11773, "indexed": true, "name": "to", "nodeType": "VariableDeclaration", - "scope": 1434, - "src": "2459:18:9", + "scope": 11777, + "src": "2468:18:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1698,10 +1698,10 @@ "typeString": "address" }, "typeName": { - "id": 1429, + "id": 11772, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2459:7:9", + "src": "2468:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1713,12 +1713,12 @@ }, { "constant": false, - "id": 1432, + "id": 11775, "indexed": false, "name": "value", "nodeType": "VariableDeclaration", - "scope": 1434, - "src": "2479:13:9", + "scope": 11777, + "src": "2488:13:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1726,10 +1726,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1431, + "id": 11774, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2479:7:9", + "src": "2488:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1739,28 +1739,28 @@ "visibility": "internal" } ], - "src": "2436:57:9" + "src": "2445:57:60" }, - "src": "2422:72:9" + "src": "2431:72:60" }, { "anonymous": false, - "documentation": "@dev Emitted when the allowance of a `spender` for an `owner` is set by\na call to `approve`. `value` is the new allowance.", - "id": 1442, + "documentation": "@dev Emitted when the allowance of a `spender` for an `owner` is set by\na call to {approve}. `value` is the new allowance.", + "id": 11785, "name": "Approval", "nodeType": "EventDefinition", "parameters": { - "id": 1441, + "id": 11784, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 1436, + "id": 11779, "indexed": true, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 1442, - "src": "2668:21:9", + "scope": 11785, + "src": "2677:21:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1768,10 +1768,10 @@ "typeString": "address" }, "typeName": { - "id": 1435, + "id": 11778, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2668:7:9", + "src": "2677:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1783,12 +1783,12 @@ }, { "constant": false, - "id": 1438, + "id": 11781, "indexed": true, "name": "spender", "nodeType": "VariableDeclaration", - "scope": 1442, - "src": "2691:23:9", + "scope": 11785, + "src": "2700:23:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1796,10 +1796,10 @@ "typeString": "address" }, "typeName": { - "id": 1437, + "id": 11780, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2691:7:9", + "src": "2700:7:60", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1811,12 +1811,12 @@ }, { "constant": false, - "id": 1440, + "id": 11783, "indexed": false, "name": "value", "nodeType": "VariableDeclaration", - "scope": 1442, - "src": "2716:13:9", + "scope": 11785, + "src": "2725:13:60", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1824,10 +1824,10 @@ "typeString": "uint256" }, "typeName": { - "id": 1439, + "id": 11782, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2716:7:9", + "src": "2725:7:60", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1837,16 +1837,16 @@ "visibility": "internal" } ], - "src": "2667:63:9" + "src": "2676:63:60" }, - "src": "2653:78:9" + "src": "2662:78:60" } ], - "scope": 1444, - "src": "176:2557:9" + "scope": 11787, + "src": "176:2566:60" } ], - "src": "0:2734:9" + "src": "0:2743:60" }, "compiler": { "name": "solc", @@ -1854,15 +1854,15 @@ }, "networks": {}, "schemaVersion": "3.0.16", - "updatedAt": "2019-11-04T18:56:07.501Z", + "updatedAt": "2019-11-07T14:57:54.942Z", "devdoc": { - "details": "Interface of the ERC20 standard as defined in the EIP. Does not include the optional functions; to access them see `ERC20Detailed`.", + "details": "Interface of the ERC20 standard as defined in the EIP. Does not include the optional functions; to access them see {ERC20Detailed}.", "methods": { "allowance(address,address)": { - "details": "Returns the remaining number of tokens that `spender` will be allowed to spend on behalf of `owner` through `transferFrom`. This is zero by default. * This value changes when `approve` or `transferFrom` are called." + "details": "Returns the remaining number of tokens that `spender` will be allowed to spend on behalf of `owner` through {transferFrom}. This is zero by default. * This value changes when {approve} or {transferFrom} are called." }, "approve(address,uint256)": { - "details": "Sets `amount` as the allowance of `spender` over the caller's tokens. * Returns a boolean value indicating whether the operation succeeded. * > Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * Emits an `Approval` event." + "details": "Sets `amount` as the allowance of `spender` over the caller's tokens. * Returns a boolean value indicating whether the operation succeeded. * IMPORTANT: Beware that changing an allowance with this method brings the risk that someone may use both the old and the new allowance by unfortunate transaction ordering. One possible solution to mitigate this race condition is to first reduce the spender's allowance to 0 and set the desired value afterwards: https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 * Emits an {Approval} event." }, "balanceOf(address)": { "details": "Returns the amount of tokens owned by `account`." @@ -1871,10 +1871,10 @@ "details": "Returns the amount of tokens in existence." }, "transfer(address,uint256)": { - "details": "Moves `amount` tokens from the caller's account to `recipient`. * Returns a boolean value indicating whether the operation succeeded. * Emits a `Transfer` event." + "details": "Moves `amount` tokens from the caller's account to `recipient`. * Returns a boolean value indicating whether the operation succeeded. * Emits a {Transfer} event." }, "transferFrom(address,address,uint256)": { - "details": "Moves `amount` tokens from `sender` to `recipient` using the allowance mechanism. `amount` is then deducted from the caller's allowance. * Returns a boolean value indicating whether the operation succeeded. * Emits a `Transfer` event." + "details": "Moves `amount` tokens from `sender` to `recipient` using the allowance mechanism. `amount` is then deducted from the caller's allowance. * Returns a boolean value indicating whether the operation succeeded. * Emits a {Transfer} event." } } }, diff --git a/client/src/contracts/IFeeProvider.json b/client/src/contracts/IFeeProvider.json new file mode 100644 index 0000000..accab17 --- /dev/null +++ b/client/src/contracts/IFeeProvider.json @@ -0,0 +1,840 @@ +{ + "contractName": "IFeeProvider", + "abi": [ + { + "constant": true, + "inputs": [ + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "calculateLoanOriginationFee", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "setLoanOriginationFeePercentage", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLoanOriginationFeePercentage", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_feesCollectionAddress", + "type": "address" + } + ], + "name": "setFeesCollectionAddress", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getFeesCollectionAddress", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"getFeesCollectionAddress\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLoanOriginationFeePercentage\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"setLoanOriginationFeePercentage\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_feesCollectionAddress\",\"type\":\"address\"}],\"name\":\"setFeesCollectionAddress\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"calculateLoanOriginationFee\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{},\"title\":\"IFeeProvider interface\"},\"userdoc\":{\"methods\":{},\"notice\":\"**********Interface for the Aave fee provider.\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol\":\"IFeeProvider\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol\":{\"keccak256\":\"0xdf72f6345d96ca2731656811b508db7f8e4975776d6de39ab24dbe4a13794fd8\",\"urls\":[\"bzzr://687ac9b4f396f264af2645041f5532b6881ec8c92dad3e505ca96477957c784d\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\n/************\n@title IFeeProvider interface\n@notice Interface for the Aave fee provider.\n*/\n\ninterface IFeeProvider {\n function calculateLoanOriginationFee(address _user, uint256 _amount) external view returns (uint256);\n\n function setLoanOriginationFeePercentage(uint256 _amount) external;\n\n function getLoanOriginationFeePercentage() external view returns (uint256);\n\n function setFeesCollectionAddress(address _feesCollectionAddress) external;\n\n function getFeesCollectionAddress() external view returns (address);\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "exportedSymbols": { + "IFeeProvider": [ + 1765 + ] + }, + "id": 1766, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1735, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:16" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "**********\n@title IFeeProvider interface\n@notice Interface for the Aave fee provider.", + "fullyImplemented": false, + "id": 1765, + "linearizedBaseContracts": [ + 1765 + ], + "name": "IFeeProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": null, + "id": 1744, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "calculateLoanOriginationFee", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1740, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1737, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 1744, + "src": "184:13:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1736, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "184:7:16", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1739, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1744, + "src": "199:15:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1738, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "199:7:16", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "183:32:16" + }, + "returnParameters": { + "id": 1743, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1742, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1744, + "src": "239:7:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1741, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "239:7:16", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "238:9:16" + }, + "scope": 1765, + "src": "147:101:16", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": null, + "id": 1749, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLoanOriginationFeePercentage", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1747, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1746, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1749, + "src": "295:15:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1745, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "295:7:16", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "294:17:16" + }, + "returnParameters": { + "id": 1748, + "nodeType": "ParameterList", + "parameters": [], + "src": "320:0:16" + }, + "scope": 1765, + "src": "254:67:16", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": null, + "id": 1754, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLoanOriginationFeePercentage", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1750, + "nodeType": "ParameterList", + "parameters": [], + "src": "367:2:16" + }, + "returnParameters": { + "id": 1753, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1752, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1754, + "src": "393:7:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1751, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "393:7:16", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "392:9:16" + }, + "scope": 1765, + "src": "327:75:16", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": null, + "id": 1759, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setFeesCollectionAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1757, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1756, + "name": "_feesCollectionAddress", + "nodeType": "VariableDeclaration", + "scope": 1759, + "src": "442:30:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1755, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "442:7:16", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "441:32:16" + }, + "returnParameters": { + "id": 1758, + "nodeType": "ParameterList", + "parameters": [], + "src": "482:0:16" + }, + "scope": 1765, + "src": "408:75:16", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": null, + "id": 1764, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getFeesCollectionAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1760, + "nodeType": "ParameterList", + "parameters": [], + "src": "522:2:16" + }, + "returnParameters": { + "id": 1763, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1762, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1764, + "src": "548:7:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1761, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "548:7:16", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "547:9:16" + }, + "scope": 1765, + "src": "489:68:16", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1766, + "src": "118:442:16" + } + ], + "src": "0:561:16" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "exportedSymbols": { + "IFeeProvider": [ + 1765 + ] + }, + "id": 1766, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1735, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:16" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "**********\n@title IFeeProvider interface\n@notice Interface for the Aave fee provider.", + "fullyImplemented": false, + "id": 1765, + "linearizedBaseContracts": [ + 1765 + ], + "name": "IFeeProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": null, + "id": 1744, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "calculateLoanOriginationFee", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1740, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1737, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 1744, + "src": "184:13:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1736, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "184:7:16", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1739, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1744, + "src": "199:15:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1738, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "199:7:16", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "183:32:16" + }, + "returnParameters": { + "id": 1743, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1742, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1744, + "src": "239:7:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1741, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "239:7:16", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "238:9:16" + }, + "scope": 1765, + "src": "147:101:16", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": null, + "id": 1749, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLoanOriginationFeePercentage", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1747, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1746, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1749, + "src": "295:15:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1745, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "295:7:16", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "294:17:16" + }, + "returnParameters": { + "id": 1748, + "nodeType": "ParameterList", + "parameters": [], + "src": "320:0:16" + }, + "scope": 1765, + "src": "254:67:16", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": null, + "id": 1754, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLoanOriginationFeePercentage", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1750, + "nodeType": "ParameterList", + "parameters": [], + "src": "367:2:16" + }, + "returnParameters": { + "id": 1753, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1752, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1754, + "src": "393:7:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1751, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "393:7:16", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "392:9:16" + }, + "scope": 1765, + "src": "327:75:16", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": null, + "id": 1759, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setFeesCollectionAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1757, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1756, + "name": "_feesCollectionAddress", + "nodeType": "VariableDeclaration", + "scope": 1759, + "src": "442:30:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1755, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "442:7:16", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "441:32:16" + }, + "returnParameters": { + "id": 1758, + "nodeType": "ParameterList", + "parameters": [], + "src": "482:0:16" + }, + "scope": 1765, + "src": "408:75:16", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": null, + "id": 1764, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getFeesCollectionAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1760, + "nodeType": "ParameterList", + "parameters": [], + "src": "522:2:16" + }, + "returnParameters": { + "id": 1763, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1762, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1764, + "src": "548:7:16", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1761, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "548:7:16", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "547:9:16" + }, + "scope": 1765, + "src": "489:68:16", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1766, + "src": "118:442:16" + } + ], + "src": "0:561:16" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.590Z", + "devdoc": { + "methods": {}, + "title": "IFeeProvider interface" + }, + "userdoc": { + "methods": {}, + "notice": "**********Interface for the Aave fee provider." + } +} \ No newline at end of file diff --git a/client/src/contracts/IFlashLoanReceiver.json b/client/src/contracts/IFlashLoanReceiver.json new file mode 100644 index 0000000..1f8512a --- /dev/null +++ b/client/src/contracts/IFlashLoanReceiver.json @@ -0,0 +1,404 @@ +{ + "contractName": "IFlashLoanReceiver", + "abi": [ + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + }, + { + "name": "_fee", + "type": "uint256" + } + ], + "name": "executeOperation", + "outputs": [ + { + "name": "returnedAmount", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_fee\",\"type\":\"uint256\"}],\"name\":\"executeOperation\",\"outputs\":[{\"name\":\"returnedAmount\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{},\"title\":\"IFeeProvider interface\"},\"userdoc\":{\"methods\":{},\"notice\":\"**********Interface for the Aave fee provider.\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol\":\"IFlashLoanReceiver\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol\":{\"keccak256\":\"0x3b825dc98b6a7aa21e9c9b05e1951bec7b5d7c84b7a0e8de0750069ccb31ebac\",\"urls\":[\"bzzr://8a616caca158d63de8db6037a2162c1effaaa71f6d7095a11516e03f7ea391d0\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\n/************\n@title IFeeProvider interface\n@notice Interface for the Aave fee provider.\n*/\n\ninterface IFlashLoanReceiver {\n\n function executeOperation(address _reserve, uint256 _amount, uint256 _fee) external returns (uint256 returnedAmount);\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol", + "exportedSymbols": { + "IFlashLoanReceiver": [ + 1733 + ] + }, + "id": 1734, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1721, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:15" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "**********\n@title IFeeProvider interface\n@notice Interface for the Aave fee provider.", + "fullyImplemented": false, + "id": 1733, + "linearizedBaseContracts": [ + 1733 + ], + "name": "IFlashLoanReceiver", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": null, + "id": 1732, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "executeOperation", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1728, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1723, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 1732, + "src": "180:16:15", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1722, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "180:7:15", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1725, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1732, + "src": "198:15:15", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1724, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "198:7:15", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1727, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 1732, + "src": "215:12:15", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1726, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "215:7:15", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "179:49:15" + }, + "returnParameters": { + "id": 1731, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1730, + "name": "returnedAmount", + "nodeType": "VariableDeclaration", + "scope": 1732, + "src": "247:22:15", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1729, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "247:7:15", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "246:24:15" + }, + "scope": 1733, + "src": "154:117:15", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1734, + "src": "118:155:15" + } + ], + "src": "0:274:15" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol", + "exportedSymbols": { + "IFlashLoanReceiver": [ + 1733 + ] + }, + "id": 1734, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1721, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:15" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "**********\n@title IFeeProvider interface\n@notice Interface for the Aave fee provider.", + "fullyImplemented": false, + "id": 1733, + "linearizedBaseContracts": [ + 1733 + ], + "name": "IFlashLoanReceiver", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": null, + "id": 1732, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "executeOperation", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1728, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1723, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 1732, + "src": "180:16:15", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1722, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "180:7:15", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1725, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 1732, + "src": "198:15:15", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1724, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "198:7:15", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1727, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 1732, + "src": "215:12:15", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1726, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "215:7:15", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "179:49:15" + }, + "returnParameters": { + "id": 1731, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1730, + "name": "returnedAmount", + "nodeType": "VariableDeclaration", + "scope": 1732, + "src": "247:22:15", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1729, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "247:7:15", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "246:24:15" + }, + "scope": 1733, + "src": "154:117:15", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1734, + "src": "118:155:15" + } + ], + "src": "0:274:15" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.589Z", + "devdoc": { + "methods": {}, + "title": "IFeeProvider interface" + }, + "userdoc": { + "methods": {}, + "notice": "**********Interface for the Aave fee provider." + } +} \ No newline at end of file diff --git a/client/src/contracts/ILendingPoolAddressesProvider.json b/client/src/contracts/ILendingPoolAddressesProvider.json new file mode 100644 index 0000000..8e2fcea --- /dev/null +++ b/client/src/contracts/ILendingPoolAddressesProvider.json @@ -0,0 +1,2837 @@ +{ + "contractName": "ILendingPoolAddressesProvider", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "getLendingPool", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_pool", + "type": "address" + } + ], + "name": "setLendingPool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolCore", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_lendingPoolCore", + "type": "address" + } + ], + "name": "setLendingPoolCore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolConfigurator", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_configurator", + "type": "address" + } + ], + "name": "setLendingPoolConfigurator", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolManager", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_lendingPoolManager", + "type": "address" + } + ], + "name": "setLendingPoolManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolDataProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_provider", + "type": "address" + } + ], + "name": "setLendingPoolDataProvider", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getNetworkMetadataProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_networkMetadataProvider", + "type": "address" + } + ], + "name": "setNetworkMetadataProvider", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolParametersProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_parametersProvider", + "type": "address" + } + ], + "name": "setLendingPoolParametersProvider", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getPriceOracle", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_priceOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingRateOracle", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_lendingRateOracle", + "type": "address" + } + ], + "name": "setLendingRateOracle", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getFeeProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_feeProvider", + "type": "address" + } + ], + "name": "setFeeProvider", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolLiquidationManager", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_manager", + "type": "address" + } + ], + "name": "setLendingPoolLiquidationManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPool\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_parametersProvider\",\"type\":\"address\"}],\"name\":\"setLendingPoolParametersProvider\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolParametersProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"name\":\"setLendingPool\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolDataProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolManager\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingRateOracle\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_lendingPoolManager\",\"type\":\"address\"}],\"name\":\"setLendingPoolManager\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_manager\",\"type\":\"address\"}],\"name\":\"setLendingPoolLiquidationManager\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_priceOracle\",\"type\":\"address\"}],\"name\":\"setPriceOracle\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolLiquidationManager\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_networkMetadataProvider\",\"type\":\"address\"}],\"name\":\"setNetworkMetadataProvider\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_lendingRateOracle\",\"type\":\"address\"}],\"name\":\"setLendingRateOracle\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolConfigurator\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_lendingPoolCore\",\"type\":\"address\"}],\"name\":\"setLendingPoolCore\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_configurator\",\"type\":\"address\"}],\"name\":\"setLendingPoolConfigurator\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getNetworkMetadataProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_feeProvider\",\"type\":\"address\"}],\"name\":\"setFeeProvider\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_provider\",\"type\":\"address\"}],\"name\":\"setLendingPoolDataProvider\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolCore\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getFeeProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getPriceOracle\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{},\"title\":\"ILendingPoolAddressesProvider interface\"},\"userdoc\":{\"methods\":{},\"notice\":\"provides the interface to fetch the LendingPoolCore address\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":\"ILendingPoolAddressesProvider\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\n/**\n@title ILendingPoolAddressesProvider interface\n@notice provides the interface to fetch the LendingPoolCore address\n */\n\ncontract ILendingPoolAddressesProvider {\n\n function getLendingPool() public view returns (address);\n function setLendingPool(address _pool) public;\n\n function getLendingPoolCore() public view returns (address payable);\n function setLendingPoolCore(address _lendingPoolCore) public;\n\n function getLendingPoolConfigurator() public view returns (address);\n function setLendingPoolConfigurator(address _configurator) public;\n\n function getLendingPoolManager() public view returns (address);\n function setLendingPoolManager(address _lendingPoolManager) public;\n\n\n function getLendingPoolDataProvider() public view returns (address);\n function setLendingPoolDataProvider(address _provider) public;\n\n function getNetworkMetadataProvider() public view returns (address);\n function setNetworkMetadataProvider(address _networkMetadataProvider) public;\n\n function getLendingPoolParametersProvider() public view returns (address);\n function setLendingPoolParametersProvider(address _parametersProvider) public;\n\n function getPriceOracle() public view returns (address);\n function setPriceOracle(address _priceOracle) public;\n\n function getLendingRateOracle() public view returns (address);\n function setLendingRateOracle(address _lendingRateOracle) public;\n\n function getFeeProvider() public view returns (address);\n function setFeeProvider(address _feeProvider) public;\n\n function getLendingPoolLiquidationManager() public view returns (address);\n function setLendingPoolLiquidationManager(address _manager) public;\n\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol", + "exportedSymbols": { + "ILendingPoolAddressesProvider": [ + 1878 + ] + }, + "id": 1879, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1767, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:17" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": "@title ILendingPoolAddressesProvider interface\n@notice provides the interface to fetch the LendingPoolCore address", + "fullyImplemented": false, + "id": 1878, + "linearizedBaseContracts": [ + 1878 + ], + "name": "ILendingPoolAddressesProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": null, + "id": 1772, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPool", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1768, + "nodeType": "ParameterList", + "parameters": [], + "src": "218:2:17" + }, + "returnParameters": { + "id": 1771, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1770, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1772, + "src": "242:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1769, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "242:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "241:9:17" + }, + "scope": 1878, + "src": "195:56:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1777, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPool", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1775, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1774, + "name": "_pool", + "nodeType": "VariableDeclaration", + "scope": 1777, + "src": "280:13:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1773, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "280:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "279:15:17" + }, + "returnParameters": { + "id": 1776, + "nodeType": "ParameterList", + "parameters": [], + "src": "301:0:17" + }, + "scope": 1878, + "src": "256:46:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1782, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolCore", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1778, + "nodeType": "ParameterList", + "parameters": [], + "src": "335:2:17" + }, + "returnParameters": { + "id": 1781, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1780, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1782, + "src": "359:15:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 1779, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "359:15:17", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "358:17:17" + }, + "scope": 1878, + "src": "308:68:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1787, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolCore", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1785, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1784, + "name": "_lendingPoolCore", + "nodeType": "VariableDeclaration", + "scope": 1787, + "src": "409:24:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1783, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "409:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "408:26:17" + }, + "returnParameters": { + "id": 1786, + "nodeType": "ParameterList", + "parameters": [], + "src": "441:0:17" + }, + "scope": 1878, + "src": "381:61:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1792, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolConfigurator", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1788, + "nodeType": "ParameterList", + "parameters": [], + "src": "483:2:17" + }, + "returnParameters": { + "id": 1791, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1790, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1792, + "src": "507:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1789, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "507:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "506:9:17" + }, + "scope": 1878, + "src": "448:68:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1797, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolConfigurator", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1795, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1794, + "name": "_configurator", + "nodeType": "VariableDeclaration", + "scope": 1797, + "src": "557:21:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1793, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "557:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "556:23:17" + }, + "returnParameters": { + "id": 1796, + "nodeType": "ParameterList", + "parameters": [], + "src": "586:0:17" + }, + "scope": 1878, + "src": "521:66:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1802, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1798, + "nodeType": "ParameterList", + "parameters": [], + "src": "623:2:17" + }, + "returnParameters": { + "id": 1801, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1800, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1802, + "src": "647:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1799, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "647:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "646:9:17" + }, + "scope": 1878, + "src": "593:63:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1807, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1805, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1804, + "name": "_lendingPoolManager", + "nodeType": "VariableDeclaration", + "scope": 1807, + "src": "692:27:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1803, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "692:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "691:29:17" + }, + "returnParameters": { + "id": 1806, + "nodeType": "ParameterList", + "parameters": [], + "src": "727:0:17" + }, + "scope": 1878, + "src": "661:67:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1812, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolDataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1808, + "nodeType": "ParameterList", + "parameters": [], + "src": "770:2:17" + }, + "returnParameters": { + "id": 1811, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1810, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1812, + "src": "794:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1809, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "794:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "793:9:17" + }, + "scope": 1878, + "src": "735:68:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1817, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolDataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1815, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1814, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 1817, + "src": "844:17:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1813, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "844:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "843:19:17" + }, + "returnParameters": { + "id": 1816, + "nodeType": "ParameterList", + "parameters": [], + "src": "869:0:17" + }, + "scope": 1878, + "src": "808:62:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1822, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getNetworkMetadataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1818, + "nodeType": "ParameterList", + "parameters": [], + "src": "911:2:17" + }, + "returnParameters": { + "id": 1821, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1820, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1822, + "src": "935:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1819, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "935:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "934:9:17" + }, + "scope": 1878, + "src": "876:68:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1827, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setNetworkMetadataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1825, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1824, + "name": "_networkMetadataProvider", + "nodeType": "VariableDeclaration", + "scope": 1827, + "src": "985:32:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1823, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "985:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "984:34:17" + }, + "returnParameters": { + "id": 1826, + "nodeType": "ParameterList", + "parameters": [], + "src": "1025:0:17" + }, + "scope": 1878, + "src": "949:77:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1832, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolParametersProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1828, + "nodeType": "ParameterList", + "parameters": [], + "src": "1073:2:17" + }, + "returnParameters": { + "id": 1831, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1830, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1832, + "src": "1097:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1829, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1097:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1096:9:17" + }, + "scope": 1878, + "src": "1032:74:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1837, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolParametersProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1835, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1834, + "name": "_parametersProvider", + "nodeType": "VariableDeclaration", + "scope": 1837, + "src": "1153:27:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1833, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1153:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1152:29:17" + }, + "returnParameters": { + "id": 1836, + "nodeType": "ParameterList", + "parameters": [], + "src": "1188:0:17" + }, + "scope": 1878, + "src": "1111:78:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1842, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getPriceOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1838, + "nodeType": "ParameterList", + "parameters": [], + "src": "1218:2:17" + }, + "returnParameters": { + "id": 1841, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1840, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1842, + "src": "1242:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1839, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1242:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1241:9:17" + }, + "scope": 1878, + "src": "1195:56:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1847, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setPriceOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1845, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1844, + "name": "_priceOracle", + "nodeType": "VariableDeclaration", + "scope": 1847, + "src": "1280:20:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1843, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1280:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1279:22:17" + }, + "returnParameters": { + "id": 1846, + "nodeType": "ParameterList", + "parameters": [], + "src": "1308:0:17" + }, + "scope": 1878, + "src": "1256:53:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1852, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingRateOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1848, + "nodeType": "ParameterList", + "parameters": [], + "src": "1344:2:17" + }, + "returnParameters": { + "id": 1851, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1850, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1852, + "src": "1368:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1849, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1368:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1367:9:17" + }, + "scope": 1878, + "src": "1315:62:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1857, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingRateOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1855, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1854, + "name": "_lendingRateOracle", + "nodeType": "VariableDeclaration", + "scope": 1857, + "src": "1412:26:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1853, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1412:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1411:28:17" + }, + "returnParameters": { + "id": 1856, + "nodeType": "ParameterList", + "parameters": [], + "src": "1446:0:17" + }, + "scope": 1878, + "src": "1382:65:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1862, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getFeeProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1858, + "nodeType": "ParameterList", + "parameters": [], + "src": "1476:2:17" + }, + "returnParameters": { + "id": 1861, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1860, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1862, + "src": "1500:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1859, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1500:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1499:9:17" + }, + "scope": 1878, + "src": "1453:56:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1867, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setFeeProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1865, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1864, + "name": "_feeProvider", + "nodeType": "VariableDeclaration", + "scope": 1867, + "src": "1538:20:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1863, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1538:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1537:22:17" + }, + "returnParameters": { + "id": 1866, + "nodeType": "ParameterList", + "parameters": [], + "src": "1566:0:17" + }, + "scope": 1878, + "src": "1514:53:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1872, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolLiquidationManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1868, + "nodeType": "ParameterList", + "parameters": [], + "src": "1614:2:17" + }, + "returnParameters": { + "id": 1871, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1870, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1872, + "src": "1638:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1869, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1638:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1637:9:17" + }, + "scope": 1878, + "src": "1573:74:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1877, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolLiquidationManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1875, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1874, + "name": "_manager", + "nodeType": "VariableDeclaration", + "scope": 1877, + "src": "1694:16:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1873, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1694:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1693:18:17" + }, + "returnParameters": { + "id": 1876, + "nodeType": "ParameterList", + "parameters": [], + "src": "1718:0:17" + }, + "scope": 1878, + "src": "1652:67:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + } + ], + "scope": 1879, + "src": "149:1573:17" + } + ], + "src": "0:1722:17" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol", + "exportedSymbols": { + "ILendingPoolAddressesProvider": [ + 1878 + ] + }, + "id": 1879, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1767, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:17" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": "@title ILendingPoolAddressesProvider interface\n@notice provides the interface to fetch the LendingPoolCore address", + "fullyImplemented": false, + "id": 1878, + "linearizedBaseContracts": [ + 1878 + ], + "name": "ILendingPoolAddressesProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": null, + "id": 1772, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPool", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1768, + "nodeType": "ParameterList", + "parameters": [], + "src": "218:2:17" + }, + "returnParameters": { + "id": 1771, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1770, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1772, + "src": "242:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1769, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "242:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "241:9:17" + }, + "scope": 1878, + "src": "195:56:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1777, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPool", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1775, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1774, + "name": "_pool", + "nodeType": "VariableDeclaration", + "scope": 1777, + "src": "280:13:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1773, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "280:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "279:15:17" + }, + "returnParameters": { + "id": 1776, + "nodeType": "ParameterList", + "parameters": [], + "src": "301:0:17" + }, + "scope": 1878, + "src": "256:46:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1782, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolCore", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1778, + "nodeType": "ParameterList", + "parameters": [], + "src": "335:2:17" + }, + "returnParameters": { + "id": 1781, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1780, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1782, + "src": "359:15:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 1779, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "359:15:17", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "358:17:17" + }, + "scope": 1878, + "src": "308:68:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1787, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolCore", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1785, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1784, + "name": "_lendingPoolCore", + "nodeType": "VariableDeclaration", + "scope": 1787, + "src": "409:24:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1783, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "409:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "408:26:17" + }, + "returnParameters": { + "id": 1786, + "nodeType": "ParameterList", + "parameters": [], + "src": "441:0:17" + }, + "scope": 1878, + "src": "381:61:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1792, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolConfigurator", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1788, + "nodeType": "ParameterList", + "parameters": [], + "src": "483:2:17" + }, + "returnParameters": { + "id": 1791, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1790, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1792, + "src": "507:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1789, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "507:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "506:9:17" + }, + "scope": 1878, + "src": "448:68:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1797, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolConfigurator", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1795, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1794, + "name": "_configurator", + "nodeType": "VariableDeclaration", + "scope": 1797, + "src": "557:21:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1793, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "557:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "556:23:17" + }, + "returnParameters": { + "id": 1796, + "nodeType": "ParameterList", + "parameters": [], + "src": "586:0:17" + }, + "scope": 1878, + "src": "521:66:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1802, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1798, + "nodeType": "ParameterList", + "parameters": [], + "src": "623:2:17" + }, + "returnParameters": { + "id": 1801, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1800, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1802, + "src": "647:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1799, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "647:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "646:9:17" + }, + "scope": 1878, + "src": "593:63:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1807, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1805, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1804, + "name": "_lendingPoolManager", + "nodeType": "VariableDeclaration", + "scope": 1807, + "src": "692:27:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1803, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "692:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "691:29:17" + }, + "returnParameters": { + "id": 1806, + "nodeType": "ParameterList", + "parameters": [], + "src": "727:0:17" + }, + "scope": 1878, + "src": "661:67:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1812, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolDataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1808, + "nodeType": "ParameterList", + "parameters": [], + "src": "770:2:17" + }, + "returnParameters": { + "id": 1811, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1810, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1812, + "src": "794:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1809, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "794:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "793:9:17" + }, + "scope": 1878, + "src": "735:68:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1817, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolDataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1815, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1814, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 1817, + "src": "844:17:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1813, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "844:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "843:19:17" + }, + "returnParameters": { + "id": 1816, + "nodeType": "ParameterList", + "parameters": [], + "src": "869:0:17" + }, + "scope": 1878, + "src": "808:62:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1822, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getNetworkMetadataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1818, + "nodeType": "ParameterList", + "parameters": [], + "src": "911:2:17" + }, + "returnParameters": { + "id": 1821, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1820, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1822, + "src": "935:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1819, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "935:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "934:9:17" + }, + "scope": 1878, + "src": "876:68:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1827, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setNetworkMetadataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1825, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1824, + "name": "_networkMetadataProvider", + "nodeType": "VariableDeclaration", + "scope": 1827, + "src": "985:32:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1823, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "985:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "984:34:17" + }, + "returnParameters": { + "id": 1826, + "nodeType": "ParameterList", + "parameters": [], + "src": "1025:0:17" + }, + "scope": 1878, + "src": "949:77:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1832, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolParametersProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1828, + "nodeType": "ParameterList", + "parameters": [], + "src": "1073:2:17" + }, + "returnParameters": { + "id": 1831, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1830, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1832, + "src": "1097:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1829, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1097:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1096:9:17" + }, + "scope": 1878, + "src": "1032:74:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1837, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolParametersProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1835, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1834, + "name": "_parametersProvider", + "nodeType": "VariableDeclaration", + "scope": 1837, + "src": "1153:27:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1833, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1153:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1152:29:17" + }, + "returnParameters": { + "id": 1836, + "nodeType": "ParameterList", + "parameters": [], + "src": "1188:0:17" + }, + "scope": 1878, + "src": "1111:78:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1842, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getPriceOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1838, + "nodeType": "ParameterList", + "parameters": [], + "src": "1218:2:17" + }, + "returnParameters": { + "id": 1841, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1840, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1842, + "src": "1242:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1839, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1242:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1241:9:17" + }, + "scope": 1878, + "src": "1195:56:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1847, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setPriceOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1845, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1844, + "name": "_priceOracle", + "nodeType": "VariableDeclaration", + "scope": 1847, + "src": "1280:20:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1843, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1280:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1279:22:17" + }, + "returnParameters": { + "id": 1846, + "nodeType": "ParameterList", + "parameters": [], + "src": "1308:0:17" + }, + "scope": 1878, + "src": "1256:53:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1852, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingRateOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1848, + "nodeType": "ParameterList", + "parameters": [], + "src": "1344:2:17" + }, + "returnParameters": { + "id": 1851, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1850, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1852, + "src": "1368:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1849, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1368:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1367:9:17" + }, + "scope": 1878, + "src": "1315:62:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1857, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingRateOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1855, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1854, + "name": "_lendingRateOracle", + "nodeType": "VariableDeclaration", + "scope": 1857, + "src": "1412:26:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1853, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1412:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1411:28:17" + }, + "returnParameters": { + "id": 1856, + "nodeType": "ParameterList", + "parameters": [], + "src": "1446:0:17" + }, + "scope": 1878, + "src": "1382:65:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1862, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getFeeProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1858, + "nodeType": "ParameterList", + "parameters": [], + "src": "1476:2:17" + }, + "returnParameters": { + "id": 1861, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1860, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1862, + "src": "1500:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1859, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1500:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1499:9:17" + }, + "scope": 1878, + "src": "1453:56:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1867, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setFeeProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1865, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1864, + "name": "_feeProvider", + "nodeType": "VariableDeclaration", + "scope": 1867, + "src": "1538:20:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1863, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1538:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1537:22:17" + }, + "returnParameters": { + "id": 1866, + "nodeType": "ParameterList", + "parameters": [], + "src": "1566:0:17" + }, + "scope": 1878, + "src": "1514:53:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1872, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolLiquidationManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1868, + "nodeType": "ParameterList", + "parameters": [], + "src": "1614:2:17" + }, + "returnParameters": { + "id": 1871, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1870, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1872, + "src": "1638:7:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1869, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1638:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1637:9:17" + }, + "scope": 1878, + "src": "1573:74:17", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": null, + "documentation": null, + "id": 1877, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolLiquidationManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1875, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1874, + "name": "_manager", + "nodeType": "VariableDeclaration", + "scope": 1877, + "src": "1694:16:17", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1873, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1694:7:17", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1693:18:17" + }, + "returnParameters": { + "id": 1876, + "nodeType": "ParameterList", + "parameters": [], + "src": "1718:0:17" + }, + "scope": 1878, + "src": "1652:67:17", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + } + ], + "scope": 1879, + "src": "149:1573:17" + } + ], + "src": "0:1722:17" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.591Z", + "devdoc": { + "methods": {}, + "title": "ILendingPoolAddressesProvider interface" + }, + "userdoc": { + "methods": {}, + "notice": "provides the interface to fetch the LendingPoolCore address" + } +} \ No newline at end of file diff --git a/client/src/contracts/ILendingRateOracle.json b/client/src/contracts/ILendingRateOracle.json new file mode 100644 index 0000000..2964060 --- /dev/null +++ b/client/src/contracts/ILendingRateOracle.json @@ -0,0 +1,861 @@ +{ + "contractName": "ILendingRateOracle", + "abi": [ + { + "constant": true, + "inputs": [ + { + "name": "_asset", + "type": "address" + } + ], + "name": "getMarketBorrowRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_asset", + "type": "address" + }, + { + "name": "_rate", + "type": "uint256" + } + ], + "name": "setMarketBorrowRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_asset", + "type": "address" + } + ], + "name": "getMarketLiquidityRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_asset", + "type": "address" + }, + { + "name": "_rate", + "type": "uint256" + } + ], + "name": "setMarketLiquidityRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"},{\"name\":\"_rate\",\"type\":\"uint256\"}],\"name\":\"setMarketBorrowRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"},{\"name\":\"_rate\",\"type\":\"uint256\"}],\"name\":\"setMarketLiquidityRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"}],\"name\":\"getMarketBorrowRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"}],\"name\":\"getMarketLiquidityRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{\"getMarketBorrowRate(address)\":{\"details\":\"returns the market borrow rate in wei\"},\"getMarketLiquidityRate(address)\":{\"details\":\"returns the market borrow rate in wei\"},\"setMarketBorrowRate(address,uint256)\":{\"details\":\"sets the market borrow rate. Rate value must be in wei\"},\"setMarketLiquidityRate(address,uint256)\":{\"details\":\"sets the market borrow rate. Rate value must be in wei\"}},\"title\":\"ILendingRateOracle interface\"},\"userdoc\":{\"methods\":{\"getMarketBorrowRate(address)\":{\"notice\":\"*********\"},\"getMarketLiquidityRate(address)\":{\"notice\":\"*********\"},\"setMarketBorrowRate(address,uint256)\":{\"notice\":\"*********\"},\"setMarketLiquidityRate(address,uint256)\":{\"notice\":\"*********\"}},\"notice\":\"**********Interface for the Aave borrow rate oracle. Provides the average market borrow rate to be used as a base for the fixed borrow rate calculations\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":\"ILendingRateOracle\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":{\"keccak256\":\"0xeeae2b67fa36103fe1c3a4e346b9c04171f9065949953abd00104c357834b0e3\",\"urls\":[\"bzzr://4e3bd29abfa796726532c3e42dd8039ab0f93388d7bbf358428dbc9b0399664a\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\n/************\n@title ILendingRateOracle interface\n@notice Interface for the Aave borrow rate oracle. Provides the average market borrow rate to be used as a base for the fixed borrow rate calculations*/\n\ninterface ILendingRateOracle {\n /***********\n @dev returns the market borrow rate in wei\n */\n function getMarketBorrowRate(address _asset) external view returns (uint256);\n\n /***********\n @dev sets the market borrow rate. Rate value must be in wei\n */\n function setMarketBorrowRate(address _asset, uint256 _rate) external;\n\n /***********\n @dev returns the market borrow rate in wei\n */\n function getMarketLiquidityRate(address _asset) external view returns (uint256);\n\n /***********\n @dev sets the market borrow rate. Rate value must be in wei\n */\n function setMarketLiquidityRate(address _asset, uint256 _rate) external;\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol", + "exportedSymbols": { + "ILendingRateOracle": [ + 1909 + ] + }, + "id": 1910, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1880, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:18" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "**********\n@title ILendingRateOracle interface\n@notice Interface for the Aave borrow rate oracle. Provides the average market borrow rate to be used as a base for the fixed borrow rate calculations", + "fullyImplemented": false, + "id": 1909, + "linearizedBaseContracts": [ + 1909 + ], + "name": "ILendingRateOracle", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": "*********\n@dev returns the market borrow rate in wei", + "id": 1887, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getMarketBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1883, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1882, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1887, + "src": "365:14:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1881, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "365:7:18", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "364:16:18" + }, + "returnParameters": { + "id": 1886, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1885, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1887, + "src": "404:7:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1884, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "404:7:18", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "403:9:18" + }, + "scope": 1909, + "src": "336:77:18", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the market borrow rate. Rate value must be in wei", + "id": 1894, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setMarketBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1892, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1889, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1894, + "src": "537:14:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1888, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "537:7:18", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1891, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 1894, + "src": "553:13:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1890, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "553:7:18", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "536:31:18" + }, + "returnParameters": { + "id": 1893, + "nodeType": "ParameterList", + "parameters": [], + "src": "576:0:18" + }, + "scope": 1909, + "src": "508:69:18", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev returns the market borrow rate in wei", + "id": 1901, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getMarketLiquidityRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1897, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1896, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1901, + "src": "687:14:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1895, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "687:7:18", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "686:16:18" + }, + "returnParameters": { + "id": 1900, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1899, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1901, + "src": "726:7:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1898, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "726:7:18", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "725:9:18" + }, + "scope": 1909, + "src": "655:80:18", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the market borrow rate. Rate value must be in wei", + "id": 1908, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setMarketLiquidityRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1906, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1903, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1908, + "src": "862:14:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1902, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "862:7:18", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1905, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 1908, + "src": "878:13:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1904, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "878:7:18", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "861:31:18" + }, + "returnParameters": { + "id": 1907, + "nodeType": "ParameterList", + "parameters": [], + "src": "901:0:18" + }, + "scope": 1909, + "src": "830:72:18", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1910, + "src": "229:676:18" + } + ], + "src": "0:906:18" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol", + "exportedSymbols": { + "ILendingRateOracle": [ + 1909 + ] + }, + "id": 1910, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1880, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:18" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "**********\n@title ILendingRateOracle interface\n@notice Interface for the Aave borrow rate oracle. Provides the average market borrow rate to be used as a base for the fixed borrow rate calculations", + "fullyImplemented": false, + "id": 1909, + "linearizedBaseContracts": [ + 1909 + ], + "name": "ILendingRateOracle", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": "*********\n@dev returns the market borrow rate in wei", + "id": 1887, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getMarketBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1883, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1882, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1887, + "src": "365:14:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1881, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "365:7:18", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "364:16:18" + }, + "returnParameters": { + "id": 1886, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1885, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1887, + "src": "404:7:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1884, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "404:7:18", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "403:9:18" + }, + "scope": 1909, + "src": "336:77:18", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the market borrow rate. Rate value must be in wei", + "id": 1894, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setMarketBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1892, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1889, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1894, + "src": "537:14:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1888, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "537:7:18", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1891, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 1894, + "src": "553:13:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1890, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "553:7:18", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "536:31:18" + }, + "returnParameters": { + "id": 1893, + "nodeType": "ParameterList", + "parameters": [], + "src": "576:0:18" + }, + "scope": 1909, + "src": "508:69:18", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev returns the market borrow rate in wei", + "id": 1901, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getMarketLiquidityRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1897, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1896, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1901, + "src": "687:14:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1895, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "687:7:18", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "686:16:18" + }, + "returnParameters": { + "id": 1900, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1899, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1901, + "src": "726:7:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1898, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "726:7:18", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "725:9:18" + }, + "scope": 1909, + "src": "655:80:18", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the market borrow rate. Rate value must be in wei", + "id": 1908, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setMarketLiquidityRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1906, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1903, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1908, + "src": "862:14:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1902, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "862:7:18", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1905, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 1908, + "src": "878:13:18", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1904, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "878:7:18", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "861:31:18" + }, + "returnParameters": { + "id": 1907, + "nodeType": "ParameterList", + "parameters": [], + "src": "901:0:18" + }, + "scope": 1909, + "src": "830:72:18", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1910, + "src": "229:676:18" + } + ], + "src": "0:906:18" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.593Z", + "devdoc": { + "methods": { + "getMarketBorrowRate(address)": { + "details": "returns the market borrow rate in wei" + }, + "getMarketLiquidityRate(address)": { + "details": "returns the market borrow rate in wei" + }, + "setMarketBorrowRate(address,uint256)": { + "details": "sets the market borrow rate. Rate value must be in wei" + }, + "setMarketLiquidityRate(address,uint256)": { + "details": "sets the market borrow rate. Rate value must be in wei" + } + }, + "title": "ILendingRateOracle interface" + }, + "userdoc": { + "methods": { + "getMarketBorrowRate(address)": { + "notice": "*********" + }, + "getMarketLiquidityRate(address)": { + "notice": "*********" + }, + "setMarketBorrowRate(address,uint256)": { + "notice": "*********" + }, + "setMarketLiquidityRate(address,uint256)": { + "notice": "*********" + } + }, + "notice": "**********Interface for the Aave borrow rate oracle. Provides the average market borrow rate to be used as a base for the fixed borrow rate calculations" + } +} \ No newline at end of file diff --git a/client/src/contracts/INetworkMetadataProvider.json b/client/src/contracts/INetworkMetadataProvider.json new file mode 100644 index 0000000..3c8a9b6 --- /dev/null +++ b/client/src/contracts/INetworkMetadataProvider.json @@ -0,0 +1,627 @@ +{ + "contractName": "INetworkMetadataProvider", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "getBlocksPerYear", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_blocksPerYear", + "type": "uint256" + } + ], + "name": "setBlocksPerYear", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getEthereumAddress", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_ethereumAddress", + "type": "address" + } + ], + "name": "setEthereumAddress", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"getEthereumAddress\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_ethereumAddress\",\"type\":\"address\"}],\"name\":\"setEthereumAddress\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getBlocksPerYear\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_blocksPerYear\",\"type\":\"uint256\"}],\"name\":\"setBlocksPerYear\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{\"getBlocksPerYear()\":{\"details\":\"returns the number of blocks in a year\"},\"getEthereumAddress()\":{\"details\":\"returns the address used as mock for the ethereum asset\"},\"setBlocksPerYear(uint256)\":{\"details\":\"sets the number of blocks in a year\"},\"setEthereumAddress(address)\":{\"details\":\"sets the address used as mock for the ethereum asset\"}},\"title\":\"INetworkMetadataProvider interface\"},\"userdoc\":{\"methods\":{\"getBlocksPerYear()\":{\"notice\":\"*********\"},\"getEthereumAddress()\":{\"notice\":\"*********\"},\"setBlocksPerYear(uint256)\":{\"notice\":\"*********\"},\"setEthereumAddress(address)\":{\"notice\":\"*********\"}},\"notice\":\"**********Interface for the ethereum network general data\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":\"INetworkMetadataProvider\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\n/************\n@title INetworkMetadataProvider interface\n@notice Interface for the ethereum network general data\n*/\n\ninterface INetworkMetadataProvider {\n /***********\n @dev returns the number of blocks in a year\n */\n function getBlocksPerYear() external view returns (uint256);\n\n /***********\n @dev sets the number of blocks in a year\n */\n function setBlocksPerYear(uint256 _blocksPerYear) external;\n\n /***********\n @dev returns the address used as mock for the ethereum asset\n */\n function getEthereumAddress() external view returns (address);\n\n /***********\n @dev sets the address used as mock for the ethereum asset\n */\n function setEthereumAddress(address _ethereumAddress) external;\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "exportedSymbols": { + "INetworkMetadataProvider": [ + 1932 + ] + }, + "id": 1933, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1911, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:19" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "**********\n@title INetworkMetadataProvider interface\n@notice Interface for the ethereum network general data", + "fullyImplemented": false, + "id": 1932, + "linearizedBaseContracts": [ + 1932 + ], + "name": "INetworkMetadataProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": "*********\n@dev returns the number of blocks in a year", + "id": 1916, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getBlocksPerYear", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1912, + "nodeType": "ParameterList", + "parameters": [], + "src": "280:2:19" + }, + "returnParameters": { + "id": 1915, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1914, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1916, + "src": "306:7:19", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1913, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "306:7:19", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "305:9:19" + }, + "scope": 1932, + "src": "255:60:19", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the number of blocks in a year", + "id": 1921, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setBlocksPerYear", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1919, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1918, + "name": "_blocksPerYear", + "nodeType": "VariableDeclaration", + "scope": 1921, + "src": "417:22:19", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1917, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "417:7:19", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "416:24:19" + }, + "returnParameters": { + "id": 1920, + "nodeType": "ParameterList", + "parameters": [], + "src": "449:0:19" + }, + "scope": 1932, + "src": "391:59:19", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev returns the address used as mock for the ethereum asset", + "id": 1926, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getEthereumAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1922, + "nodeType": "ParameterList", + "parameters": [], + "src": "573:2:19" + }, + "returnParameters": { + "id": 1925, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1924, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1926, + "src": "599:7:19", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1923, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "599:7:19", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "598:9:19" + }, + "scope": 1932, + "src": "546:62:19", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the address used as mock for the ethereum asset", + "id": 1931, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setEthereumAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1929, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1928, + "name": "_ethereumAddress", + "nodeType": "VariableDeclaration", + "scope": 1931, + "src": "729:24:19", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1927, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "729:7:19", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "728:26:19" + }, + "returnParameters": { + "id": 1930, + "nodeType": "ParameterList", + "parameters": [], + "src": "763:0:19" + }, + "scope": 1932, + "src": "701:63:19", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1933, + "src": "141:626:19" + } + ], + "src": "0:768:19" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "exportedSymbols": { + "INetworkMetadataProvider": [ + 1932 + ] + }, + "id": 1933, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1911, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:19" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "**********\n@title INetworkMetadataProvider interface\n@notice Interface for the ethereum network general data", + "fullyImplemented": false, + "id": 1932, + "linearizedBaseContracts": [ + 1932 + ], + "name": "INetworkMetadataProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": "*********\n@dev returns the number of blocks in a year", + "id": 1916, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getBlocksPerYear", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1912, + "nodeType": "ParameterList", + "parameters": [], + "src": "280:2:19" + }, + "returnParameters": { + "id": 1915, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1914, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1916, + "src": "306:7:19", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1913, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "306:7:19", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "305:9:19" + }, + "scope": 1932, + "src": "255:60:19", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the number of blocks in a year", + "id": 1921, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setBlocksPerYear", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1919, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1918, + "name": "_blocksPerYear", + "nodeType": "VariableDeclaration", + "scope": 1921, + "src": "417:22:19", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1917, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "417:7:19", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "416:24:19" + }, + "returnParameters": { + "id": 1920, + "nodeType": "ParameterList", + "parameters": [], + "src": "449:0:19" + }, + "scope": 1932, + "src": "391:59:19", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev returns the address used as mock for the ethereum asset", + "id": 1926, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getEthereumAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1922, + "nodeType": "ParameterList", + "parameters": [], + "src": "573:2:19" + }, + "returnParameters": { + "id": 1925, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1924, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1926, + "src": "599:7:19", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1923, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "599:7:19", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "598:9:19" + }, + "scope": 1932, + "src": "546:62:19", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the address used as mock for the ethereum asset", + "id": 1931, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setEthereumAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1929, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1928, + "name": "_ethereumAddress", + "nodeType": "VariableDeclaration", + "scope": 1931, + "src": "729:24:19", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1927, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "729:7:19", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "728:26:19" + }, + "returnParameters": { + "id": 1930, + "nodeType": "ParameterList", + "parameters": [], + "src": "763:0:19" + }, + "scope": 1932, + "src": "701:63:19", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1933, + "src": "141:626:19" + } + ], + "src": "0:768:19" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.594Z", + "devdoc": { + "methods": { + "getBlocksPerYear()": { + "details": "returns the number of blocks in a year" + }, + "getEthereumAddress()": { + "details": "returns the address used as mock for the ethereum asset" + }, + "setBlocksPerYear(uint256)": { + "details": "sets the number of blocks in a year" + }, + "setEthereumAddress(address)": { + "details": "sets the address used as mock for the ethereum asset" + } + }, + "title": "INetworkMetadataProvider interface" + }, + "userdoc": { + "methods": { + "getBlocksPerYear()": { + "notice": "*********" + }, + "getEthereumAddress()": { + "notice": "*********" + }, + "setBlocksPerYear(uint256)": { + "notice": "*********" + }, + "setEthereumAddress(address)": { + "notice": "*********" + } + }, + "notice": "**********Interface for the ethereum network general data" + } +} \ No newline at end of file diff --git a/client/src/contracts/IPriceOracle.json b/client/src/contracts/IPriceOracle.json new file mode 100644 index 0000000..2390fa8 --- /dev/null +++ b/client/src/contracts/IPriceOracle.json @@ -0,0 +1,742 @@ +{ + "contractName": "IPriceOracle", + "abi": [ + { + "constant": true, + "inputs": [ + { + "name": "_asset", + "type": "address" + } + ], + "name": "getAssetPrice", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_asset", + "type": "address" + }, + { + "name": "_price", + "type": "uint256" + } + ], + "name": "setAssetPrice", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getEthUsdPrice", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_price", + "type": "uint256" + } + ], + "name": "setEthUsdPrice", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"},{\"name\":\"_price\",\"type\":\"uint256\"}],\"name\":\"setAssetPrice\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getEthUsdPrice\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"}],\"name\":\"getAssetPrice\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_price\",\"type\":\"uint256\"}],\"name\":\"setEthUsdPrice\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{\"getAssetPrice(address)\":{\"details\":\"returns the asset price in ETH\"},\"getEthUsdPrice()\":{\"details\":\"returns the asset price in USD\"},\"setAssetPrice(address,uint256)\":{\"details\":\"sets the asset price\"},\"setEthUsdPrice(uint256)\":{\"details\":\"sets the asset price\"}},\"title\":\"IPriceOracle interface\"},\"userdoc\":{\"methods\":{\"getAssetPrice(address)\":{\"notice\":\"*********\"},\"getEthUsdPrice()\":{\"notice\":\"*********\"},\"setAssetPrice(address,uint256)\":{\"notice\":\"*********\"},\"setEthUsdPrice(uint256)\":{\"notice\":\"*********\"}},\"notice\":\"**********Interface for the Aave price oracle.\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":\"IPriceOracle\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x0adf744884b9262f507aba565d1c96c82397f58d399a2dc2c60a452953197574\",\"urls\":[\"bzzr://03099f88c041565b5ac13ea7e645a8f9bff0c29bfa584c7969372ce12c5473f5\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\n/************\n@title IPriceOracle interface\n@notice Interface for the Aave price oracle.*/\ninterface IPriceOracle {\n /***********\n @dev returns the asset price in ETH\n */\n function getAssetPrice(address _asset) external view returns (uint256);\n\n /***********\n @dev sets the asset price\n */\n function setAssetPrice(address _asset, uint256 _price) external;\n\n /***********\n @dev returns the asset price in USD\n */\n function getEthUsdPrice() external view returns (uint256);\n\n /***********\n @dev sets the asset price\n */\n function setEthUsdPrice(uint256 _price) external;\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol", + "exportedSymbols": { + "IPriceOracle": [ + 1959 + ] + }, + "id": 1960, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1934, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:20" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "**********\n@title IPriceOracle interface\n@notice Interface for the Aave price oracle.", + "fullyImplemented": false, + "id": 1959, + "linearizedBaseContracts": [ + 1959 + ], + "name": "IPriceOracle", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": "*********\n@dev returns the asset price in ETH", + "id": 1941, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getAssetPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1937, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1936, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1941, + "src": "233:14:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1935, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "233:7:20", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "232:16:20" + }, + "returnParameters": { + "id": 1940, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1939, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1941, + "src": "272:7:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1938, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "272:7:20", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "271:9:20" + }, + "scope": 1959, + "src": "210:71:20", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the asset price", + "id": 1948, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setAssetPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1946, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1943, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1948, + "src": "365:14:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1942, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "365:7:20", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1945, + "name": "_price", + "nodeType": "VariableDeclaration", + "scope": 1948, + "src": "381:14:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1944, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "381:7:20", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "364:32:20" + }, + "returnParameters": { + "id": 1947, + "nodeType": "ParameterList", + "parameters": [], + "src": "405:0:20" + }, + "scope": 1959, + "src": "342:64:20", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev returns the asset price in USD", + "id": 1953, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getEthUsdPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1949, + "nodeType": "ParameterList", + "parameters": [], + "src": "500:2:20" + }, + "returnParameters": { + "id": 1952, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1951, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1953, + "src": "526:7:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1950, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "526:7:20", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "525:9:20" + }, + "scope": 1959, + "src": "477:58:20", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the asset price", + "id": 1958, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setEthUsdPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1956, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1955, + "name": "_price", + "nodeType": "VariableDeclaration", + "scope": 1958, + "src": "620:14:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1954, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "620:7:20", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "619:16:20" + }, + "returnParameters": { + "id": 1957, + "nodeType": "ParameterList", + "parameters": [], + "src": "644:0:20" + }, + "scope": 1959, + "src": "596:49:20", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1960, + "src": "116:532:20" + } + ], + "src": "0:649:20" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol", + "exportedSymbols": { + "IPriceOracle": [ + 1959 + ] + }, + "id": 1960, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1934, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:20" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "**********\n@title IPriceOracle interface\n@notice Interface for the Aave price oracle.", + "fullyImplemented": false, + "id": 1959, + "linearizedBaseContracts": [ + 1959 + ], + "name": "IPriceOracle", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": "*********\n@dev returns the asset price in ETH", + "id": 1941, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getAssetPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1937, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1936, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1941, + "src": "233:14:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1935, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "233:7:20", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "232:16:20" + }, + "returnParameters": { + "id": 1940, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1939, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1941, + "src": "272:7:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1938, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "272:7:20", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "271:9:20" + }, + "scope": 1959, + "src": "210:71:20", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the asset price", + "id": 1948, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setAssetPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1946, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1943, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 1948, + "src": "365:14:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1942, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "365:7:20", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1945, + "name": "_price", + "nodeType": "VariableDeclaration", + "scope": 1948, + "src": "381:14:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1944, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "381:7:20", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "364:32:20" + }, + "returnParameters": { + "id": 1947, + "nodeType": "ParameterList", + "parameters": [], + "src": "405:0:20" + }, + "scope": 1959, + "src": "342:64:20", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev returns the asset price in USD", + "id": 1953, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getEthUsdPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1949, + "nodeType": "ParameterList", + "parameters": [], + "src": "500:2:20" + }, + "returnParameters": { + "id": 1952, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1951, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1953, + "src": "526:7:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1950, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "526:7:20", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "525:9:20" + }, + "scope": 1959, + "src": "477:58:20", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "*********\n@dev sets the asset price", + "id": 1958, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "setEthUsdPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1956, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1955, + "name": "_price", + "nodeType": "VariableDeclaration", + "scope": 1958, + "src": "620:14:20", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1954, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "620:7:20", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "619:16:20" + }, + "returnParameters": { + "id": 1957, + "nodeType": "ParameterList", + "parameters": [], + "src": "644:0:20" + }, + "scope": 1959, + "src": "596:49:20", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1960, + "src": "116:532:20" + } + ], + "src": "0:649:20" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.594Z", + "devdoc": { + "methods": { + "getAssetPrice(address)": { + "details": "returns the asset price in ETH" + }, + "getEthUsdPrice()": { + "details": "returns the asset price in USD" + }, + "setAssetPrice(address,uint256)": { + "details": "sets the asset price" + }, + "setEthUsdPrice(uint256)": { + "details": "sets the asset price" + } + }, + "title": "IPriceOracle interface" + }, + "userdoc": { + "methods": { + "getAssetPrice(address)": { + "notice": "*********" + }, + "getEthUsdPrice()": { + "notice": "*********" + }, + "setAssetPrice(address,uint256)": { + "notice": "*********" + }, + "setEthUsdPrice(uint256)": { + "notice": "*********" + } + }, + "notice": "**********Interface for the Aave price oracle." + } +} \ No newline at end of file diff --git a/client/src/contracts/IReserveInterestRateStrategy.json b/client/src/contracts/IReserveInterestRateStrategy.json new file mode 100644 index 0000000..ed56cc8 --- /dev/null +++ b/client/src/contracts/IReserveInterestRateStrategy.json @@ -0,0 +1,757 @@ +{ + "contractName": "IReserveInterestRateStrategy", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "getBaseVariableBorrowRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_utilizationRate", + "type": "uint256" + }, + { + "name": "_totalBorrowsFixed", + "type": "uint256" + }, + { + "name": "_totalBorrowsVariable", + "type": "uint256" + }, + { + "name": "_averageFixedBorrowRate", + "type": "uint256" + } + ], + "name": "calculateInterestRates", + "outputs": [ + { + "name": "liquidityRate", + "type": "uint256" + }, + { + "name": "fixedBorrowRate", + "type": "uint256" + }, + { + "name": "variableBorrowRate", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"getBaseVariableBorrowRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_utilizationRate\",\"type\":\"uint256\"},{\"name\":\"_totalBorrowsFixed\",\"type\":\"uint256\"},{\"name\":\"_totalBorrowsVariable\",\"type\":\"uint256\"},{\"name\":\"_averageFixedBorrowRate\",\"type\":\"uint256\"}],\"name\":\"calculateInterestRates\",\"outputs\":[{\"name\":\"liquidityRate\",\"type\":\"uint256\"},{\"name\":\"fixedBorrowRate\",\"type\":\"uint256\"},{\"name\":\"variableBorrowRate\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{\"calculateInterestRates(address,uint256,uint256,uint256,uint256)\":{\"details\":\"calculates the liquidity, fixed, and variable rates depending on the current utilization rate and the base parameters \"},\"getBaseVariableBorrowRate()\":{\"details\":\"returns the base variable borrow rate, in rays\"}},\"title\":\"IReserveInterestRateStrategyInterface interface\"},\"userdoc\":{\"methods\":{},\"notice\":\"Interface for the calculation of the interest rates.\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol\":\"IReserveInterestRateStrategy\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol\":{\"keccak256\":\"0x35a7f1a34259948cdcb03084718f765215fe69559f557b395d9d6e18c63ac823\",\"urls\":[\"bzzr://f529e265dd06192a1d552f1f41c245790419562dfb52e7be9d443c758ccb72d0\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\n/**\n@title IReserveInterestRateStrategyInterface interface\n@notice Interface for the calculation of the interest rates.\n*/\n\ninterface IReserveInterestRateStrategy {\n\n /**\n * @dev returns the base variable borrow rate, in rays\n */\n\n function getBaseVariableBorrowRate() external view returns (uint);\n /**\n * @dev calculates the liquidity, fixed, and variable rates depending on the current utilization rate\n * and the base parameters\n *\n */\n function calculateInterestRates(\n address _reserve,\n uint256 _utilizationRate,\n uint256 _totalBorrowsFixed,\n uint256 _totalBorrowsVariable,\n uint256 _averageFixedBorrowRate)\n external\n view\n returns (uint256 liquidityRate, uint256 fixedBorrowRate, uint256 variableBorrowRate);\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol", + "exportedSymbols": { + "IReserveInterestRateStrategy": [ + 1986 + ] + }, + "id": 1987, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1961, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:21" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "@title IReserveInterestRateStrategyInterface interface\n@notice Interface for the calculation of the interest rates.", + "fullyImplemented": false, + "id": 1986, + "linearizedBaseContracts": [ + 1986 + ], + "name": "IReserveInterestRateStrategy", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": "@dev returns the base variable borrow rate, in rays", + "id": 1966, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getBaseVariableBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1962, + "nodeType": "ParameterList", + "parameters": [], + "src": "303:2:21" + }, + "returnParameters": { + "id": 1965, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1964, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1966, + "src": "329:4:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1963, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "329:4:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "328:6:21" + }, + "scope": 1986, + "src": "269:66:21", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "@dev calculates the liquidity, fixed, and variable rates depending on the current utilization rate\n and the base parameters\n ", + "id": 1985, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "calculateInterestRates", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1977, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1968, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "542:16:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1967, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "542:7:21", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1970, + "name": "_utilizationRate", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "568:24:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1969, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "568:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1972, + "name": "_totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "602:26:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1971, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "602:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1974, + "name": "_totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "638:29:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1973, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "638:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1976, + "name": "_averageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "677:31:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1975, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "677:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "532:177:21" + }, + "returnParameters": { + "id": 1984, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1979, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "745:21:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1978, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "745:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1981, + "name": "fixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "768:23:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1980, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "768:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1983, + "name": "variableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "793:26:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1982, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "793:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "744:76:21" + }, + "scope": 1986, + "src": "501:320:21", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1987, + "src": "149:674:21" + } + ], + "src": "0:824:21" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol", + "exportedSymbols": { + "IReserveInterestRateStrategy": [ + 1986 + ] + }, + "id": 1987, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1961, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:21" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "interface", + "documentation": "@title IReserveInterestRateStrategyInterface interface\n@notice Interface for the calculation of the interest rates.", + "fullyImplemented": false, + "id": 1986, + "linearizedBaseContracts": [ + 1986 + ], + "name": "IReserveInterestRateStrategy", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": null, + "documentation": "@dev returns the base variable borrow rate, in rays", + "id": 1966, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "getBaseVariableBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1962, + "nodeType": "ParameterList", + "parameters": [], + "src": "303:2:21" + }, + "returnParameters": { + "id": 1965, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1964, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1966, + "src": "329:4:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1963, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "329:4:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "328:6:21" + }, + "scope": 1986, + "src": "269:66:21", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": null, + "documentation": "@dev calculates the liquidity, fixed, and variable rates depending on the current utilization rate\n and the base parameters\n ", + "id": 1985, + "implemented": false, + "kind": "function", + "modifiers": [], + "name": "calculateInterestRates", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1977, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1968, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "542:16:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1967, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "542:7:21", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1970, + "name": "_utilizationRate", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "568:24:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1969, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "568:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1972, + "name": "_totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "602:26:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1971, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "602:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1974, + "name": "_totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "638:29:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1973, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "638:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1976, + "name": "_averageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "677:31:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1975, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "677:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "532:177:21" + }, + "returnParameters": { + "id": 1984, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1979, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "745:21:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1978, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "745:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1981, + "name": "fixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "768:23:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1980, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "768:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1983, + "name": "variableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 1985, + "src": "793:26:21", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1982, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "793:7:21", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "744:76:21" + }, + "scope": 1986, + "src": "501:320:21", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1987, + "src": "149:674:21" + } + ], + "src": "0:824:21" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.595Z", + "devdoc": { + "methods": { + "calculateInterestRates(address,uint256,uint256,uint256,uint256)": { + "details": "calculates the liquidity, fixed, and variable rates depending on the current utilization rate and the base parameters " + }, + "getBaseVariableBorrowRate()": { + "details": "returns the base variable borrow rate, in rays" + } + }, + "title": "IReserveInterestRateStrategyInterface interface" + }, + "userdoc": { + "methods": {}, + "notice": "Interface for the calculation of the interest rates." + } +} \ No newline at end of file diff --git a/client/src/contracts/KyberNetworkProxy.json b/client/src/contracts/KyberNetworkProxy.json index 593e138..f527086 100644 --- a/client/src/contracts/KyberNetworkProxy.json +++ b/client/src/contracts/KyberNetworkProxy.json @@ -203,14 +203,14 @@ "absolutePath": "/Users/jg/Documents/aaveBot/contracts/KyberNetworkProxy.sol", "exportedSymbols": { "KyberNetworkProxy": [ - 85 + 161 ] }, - "id": 86, + "id": 162, "nodeType": "SourceUnit", "nodes": [ { - "id": 7, + "id": 83, "literals": [ "solidity", "^", @@ -218,16 +218,16 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:1" + "src": "0:23:2" }, { "absolutePath": "@openzeppelin/contracts/token/ERC20/ERC20.sol", "file": "@openzeppelin/contracts/token/ERC20/ERC20.sol", - "id": 8, + "id": 84, "nodeType": "ImportDirective", - "scope": 86, - "sourceUnit": 1375, - "src": "25:55:1", + "scope": 162, + "sourceUnit": 10858, + "src": "25:55:2", "symbolAliases": [], "unitAlias": "" }, @@ -237,9 +237,9 @@ "contractKind": "contract", "documentation": "@title Kyber Network interface", "fullyImplemented": false, - "id": 85, + "id": 161, "linearizedBaseContracts": [ - 85 + 161 ], "name": "KyberNetworkProxy", "nodeType": "ContractDefinition", @@ -247,29 +247,29 @@ { "body": null, "documentation": null, - "id": 13, + "id": 89, "implemented": false, "kind": "function", "modifiers": [], "name": "maxGasPrice", "nodeType": "FunctionDefinition", "parameters": { - "id": 9, + "id": 85, "nodeType": "ParameterList", "parameters": [], - "src": "170:2:1" + "src": "170:2:2" }, "returnParameters": { - "id": 12, + "id": 88, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 11, + "id": 87, "name": "", "nodeType": "VariableDeclaration", - "scope": 13, - "src": "193:4:1", + "scope": 89, + "src": "193:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -277,10 +277,10 @@ "typeString": "uint256" }, "typeName": { - "id": 10, + "id": 86, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "193:4:1", + "src": "193:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -290,10 +290,10 @@ "visibility": "internal" } ], - "src": "192:6:1" + "src": "192:6:2" }, - "scope": 85, - "src": "150:49:1", + "scope": 161, + "src": "150:49:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -301,23 +301,23 @@ { "body": null, "documentation": null, - "id": 20, + "id": 96, "implemented": false, "kind": "function", "modifiers": [], "name": "getUserCapInWei", "nodeType": "FunctionDefinition", "parameters": { - "id": 16, + "id": 92, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 15, + "id": 91, "name": "user", "nodeType": "VariableDeclaration", - "scope": 20, - "src": "229:12:1", + "scope": 96, + "src": "229:12:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -325,10 +325,10 @@ "typeString": "address" }, "typeName": { - "id": 14, + "id": 90, "name": "address", "nodeType": "ElementaryTypeName", - "src": "229:7:1", + "src": "229:7:2", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -339,19 +339,19 @@ "visibility": "internal" } ], - "src": "228:14:1" + "src": "228:14:2" }, "returnParameters": { - "id": 19, + "id": 95, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 18, + "id": 94, "name": "", "nodeType": "VariableDeclaration", - "scope": 20, - "src": "263:4:1", + "scope": 96, + "src": "263:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -359,10 +359,10 @@ "typeString": "uint256" }, "typeName": { - "id": 17, + "id": 93, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "263:4:1", + "src": "263:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -372,10 +372,10 @@ "visibility": "internal" } ], - "src": "262:6:1" + "src": "262:6:2" }, - "scope": 85, - "src": "204:65:1", + "scope": 161, + "src": "204:65:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -383,23 +383,23 @@ { "body": null, "documentation": null, - "id": 29, + "id": 105, "implemented": false, "kind": "function", "modifiers": [], "name": "getUserCapInTokenWei", "nodeType": "FunctionDefinition", "parameters": { - "id": 25, + "id": 101, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 22, + "id": 98, "name": "user", "nodeType": "VariableDeclaration", - "scope": 29, - "src": "304:12:1", + "scope": 105, + "src": "304:12:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -407,10 +407,10 @@ "typeString": "address" }, "typeName": { - "id": 21, + "id": 97, "name": "address", "nodeType": "ElementaryTypeName", - "src": "304:7:1", + "src": "304:7:2", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -422,26 +422,26 @@ }, { "constant": false, - "id": 24, + "id": 100, "name": "token", "nodeType": "VariableDeclaration", - "scope": 29, - "src": "318:11:1", + "scope": 105, + "src": "318:11:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 23, + "id": 99, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "318:5:1", + "referencedDeclaration": 10857, + "src": "318:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -449,19 +449,19 @@ "visibility": "internal" } ], - "src": "303:27:1" + "src": "303:27:2" }, "returnParameters": { - "id": 28, + "id": 104, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 27, + "id": 103, "name": "", "nodeType": "VariableDeclaration", - "scope": 29, - "src": "351:4:1", + "scope": 105, + "src": "351:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -469,10 +469,10 @@ "typeString": "uint256" }, "typeName": { - "id": 26, + "id": 102, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "351:4:1", + "src": "351:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -482,10 +482,10 @@ "visibility": "internal" } ], - "src": "350:6:1" + "src": "350:6:2" }, - "scope": 85, - "src": "274:83:1", + "scope": 161, + "src": "274:83:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -493,29 +493,29 @@ { "body": null, "documentation": null, - "id": 34, + "id": 110, "implemented": false, "kind": "function", "modifiers": [], "name": "enabled", "nodeType": "FunctionDefinition", "parameters": { - "id": 30, + "id": 106, "nodeType": "ParameterList", "parameters": [], - "src": "378:2:1" + "src": "378:2:2" }, "returnParameters": { - "id": 33, + "id": 109, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 32, + "id": 108, "name": "", "nodeType": "VariableDeclaration", - "scope": 34, - "src": "401:4:1", + "scope": 110, + "src": "401:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -523,10 +523,10 @@ "typeString": "bool" }, "typeName": { - "id": 31, + "id": 107, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "401:4:1", + "src": "401:4:2", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -536,10 +536,10 @@ "visibility": "internal" } ], - "src": "400:6:1" + "src": "400:6:2" }, - "scope": 85, - "src": "362:45:1", + "scope": 161, + "src": "362:45:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -547,23 +547,23 @@ { "body": null, "documentation": null, - "id": 41, + "id": 117, "implemented": false, "kind": "function", "modifiers": [], "name": "info", "nodeType": "FunctionDefinition", "parameters": { - "id": 37, + "id": 113, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 36, + "id": 112, "name": "id", "nodeType": "VariableDeclaration", - "scope": 41, - "src": "426:10:1", + "scope": 117, + "src": "426:10:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -571,10 +571,10 @@ "typeString": "bytes32" }, "typeName": { - "id": 35, + "id": 111, "name": "bytes32", "nodeType": "ElementaryTypeName", - "src": "426:7:1", + "src": "426:7:2", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" @@ -584,19 +584,19 @@ "visibility": "internal" } ], - "src": "425:12:1" + "src": "425:12:2" }, "returnParameters": { - "id": 40, + "id": 116, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 39, + "id": 115, "name": "", "nodeType": "VariableDeclaration", - "scope": 41, - "src": "458:4:1", + "scope": 117, + "src": "458:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -604,10 +604,10 @@ "typeString": "uint256" }, "typeName": { - "id": 38, + "id": 114, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "458:4:1", + "src": "458:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -617,10 +617,10 @@ "visibility": "internal" } ], - "src": "457:6:1" + "src": "457:6:2" }, - "scope": 85, - "src": "412:52:1", + "scope": 161, + "src": "412:52:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -628,38 +628,38 @@ { "body": null, "documentation": null, - "id": 54, + "id": 130, "implemented": false, "kind": "function", "modifiers": [], "name": "getExpectedRate", "nodeType": "FunctionDefinition", "parameters": { - "id": 48, + "id": 124, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 43, + "id": 119, "name": "src", "nodeType": "VariableDeclaration", - "scope": 54, - "src": "495:9:1", + "scope": 130, + "src": "495:9:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 42, + "id": 118, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "495:5:1", + "referencedDeclaration": 10857, + "src": "495:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -668,26 +668,26 @@ }, { "constant": false, - "id": 45, + "id": 121, "name": "dest", "nodeType": "VariableDeclaration", - "scope": 54, - "src": "506:10:1", + "scope": 130, + "src": "506:10:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 44, + "id": 120, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "506:5:1", + "referencedDeclaration": 10857, + "src": "506:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -696,11 +696,11 @@ }, { "constant": false, - "id": 47, + "id": 123, "name": "srcQty", "nodeType": "VariableDeclaration", - "scope": 54, - "src": "518:11:1", + "scope": 130, + "src": "518:11:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -708,10 +708,10 @@ "typeString": "uint256" }, "typeName": { - "id": 46, + "id": 122, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "518:4:1", + "src": "518:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -721,19 +721,19 @@ "visibility": "internal" } ], - "src": "494:36:1" + "src": "494:36:2" }, "returnParameters": { - "id": 53, + "id": 129, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 50, + "id": 126, "name": "expectedRate", "nodeType": "VariableDeclaration", - "scope": 54, - "src": "560:17:1", + "scope": 130, + "src": "560:17:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -741,10 +741,10 @@ "typeString": "uint256" }, "typeName": { - "id": 49, + "id": 125, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "560:4:1", + "src": "560:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -755,11 +755,11 @@ }, { "constant": false, - "id": 52, + "id": 128, "name": "slippageRate", "nodeType": "VariableDeclaration", - "scope": 54, - "src": "579:17:1", + "scope": 130, + "src": "579:17:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -767,10 +767,10 @@ "typeString": "uint256" }, "typeName": { - "id": 51, + "id": 127, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "579:4:1", + "src": "579:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -780,10 +780,10 @@ "visibility": "internal" } ], - "src": "559:38:1" + "src": "559:38:2" }, - "scope": 85, - "src": "470:128:1", + "scope": 161, + "src": "470:128:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -791,38 +791,38 @@ { "body": null, "documentation": null, - "id": 75, + "id": 151, "implemented": false, "kind": "function", "modifiers": [], "name": "tradeWithHint", "nodeType": "FunctionDefinition", "parameters": { - "id": 71, + "id": 147, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 56, + "id": 132, "name": "src", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "627:9:1", + "scope": 151, + "src": "627:9:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 55, + "id": 131, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "627:5:1", + "referencedDeclaration": 10857, + "src": "627:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -831,11 +831,11 @@ }, { "constant": false, - "id": 58, + "id": 134, "name": "srcAmount", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "638:14:1", + "scope": 151, + "src": "638:14:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -843,10 +843,10 @@ "typeString": "uint256" }, "typeName": { - "id": 57, + "id": 133, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "638:4:1", + "src": "638:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -857,26 +857,26 @@ }, { "constant": false, - "id": 60, + "id": 136, "name": "dest", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "654:10:1", + "scope": 151, + "src": "654:10:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 59, + "id": 135, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "654:5:1", + "referencedDeclaration": 10857, + "src": "654:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -885,11 +885,11 @@ }, { "constant": false, - "id": 62, + "id": 138, "name": "destAddress", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "666:19:1", + "scope": 151, + "src": "666:19:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -897,10 +897,10 @@ "typeString": "address" }, "typeName": { - "id": 61, + "id": 137, "name": "address", "nodeType": "ElementaryTypeName", - "src": "666:7:1", + "src": "666:7:2", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -912,11 +912,11 @@ }, { "constant": false, - "id": 64, + "id": 140, "name": "maxDestAmount", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "687:18:1", + "scope": 151, + "src": "687:18:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -924,10 +924,10 @@ "typeString": "uint256" }, "typeName": { - "id": 63, + "id": 139, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "687:4:1", + "src": "687:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -938,11 +938,11 @@ }, { "constant": false, - "id": 66, + "id": 142, "name": "minConversionRate", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "715:22:1", + "scope": 151, + "src": "715:22:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -950,10 +950,10 @@ "typeString": "uint256" }, "typeName": { - "id": 65, + "id": 141, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "715:4:1", + "src": "715:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -964,11 +964,11 @@ }, { "constant": false, - "id": 68, + "id": 144, "name": "walletId", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "739:16:1", + "scope": 151, + "src": "739:16:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -976,10 +976,10 @@ "typeString": "address" }, "typeName": { - "id": 67, + "id": 143, "name": "address", "nodeType": "ElementaryTypeName", - "src": "739:7:1", + "src": "739:7:2", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -991,11 +991,11 @@ }, { "constant": false, - "id": 70, + "id": 146, "name": "hint", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "757:17:1", + "scope": 151, + "src": "757:17:2", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { @@ -1003,10 +1003,10 @@ "typeString": "bytes" }, "typeName": { - "id": 69, + "id": 145, "name": "bytes", "nodeType": "ElementaryTypeName", - "src": "757:5:1", + "src": "757:5:2", "typeDescriptions": { "typeIdentifier": "t_bytes_storage_ptr", "typeString": "bytes" @@ -1016,19 +1016,19 @@ "visibility": "internal" } ], - "src": "626:149:1" + "src": "626:149:2" }, "returnParameters": { - "id": 74, + "id": 150, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 73, + "id": 149, "name": "", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "799:4:1", + "scope": 151, + "src": "799:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1036,10 +1036,10 @@ "typeString": "uint256" }, "typeName": { - "id": 72, + "id": 148, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "799:4:1", + "src": "799:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1049,10 +1049,10 @@ "visibility": "internal" } ], - "src": "798:6:1" + "src": "798:6:2" }, - "scope": 85, - "src": "604:201:1", + "scope": 161, + "src": "604:201:2", "stateMutability": "payable", "superFunction": null, "visibility": "public" @@ -1060,38 +1060,38 @@ { "body": null, "documentation": null, - "id": 84, + "id": 160, "implemented": false, "kind": "function", "modifiers": [], "name": "swapEtherToToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 80, + "id": 156, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 77, + "id": 153, "name": "token", "nodeType": "VariableDeclaration", - "scope": 84, - "src": "837:11:1", + "scope": 160, + "src": "837:11:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 76, + "id": 152, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "837:5:1", + "referencedDeclaration": 10857, + "src": "837:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -1100,11 +1100,11 @@ }, { "constant": false, - "id": 79, + "id": 155, "name": "minConversionRate", "nodeType": "VariableDeclaration", - "scope": 84, - "src": "850:22:1", + "scope": 160, + "src": "850:22:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1112,10 +1112,10 @@ "typeString": "uint256" }, "typeName": { - "id": 78, + "id": 154, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "850:4:1", + "src": "850:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1125,19 +1125,19 @@ "visibility": "internal" } ], - "src": "836:37:1" + "src": "836:37:2" }, "returnParameters": { - "id": 83, + "id": 159, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 82, + "id": 158, "name": "", "nodeType": "VariableDeclaration", - "scope": 84, - "src": "897:4:1", + "scope": 160, + "src": "897:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1145,10 +1145,10 @@ "typeString": "uint256" }, "typeName": { - "id": 81, + "id": 157, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "897:4:1", + "src": "897:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1158,33 +1158,33 @@ "visibility": "internal" } ], - "src": "896:6:1" + "src": "896:6:2" }, - "scope": 85, - "src": "811:92:1", + "scope": 161, + "src": "811:92:2", "stateMutability": "payable", "superFunction": null, "visibility": "public" } ], - "scope": 86, - "src": "117:788:1" + "scope": 162, + "src": "117:788:2" } ], - "src": "0:906:1" + "src": "0:906:2" }, "legacyAST": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/KyberNetworkProxy.sol", "exportedSymbols": { "KyberNetworkProxy": [ - 85 + 161 ] }, - "id": 86, + "id": 162, "nodeType": "SourceUnit", "nodes": [ { - "id": 7, + "id": 83, "literals": [ "solidity", "^", @@ -1192,16 +1192,16 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:1" + "src": "0:23:2" }, { "absolutePath": "@openzeppelin/contracts/token/ERC20/ERC20.sol", "file": "@openzeppelin/contracts/token/ERC20/ERC20.sol", - "id": 8, + "id": 84, "nodeType": "ImportDirective", - "scope": 86, - "sourceUnit": 1375, - "src": "25:55:1", + "scope": 162, + "sourceUnit": 10858, + "src": "25:55:2", "symbolAliases": [], "unitAlias": "" }, @@ -1211,9 +1211,9 @@ "contractKind": "contract", "documentation": "@title Kyber Network interface", "fullyImplemented": false, - "id": 85, + "id": 161, "linearizedBaseContracts": [ - 85 + 161 ], "name": "KyberNetworkProxy", "nodeType": "ContractDefinition", @@ -1221,29 +1221,29 @@ { "body": null, "documentation": null, - "id": 13, + "id": 89, "implemented": false, "kind": "function", "modifiers": [], "name": "maxGasPrice", "nodeType": "FunctionDefinition", "parameters": { - "id": 9, + "id": 85, "nodeType": "ParameterList", "parameters": [], - "src": "170:2:1" + "src": "170:2:2" }, "returnParameters": { - "id": 12, + "id": 88, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 11, + "id": 87, "name": "", "nodeType": "VariableDeclaration", - "scope": 13, - "src": "193:4:1", + "scope": 89, + "src": "193:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1251,10 +1251,10 @@ "typeString": "uint256" }, "typeName": { - "id": 10, + "id": 86, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "193:4:1", + "src": "193:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1264,10 +1264,10 @@ "visibility": "internal" } ], - "src": "192:6:1" + "src": "192:6:2" }, - "scope": 85, - "src": "150:49:1", + "scope": 161, + "src": "150:49:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -1275,23 +1275,23 @@ { "body": null, "documentation": null, - "id": 20, + "id": 96, "implemented": false, "kind": "function", "modifiers": [], "name": "getUserCapInWei", "nodeType": "FunctionDefinition", "parameters": { - "id": 16, + "id": 92, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 15, + "id": 91, "name": "user", "nodeType": "VariableDeclaration", - "scope": 20, - "src": "229:12:1", + "scope": 96, + "src": "229:12:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1299,10 +1299,10 @@ "typeString": "address" }, "typeName": { - "id": 14, + "id": 90, "name": "address", "nodeType": "ElementaryTypeName", - "src": "229:7:1", + "src": "229:7:2", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1313,19 +1313,19 @@ "visibility": "internal" } ], - "src": "228:14:1" + "src": "228:14:2" }, "returnParameters": { - "id": 19, + "id": 95, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 18, + "id": 94, "name": "", "nodeType": "VariableDeclaration", - "scope": 20, - "src": "263:4:1", + "scope": 96, + "src": "263:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1333,10 +1333,10 @@ "typeString": "uint256" }, "typeName": { - "id": 17, + "id": 93, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "263:4:1", + "src": "263:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1346,10 +1346,10 @@ "visibility": "internal" } ], - "src": "262:6:1" + "src": "262:6:2" }, - "scope": 85, - "src": "204:65:1", + "scope": 161, + "src": "204:65:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -1357,23 +1357,23 @@ { "body": null, "documentation": null, - "id": 29, + "id": 105, "implemented": false, "kind": "function", "modifiers": [], "name": "getUserCapInTokenWei", "nodeType": "FunctionDefinition", "parameters": { - "id": 25, + "id": 101, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 22, + "id": 98, "name": "user", "nodeType": "VariableDeclaration", - "scope": 29, - "src": "304:12:1", + "scope": 105, + "src": "304:12:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1381,10 +1381,10 @@ "typeString": "address" }, "typeName": { - "id": 21, + "id": 97, "name": "address", "nodeType": "ElementaryTypeName", - "src": "304:7:1", + "src": "304:7:2", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1396,26 +1396,26 @@ }, { "constant": false, - "id": 24, + "id": 100, "name": "token", "nodeType": "VariableDeclaration", - "scope": 29, - "src": "318:11:1", + "scope": 105, + "src": "318:11:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 23, + "id": 99, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "318:5:1", + "referencedDeclaration": 10857, + "src": "318:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -1423,19 +1423,19 @@ "visibility": "internal" } ], - "src": "303:27:1" + "src": "303:27:2" }, "returnParameters": { - "id": 28, + "id": 104, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 27, + "id": 103, "name": "", "nodeType": "VariableDeclaration", - "scope": 29, - "src": "351:4:1", + "scope": 105, + "src": "351:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1443,10 +1443,10 @@ "typeString": "uint256" }, "typeName": { - "id": 26, + "id": 102, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "351:4:1", + "src": "351:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1456,10 +1456,10 @@ "visibility": "internal" } ], - "src": "350:6:1" + "src": "350:6:2" }, - "scope": 85, - "src": "274:83:1", + "scope": 161, + "src": "274:83:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -1467,29 +1467,29 @@ { "body": null, "documentation": null, - "id": 34, + "id": 110, "implemented": false, "kind": "function", "modifiers": [], "name": "enabled", "nodeType": "FunctionDefinition", "parameters": { - "id": 30, + "id": 106, "nodeType": "ParameterList", "parameters": [], - "src": "378:2:1" + "src": "378:2:2" }, "returnParameters": { - "id": 33, + "id": 109, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 32, + "id": 108, "name": "", "nodeType": "VariableDeclaration", - "scope": 34, - "src": "401:4:1", + "scope": 110, + "src": "401:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1497,10 +1497,10 @@ "typeString": "bool" }, "typeName": { - "id": 31, + "id": 107, "name": "bool", "nodeType": "ElementaryTypeName", - "src": "401:4:1", + "src": "401:4:2", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1510,10 +1510,10 @@ "visibility": "internal" } ], - "src": "400:6:1" + "src": "400:6:2" }, - "scope": 85, - "src": "362:45:1", + "scope": 161, + "src": "362:45:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -1521,23 +1521,23 @@ { "body": null, "documentation": null, - "id": 41, + "id": 117, "implemented": false, "kind": "function", "modifiers": [], "name": "info", "nodeType": "FunctionDefinition", "parameters": { - "id": 37, + "id": 113, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 36, + "id": 112, "name": "id", "nodeType": "VariableDeclaration", - "scope": 41, - "src": "426:10:1", + "scope": 117, + "src": "426:10:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1545,10 +1545,10 @@ "typeString": "bytes32" }, "typeName": { - "id": 35, + "id": 111, "name": "bytes32", "nodeType": "ElementaryTypeName", - "src": "426:7:1", + "src": "426:7:2", "typeDescriptions": { "typeIdentifier": "t_bytes32", "typeString": "bytes32" @@ -1558,19 +1558,19 @@ "visibility": "internal" } ], - "src": "425:12:1" + "src": "425:12:2" }, "returnParameters": { - "id": 40, + "id": 116, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 39, + "id": 115, "name": "", "nodeType": "VariableDeclaration", - "scope": 41, - "src": "458:4:1", + "scope": 117, + "src": "458:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1578,10 +1578,10 @@ "typeString": "uint256" }, "typeName": { - "id": 38, + "id": 114, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "458:4:1", + "src": "458:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1591,10 +1591,10 @@ "visibility": "internal" } ], - "src": "457:6:1" + "src": "457:6:2" }, - "scope": 85, - "src": "412:52:1", + "scope": 161, + "src": "412:52:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -1602,38 +1602,38 @@ { "body": null, "documentation": null, - "id": 54, + "id": 130, "implemented": false, "kind": "function", "modifiers": [], "name": "getExpectedRate", "nodeType": "FunctionDefinition", "parameters": { - "id": 48, + "id": 124, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 43, + "id": 119, "name": "src", "nodeType": "VariableDeclaration", - "scope": 54, - "src": "495:9:1", + "scope": 130, + "src": "495:9:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 42, + "id": 118, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "495:5:1", + "referencedDeclaration": 10857, + "src": "495:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -1642,26 +1642,26 @@ }, { "constant": false, - "id": 45, + "id": 121, "name": "dest", "nodeType": "VariableDeclaration", - "scope": 54, - "src": "506:10:1", + "scope": 130, + "src": "506:10:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 44, + "id": 120, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "506:5:1", + "referencedDeclaration": 10857, + "src": "506:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -1670,11 +1670,11 @@ }, { "constant": false, - "id": 47, + "id": 123, "name": "srcQty", "nodeType": "VariableDeclaration", - "scope": 54, - "src": "518:11:1", + "scope": 130, + "src": "518:11:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1682,10 +1682,10 @@ "typeString": "uint256" }, "typeName": { - "id": 46, + "id": 122, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "518:4:1", + "src": "518:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1695,19 +1695,19 @@ "visibility": "internal" } ], - "src": "494:36:1" + "src": "494:36:2" }, "returnParameters": { - "id": 53, + "id": 129, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 50, + "id": 126, "name": "expectedRate", "nodeType": "VariableDeclaration", - "scope": 54, - "src": "560:17:1", + "scope": 130, + "src": "560:17:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1715,10 +1715,10 @@ "typeString": "uint256" }, "typeName": { - "id": 49, + "id": 125, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "560:4:1", + "src": "560:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1729,11 +1729,11 @@ }, { "constant": false, - "id": 52, + "id": 128, "name": "slippageRate", "nodeType": "VariableDeclaration", - "scope": 54, - "src": "579:17:1", + "scope": 130, + "src": "579:17:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1741,10 +1741,10 @@ "typeString": "uint256" }, "typeName": { - "id": 51, + "id": 127, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "579:4:1", + "src": "579:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1754,10 +1754,10 @@ "visibility": "internal" } ], - "src": "559:38:1" + "src": "559:38:2" }, - "scope": 85, - "src": "470:128:1", + "scope": 161, + "src": "470:128:2", "stateMutability": "view", "superFunction": null, "visibility": "public" @@ -1765,38 +1765,38 @@ { "body": null, "documentation": null, - "id": 75, + "id": 151, "implemented": false, "kind": "function", "modifiers": [], "name": "tradeWithHint", "nodeType": "FunctionDefinition", "parameters": { - "id": 71, + "id": 147, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 56, + "id": 132, "name": "src", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "627:9:1", + "scope": 151, + "src": "627:9:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 55, + "id": 131, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "627:5:1", + "referencedDeclaration": 10857, + "src": "627:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -1805,11 +1805,11 @@ }, { "constant": false, - "id": 58, + "id": 134, "name": "srcAmount", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "638:14:1", + "scope": 151, + "src": "638:14:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1817,10 +1817,10 @@ "typeString": "uint256" }, "typeName": { - "id": 57, + "id": 133, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "638:4:1", + "src": "638:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1831,26 +1831,26 @@ }, { "constant": false, - "id": 60, + "id": 136, "name": "dest", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "654:10:1", + "scope": 151, + "src": "654:10:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 59, + "id": 135, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "654:5:1", + "referencedDeclaration": 10857, + "src": "654:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -1859,11 +1859,11 @@ }, { "constant": false, - "id": 62, + "id": 138, "name": "destAddress", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "666:19:1", + "scope": 151, + "src": "666:19:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1871,10 +1871,10 @@ "typeString": "address" }, "typeName": { - "id": 61, + "id": 137, "name": "address", "nodeType": "ElementaryTypeName", - "src": "666:7:1", + "src": "666:7:2", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1886,11 +1886,11 @@ }, { "constant": false, - "id": 64, + "id": 140, "name": "maxDestAmount", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "687:18:1", + "scope": 151, + "src": "687:18:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1898,10 +1898,10 @@ "typeString": "uint256" }, "typeName": { - "id": 63, + "id": 139, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "687:4:1", + "src": "687:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1912,11 +1912,11 @@ }, { "constant": false, - "id": 66, + "id": 142, "name": "minConversionRate", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "715:22:1", + "scope": 151, + "src": "715:22:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1924,10 +1924,10 @@ "typeString": "uint256" }, "typeName": { - "id": 65, + "id": 141, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "715:4:1", + "src": "715:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1938,11 +1938,11 @@ }, { "constant": false, - "id": 68, + "id": 144, "name": "walletId", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "739:16:1", + "scope": 151, + "src": "739:16:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1950,10 +1950,10 @@ "typeString": "address" }, "typeName": { - "id": 67, + "id": 143, "name": "address", "nodeType": "ElementaryTypeName", - "src": "739:7:1", + "src": "739:7:2", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1965,11 +1965,11 @@ }, { "constant": false, - "id": 70, + "id": 146, "name": "hint", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "757:17:1", + "scope": 151, + "src": "757:17:2", "stateVariable": false, "storageLocation": "memory", "typeDescriptions": { @@ -1977,10 +1977,10 @@ "typeString": "bytes" }, "typeName": { - "id": 69, + "id": 145, "name": "bytes", "nodeType": "ElementaryTypeName", - "src": "757:5:1", + "src": "757:5:2", "typeDescriptions": { "typeIdentifier": "t_bytes_storage_ptr", "typeString": "bytes" @@ -1990,19 +1990,19 @@ "visibility": "internal" } ], - "src": "626:149:1" + "src": "626:149:2" }, "returnParameters": { - "id": 74, + "id": 150, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 73, + "id": 149, "name": "", "nodeType": "VariableDeclaration", - "scope": 75, - "src": "799:4:1", + "scope": 151, + "src": "799:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2010,10 +2010,10 @@ "typeString": "uint256" }, "typeName": { - "id": 72, + "id": 148, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "799:4:1", + "src": "799:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2023,10 +2023,10 @@ "visibility": "internal" } ], - "src": "798:6:1" + "src": "798:6:2" }, - "scope": 85, - "src": "604:201:1", + "scope": 161, + "src": "604:201:2", "stateMutability": "payable", "superFunction": null, "visibility": "public" @@ -2034,38 +2034,38 @@ { "body": null, "documentation": null, - "id": 84, + "id": 160, "implemented": false, "kind": "function", "modifiers": [], "name": "swapEtherToToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 80, + "id": 156, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 77, + "id": 153, "name": "token", "nodeType": "VariableDeclaration", - "scope": 84, - "src": "837:11:1", + "scope": 160, + "src": "837:11:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 76, + "id": 152, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "837:5:1", + "referencedDeclaration": 10857, + "src": "837:5:2", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -2074,11 +2074,11 @@ }, { "constant": false, - "id": 79, + "id": 155, "name": "minConversionRate", "nodeType": "VariableDeclaration", - "scope": 84, - "src": "850:22:1", + "scope": 160, + "src": "850:22:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2086,10 +2086,10 @@ "typeString": "uint256" }, "typeName": { - "id": 78, + "id": 154, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "850:4:1", + "src": "850:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2099,19 +2099,19 @@ "visibility": "internal" } ], - "src": "836:37:1" + "src": "836:37:2" }, "returnParameters": { - "id": 83, + "id": 159, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 82, + "id": 158, "name": "", "nodeType": "VariableDeclaration", - "scope": 84, - "src": "897:4:1", + "scope": 160, + "src": "897:4:2", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2119,10 +2119,10 @@ "typeString": "uint256" }, "typeName": { - "id": 81, + "id": 157, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "897:4:1", + "src": "897:4:2", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2132,20 +2132,20 @@ "visibility": "internal" } ], - "src": "896:6:1" + "src": "896:6:2" }, - "scope": 85, - "src": "811:92:1", + "scope": 161, + "src": "811:92:2", "stateMutability": "payable", "superFunction": null, "visibility": "public" } ], - "scope": 86, - "src": "117:788:1" + "scope": 162, + "src": "117:788:2" } ], - "src": "0:906:1" + "src": "0:906:2" }, "compiler": { "name": "solc", @@ -2153,7 +2153,7 @@ }, "networks": {}, "schemaVersion": "3.0.16", - "updatedAt": "2019-11-04T18:56:07.463Z", + "updatedAt": "2019-11-07T14:57:54.555Z", "devdoc": { "methods": {}, "title": "Kyber Network interface" diff --git a/client/src/contracts/KyberTestContract.json b/client/src/contracts/KyberTestContract.json index cc7d124..547f50f 100644 --- a/client/src/contracts/KyberTestContract.json +++ b/client/src/contracts/KyberTestContract.json @@ -204,22 +204,22 @@ "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"getBalance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"kyberExchangeAddress\",\"type\":\"address\"},{\"name\":\"tokenAddress\",\"type\":\"address\"},{\"name\":\"kyberMinConversionRate\",\"type\":\"uint256\"},{\"name\":\"uniSwapExchangeAddress\",\"type\":\"address\"},{\"name\":\"ethToSell\",\"type\":\"uint256\"},{\"name\":\"maxTokensSell\",\"type\":\"uint256\"},{\"name\":\"sellDeadline\",\"type\":\"uint256\"},{\"name\":\"ethToBuy\",\"type\":\"uint256\"}],\"name\":\"trade\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"uniSwapExchangeAddress\",\"type\":\"address\"},{\"name\":\"maxTokensSell\",\"type\":\"uint256\"},{\"name\":\"sellDeadline\",\"type\":\"uint256\"},{\"name\":\"ethToBuy\",\"type\":\"uint256\"}],\"name\":\"tradeTokenToEth\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"kyberExchangeAddress\",\"type\":\"address\"},{\"name\":\"tokenAddress\",\"type\":\"address\"},{\"name\":\"kyberMinConversionRate\",\"type\":\"uint256\"},{\"name\":\"ethToSell\",\"type\":\"uint256\"}],\"name\":\"tradeEthToToken\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"tokenAddress\",\"type\":\"address\"},{\"name\":\"exchangeAddress\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approveToken\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"trader\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"tokens\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"token_bought\",\"type\":\"uint256\"}],\"name\":\"ethToToken\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"trader\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"ethToBuy\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"maxTokensSell\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"tokens_sold\",\"type\":\"uint256\"}],\"name\":\"tokenToEth\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"approveToken(address,address,uint256)\":{\"details\":\"Approves UniSwap exchange to transfer tokens from contract.\",\"params\":{\"amount\":\"Token amount to approve\",\"exchangeAddress\":\"UniSwap Exchange address\",\"tokenAddress\":\"Address of the token to approve\"}},\"constructor\":{\"details\":\"Contract constructor. Set owner of contract as deployer.\"},\"trade(address,address,uint256,address,uint256,uint256,uint256,uint256)\":{\"details\":\"Executes trade.\",\"params\":{\"ethToBuy\":\"Amount of Eth bought in Uniswap trade.\",\"ethToSell\":\"Amount of Eth that is being traded via Kyber. Should be sent as value too.\",\"kyberExchangeAddress\":\"Kyber network address\",\"kyberMinConversionRate\":\"Min conversion rate for Kyber\",\"maxTokensSell\":\"Maximum ERC20 tokens sold in Uniswap trade.\",\"sellDeadline\":\"Uniswap transaction deadline.\",\"tokenAddress\":\"Address of the token that is being traded\",\"uniSwapExchangeAddress\":\"UniSwap exchange address\"}}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/KyberTestContract.sol\":\"KyberTestContract\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/KyberNetworkProxy.sol\":{\"keccak256\":\"0x2fd6874b83795c5bdefc5fb0590c38508728a6e02c15ce63da00cac3789ba2af\",\"urls\":[\"bzzr://bc3bd85ae5d2dc5ad5c9351462dfdb853a7d04ad470fcfe90ab706476267be03\"]},\"/Users/jg/Documents/aaveBot/contracts/KyberTestContract.sol\":{\"keccak256\":\"0x1719804b4e9e37243d589c6b4f45429b760adf645bc0bf7e94b2be373214d723\",\"urls\":[\"bzzr://9b5d610653cc45fecc14be18e01a701d366acf2da5ad656f2db4e5920c757e34\"]},\"/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol\":{\"keccak256\":\"0x35ce204d214fb0d5b2e05df0b9e45833a2e8db564c995db36bfc023ff4a3f4f4\",\"urls\":[\"bzzr://5d4c7bc352bb1accf85e754811b6c0acc9bf0be87e852ba011c92b1344cfa463\"]},\"@openzeppelin/contracts/math/SafeMath.sol\":{\"keccak256\":\"0xd1804d04fb39689453f673601429a99a0c68c422a981fc338773df9a59180fe9\",\"urls\":[\"bzzr://a7dfb6fc259d0074da840a848461487567e2a6309105dd5c050a4e025f0fa7cb\"]},\"@openzeppelin/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x852793a3c2f86d336a683b30d688ec3dcfc57451af5a2bf5975cda3b7191a901\",\"urls\":[\"bzzr://07fb42206812a17c1f71e548cfa5cec6f9aa1ae0ca5df870718ca4aa9759d1a5\"]},\"@openzeppelin/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0x90e8c2521653bbb1768b05889c5760031e688d9cd361f167489b89215e201b95\",\"urls\":[\"bzzr://aa8b45b57edafc3d67bc5d916327ea16807fae33f753ca163ae0c4061b789766\"]}},\"version\":1}", "bytecode": "0x608060405234801561001057600080fd5b50336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550610b35806100606000396000f3fe6080604052600436106100555760003560e01c806312065fe01461005a5780635a1b2c78146100855780636efd905c1461013c5780638da5cb5b146101ab578063c37113b114610202578063da3e33971461027a575b600080fd5b34801561006657600080fd5b5061006f6102f5565b6040518082815260200191505060405180910390f35b61013a600480360361010081101561009c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291908035906020019092919080359060200190929190505050610314565b005b34801561014857600080fd5b506101a96004803603608081101561015f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035906020019092919080359060200190929190505050610633565b005b3480156101b757600080fd5b506101c0610791565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6102786004803603608081101561021857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291905050506107b6565b005b34801561028657600080fd5b506102f36004803603606081101561029d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610979565b005b60003073ffffffffffffffffffffffffffffffffffffffff1631905090565b8334101561038a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4e6f7420456e6f756768204574682053656e740000000000000000000000000081525060200191505060405180910390fd5b6000889050600088905060008273ffffffffffffffffffffffffffffffffffffffff16637a2a045688848c6040518463ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001925050506020604051808303818588803b15801561041d57600080fd5b505af1158015610431573d6000803e3d6000fd5b50505050506040513d602081101561044857600080fd5b810190808051906020019092919050505090507fef501080e89b7bbe29cfb8e1eb48a349f22c4777a3c85d770104c8a80f45b68d338883604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a1600088905060008173ffffffffffffffffffffffffffffffffffffffff1663d4e4841d878a8a336040518563ffffffff1660e01b8152600401808581526020018481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b15801561056c57600080fd5b505af1158015610580573d6000803e3d6000fd5b505050506040513d602081101561059657600080fd5b810190808051906020019092919050505090507fe9c245f1c1a4a7a621218231e7ed679594b1c02c80e4fe05a465ecb46dc37f4733878a84604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a150505050505050505050505050565b600084905060008173ffffffffffffffffffffffffffffffffffffffff1663d4e4841d848787336040518563ffffffff1660e01b8152600401808581526020018481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b1580156106d157600080fd5b505af11580156106e5573d6000803e3d6000fd5b505050506040513d60208110156106fb57600080fd5b810190808051906020019092919050505090507fe9c245f1c1a4a7a621218231e7ed679594b1c02c80e4fe05a465ecb46dc37f4733848784604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a1505050505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b8034101561082c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4e6f7420456e6f756768204574682053656e740000000000000000000000000081525060200191505060405180910390fd5b6000849050600084905060008273ffffffffffffffffffffffffffffffffffffffff16637a2a04568584886040518463ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001925050506020604051808303818588803b1580156108bf57600080fd5b505af11580156108d3573d6000803e3d6000fd5b50505050506040513d60208110156108ea57600080fd5b810190808051906020019092919050505090507fef501080e89b7bbe29cfb8e1eb48a349f22c4777a3c85d770104c8a80f45b68d338583604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a150505050505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610a3b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260168152602001807f4f6e6c79204f776e65722043616e20417070726f76650000000000000000000081525060200191505060405180910390fd5b60008390508073ffffffffffffffffffffffffffffffffffffffff1663095ea7b384846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b158015610ac757600080fd5b505af1158015610adb573d6000803e3d6000fd5b505050506040513d6020811015610af157600080fd5b8101908080519060200190929190505050505050505056fea165627a7a72305820c95462dfc0539afe9f4dce1d52e97708223e09a8ca0dce431fdfffa9a4edb3800029", "deployedBytecode": "0x6080604052600436106100555760003560e01c806312065fe01461005a5780635a1b2c78146100855780636efd905c1461013c5780638da5cb5b146101ab578063c37113b114610202578063da3e33971461027a575b600080fd5b34801561006657600080fd5b5061006f6102f5565b6040518082815260200191505060405180910390f35b61013a600480360361010081101561009c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291908035906020019092919080359060200190929190505050610314565b005b34801561014857600080fd5b506101a96004803603608081101561015f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035906020019092919080359060200190929190505050610633565b005b3480156101b757600080fd5b506101c0610791565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6102786004803603608081101561021857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291905050506107b6565b005b34801561028657600080fd5b506102f36004803603606081101561029d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610979565b005b60003073ffffffffffffffffffffffffffffffffffffffff1631905090565b8334101561038a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4e6f7420456e6f756768204574682053656e740000000000000000000000000081525060200191505060405180910390fd5b6000889050600088905060008273ffffffffffffffffffffffffffffffffffffffff16637a2a045688848c6040518463ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001925050506020604051808303818588803b15801561041d57600080fd5b505af1158015610431573d6000803e3d6000fd5b50505050506040513d602081101561044857600080fd5b810190808051906020019092919050505090507fef501080e89b7bbe29cfb8e1eb48a349f22c4777a3c85d770104c8a80f45b68d338883604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a1600088905060008173ffffffffffffffffffffffffffffffffffffffff1663d4e4841d878a8a336040518563ffffffff1660e01b8152600401808581526020018481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b15801561056c57600080fd5b505af1158015610580573d6000803e3d6000fd5b505050506040513d602081101561059657600080fd5b810190808051906020019092919050505090507fe9c245f1c1a4a7a621218231e7ed679594b1c02c80e4fe05a465ecb46dc37f4733878a84604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a150505050505050505050505050565b600084905060008173ffffffffffffffffffffffffffffffffffffffff1663d4e4841d848787336040518563ffffffff1660e01b8152600401808581526020018481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b1580156106d157600080fd5b505af11580156106e5573d6000803e3d6000fd5b505050506040513d60208110156106fb57600080fd5b810190808051906020019092919050505090507fe9c245f1c1a4a7a621218231e7ed679594b1c02c80e4fe05a465ecb46dc37f4733848784604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a1505050505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b8034101561082c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4e6f7420456e6f756768204574682053656e740000000000000000000000000081525060200191505060405180910390fd5b6000849050600084905060008273ffffffffffffffffffffffffffffffffffffffff16637a2a04568584886040518463ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001925050506020604051808303818588803b1580156108bf57600080fd5b505af11580156108d3573d6000803e3d6000fd5b50505050506040513d60208110156108ea57600080fd5b810190808051906020019092919050505090507fef501080e89b7bbe29cfb8e1eb48a349f22c4777a3c85d770104c8a80f45b68d338583604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a150505050505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610a3b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260168152602001807f4f6e6c79204f776e65722043616e20417070726f76650000000000000000000081525060200191505060405180910390fd5b60008390508073ffffffffffffffffffffffffffffffffffffffff1663095ea7b384846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b158015610ac757600080fd5b505af1158015610adb573d6000803e3d6000fd5b505050506040513d6020811015610af157600080fd5b8101908080519060200190929190505050505050505056fea165627a7a72305820c95462dfc0539afe9f4dce1d52e97708223e09a8ca0dce431fdfffa9a4edb3800029", - "sourceMap": "148:3661:2:-;;;524:50;8:9:-1;5:2;;;30:1;27;20:12;5:2;524:50:2;559:10;551:5;;:18;;;;;;;;;;;;;;;;;;148:3661;;;;;;", - "deployedSourceMap": "148:3661:2:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3716:91;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3716:91:2;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1621:1024;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;1621:1024:2;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;3229:483;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3229:483:2;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;3229:483:2;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;235:20;;8:9:-1;5:2;;;30:1;27;20:12;5:2;235:20:2;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2649:576;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;2649:576:2;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;813:237;;8:9:-1;5:2;;;30:1;27;20:12;5:2;813:237:2;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;813:237:2;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;3716:91;3759:7;3789:4;3781:21;;;3774:28;;3716:91;:::o;1621:1024::-;1918:9;1905;:22;;1897:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1980:31;2032:20;1980:73;;2059:11;2079:12;2059:33;;2145:20;2168:13;:30;;;2205:9;2216:5;2223:22;2168:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2168:78:2;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2168:78:2;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2168:78:2;;;;;;;;;;;;;;;;2145:101;;2257:47;2268:10;2280:9;2291:12;2257:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2377:31;2427:22;2377:73;;2456:19;2478:15;:40;;;2519:8;2529:13;2544:12;2558:10;2478:91;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2478:91:2;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2478:91:2;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2478:91:2;;;;;;;;;;;;;;;;2456:113;;2580:60;2591:10;2603:8;2613:13;2628:11;2580:60;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1621:1024;;;;;;;;;;;;;:::o;3229:483::-;3438:31;3488:22;3438:73;;3520:19;3542:15;:40;;;3583:8;3593:13;3608:12;3622:10;3542:91;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3542:91:2;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3542:91:2;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3542:91:2;;;;;;;;;;;;;;;;3520:113;;3647:60;3658:10;3670:8;3680:13;3695:11;3647:60;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3229:483;;;;;;:::o;235:20::-;;;;;;;;;;;;;:::o;2649:576::-;2842:9;2829;:22;;2821:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2884:31;2936:20;2884:73;;2966:11;2986:12;2966:33;;3008:20;3031:13;:30;;;3068:9;3079:5;3086:22;3031:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3031:78:2;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3031:78:2;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3031:78:2;;;;;;;;;;;;;;;;3008:101;;3173:47;3184:10;3196:9;3207:12;3173:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2649:576;;;;;;;:::o;813:237::-;930:5;;;;;;;;;;;916:19;;:10;:19;;;908:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;968:11;988:12;968:33;;1007:5;:13;;;1021:15;1038:6;1007:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1007:38:2;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1007:38:2;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1007:38:2;;;;;;;;;;;;;;;;;813:237;;;;:::o", + "sourceMap": "148:3661:3:-;;;524:50;8:9:-1;5:2;;;30:1;27;20:12;5:2;524:50:3;559:10;551:5;;:18;;;;;;;;;;;;;;;;;;148:3661;;;;;;", + "deployedSourceMap": "148:3661:3:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3716:91;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3716:91:3;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1621:1024;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;1621:1024:3;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;3229:483;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3229:483:3;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;3229:483:3;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;235:20;;8:9:-1;5:2;;;30:1;27;20:12;5:2;235:20:3;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2649:576;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;2649:576:3;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;813:237;;8:9:-1;5:2;;;30:1;27;20:12;5:2;813:237:3;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;813:237:3;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;3716:91;3759:7;3789:4;3781:21;;;3774:28;;3716:91;:::o;1621:1024::-;1918:9;1905;:22;;1897:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1980:31;2032:20;1980:73;;2059:11;2079:12;2059:33;;2145:20;2168:13;:30;;;2205:9;2216:5;2223:22;2168:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2168:78:3;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2168:78:3;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2168:78:3;;;;;;;;;;;;;;;;2145:101;;2257:47;2268:10;2280:9;2291:12;2257:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2377:31;2427:22;2377:73;;2456:19;2478:15;:40;;;2519:8;2529:13;2544:12;2558:10;2478:91;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2478:91:3;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2478:91:3;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2478:91:3;;;;;;;;;;;;;;;;2456:113;;2580:60;2591:10;2603:8;2613:13;2628:11;2580:60;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1621:1024;;;;;;;;;;;;;:::o;3229:483::-;3438:31;3488:22;3438:73;;3520:19;3542:15;:40;;;3583:8;3593:13;3608:12;3622:10;3542:91;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3542:91:3;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3542:91:3;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3542:91:3;;;;;;;;;;;;;;;;3520:113;;3647:60;3658:10;3670:8;3680:13;3695:11;3647:60;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3229:483;;;;;;:::o;235:20::-;;;;;;;;;;;;;:::o;2649:576::-;2842:9;2829;:22;;2821:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2884:31;2936:20;2884:73;;2966:11;2986:12;2966:33;;3008:20;3031:13;:30;;;3068:9;3079:5;3086:22;3031:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3031:78:3;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3031:78:3;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3031:78:3;;;;;;;;;;;;;;;;3008:101;;3173:47;3184:10;3196:9;3207:12;3173:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2649:576;;;;;;;:::o;813:237::-;930:5;;;;;;;;;;;916:19;;:10;:19;;;908:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;968:11;988:12;968:33;;1007:5;:13;;;1021:15;1038:6;1007:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1007:38:3;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1007:38:3;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1007:38:3;;;;;;;;;;;;;;;;;813:237;;;;:::o", "source": "pragma solidity ^0.5.0;\n\nimport \"./UniswapExchange.sol\";\nimport \"@openzeppelin/contracts/token/ERC20/ERC20.sol\";\nimport \"./KyberNetworkProxy.sol\";\n\ncontract KyberTestContract {\n // Variable to hold owner of contract. Set on deploy.\n address public owner;\n\n // Events\n event ethToToken(address trader, uint256 tokens, uint256 token_bought);\n event tokenToEth(address trader, uint256 ethToBuy, uint256 maxTokensSell, uint256 tokens_sold);\n\n /**\n * @dev Contract constructor. Set owner of contract as deployer.\n */\n constructor() public {\n owner = msg.sender;\n }\n\n /**\n * @dev Approves UniSwap exchange to transfer tokens from contract.\n * @param tokenAddress Address of the token to approve\n * @param exchangeAddress UniSwap Exchange address\n * @param amount Token amount to approve\n */\n function approveToken(address tokenAddress, address exchangeAddress, uint amount) public {\n require(msg.sender == owner, \"Only Owner Can Approve\");\n ERC20 token = ERC20(tokenAddress);\n token.approve(exchangeAddress, amount);\n }\n\n /**\n * @dev Executes trade.\n * @param kyberExchangeAddress Kyber network address\n * @param tokenAddress Address of the token that is being traded\n * @param kyberMinConversionRate Min conversion rate for Kyber\n * @param uniSwapExchangeAddress UniSwap exchange address\n * @param ethToSell Amount of Eth that is being traded via Kyber. Should be sent as value too.\n * @param maxTokensSell Maximum ERC20 tokens sold in Uniswap trade.\n * @param sellDeadline Uniswap transaction deadline.\n * @param ethToBuy Amount of Eth bought in Uniswap trade.\n */\n function trade(\n address kyberExchangeAddress,\n address tokenAddress,\n uint256 kyberMinConversionRate,\n address uniSwapExchangeAddress,\n uint256 ethToSell,\n uint256 maxTokensSell,\n uint256 sellDeadline,\n uint256 ethToBuy\n ) public\n payable\n {\n require(msg.value >= ethToSell, \"Not Enough Eth Sent\");\n // check approval\n\n KyberNetworkProxy kyberExchange = KyberNetworkProxy(kyberExchangeAddress);\n ERC20 token = ERC20(tokenAddress);\n\n // Swaps Eth for Token via Kyber Exchange\n uint256 token_bought = kyberExchange.swapEtherToToken.value(ethToSell)(token, kyberMinConversionRate);\n emit ethToToken(msg.sender, ethToSell, token_bought);\n\n // Swaps token to Eth and transfers Eth to msg sender address\n UniswapExchange uniSwapExchange = UniswapExchange(uniSwapExchangeAddress);\n uint256 tokens_sold = uniSwapExchange.tokenToEthTransferOutput(ethToBuy, maxTokensSell, sellDeadline, msg.sender);\n emit tokenToEth(msg.sender, ethToBuy, maxTokensSell, tokens_sold);\n }\n\n function tradeEthToToken(\n address kyberExchangeAddress,\n address tokenAddress,\n uint256 kyberMinConversionRate,\n uint256 ethToSell)\n public payable {\n require(msg.value >= ethToSell, \"Not Enough Eth Sent\");\n\n KyberNetworkProxy kyberExchange = KyberNetworkProxy(kyberExchangeAddress);\n\n ERC20 token = ERC20(tokenAddress);\n\n uint256 token_bought = kyberExchange.swapEtherToToken.value(ethToSell)(token, kyberMinConversionRate); // Swap Eth to token in UniSwap\n emit ethToToken(msg.sender, ethToSell, token_bought);\n }\n\n function tradeTokenToEth(\n address uniSwapExchangeAddress,\n uint256 maxTokensSell,\n uint256 sellDeadline,\n uint256 ethToBuy)\n public {\n // Should check approval - see Kyber example?\n\n UniswapExchange uniSwapExchange = UniswapExchange(uniSwapExchangeAddress);\n\n uint256 tokens_sold = uniSwapExchange.tokenToEthTransferOutput(ethToBuy, maxTokensSell, sellDeadline, msg.sender);\n\n emit tokenToEth(msg.sender, ethToBuy, maxTokensSell, tokens_sold);\n }\n\n function getBalance() public view returns (uint256) {\n return address(this).balance;\n }\n}\n", "sourcePath": "/Users/jg/Documents/aaveBot/contracts/KyberTestContract.sol", "ast": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/KyberTestContract.sol", "exportedSymbols": { "KyberTestContract": [ - 332 + 408 ] }, - "id": 333, + "id": 409, "nodeType": "SourceUnit", "nodes": [ { - "id": 87, + "id": 163, "literals": [ "solidity", "^", @@ -227,38 +227,38 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:2" + "src": "0:23:3" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol", "file": "./UniswapExchange.sol", - "id": 88, + "id": 164, "nodeType": "ImportDirective", - "scope": 333, - "sourceUnit": 845, - "src": "25:31:2", + "scope": 409, + "sourceUnit": 921, + "src": "25:31:3", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "@openzeppelin/contracts/token/ERC20/ERC20.sol", "file": "@openzeppelin/contracts/token/ERC20/ERC20.sol", - "id": 89, + "id": 165, "nodeType": "ImportDirective", - "scope": 333, - "sourceUnit": 1375, - "src": "57:55:2", + "scope": 409, + "sourceUnit": 10858, + "src": "57:55:3", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/KyberNetworkProxy.sol", "file": "./KyberNetworkProxy.sol", - "id": 90, + "id": 166, "nodeType": "ImportDirective", - "scope": 333, - "sourceUnit": 86, - "src": "113:33:2", + "scope": 409, + "sourceUnit": 162, + "src": "113:33:3", "symbolAliases": [], "unitAlias": "" }, @@ -268,20 +268,20 @@ "contractKind": "contract", "documentation": null, "fullyImplemented": true, - "id": 332, + "id": 408, "linearizedBaseContracts": [ - 332 + 408 ], "name": "KyberTestContract", "nodeType": "ContractDefinition", "nodes": [ { "constant": false, - "id": 92, + "id": 168, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 332, - "src": "235:20:2", + "scope": 408, + "src": "235:20:3", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -289,10 +289,10 @@ "typeString": "address" }, "typeName": { - "id": 91, + "id": 167, "name": "address", "nodeType": "ElementaryTypeName", - "src": "235:7:2", + "src": "235:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -305,21 +305,21 @@ { "anonymous": false, "documentation": null, - "id": 100, + "id": 176, "name": "ethToToken", "nodeType": "EventDefinition", "parameters": { - "id": 99, + "id": 175, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 94, + "id": 170, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 100, - "src": "289:14:2", + "scope": 176, + "src": "289:14:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -327,10 +327,10 @@ "typeString": "address" }, "typeName": { - "id": 93, + "id": 169, "name": "address", "nodeType": "ElementaryTypeName", - "src": "289:7:2", + "src": "289:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -342,12 +342,12 @@ }, { "constant": false, - "id": 96, + "id": 172, "indexed": false, "name": "tokens", "nodeType": "VariableDeclaration", - "scope": 100, - "src": "305:14:2", + "scope": 176, + "src": "305:14:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -355,10 +355,10 @@ "typeString": "uint256" }, "typeName": { - "id": 95, + "id": 171, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "305:7:2", + "src": "305:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -369,12 +369,12 @@ }, { "constant": false, - "id": 98, + "id": 174, "indexed": false, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 100, - "src": "321:20:2", + "scope": 176, + "src": "321:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -382,10 +382,10 @@ "typeString": "uint256" }, "typeName": { - "id": 97, + "id": 173, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "321:7:2", + "src": "321:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -395,28 +395,28 @@ "visibility": "internal" } ], - "src": "288:54:2" + "src": "288:54:3" }, - "src": "272:71:2" + "src": "272:71:3" }, { "anonymous": false, "documentation": null, - "id": 110, + "id": 186, "name": "tokenToEth", "nodeType": "EventDefinition", "parameters": { - "id": 109, + "id": 185, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 102, + "id": 178, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 110, - "src": "363:14:2", + "scope": 186, + "src": "363:14:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -424,10 +424,10 @@ "typeString": "address" }, "typeName": { - "id": 101, + "id": 177, "name": "address", "nodeType": "ElementaryTypeName", - "src": "363:7:2", + "src": "363:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -439,12 +439,12 @@ }, { "constant": false, - "id": 104, + "id": 180, "indexed": false, "name": "ethToBuy", "nodeType": "VariableDeclaration", - "scope": 110, - "src": "379:16:2", + "scope": 186, + "src": "379:16:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -452,10 +452,10 @@ "typeString": "uint256" }, "typeName": { - "id": 103, + "id": 179, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "379:7:2", + "src": "379:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -466,12 +466,12 @@ }, { "constant": false, - "id": 106, + "id": 182, "indexed": false, "name": "maxTokensSell", "nodeType": "VariableDeclaration", - "scope": 110, - "src": "397:21:2", + "scope": 186, + "src": "397:21:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -479,10 +479,10 @@ "typeString": "uint256" }, "typeName": { - "id": 105, + "id": 181, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "397:7:2", + "src": "397:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -493,12 +493,12 @@ }, { "constant": false, - "id": 108, + "id": 184, "indexed": false, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 110, - "src": "420:19:2", + "scope": 186, + "src": "420:19:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -506,10 +506,10 @@ "typeString": "uint256" }, "typeName": { - "id": 107, + "id": 183, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "420:7:2", + "src": "420:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -519,32 +519,32 @@ "visibility": "internal" } ], - "src": "362:78:2" + "src": "362:78:3" }, - "src": "346:95:2" + "src": "346:95:3" }, { "body": { - "id": 118, + "id": 194, "nodeType": "Block", - "src": "545:29:2", + "src": "545:29:3", "statements": [ { "expression": { "argumentTypes": null, - "id": 116, + "id": 192, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 113, + "id": 189, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 92, - "src": "551:5:2", + "referencedDeclaration": 168, + "src": "551:5:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -556,18 +556,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 114, + "id": 190, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "559:3:2", + "referencedDeclaration": 12128, + "src": "559:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 115, + "id": 191, "isConstant": false, "isLValue": false, "isPure": false, @@ -575,54 +575,54 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "559:10:2", + "src": "559:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "551:18:2", + "src": "551:18:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 117, + "id": 193, "nodeType": "ExpressionStatement", - "src": "551:18:2" + "src": "551:18:3" } ] }, "documentation": "@dev Contract constructor. Set owner of contract as deployer.", - "id": 119, + "id": 195, "implemented": true, "kind": "constructor", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "parameters": { - "id": 111, + "id": 187, "nodeType": "ParameterList", "parameters": [], - "src": "535:2:2" + "src": "535:2:3" }, "returnParameters": { - "id": 112, + "id": 188, "nodeType": "ParameterList", "parameters": [], - "src": "545:0:2" + "src": "545:0:3" }, - "scope": 332, - "src": "524:50:2", + "scope": 408, + "src": "524:50:3", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 149, + "id": 225, "nodeType": "Block", - "src": "902:148:2", + "src": "902:148:3", "statements": [ { "expression": { @@ -634,7 +634,7 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 132, + "id": 208, "isConstant": false, "isLValue": false, "isPure": false, @@ -643,18 +643,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 129, + "id": 205, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "916:3:2", + "referencedDeclaration": 12128, + "src": "916:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 130, + "id": 206, "isConstant": false, "isLValue": false, "isPure": false, @@ -662,7 +662,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "916:10:2", + "src": "916:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -672,18 +672,18 @@ "operator": "==", "rightExpression": { "argumentTypes": null, - "id": 131, + "id": 207, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 92, - "src": "930:5:2", + "referencedDeclaration": 168, + "src": "930:5:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "src": "916:19:2", + "src": "916:19:3", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -692,14 +692,14 @@ { "argumentTypes": null, "hexValue": "4f6e6c79204f776e65722043616e20417070726f7665", - "id": 133, + "id": 209, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "937:24:2", + "src": "937:24:3", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_ec0b1a840a8a6c4384575556c3817abb58aac6b2bc4e7741e1c712be8067937e", @@ -719,21 +719,21 @@ "typeString": "literal_string \"Only Owner Can Approve\"" } ], - "id": 128, + "id": 204, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "908:7:2", + "referencedDeclaration": 12132, + "src": "908:7:3", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 134, + "id": 210, "isConstant": false, "isLValue": false, "isPure": false, @@ -741,43 +741,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "908:54:2", + "src": "908:54:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 135, + "id": 211, "nodeType": "ExpressionStatement", - "src": "908:54:2" + "src": "908:54:3" }, { "assignments": [ - 137 + 213 ], "declarations": [ { "constant": false, - "id": 137, + "id": 213, "name": "token", "nodeType": "VariableDeclaration", - "scope": 149, - "src": "968:11:2", + "scope": 225, + "src": "968:11:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 136, + "id": 212, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "968:5:2", + "referencedDeclaration": 10857, + "src": "968:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -785,18 +785,18 @@ "visibility": "internal" } ], - "id": 141, + "id": 217, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 139, + "id": 215, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 121, - "src": "988:12:2", + "referencedDeclaration": 197, + "src": "988:12:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -810,18 +810,18 @@ "typeString": "address" } ], - "id": 138, + "id": 214, "name": "ERC20", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1374, - "src": "982:5:2", + "referencedDeclaration": 10857, + "src": "982:5:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_ERC20_$1374_$", + "typeIdentifier": "t_type$_t_contract$_ERC20_$10857_$", "typeString": "type(contract ERC20)" } }, - "id": 140, + "id": 216, "isConstant": false, "isLValue": false, "isPure": false, @@ -829,14 +829,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "982:19:2", + "src": "982:19:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, "nodeType": "VariableDeclarationStatement", - "src": "968:33:2" + "src": "968:33:3" }, { "expression": { @@ -844,12 +844,12 @@ "arguments": [ { "argumentTypes": null, - "id": 145, + "id": 221, "name": "exchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 123, - "src": "1021:15:2", + "referencedDeclaration": 199, + "src": "1021:15:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -857,12 +857,12 @@ }, { "argumentTypes": null, - "id": 146, + "id": 222, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 125, - "src": "1038:6:2", + "referencedDeclaration": 201, + "src": "1038:6:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -882,32 +882,32 @@ ], "expression": { "argumentTypes": null, - "id": 142, + "id": 218, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 137, - "src": "1007:5:2", + "referencedDeclaration": 213, + "src": "1007:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, - "id": 144, + "id": 220, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "approve", "nodeType": "MemberAccess", - "referencedDeclaration": 1072, - "src": "1007:13:2", + "referencedDeclaration": 10555, + "src": "1007:13:3", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,uint256) external returns (bool)" } }, - "id": 147, + "id": 223, "isConstant": false, "isLValue": false, "isPure": false, @@ -915,36 +915,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1007:38:2", + "src": "1007:38:3", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, - "id": 148, + "id": 224, "nodeType": "ExpressionStatement", - "src": "1007:38:2" + "src": "1007:38:3" } ] }, "documentation": "@dev Approves UniSwap exchange to transfer tokens from contract.\n@param tokenAddress Address of the token to approve\n@param exchangeAddress UniSwap Exchange address\n@param amount Token amount to approve", - "id": 150, + "id": 226, "implemented": true, "kind": "function", "modifiers": [], "name": "approveToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 126, + "id": 202, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 121, + "id": 197, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 150, - "src": "835:20:2", + "scope": 226, + "src": "835:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -952,10 +952,10 @@ "typeString": "address" }, "typeName": { - "id": 120, + "id": 196, "name": "address", "nodeType": "ElementaryTypeName", - "src": "835:7:2", + "src": "835:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -967,11 +967,11 @@ }, { "constant": false, - "id": 123, + "id": 199, "name": "exchangeAddress", "nodeType": "VariableDeclaration", - "scope": 150, - "src": "857:23:2", + "scope": 226, + "src": "857:23:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -979,10 +979,10 @@ "typeString": "address" }, "typeName": { - "id": 122, + "id": 198, "name": "address", "nodeType": "ElementaryTypeName", - "src": "857:7:2", + "src": "857:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -994,11 +994,11 @@ }, { "constant": false, - "id": 125, + "id": 201, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 150, - "src": "882:11:2", + "scope": 226, + "src": "882:11:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1006,10 +1006,10 @@ "typeString": "uint256" }, "typeName": { - "id": 124, + "id": 200, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "882:4:2", + "src": "882:4:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1019,25 +1019,25 @@ "visibility": "internal" } ], - "src": "834:60:2" + "src": "834:60:3" }, "returnParameters": { - "id": 127, + "id": 203, "nodeType": "ParameterList", "parameters": [], - "src": "902:0:2" + "src": "902:0:3" }, - "scope": 332, - "src": "813:237:2", + "scope": 408, + "src": "813:237:3", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 232, + "id": 308, "nodeType": "Block", - "src": "1891:754:2", + "src": "1891:754:3", "statements": [ { "expression": { @@ -1049,7 +1049,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 173, + "id": 249, "isConstant": false, "isLValue": false, "isPure": false, @@ -1058,18 +1058,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 170, + "id": 246, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1905:3:2", + "referencedDeclaration": 12128, + "src": "1905:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 171, + "id": 247, "isConstant": false, "isLValue": false, "isPure": false, @@ -1077,7 +1077,7 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1905:9:2", + "src": "1905:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1087,18 +1087,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 172, + "id": 248, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 160, - "src": "1918:9:2", + "referencedDeclaration": 236, + "src": "1918:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "1905:22:2", + "src": "1905:22:3", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1107,14 +1107,14 @@ { "argumentTypes": null, "hexValue": "4e6f7420456e6f756768204574682053656e74", - "id": 174, + "id": 250, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "1929:21:2", + "src": "1929:21:3", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30b29beae4cdbb7acc80a8e1229a071d1d9114e20038f0c713ecf8dbdd0dcc4e", @@ -1134,21 +1134,21 @@ "typeString": "literal_string \"Not Enough Eth Sent\"" } ], - "id": 169, + "id": 245, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "1897:7:2", + "referencedDeclaration": 12132, + "src": "1897:7:3", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 175, + "id": 251, "isConstant": false, "isLValue": false, "isPure": false, @@ -1156,43 +1156,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1897:54:2", + "src": "1897:54:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 176, + "id": 252, "nodeType": "ExpressionStatement", - "src": "1897:54:2" + "src": "1897:54:3" }, { "assignments": [ - 178 + 254 ], "declarations": [ { "constant": false, - "id": 178, + "id": 254, "name": "kyberExchange", "nodeType": "VariableDeclaration", - "scope": 232, - "src": "1980:31:2", + "scope": 308, + "src": "1980:31:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" }, "typeName": { "contractScope": null, - "id": 177, + "id": 253, "name": "KyberNetworkProxy", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 85, - "src": "1980:17:2", + "referencedDeclaration": 161, + "src": "1980:17:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, @@ -1200,18 +1200,18 @@ "visibility": "internal" } ], - "id": 182, + "id": 258, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 180, + "id": 256, "name": "kyberExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 152, - "src": "2032:20:2", + "referencedDeclaration": 228, + "src": "2032:20:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1225,18 +1225,18 @@ "typeString": "address" } ], - "id": 179, + "id": 255, "name": "KyberNetworkProxy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 85, - "src": "2014:17:2", + "referencedDeclaration": 161, + "src": "2014:17:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$85_$", + "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$161_$", "typeString": "type(contract KyberNetworkProxy)" } }, - "id": 181, + "id": 257, "isConstant": false, "isLValue": false, "isPure": false, @@ -1244,42 +1244,42 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2014:39:2", + "src": "2014:39:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, "nodeType": "VariableDeclarationStatement", - "src": "1980:73:2" + "src": "1980:73:3" }, { "assignments": [ - 184 + 260 ], "declarations": [ { "constant": false, - "id": 184, + "id": 260, "name": "token", "nodeType": "VariableDeclaration", - "scope": 232, - "src": "2059:11:2", + "scope": 308, + "src": "2059:11:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 183, + "id": 259, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "2059:5:2", + "referencedDeclaration": 10857, + "src": "2059:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -1287,18 +1287,18 @@ "visibility": "internal" } ], - "id": 188, + "id": 264, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 186, + "id": 262, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 154, - "src": "2079:12:2", + "referencedDeclaration": 230, + "src": "2079:12:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1312,18 +1312,18 @@ "typeString": "address" } ], - "id": 185, + "id": 261, "name": "ERC20", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1374, - "src": "2073:5:2", + "referencedDeclaration": 10857, + "src": "2073:5:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_ERC20_$1374_$", + "typeIdentifier": "t_type$_t_contract$_ERC20_$10857_$", "typeString": "type(contract ERC20)" } }, - "id": 187, + "id": 263, "isConstant": false, "isLValue": false, "isPure": false, @@ -1331,27 +1331,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2073:19:2", + "src": "2073:19:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, "nodeType": "VariableDeclarationStatement", - "src": "2059:33:2" + "src": "2059:33:3" }, { "assignments": [ - 190 + 266 ], "declarations": [ { "constant": false, - "id": 190, + "id": 266, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 232, - "src": "2145:20:2", + "scope": 308, + "src": "2145:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1359,10 +1359,10 @@ "typeString": "uint256" }, "typeName": { - "id": 189, + "id": 265, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2145:7:2", + "src": "2145:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1372,31 +1372,31 @@ "visibility": "internal" } ], - "id": 199, + "id": 275, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 196, + "id": 272, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 184, - "src": "2216:5:2", + "referencedDeclaration": 260, + "src": "2216:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, { "argumentTypes": null, - "id": 197, + "id": 273, "name": "kyberMinConversionRate", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 156, - "src": "2223:22:2", + "referencedDeclaration": 232, + "src": "2223:22:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1406,7 +1406,7 @@ "expression": { "argumentTypes": [ { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, { @@ -1417,12 +1417,12 @@ "arguments": [ { "argumentTypes": null, - "id": 194, + "id": 270, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 160, - "src": "2205:9:2", + "referencedDeclaration": 236, + "src": "2205:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1440,32 +1440,32 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 191, + "id": 267, "name": "kyberExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 178, - "src": "2168:13:2", + "referencedDeclaration": 254, + "src": "2168:13:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, - "id": 192, + "id": 268, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "swapEtherToToken", "nodeType": "MemberAccess", - "referencedDeclaration": 84, - "src": "2168:30:2", + "referencedDeclaration": 160, + "src": "2168:30:3", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 193, + "id": 269, "isConstant": false, "isLValue": false, "isPure": false, @@ -1473,13 +1473,13 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2168:36:2", + "src": "2168:36:3", "typeDescriptions": { - "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value_$", + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value_$", "typeString": "function (uint256) returns (function (contract ERC20,uint256) payable external returns (uint256))" } }, - "id": 195, + "id": 271, "isConstant": false, "isLValue": false, "isPure": false, @@ -1487,13 +1487,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2168:47:2", + "src": "2168:47:3", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 198, + "id": 274, "isConstant": false, "isLValue": false, "isPure": false, @@ -1501,14 +1501,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2168:78:2", + "src": "2168:78:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2145:101:2" + "src": "2145:101:3" }, { "eventCall": { @@ -1518,18 +1518,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 201, + "id": 277, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2268:3:2", + "referencedDeclaration": 12128, + "src": "2268:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 202, + "id": 278, "isConstant": false, "isLValue": false, "isPure": false, @@ -1537,7 +1537,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2268:10:2", + "src": "2268:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1545,12 +1545,12 @@ }, { "argumentTypes": null, - "id": 203, + "id": 279, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 160, - "src": "2280:9:2", + "referencedDeclaration": 236, + "src": "2280:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1558,12 +1558,12 @@ }, { "argumentTypes": null, - "id": 204, + "id": 280, "name": "token_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 190, - "src": "2291:12:2", + "referencedDeclaration": 266, + "src": "2291:12:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1585,18 +1585,18 @@ "typeString": "uint256" } ], - "id": 200, + "id": 276, "name": "ethToToken", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 100, - "src": "2257:10:2", + "referencedDeclaration": 176, + "src": "2257:10:3", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256)" } }, - "id": 205, + "id": 281, "isConstant": false, "isLValue": false, "isPure": false, @@ -1604,43 +1604,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2257:47:2", + "src": "2257:47:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 206, + "id": 282, "nodeType": "EmitStatement", - "src": "2252:52:2" + "src": "2252:52:3" }, { "assignments": [ - 208 + 284 ], "declarations": [ { "constant": false, - "id": 208, + "id": 284, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 232, - "src": "2377:31:2", + "scope": 308, + "src": "2377:31:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 207, + "id": 283, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "2377:15:2", + "referencedDeclaration": 920, + "src": "2377:15:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -1648,18 +1648,18 @@ "visibility": "internal" } ], - "id": 212, + "id": 288, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 210, + "id": 286, "name": "uniSwapExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 158, - "src": "2427:22:2", + "referencedDeclaration": 234, + "src": "2427:22:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1673,18 +1673,18 @@ "typeString": "address" } ], - "id": 209, + "id": 285, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "2411:15:2", + "referencedDeclaration": 920, + "src": "2411:15:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 211, + "id": 287, "isConstant": false, "isLValue": false, "isPure": false, @@ -1692,27 +1692,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2411:39:2", + "src": "2411:39:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "2377:73:2" + "src": "2377:73:3" }, { "assignments": [ - 214 + 290 ], "declarations": [ { "constant": false, - "id": 214, + "id": 290, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 232, - "src": "2456:19:2", + "scope": 308, + "src": "2456:19:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1720,10 +1720,10 @@ "typeString": "uint256" }, "typeName": { - "id": 213, + "id": 289, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2456:7:2", + "src": "2456:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1733,18 +1733,18 @@ "visibility": "internal" } ], - "id": 223, + "id": 299, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 217, + "id": 293, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 166, - "src": "2519:8:2", + "referencedDeclaration": 242, + "src": "2519:8:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1752,12 +1752,12 @@ }, { "argumentTypes": null, - "id": 218, + "id": 294, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 162, - "src": "2529:13:2", + "referencedDeclaration": 238, + "src": "2529:13:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1765,12 +1765,12 @@ }, { "argumentTypes": null, - "id": 219, + "id": 295, "name": "sellDeadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 164, - "src": "2544:12:2", + "referencedDeclaration": 240, + "src": "2544:12:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1780,18 +1780,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 220, + "id": 296, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2558:3:2", + "referencedDeclaration": 12128, + "src": "2558:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 221, + "id": 297, "isConstant": false, "isLValue": false, "isPure": false, @@ -1799,7 +1799,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2558:10:2", + "src": "2558:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1827,32 +1827,32 @@ ], "expression": { "argumentTypes": null, - "id": 215, + "id": 291, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 208, - "src": "2478:15:2", + "referencedDeclaration": 284, + "src": "2478:15:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 216, + "id": 292, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "tokenToEthTransferOutput", "nodeType": "MemberAccess", - "referencedDeclaration": 839, - "src": "2478:40:2", + "referencedDeclaration": 915, + "src": "2478:40:3", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_payable_$returns$_t_uint256_$", "typeString": "function (uint256,uint256,uint256,address payable) external returns (uint256)" } }, - "id": 222, + "id": 298, "isConstant": false, "isLValue": false, "isPure": false, @@ -1860,14 +1860,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2478:91:2", + "src": "2478:91:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2456:113:2" + "src": "2456:113:3" }, { "eventCall": { @@ -1877,18 +1877,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 225, + "id": 301, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2591:3:2", + "referencedDeclaration": 12128, + "src": "2591:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 226, + "id": 302, "isConstant": false, "isLValue": false, "isPure": false, @@ -1896,7 +1896,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2591:10:2", + "src": "2591:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1904,12 +1904,12 @@ }, { "argumentTypes": null, - "id": 227, + "id": 303, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 166, - "src": "2603:8:2", + "referencedDeclaration": 242, + "src": "2603:8:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1917,12 +1917,12 @@ }, { "argumentTypes": null, - "id": 228, + "id": 304, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 162, - "src": "2613:13:2", + "referencedDeclaration": 238, + "src": "2613:13:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1930,12 +1930,12 @@ }, { "argumentTypes": null, - "id": 229, + "id": 305, "name": "tokens_sold", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 214, - "src": "2628:11:2", + "referencedDeclaration": 290, + "src": "2628:11:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1961,18 +1961,18 @@ "typeString": "uint256" } ], - "id": 224, + "id": 300, "name": "tokenToEth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 110, - "src": "2580:10:2", + "referencedDeclaration": 186, + "src": "2580:10:3", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 230, + "id": 306, "isConstant": false, "isLValue": false, "isPure": false, @@ -1980,36 +1980,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2580:60:2", + "src": "2580:60:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 231, + "id": 307, "nodeType": "EmitStatement", - "src": "2575:65:2" + "src": "2575:65:3" } ] }, "documentation": "@dev Executes trade.\n@param kyberExchangeAddress Kyber network address\n@param tokenAddress Address of the token that is being traded\n@param kyberMinConversionRate Min conversion rate for Kyber\n@param uniSwapExchangeAddress UniSwap exchange address\n@param ethToSell Amount of Eth that is being traded via Kyber. Should be sent as value too.\n@param maxTokensSell Maximum ERC20 tokens sold in Uniswap trade.\n@param sellDeadline Uniswap transaction deadline.\n@param ethToBuy Amount of Eth bought in Uniswap trade.", - "id": 233, + "id": 309, "implemented": true, "kind": "function", "modifiers": [], "name": "trade", "nodeType": "FunctionDefinition", "parameters": { - "id": 167, + "id": 243, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 152, + "id": 228, "name": "kyberExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1641:28:2", + "scope": 309, + "src": "1641:28:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2017,10 +2017,10 @@ "typeString": "address" }, "typeName": { - "id": 151, + "id": 227, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1641:7:2", + "src": "1641:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2032,11 +2032,11 @@ }, { "constant": false, - "id": 154, + "id": 230, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1675:20:2", + "scope": 309, + "src": "1675:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2044,10 +2044,10 @@ "typeString": "address" }, "typeName": { - "id": 153, + "id": 229, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1675:7:2", + "src": "1675:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2059,11 +2059,11 @@ }, { "constant": false, - "id": 156, + "id": 232, "name": "kyberMinConversionRate", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1701:30:2", + "scope": 309, + "src": "1701:30:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2071,10 +2071,10 @@ "typeString": "uint256" }, "typeName": { - "id": 155, + "id": 231, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1701:7:2", + "src": "1701:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2085,11 +2085,11 @@ }, { "constant": false, - "id": 158, + "id": 234, "name": "uniSwapExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1737:30:2", + "scope": 309, + "src": "1737:30:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2097,10 +2097,10 @@ "typeString": "address" }, "typeName": { - "id": 157, + "id": 233, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1737:7:2", + "src": "1737:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2112,11 +2112,11 @@ }, { "constant": false, - "id": 160, + "id": 236, "name": "ethToSell", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1773:17:2", + "scope": 309, + "src": "1773:17:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2124,10 +2124,10 @@ "typeString": "uint256" }, "typeName": { - "id": 159, + "id": 235, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1773:7:2", + "src": "1773:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2138,11 +2138,11 @@ }, { "constant": false, - "id": 162, + "id": 238, "name": "maxTokensSell", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1796:21:2", + "scope": 309, + "src": "1796:21:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2150,10 +2150,10 @@ "typeString": "uint256" }, "typeName": { - "id": 161, + "id": 237, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1796:7:2", + "src": "1796:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2164,11 +2164,11 @@ }, { "constant": false, - "id": 164, + "id": 240, "name": "sellDeadline", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1823:20:2", + "scope": 309, + "src": "1823:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2176,10 +2176,10 @@ "typeString": "uint256" }, "typeName": { - "id": 163, + "id": 239, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1823:7:2", + "src": "1823:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2190,11 +2190,11 @@ }, { "constant": false, - "id": 166, + "id": 242, "name": "ethToBuy", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1849:16:2", + "scope": 309, + "src": "1849:16:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2202,10 +2202,10 @@ "typeString": "uint256" }, "typeName": { - "id": 165, + "id": 241, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1849:7:2", + "src": "1849:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2215,25 +2215,25 @@ "visibility": "internal" } ], - "src": "1635:234:2" + "src": "1635:234:3" }, "returnParameters": { - "id": 168, + "id": 244, "nodeType": "ParameterList", "parameters": [], - "src": "1891:0:2" + "src": "1891:0:3" }, - "scope": 332, - "src": "1621:1024:2", + "scope": 408, + "src": "1621:1024:3", "stateMutability": "payable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 282, + "id": 358, "nodeType": "Block", - "src": "2813:412:2", + "src": "2813:412:3", "statements": [ { "expression": { @@ -2245,7 +2245,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 248, + "id": 324, "isConstant": false, "isLValue": false, "isPure": false, @@ -2254,18 +2254,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 245, + "id": 321, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2829:3:2", + "referencedDeclaration": 12128, + "src": "2829:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 246, + "id": 322, "isConstant": false, "isLValue": false, "isPure": false, @@ -2273,7 +2273,7 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2829:9:2", + "src": "2829:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2283,18 +2283,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 247, + "id": 323, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 241, - "src": "2842:9:2", + "referencedDeclaration": 317, + "src": "2842:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "2829:22:2", + "src": "2829:22:3", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -2303,14 +2303,14 @@ { "argumentTypes": null, "hexValue": "4e6f7420456e6f756768204574682053656e74", - "id": 249, + "id": 325, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "2853:21:2", + "src": "2853:21:3", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30b29beae4cdbb7acc80a8e1229a071d1d9114e20038f0c713ecf8dbdd0dcc4e", @@ -2330,21 +2330,21 @@ "typeString": "literal_string \"Not Enough Eth Sent\"" } ], - "id": 244, + "id": 320, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "2821:7:2", + "referencedDeclaration": 12132, + "src": "2821:7:3", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 250, + "id": 326, "isConstant": false, "isLValue": false, "isPure": false, @@ -2352,43 +2352,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2821:54:2", + "src": "2821:54:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 251, + "id": 327, "nodeType": "ExpressionStatement", - "src": "2821:54:2" + "src": "2821:54:3" }, { "assignments": [ - 253 + 329 ], "declarations": [ { "constant": false, - "id": 253, + "id": 329, "name": "kyberExchange", "nodeType": "VariableDeclaration", - "scope": 282, - "src": "2884:31:2", + "scope": 358, + "src": "2884:31:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" }, "typeName": { "contractScope": null, - "id": 252, + "id": 328, "name": "KyberNetworkProxy", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 85, - "src": "2884:17:2", + "referencedDeclaration": 161, + "src": "2884:17:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, @@ -2396,18 +2396,18 @@ "visibility": "internal" } ], - "id": 257, + "id": 333, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 255, + "id": 331, "name": "kyberExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 235, - "src": "2936:20:2", + "referencedDeclaration": 311, + "src": "2936:20:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2421,18 +2421,18 @@ "typeString": "address" } ], - "id": 254, + "id": 330, "name": "KyberNetworkProxy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 85, - "src": "2918:17:2", + "referencedDeclaration": 161, + "src": "2918:17:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$85_$", + "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$161_$", "typeString": "type(contract KyberNetworkProxy)" } }, - "id": 256, + "id": 332, "isConstant": false, "isLValue": false, "isPure": false, @@ -2440,42 +2440,42 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2918:39:2", + "src": "2918:39:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, "nodeType": "VariableDeclarationStatement", - "src": "2884:73:2" + "src": "2884:73:3" }, { "assignments": [ - 259 + 335 ], "declarations": [ { "constant": false, - "id": 259, + "id": 335, "name": "token", "nodeType": "VariableDeclaration", - "scope": 282, - "src": "2966:11:2", + "scope": 358, + "src": "2966:11:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 258, + "id": 334, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "2966:5:2", + "referencedDeclaration": 10857, + "src": "2966:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -2483,18 +2483,18 @@ "visibility": "internal" } ], - "id": 263, + "id": 339, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 261, + "id": 337, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 237, - "src": "2986:12:2", + "referencedDeclaration": 313, + "src": "2986:12:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2508,18 +2508,18 @@ "typeString": "address" } ], - "id": 260, + "id": 336, "name": "ERC20", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1374, - "src": "2980:5:2", + "referencedDeclaration": 10857, + "src": "2980:5:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_ERC20_$1374_$", + "typeIdentifier": "t_type$_t_contract$_ERC20_$10857_$", "typeString": "type(contract ERC20)" } }, - "id": 262, + "id": 338, "isConstant": false, "isLValue": false, "isPure": false, @@ -2527,27 +2527,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2980:19:2", + "src": "2980:19:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, "nodeType": "VariableDeclarationStatement", - "src": "2966:33:2" + "src": "2966:33:3" }, { "assignments": [ - 265 + 341 ], "declarations": [ { "constant": false, - "id": 265, + "id": 341, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 282, - "src": "3008:20:2", + "scope": 358, + "src": "3008:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2555,10 +2555,10 @@ "typeString": "uint256" }, "typeName": { - "id": 264, + "id": 340, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3008:7:2", + "src": "3008:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2568,31 +2568,31 @@ "visibility": "internal" } ], - "id": 274, + "id": 350, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 271, + "id": 347, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 259, - "src": "3079:5:2", + "referencedDeclaration": 335, + "src": "3079:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, { "argumentTypes": null, - "id": 272, + "id": 348, "name": "kyberMinConversionRate", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 239, - "src": "3086:22:2", + "referencedDeclaration": 315, + "src": "3086:22:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2602,7 +2602,7 @@ "expression": { "argumentTypes": [ { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, { @@ -2613,12 +2613,12 @@ "arguments": [ { "argumentTypes": null, - "id": 269, + "id": 345, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 241, - "src": "3068:9:2", + "referencedDeclaration": 317, + "src": "3068:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2636,32 +2636,32 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 266, + "id": 342, "name": "kyberExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 253, - "src": "3031:13:2", + "referencedDeclaration": 329, + "src": "3031:13:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, - "id": 267, + "id": 343, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "swapEtherToToken", "nodeType": "MemberAccess", - "referencedDeclaration": 84, - "src": "3031:30:2", + "referencedDeclaration": 160, + "src": "3031:30:3", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 268, + "id": 344, "isConstant": false, "isLValue": false, "isPure": false, @@ -2669,13 +2669,13 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "3031:36:2", + "src": "3031:36:3", "typeDescriptions": { - "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value_$", + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value_$", "typeString": "function (uint256) returns (function (contract ERC20,uint256) payable external returns (uint256))" } }, - "id": 270, + "id": 346, "isConstant": false, "isLValue": false, "isPure": false, @@ -2683,13 +2683,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3031:47:2", + "src": "3031:47:3", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 273, + "id": 349, "isConstant": false, "isLValue": false, "isPure": false, @@ -2697,14 +2697,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3031:78:2", + "src": "3031:78:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "3008:101:2" + "src": "3008:101:3" }, { "eventCall": { @@ -2714,18 +2714,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 276, + "id": 352, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3184:3:2", + "referencedDeclaration": 12128, + "src": "3184:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 277, + "id": 353, "isConstant": false, "isLValue": false, "isPure": false, @@ -2733,7 +2733,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "3184:10:2", + "src": "3184:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -2741,12 +2741,12 @@ }, { "argumentTypes": null, - "id": 278, + "id": 354, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 241, - "src": "3196:9:2", + "referencedDeclaration": 317, + "src": "3196:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2754,12 +2754,12 @@ }, { "argumentTypes": null, - "id": 279, + "id": 355, "name": "token_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 265, - "src": "3207:12:2", + "referencedDeclaration": 341, + "src": "3207:12:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2781,18 +2781,18 @@ "typeString": "uint256" } ], - "id": 275, + "id": 351, "name": "ethToToken", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 100, - "src": "3173:10:2", + "referencedDeclaration": 176, + "src": "3173:10:3", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256)" } }, - "id": 280, + "id": 356, "isConstant": false, "isLValue": false, "isPure": false, @@ -2800,36 +2800,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3173:47:2", + "src": "3173:47:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 281, + "id": 357, "nodeType": "EmitStatement", - "src": "3168:52:2" + "src": "3168:52:3" } ] }, "documentation": null, - "id": 283, + "id": 359, "implemented": true, "kind": "function", "modifiers": [], "name": "tradeEthToToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 242, + "id": 318, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 235, + "id": 311, "name": "kyberExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 283, - "src": "2679:28:2", + "scope": 359, + "src": "2679:28:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2837,10 +2837,10 @@ "typeString": "address" }, "typeName": { - "id": 234, + "id": 310, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2679:7:2", + "src": "2679:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2852,11 +2852,11 @@ }, { "constant": false, - "id": 237, + "id": 313, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 283, - "src": "2713:20:2", + "scope": 359, + "src": "2713:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2864,10 +2864,10 @@ "typeString": "address" }, "typeName": { - "id": 236, + "id": 312, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2713:7:2", + "src": "2713:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2879,11 +2879,11 @@ }, { "constant": false, - "id": 239, + "id": 315, "name": "kyberMinConversionRate", "nodeType": "VariableDeclaration", - "scope": 283, - "src": "2739:30:2", + "scope": 359, + "src": "2739:30:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2891,10 +2891,10 @@ "typeString": "uint256" }, "typeName": { - "id": 238, + "id": 314, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2739:7:2", + "src": "2739:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2905,11 +2905,11 @@ }, { "constant": false, - "id": 241, + "id": 317, "name": "ethToSell", "nodeType": "VariableDeclaration", - "scope": 283, - "src": "2775:17:2", + "scope": 359, + "src": "2775:17:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2917,10 +2917,10 @@ "typeString": "uint256" }, "typeName": { - "id": 240, + "id": 316, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2775:7:2", + "src": "2775:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2930,53 +2930,53 @@ "visibility": "internal" } ], - "src": "2673:120:2" + "src": "2673:120:3" }, "returnParameters": { - "id": 243, + "id": 319, "nodeType": "ParameterList", "parameters": [], - "src": "2813:0:2" + "src": "2813:0:3" }, - "scope": 332, - "src": "2649:576:2", + "scope": 408, + "src": "2649:576:3", "stateMutability": "payable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 319, + "id": 395, "nodeType": "Block", - "src": "3377:335:2", + "src": "3377:335:3", "statements": [ { "assignments": [ - 295 + 371 ], "declarations": [ { "constant": false, - "id": 295, + "id": 371, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 319, - "src": "3438:31:2", + "scope": 395, + "src": "3438:31:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 294, + "id": 370, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "3438:15:2", + "referencedDeclaration": 920, + "src": "3438:15:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -2984,18 +2984,18 @@ "visibility": "internal" } ], - "id": 299, + "id": 375, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 297, + "id": 373, "name": "uniSwapExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 285, - "src": "3488:22:2", + "referencedDeclaration": 361, + "src": "3488:22:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3009,18 +3009,18 @@ "typeString": "address" } ], - "id": 296, + "id": 372, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "3472:15:2", + "referencedDeclaration": 920, + "src": "3472:15:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 298, + "id": 374, "isConstant": false, "isLValue": false, "isPure": false, @@ -3028,27 +3028,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3472:39:2", + "src": "3472:39:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "3438:73:2" + "src": "3438:73:3" }, { "assignments": [ - 301 + 377 ], "declarations": [ { "constant": false, - "id": 301, + "id": 377, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 319, - "src": "3520:19:2", + "scope": 395, + "src": "3520:19:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3056,10 +3056,10 @@ "typeString": "uint256" }, "typeName": { - "id": 300, + "id": 376, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3520:7:2", + "src": "3520:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3069,18 +3069,18 @@ "visibility": "internal" } ], - "id": 310, + "id": 386, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 304, + "id": 380, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 291, - "src": "3583:8:2", + "referencedDeclaration": 367, + "src": "3583:8:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3088,12 +3088,12 @@ }, { "argumentTypes": null, - "id": 305, + "id": 381, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 287, - "src": "3593:13:2", + "referencedDeclaration": 363, + "src": "3593:13:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3101,12 +3101,12 @@ }, { "argumentTypes": null, - "id": 306, + "id": 382, "name": "sellDeadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 289, - "src": "3608:12:2", + "referencedDeclaration": 365, + "src": "3608:12:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3116,18 +3116,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 307, + "id": 383, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3622:3:2", + "referencedDeclaration": 12128, + "src": "3622:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 308, + "id": 384, "isConstant": false, "isLValue": false, "isPure": false, @@ -3135,7 +3135,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "3622:10:2", + "src": "3622:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -3163,32 +3163,32 @@ ], "expression": { "argumentTypes": null, - "id": 302, + "id": 378, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 295, - "src": "3542:15:2", + "referencedDeclaration": 371, + "src": "3542:15:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 303, + "id": 379, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "tokenToEthTransferOutput", "nodeType": "MemberAccess", - "referencedDeclaration": 839, - "src": "3542:40:2", + "referencedDeclaration": 915, + "src": "3542:40:3", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_payable_$returns$_t_uint256_$", "typeString": "function (uint256,uint256,uint256,address payable) external returns (uint256)" } }, - "id": 309, + "id": 385, "isConstant": false, "isLValue": false, "isPure": false, @@ -3196,14 +3196,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3542:91:2", + "src": "3542:91:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "3520:113:2" + "src": "3520:113:3" }, { "eventCall": { @@ -3213,18 +3213,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 312, + "id": 388, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3658:3:2", + "referencedDeclaration": 12128, + "src": "3658:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 313, + "id": 389, "isConstant": false, "isLValue": false, "isPure": false, @@ -3232,7 +3232,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "3658:10:2", + "src": "3658:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -3240,12 +3240,12 @@ }, { "argumentTypes": null, - "id": 314, + "id": 390, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 291, - "src": "3670:8:2", + "referencedDeclaration": 367, + "src": "3670:8:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3253,12 +3253,12 @@ }, { "argumentTypes": null, - "id": 315, + "id": 391, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 287, - "src": "3680:13:2", + "referencedDeclaration": 363, + "src": "3680:13:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3266,12 +3266,12 @@ }, { "argumentTypes": null, - "id": 316, + "id": 392, "name": "tokens_sold", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 301, - "src": "3695:11:2", + "referencedDeclaration": 377, + "src": "3695:11:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3297,18 +3297,18 @@ "typeString": "uint256" } ], - "id": 311, + "id": 387, "name": "tokenToEth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 110, - "src": "3647:10:2", + "referencedDeclaration": 186, + "src": "3647:10:3", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 317, + "id": 393, "isConstant": false, "isLValue": false, "isPure": false, @@ -3316,36 +3316,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3647:60:2", + "src": "3647:60:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 318, + "id": 394, "nodeType": "EmitStatement", - "src": "3642:65:2" + "src": "3642:65:3" } ] }, "documentation": null, - "id": 320, + "id": 396, "implemented": true, "kind": "function", "modifiers": [], "name": "tradeTokenToEth", "nodeType": "FunctionDefinition", "parameters": { - "id": 292, + "id": 368, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 285, + "id": 361, "name": "uniSwapExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 320, - "src": "3259:30:2", + "scope": 396, + "src": "3259:30:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3353,10 +3353,10 @@ "typeString": "address" }, "typeName": { - "id": 284, + "id": 360, "name": "address", "nodeType": "ElementaryTypeName", - "src": "3259:7:2", + "src": "3259:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3368,11 +3368,11 @@ }, { "constant": false, - "id": 287, + "id": 363, "name": "maxTokensSell", "nodeType": "VariableDeclaration", - "scope": 320, - "src": "3295:21:2", + "scope": 396, + "src": "3295:21:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3380,10 +3380,10 @@ "typeString": "uint256" }, "typeName": { - "id": 286, + "id": 362, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3295:7:2", + "src": "3295:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3394,11 +3394,11 @@ }, { "constant": false, - "id": 289, + "id": 365, "name": "sellDeadline", "nodeType": "VariableDeclaration", - "scope": 320, - "src": "3322:20:2", + "scope": 396, + "src": "3322:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3406,10 +3406,10 @@ "typeString": "uint256" }, "typeName": { - "id": 288, + "id": 364, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3322:7:2", + "src": "3322:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3420,11 +3420,11 @@ }, { "constant": false, - "id": 291, + "id": 367, "name": "ethToBuy", "nodeType": "VariableDeclaration", - "scope": 320, - "src": "3348:16:2", + "scope": 396, + "src": "3348:16:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3432,10 +3432,10 @@ "typeString": "uint256" }, "typeName": { - "id": 290, + "id": 366, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3348:7:2", + "src": "3348:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3445,25 +3445,25 @@ "visibility": "internal" } ], - "src": "3253:112:2" + "src": "3253:112:3" }, "returnParameters": { - "id": 293, + "id": 369, "nodeType": "ParameterList", "parameters": [], - "src": "3377:0:2" + "src": "3377:0:3" }, - "scope": 332, - "src": "3229:483:2", + "scope": 408, + "src": "3229:483:3", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 330, + "id": 406, "nodeType": "Block", - "src": "3768:39:2", + "src": "3768:39:3", "statements": [ { "expression": { @@ -3473,14 +3473,14 @@ "arguments": [ { "argumentTypes": null, - "id": 326, + "id": 402, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1484, - "src": "3789:4:2", + "referencedDeclaration": 12186, + "src": "3789:4:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberTestContract_$332", + "typeIdentifier": "t_contract$_KyberTestContract_$408", "typeString": "contract KyberTestContract" } } @@ -3488,24 +3488,24 @@ "expression": { "argumentTypes": [ { - "typeIdentifier": "t_contract$_KyberTestContract_$332", + "typeIdentifier": "t_contract$_KyberTestContract_$408", "typeString": "contract KyberTestContract" } ], - "id": 325, + "id": 401, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "3781:7:2", + "src": "3781:7:3", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 327, + "id": 403, "isConstant": false, "isLValue": false, "isPure": false, @@ -3513,13 +3513,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3781:13:2", + "src": "3781:13:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 328, + "id": 404, "isConstant": false, "isLValue": false, "isPure": false, @@ -3527,43 +3527,43 @@ "memberName": "balance", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "3781:21:2", + "src": "3781:21:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 324, - "id": 329, + "functionReturnParameters": 400, + "id": 405, "nodeType": "Return", - "src": "3774:28:2" + "src": "3774:28:3" } ] }, "documentation": null, - "id": 331, + "id": 407, "implemented": true, "kind": "function", "modifiers": [], "name": "getBalance", "nodeType": "FunctionDefinition", "parameters": { - "id": 321, + "id": 397, "nodeType": "ParameterList", "parameters": [], - "src": "3735:2:2" + "src": "3735:2:3" }, "returnParameters": { - "id": 324, + "id": 400, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 323, + "id": 399, "name": "", "nodeType": "VariableDeclaration", - "scope": 331, - "src": "3759:7:2", + "scope": 407, + "src": "3759:7:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3571,10 +3571,10 @@ "typeString": "uint256" }, "typeName": { - "id": 322, + "id": 398, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3759:7:2", + "src": "3759:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3584,33 +3584,33 @@ "visibility": "internal" } ], - "src": "3758:9:2" + "src": "3758:9:3" }, - "scope": 332, - "src": "3716:91:2", + "scope": 408, + "src": "3716:91:3", "stateMutability": "view", "superFunction": null, "visibility": "public" } ], - "scope": 333, - "src": "148:3661:2" + "scope": 409, + "src": "148:3661:3" } ], - "src": "0:3810:2" + "src": "0:3810:3" }, "legacyAST": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/KyberTestContract.sol", "exportedSymbols": { "KyberTestContract": [ - 332 + 408 ] }, - "id": 333, + "id": 409, "nodeType": "SourceUnit", "nodes": [ { - "id": 87, + "id": 163, "literals": [ "solidity", "^", @@ -3618,38 +3618,38 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:2" + "src": "0:23:3" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol", "file": "./UniswapExchange.sol", - "id": 88, + "id": 164, "nodeType": "ImportDirective", - "scope": 333, - "sourceUnit": 845, - "src": "25:31:2", + "scope": 409, + "sourceUnit": 921, + "src": "25:31:3", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "@openzeppelin/contracts/token/ERC20/ERC20.sol", "file": "@openzeppelin/contracts/token/ERC20/ERC20.sol", - "id": 89, + "id": 165, "nodeType": "ImportDirective", - "scope": 333, - "sourceUnit": 1375, - "src": "57:55:2", + "scope": 409, + "sourceUnit": 10858, + "src": "57:55:3", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/KyberNetworkProxy.sol", "file": "./KyberNetworkProxy.sol", - "id": 90, + "id": 166, "nodeType": "ImportDirective", - "scope": 333, - "sourceUnit": 86, - "src": "113:33:2", + "scope": 409, + "sourceUnit": 162, + "src": "113:33:3", "symbolAliases": [], "unitAlias": "" }, @@ -3659,20 +3659,20 @@ "contractKind": "contract", "documentation": null, "fullyImplemented": true, - "id": 332, + "id": 408, "linearizedBaseContracts": [ - 332 + 408 ], "name": "KyberTestContract", "nodeType": "ContractDefinition", "nodes": [ { "constant": false, - "id": 92, + "id": 168, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 332, - "src": "235:20:2", + "scope": 408, + "src": "235:20:3", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -3680,10 +3680,10 @@ "typeString": "address" }, "typeName": { - "id": 91, + "id": 167, "name": "address", "nodeType": "ElementaryTypeName", - "src": "235:7:2", + "src": "235:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3696,21 +3696,21 @@ { "anonymous": false, "documentation": null, - "id": 100, + "id": 176, "name": "ethToToken", "nodeType": "EventDefinition", "parameters": { - "id": 99, + "id": 175, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 94, + "id": 170, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 100, - "src": "289:14:2", + "scope": 176, + "src": "289:14:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3718,10 +3718,10 @@ "typeString": "address" }, "typeName": { - "id": 93, + "id": 169, "name": "address", "nodeType": "ElementaryTypeName", - "src": "289:7:2", + "src": "289:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3733,12 +3733,12 @@ }, { "constant": false, - "id": 96, + "id": 172, "indexed": false, "name": "tokens", "nodeType": "VariableDeclaration", - "scope": 100, - "src": "305:14:2", + "scope": 176, + "src": "305:14:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3746,10 +3746,10 @@ "typeString": "uint256" }, "typeName": { - "id": 95, + "id": 171, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "305:7:2", + "src": "305:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3760,12 +3760,12 @@ }, { "constant": false, - "id": 98, + "id": 174, "indexed": false, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 100, - "src": "321:20:2", + "scope": 176, + "src": "321:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3773,10 +3773,10 @@ "typeString": "uint256" }, "typeName": { - "id": 97, + "id": 173, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "321:7:2", + "src": "321:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3786,28 +3786,28 @@ "visibility": "internal" } ], - "src": "288:54:2" + "src": "288:54:3" }, - "src": "272:71:2" + "src": "272:71:3" }, { "anonymous": false, "documentation": null, - "id": 110, + "id": 186, "name": "tokenToEth", "nodeType": "EventDefinition", "parameters": { - "id": 109, + "id": 185, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 102, + "id": 178, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 110, - "src": "363:14:2", + "scope": 186, + "src": "363:14:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3815,10 +3815,10 @@ "typeString": "address" }, "typeName": { - "id": 101, + "id": 177, "name": "address", "nodeType": "ElementaryTypeName", - "src": "363:7:2", + "src": "363:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3830,12 +3830,12 @@ }, { "constant": false, - "id": 104, + "id": 180, "indexed": false, "name": "ethToBuy", "nodeType": "VariableDeclaration", - "scope": 110, - "src": "379:16:2", + "scope": 186, + "src": "379:16:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3843,10 +3843,10 @@ "typeString": "uint256" }, "typeName": { - "id": 103, + "id": 179, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "379:7:2", + "src": "379:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3857,12 +3857,12 @@ }, { "constant": false, - "id": 106, + "id": 182, "indexed": false, "name": "maxTokensSell", "nodeType": "VariableDeclaration", - "scope": 110, - "src": "397:21:2", + "scope": 186, + "src": "397:21:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3870,10 +3870,10 @@ "typeString": "uint256" }, "typeName": { - "id": 105, + "id": 181, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "397:7:2", + "src": "397:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3884,12 +3884,12 @@ }, { "constant": false, - "id": 108, + "id": 184, "indexed": false, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 110, - "src": "420:19:2", + "scope": 186, + "src": "420:19:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3897,10 +3897,10 @@ "typeString": "uint256" }, "typeName": { - "id": 107, + "id": 183, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "420:7:2", + "src": "420:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3910,32 +3910,32 @@ "visibility": "internal" } ], - "src": "362:78:2" + "src": "362:78:3" }, - "src": "346:95:2" + "src": "346:95:3" }, { "body": { - "id": 118, + "id": 194, "nodeType": "Block", - "src": "545:29:2", + "src": "545:29:3", "statements": [ { "expression": { "argumentTypes": null, - "id": 116, + "id": 192, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 113, + "id": 189, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 92, - "src": "551:5:2", + "referencedDeclaration": 168, + "src": "551:5:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3947,18 +3947,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 114, + "id": 190, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "559:3:2", + "referencedDeclaration": 12128, + "src": "559:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 115, + "id": 191, "isConstant": false, "isLValue": false, "isPure": false, @@ -3966,54 +3966,54 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "559:10:2", + "src": "559:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "551:18:2", + "src": "551:18:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 117, + "id": 193, "nodeType": "ExpressionStatement", - "src": "551:18:2" + "src": "551:18:3" } ] }, "documentation": "@dev Contract constructor. Set owner of contract as deployer.", - "id": 119, + "id": 195, "implemented": true, "kind": "constructor", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "parameters": { - "id": 111, + "id": 187, "nodeType": "ParameterList", "parameters": [], - "src": "535:2:2" + "src": "535:2:3" }, "returnParameters": { - "id": 112, + "id": 188, "nodeType": "ParameterList", "parameters": [], - "src": "545:0:2" + "src": "545:0:3" }, - "scope": 332, - "src": "524:50:2", + "scope": 408, + "src": "524:50:3", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 149, + "id": 225, "nodeType": "Block", - "src": "902:148:2", + "src": "902:148:3", "statements": [ { "expression": { @@ -4025,7 +4025,7 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 132, + "id": 208, "isConstant": false, "isLValue": false, "isPure": false, @@ -4034,18 +4034,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 129, + "id": 205, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "916:3:2", + "referencedDeclaration": 12128, + "src": "916:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 130, + "id": 206, "isConstant": false, "isLValue": false, "isPure": false, @@ -4053,7 +4053,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "916:10:2", + "src": "916:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -4063,18 +4063,18 @@ "operator": "==", "rightExpression": { "argumentTypes": null, - "id": 131, + "id": 207, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 92, - "src": "930:5:2", + "referencedDeclaration": 168, + "src": "930:5:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "src": "916:19:2", + "src": "916:19:3", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -4083,14 +4083,14 @@ { "argumentTypes": null, "hexValue": "4f6e6c79204f776e65722043616e20417070726f7665", - "id": 133, + "id": 209, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "937:24:2", + "src": "937:24:3", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_ec0b1a840a8a6c4384575556c3817abb58aac6b2bc4e7741e1c712be8067937e", @@ -4110,21 +4110,21 @@ "typeString": "literal_string \"Only Owner Can Approve\"" } ], - "id": 128, + "id": 204, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "908:7:2", + "referencedDeclaration": 12132, + "src": "908:7:3", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 134, + "id": 210, "isConstant": false, "isLValue": false, "isPure": false, @@ -4132,43 +4132,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "908:54:2", + "src": "908:54:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 135, + "id": 211, "nodeType": "ExpressionStatement", - "src": "908:54:2" + "src": "908:54:3" }, { "assignments": [ - 137 + 213 ], "declarations": [ { "constant": false, - "id": 137, + "id": 213, "name": "token", "nodeType": "VariableDeclaration", - "scope": 149, - "src": "968:11:2", + "scope": 225, + "src": "968:11:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 136, + "id": 212, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "968:5:2", + "referencedDeclaration": 10857, + "src": "968:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -4176,18 +4176,18 @@ "visibility": "internal" } ], - "id": 141, + "id": 217, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 139, + "id": 215, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 121, - "src": "988:12:2", + "referencedDeclaration": 197, + "src": "988:12:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4201,18 +4201,18 @@ "typeString": "address" } ], - "id": 138, + "id": 214, "name": "ERC20", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1374, - "src": "982:5:2", + "referencedDeclaration": 10857, + "src": "982:5:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_ERC20_$1374_$", + "typeIdentifier": "t_type$_t_contract$_ERC20_$10857_$", "typeString": "type(contract ERC20)" } }, - "id": 140, + "id": 216, "isConstant": false, "isLValue": false, "isPure": false, @@ -4220,14 +4220,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "982:19:2", + "src": "982:19:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, "nodeType": "VariableDeclarationStatement", - "src": "968:33:2" + "src": "968:33:3" }, { "expression": { @@ -4235,12 +4235,12 @@ "arguments": [ { "argumentTypes": null, - "id": 145, + "id": 221, "name": "exchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 123, - "src": "1021:15:2", + "referencedDeclaration": 199, + "src": "1021:15:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4248,12 +4248,12 @@ }, { "argumentTypes": null, - "id": 146, + "id": 222, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 125, - "src": "1038:6:2", + "referencedDeclaration": 201, + "src": "1038:6:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4273,32 +4273,32 @@ ], "expression": { "argumentTypes": null, - "id": 142, + "id": 218, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 137, - "src": "1007:5:2", + "referencedDeclaration": 213, + "src": "1007:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, - "id": 144, + "id": 220, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "approve", "nodeType": "MemberAccess", - "referencedDeclaration": 1072, - "src": "1007:13:2", + "referencedDeclaration": 10555, + "src": "1007:13:3", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,uint256) external returns (bool)" } }, - "id": 147, + "id": 223, "isConstant": false, "isLValue": false, "isPure": false, @@ -4306,36 +4306,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1007:38:2", + "src": "1007:38:3", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, - "id": 148, + "id": 224, "nodeType": "ExpressionStatement", - "src": "1007:38:2" + "src": "1007:38:3" } ] }, "documentation": "@dev Approves UniSwap exchange to transfer tokens from contract.\n@param tokenAddress Address of the token to approve\n@param exchangeAddress UniSwap Exchange address\n@param amount Token amount to approve", - "id": 150, + "id": 226, "implemented": true, "kind": "function", "modifiers": [], "name": "approveToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 126, + "id": 202, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 121, + "id": 197, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 150, - "src": "835:20:2", + "scope": 226, + "src": "835:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4343,10 +4343,10 @@ "typeString": "address" }, "typeName": { - "id": 120, + "id": 196, "name": "address", "nodeType": "ElementaryTypeName", - "src": "835:7:2", + "src": "835:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -4358,11 +4358,11 @@ }, { "constant": false, - "id": 123, + "id": 199, "name": "exchangeAddress", "nodeType": "VariableDeclaration", - "scope": 150, - "src": "857:23:2", + "scope": 226, + "src": "857:23:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4370,10 +4370,10 @@ "typeString": "address" }, "typeName": { - "id": 122, + "id": 198, "name": "address", "nodeType": "ElementaryTypeName", - "src": "857:7:2", + "src": "857:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -4385,11 +4385,11 @@ }, { "constant": false, - "id": 125, + "id": 201, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 150, - "src": "882:11:2", + "scope": 226, + "src": "882:11:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4397,10 +4397,10 @@ "typeString": "uint256" }, "typeName": { - "id": 124, + "id": 200, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "882:4:2", + "src": "882:4:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4410,25 +4410,25 @@ "visibility": "internal" } ], - "src": "834:60:2" + "src": "834:60:3" }, "returnParameters": { - "id": 127, + "id": 203, "nodeType": "ParameterList", "parameters": [], - "src": "902:0:2" + "src": "902:0:3" }, - "scope": 332, - "src": "813:237:2", + "scope": 408, + "src": "813:237:3", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 232, + "id": 308, "nodeType": "Block", - "src": "1891:754:2", + "src": "1891:754:3", "statements": [ { "expression": { @@ -4440,7 +4440,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 173, + "id": 249, "isConstant": false, "isLValue": false, "isPure": false, @@ -4449,18 +4449,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 170, + "id": 246, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1905:3:2", + "referencedDeclaration": 12128, + "src": "1905:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 171, + "id": 247, "isConstant": false, "isLValue": false, "isPure": false, @@ -4468,7 +4468,7 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1905:9:2", + "src": "1905:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4478,18 +4478,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 172, + "id": 248, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 160, - "src": "1918:9:2", + "referencedDeclaration": 236, + "src": "1918:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "1905:22:2", + "src": "1905:22:3", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -4498,14 +4498,14 @@ { "argumentTypes": null, "hexValue": "4e6f7420456e6f756768204574682053656e74", - "id": 174, + "id": 250, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "1929:21:2", + "src": "1929:21:3", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30b29beae4cdbb7acc80a8e1229a071d1d9114e20038f0c713ecf8dbdd0dcc4e", @@ -4525,21 +4525,21 @@ "typeString": "literal_string \"Not Enough Eth Sent\"" } ], - "id": 169, + "id": 245, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "1897:7:2", + "referencedDeclaration": 12132, + "src": "1897:7:3", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 175, + "id": 251, "isConstant": false, "isLValue": false, "isPure": false, @@ -4547,43 +4547,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1897:54:2", + "src": "1897:54:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 176, + "id": 252, "nodeType": "ExpressionStatement", - "src": "1897:54:2" + "src": "1897:54:3" }, { "assignments": [ - 178 + 254 ], "declarations": [ { "constant": false, - "id": 178, + "id": 254, "name": "kyberExchange", "nodeType": "VariableDeclaration", - "scope": 232, - "src": "1980:31:2", + "scope": 308, + "src": "1980:31:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" }, "typeName": { "contractScope": null, - "id": 177, + "id": 253, "name": "KyberNetworkProxy", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 85, - "src": "1980:17:2", + "referencedDeclaration": 161, + "src": "1980:17:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, @@ -4591,18 +4591,18 @@ "visibility": "internal" } ], - "id": 182, + "id": 258, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 180, + "id": 256, "name": "kyberExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 152, - "src": "2032:20:2", + "referencedDeclaration": 228, + "src": "2032:20:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4616,18 +4616,18 @@ "typeString": "address" } ], - "id": 179, + "id": 255, "name": "KyberNetworkProxy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 85, - "src": "2014:17:2", + "referencedDeclaration": 161, + "src": "2014:17:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$85_$", + "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$161_$", "typeString": "type(contract KyberNetworkProxy)" } }, - "id": 181, + "id": 257, "isConstant": false, "isLValue": false, "isPure": false, @@ -4635,42 +4635,42 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2014:39:2", + "src": "2014:39:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, "nodeType": "VariableDeclarationStatement", - "src": "1980:73:2" + "src": "1980:73:3" }, { "assignments": [ - 184 + 260 ], "declarations": [ { "constant": false, - "id": 184, + "id": 260, "name": "token", "nodeType": "VariableDeclaration", - "scope": 232, - "src": "2059:11:2", + "scope": 308, + "src": "2059:11:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 183, + "id": 259, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "2059:5:2", + "referencedDeclaration": 10857, + "src": "2059:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -4678,18 +4678,18 @@ "visibility": "internal" } ], - "id": 188, + "id": 264, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 186, + "id": 262, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 154, - "src": "2079:12:2", + "referencedDeclaration": 230, + "src": "2079:12:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4703,18 +4703,18 @@ "typeString": "address" } ], - "id": 185, + "id": 261, "name": "ERC20", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1374, - "src": "2073:5:2", + "referencedDeclaration": 10857, + "src": "2073:5:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_ERC20_$1374_$", + "typeIdentifier": "t_type$_t_contract$_ERC20_$10857_$", "typeString": "type(contract ERC20)" } }, - "id": 187, + "id": 263, "isConstant": false, "isLValue": false, "isPure": false, @@ -4722,27 +4722,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2073:19:2", + "src": "2073:19:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, "nodeType": "VariableDeclarationStatement", - "src": "2059:33:2" + "src": "2059:33:3" }, { "assignments": [ - 190 + 266 ], "declarations": [ { "constant": false, - "id": 190, + "id": 266, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 232, - "src": "2145:20:2", + "scope": 308, + "src": "2145:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4750,10 +4750,10 @@ "typeString": "uint256" }, "typeName": { - "id": 189, + "id": 265, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2145:7:2", + "src": "2145:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4763,31 +4763,31 @@ "visibility": "internal" } ], - "id": 199, + "id": 275, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 196, + "id": 272, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 184, - "src": "2216:5:2", + "referencedDeclaration": 260, + "src": "2216:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, { "argumentTypes": null, - "id": 197, + "id": 273, "name": "kyberMinConversionRate", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 156, - "src": "2223:22:2", + "referencedDeclaration": 232, + "src": "2223:22:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4797,7 +4797,7 @@ "expression": { "argumentTypes": [ { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, { @@ -4808,12 +4808,12 @@ "arguments": [ { "argumentTypes": null, - "id": 194, + "id": 270, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 160, - "src": "2205:9:2", + "referencedDeclaration": 236, + "src": "2205:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4831,32 +4831,32 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 191, + "id": 267, "name": "kyberExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 178, - "src": "2168:13:2", + "referencedDeclaration": 254, + "src": "2168:13:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, - "id": 192, + "id": 268, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "swapEtherToToken", "nodeType": "MemberAccess", - "referencedDeclaration": 84, - "src": "2168:30:2", + "referencedDeclaration": 160, + "src": "2168:30:3", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 193, + "id": 269, "isConstant": false, "isLValue": false, "isPure": false, @@ -4864,13 +4864,13 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2168:36:2", + "src": "2168:36:3", "typeDescriptions": { - "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value_$", + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value_$", "typeString": "function (uint256) returns (function (contract ERC20,uint256) payable external returns (uint256))" } }, - "id": 195, + "id": 271, "isConstant": false, "isLValue": false, "isPure": false, @@ -4878,13 +4878,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2168:47:2", + "src": "2168:47:3", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 198, + "id": 274, "isConstant": false, "isLValue": false, "isPure": false, @@ -4892,14 +4892,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2168:78:2", + "src": "2168:78:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2145:101:2" + "src": "2145:101:3" }, { "eventCall": { @@ -4909,18 +4909,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 201, + "id": 277, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2268:3:2", + "referencedDeclaration": 12128, + "src": "2268:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 202, + "id": 278, "isConstant": false, "isLValue": false, "isPure": false, @@ -4928,7 +4928,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2268:10:2", + "src": "2268:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -4936,12 +4936,12 @@ }, { "argumentTypes": null, - "id": 203, + "id": 279, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 160, - "src": "2280:9:2", + "referencedDeclaration": 236, + "src": "2280:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4949,12 +4949,12 @@ }, { "argumentTypes": null, - "id": 204, + "id": 280, "name": "token_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 190, - "src": "2291:12:2", + "referencedDeclaration": 266, + "src": "2291:12:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4976,18 +4976,18 @@ "typeString": "uint256" } ], - "id": 200, + "id": 276, "name": "ethToToken", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 100, - "src": "2257:10:2", + "referencedDeclaration": 176, + "src": "2257:10:3", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256)" } }, - "id": 205, + "id": 281, "isConstant": false, "isLValue": false, "isPure": false, @@ -4995,43 +4995,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2257:47:2", + "src": "2257:47:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 206, + "id": 282, "nodeType": "EmitStatement", - "src": "2252:52:2" + "src": "2252:52:3" }, { "assignments": [ - 208 + 284 ], "declarations": [ { "constant": false, - "id": 208, + "id": 284, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 232, - "src": "2377:31:2", + "scope": 308, + "src": "2377:31:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 207, + "id": 283, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "2377:15:2", + "referencedDeclaration": 920, + "src": "2377:15:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -5039,18 +5039,18 @@ "visibility": "internal" } ], - "id": 212, + "id": 288, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 210, + "id": 286, "name": "uniSwapExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 158, - "src": "2427:22:2", + "referencedDeclaration": 234, + "src": "2427:22:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5064,18 +5064,18 @@ "typeString": "address" } ], - "id": 209, + "id": 285, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "2411:15:2", + "referencedDeclaration": 920, + "src": "2411:15:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 211, + "id": 287, "isConstant": false, "isLValue": false, "isPure": false, @@ -5083,27 +5083,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2411:39:2", + "src": "2411:39:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "2377:73:2" + "src": "2377:73:3" }, { "assignments": [ - 214 + 290 ], "declarations": [ { "constant": false, - "id": 214, + "id": 290, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 232, - "src": "2456:19:2", + "scope": 308, + "src": "2456:19:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5111,10 +5111,10 @@ "typeString": "uint256" }, "typeName": { - "id": 213, + "id": 289, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2456:7:2", + "src": "2456:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5124,18 +5124,18 @@ "visibility": "internal" } ], - "id": 223, + "id": 299, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 217, + "id": 293, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 166, - "src": "2519:8:2", + "referencedDeclaration": 242, + "src": "2519:8:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5143,12 +5143,12 @@ }, { "argumentTypes": null, - "id": 218, + "id": 294, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 162, - "src": "2529:13:2", + "referencedDeclaration": 238, + "src": "2529:13:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5156,12 +5156,12 @@ }, { "argumentTypes": null, - "id": 219, + "id": 295, "name": "sellDeadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 164, - "src": "2544:12:2", + "referencedDeclaration": 240, + "src": "2544:12:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5171,18 +5171,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 220, + "id": 296, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2558:3:2", + "referencedDeclaration": 12128, + "src": "2558:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 221, + "id": 297, "isConstant": false, "isLValue": false, "isPure": false, @@ -5190,7 +5190,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2558:10:2", + "src": "2558:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -5218,32 +5218,32 @@ ], "expression": { "argumentTypes": null, - "id": 215, + "id": 291, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 208, - "src": "2478:15:2", + "referencedDeclaration": 284, + "src": "2478:15:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 216, + "id": 292, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "tokenToEthTransferOutput", "nodeType": "MemberAccess", - "referencedDeclaration": 839, - "src": "2478:40:2", + "referencedDeclaration": 915, + "src": "2478:40:3", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_payable_$returns$_t_uint256_$", "typeString": "function (uint256,uint256,uint256,address payable) external returns (uint256)" } }, - "id": 222, + "id": 298, "isConstant": false, "isLValue": false, "isPure": false, @@ -5251,14 +5251,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2478:91:2", + "src": "2478:91:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2456:113:2" + "src": "2456:113:3" }, { "eventCall": { @@ -5268,18 +5268,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 225, + "id": 301, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2591:3:2", + "referencedDeclaration": 12128, + "src": "2591:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 226, + "id": 302, "isConstant": false, "isLValue": false, "isPure": false, @@ -5287,7 +5287,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2591:10:2", + "src": "2591:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -5295,12 +5295,12 @@ }, { "argumentTypes": null, - "id": 227, + "id": 303, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 166, - "src": "2603:8:2", + "referencedDeclaration": 242, + "src": "2603:8:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5308,12 +5308,12 @@ }, { "argumentTypes": null, - "id": 228, + "id": 304, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 162, - "src": "2613:13:2", + "referencedDeclaration": 238, + "src": "2613:13:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5321,12 +5321,12 @@ }, { "argumentTypes": null, - "id": 229, + "id": 305, "name": "tokens_sold", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 214, - "src": "2628:11:2", + "referencedDeclaration": 290, + "src": "2628:11:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5352,18 +5352,18 @@ "typeString": "uint256" } ], - "id": 224, + "id": 300, "name": "tokenToEth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 110, - "src": "2580:10:2", + "referencedDeclaration": 186, + "src": "2580:10:3", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 230, + "id": 306, "isConstant": false, "isLValue": false, "isPure": false, @@ -5371,36 +5371,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2580:60:2", + "src": "2580:60:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 231, + "id": 307, "nodeType": "EmitStatement", - "src": "2575:65:2" + "src": "2575:65:3" } ] }, "documentation": "@dev Executes trade.\n@param kyberExchangeAddress Kyber network address\n@param tokenAddress Address of the token that is being traded\n@param kyberMinConversionRate Min conversion rate for Kyber\n@param uniSwapExchangeAddress UniSwap exchange address\n@param ethToSell Amount of Eth that is being traded via Kyber. Should be sent as value too.\n@param maxTokensSell Maximum ERC20 tokens sold in Uniswap trade.\n@param sellDeadline Uniswap transaction deadline.\n@param ethToBuy Amount of Eth bought in Uniswap trade.", - "id": 233, + "id": 309, "implemented": true, "kind": "function", "modifiers": [], "name": "trade", "nodeType": "FunctionDefinition", "parameters": { - "id": 167, + "id": 243, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 152, + "id": 228, "name": "kyberExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1641:28:2", + "scope": 309, + "src": "1641:28:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5408,10 +5408,10 @@ "typeString": "address" }, "typeName": { - "id": 151, + "id": 227, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1641:7:2", + "src": "1641:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -5423,11 +5423,11 @@ }, { "constant": false, - "id": 154, + "id": 230, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1675:20:2", + "scope": 309, + "src": "1675:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5435,10 +5435,10 @@ "typeString": "address" }, "typeName": { - "id": 153, + "id": 229, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1675:7:2", + "src": "1675:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -5450,11 +5450,11 @@ }, { "constant": false, - "id": 156, + "id": 232, "name": "kyberMinConversionRate", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1701:30:2", + "scope": 309, + "src": "1701:30:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5462,10 +5462,10 @@ "typeString": "uint256" }, "typeName": { - "id": 155, + "id": 231, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1701:7:2", + "src": "1701:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5476,11 +5476,11 @@ }, { "constant": false, - "id": 158, + "id": 234, "name": "uniSwapExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1737:30:2", + "scope": 309, + "src": "1737:30:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5488,10 +5488,10 @@ "typeString": "address" }, "typeName": { - "id": 157, + "id": 233, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1737:7:2", + "src": "1737:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -5503,11 +5503,11 @@ }, { "constant": false, - "id": 160, + "id": 236, "name": "ethToSell", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1773:17:2", + "scope": 309, + "src": "1773:17:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5515,10 +5515,10 @@ "typeString": "uint256" }, "typeName": { - "id": 159, + "id": 235, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1773:7:2", + "src": "1773:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5529,11 +5529,11 @@ }, { "constant": false, - "id": 162, + "id": 238, "name": "maxTokensSell", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1796:21:2", + "scope": 309, + "src": "1796:21:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5541,10 +5541,10 @@ "typeString": "uint256" }, "typeName": { - "id": 161, + "id": 237, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1796:7:2", + "src": "1796:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5555,11 +5555,11 @@ }, { "constant": false, - "id": 164, + "id": 240, "name": "sellDeadline", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1823:20:2", + "scope": 309, + "src": "1823:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5567,10 +5567,10 @@ "typeString": "uint256" }, "typeName": { - "id": 163, + "id": 239, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1823:7:2", + "src": "1823:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5581,11 +5581,11 @@ }, { "constant": false, - "id": 166, + "id": 242, "name": "ethToBuy", "nodeType": "VariableDeclaration", - "scope": 233, - "src": "1849:16:2", + "scope": 309, + "src": "1849:16:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5593,10 +5593,10 @@ "typeString": "uint256" }, "typeName": { - "id": 165, + "id": 241, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1849:7:2", + "src": "1849:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5606,25 +5606,25 @@ "visibility": "internal" } ], - "src": "1635:234:2" + "src": "1635:234:3" }, "returnParameters": { - "id": 168, + "id": 244, "nodeType": "ParameterList", "parameters": [], - "src": "1891:0:2" + "src": "1891:0:3" }, - "scope": 332, - "src": "1621:1024:2", + "scope": 408, + "src": "1621:1024:3", "stateMutability": "payable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 282, + "id": 358, "nodeType": "Block", - "src": "2813:412:2", + "src": "2813:412:3", "statements": [ { "expression": { @@ -5636,7 +5636,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 248, + "id": 324, "isConstant": false, "isLValue": false, "isPure": false, @@ -5645,18 +5645,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 245, + "id": 321, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2829:3:2", + "referencedDeclaration": 12128, + "src": "2829:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 246, + "id": 322, "isConstant": false, "isLValue": false, "isPure": false, @@ -5664,7 +5664,7 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2829:9:2", + "src": "2829:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5674,18 +5674,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 247, + "id": 323, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 241, - "src": "2842:9:2", + "referencedDeclaration": 317, + "src": "2842:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "2829:22:2", + "src": "2829:22:3", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -5694,14 +5694,14 @@ { "argumentTypes": null, "hexValue": "4e6f7420456e6f756768204574682053656e74", - "id": 249, + "id": 325, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "2853:21:2", + "src": "2853:21:3", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30b29beae4cdbb7acc80a8e1229a071d1d9114e20038f0c713ecf8dbdd0dcc4e", @@ -5721,21 +5721,21 @@ "typeString": "literal_string \"Not Enough Eth Sent\"" } ], - "id": 244, + "id": 320, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "2821:7:2", + "referencedDeclaration": 12132, + "src": "2821:7:3", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 250, + "id": 326, "isConstant": false, "isLValue": false, "isPure": false, @@ -5743,43 +5743,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2821:54:2", + "src": "2821:54:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 251, + "id": 327, "nodeType": "ExpressionStatement", - "src": "2821:54:2" + "src": "2821:54:3" }, { "assignments": [ - 253 + 329 ], "declarations": [ { "constant": false, - "id": 253, + "id": 329, "name": "kyberExchange", "nodeType": "VariableDeclaration", - "scope": 282, - "src": "2884:31:2", + "scope": 358, + "src": "2884:31:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" }, "typeName": { "contractScope": null, - "id": 252, + "id": 328, "name": "KyberNetworkProxy", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 85, - "src": "2884:17:2", + "referencedDeclaration": 161, + "src": "2884:17:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, @@ -5787,18 +5787,18 @@ "visibility": "internal" } ], - "id": 257, + "id": 333, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 255, + "id": 331, "name": "kyberExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 235, - "src": "2936:20:2", + "referencedDeclaration": 311, + "src": "2936:20:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5812,18 +5812,18 @@ "typeString": "address" } ], - "id": 254, + "id": 330, "name": "KyberNetworkProxy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 85, - "src": "2918:17:2", + "referencedDeclaration": 161, + "src": "2918:17:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$85_$", + "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$161_$", "typeString": "type(contract KyberNetworkProxy)" } }, - "id": 256, + "id": 332, "isConstant": false, "isLValue": false, "isPure": false, @@ -5831,42 +5831,42 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2918:39:2", + "src": "2918:39:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, "nodeType": "VariableDeclarationStatement", - "src": "2884:73:2" + "src": "2884:73:3" }, { "assignments": [ - 259 + 335 ], "declarations": [ { "constant": false, - "id": 259, + "id": 335, "name": "token", "nodeType": "VariableDeclaration", - "scope": 282, - "src": "2966:11:2", + "scope": 358, + "src": "2966:11:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 258, + "id": 334, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "2966:5:2", + "referencedDeclaration": 10857, + "src": "2966:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -5874,18 +5874,18 @@ "visibility": "internal" } ], - "id": 263, + "id": 339, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 261, + "id": 337, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 237, - "src": "2986:12:2", + "referencedDeclaration": 313, + "src": "2986:12:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5899,18 +5899,18 @@ "typeString": "address" } ], - "id": 260, + "id": 336, "name": "ERC20", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1374, - "src": "2980:5:2", + "referencedDeclaration": 10857, + "src": "2980:5:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_ERC20_$1374_$", + "typeIdentifier": "t_type$_t_contract$_ERC20_$10857_$", "typeString": "type(contract ERC20)" } }, - "id": 262, + "id": 338, "isConstant": false, "isLValue": false, "isPure": false, @@ -5918,27 +5918,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2980:19:2", + "src": "2980:19:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, "nodeType": "VariableDeclarationStatement", - "src": "2966:33:2" + "src": "2966:33:3" }, { "assignments": [ - 265 + 341 ], "declarations": [ { "constant": false, - "id": 265, + "id": 341, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 282, - "src": "3008:20:2", + "scope": 358, + "src": "3008:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5946,10 +5946,10 @@ "typeString": "uint256" }, "typeName": { - "id": 264, + "id": 340, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3008:7:2", + "src": "3008:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5959,31 +5959,31 @@ "visibility": "internal" } ], - "id": 274, + "id": 350, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 271, + "id": 347, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 259, - "src": "3079:5:2", + "referencedDeclaration": 335, + "src": "3079:5:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, { "argumentTypes": null, - "id": 272, + "id": 348, "name": "kyberMinConversionRate", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 239, - "src": "3086:22:2", + "referencedDeclaration": 315, + "src": "3086:22:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5993,7 +5993,7 @@ "expression": { "argumentTypes": [ { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, { @@ -6004,12 +6004,12 @@ "arguments": [ { "argumentTypes": null, - "id": 269, + "id": 345, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 241, - "src": "3068:9:2", + "referencedDeclaration": 317, + "src": "3068:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6027,32 +6027,32 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 266, + "id": 342, "name": "kyberExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 253, - "src": "3031:13:2", + "referencedDeclaration": 329, + "src": "3031:13:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, - "id": 267, + "id": 343, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "swapEtherToToken", "nodeType": "MemberAccess", - "referencedDeclaration": 84, - "src": "3031:30:2", + "referencedDeclaration": 160, + "src": "3031:30:3", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 268, + "id": 344, "isConstant": false, "isLValue": false, "isPure": false, @@ -6060,13 +6060,13 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "3031:36:2", + "src": "3031:36:3", "typeDescriptions": { - "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value_$", + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value_$", "typeString": "function (uint256) returns (function (contract ERC20,uint256) payable external returns (uint256))" } }, - "id": 270, + "id": 346, "isConstant": false, "isLValue": false, "isPure": false, @@ -6074,13 +6074,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3031:47:2", + "src": "3031:47:3", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 273, + "id": 349, "isConstant": false, "isLValue": false, "isPure": false, @@ -6088,14 +6088,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3031:78:2", + "src": "3031:78:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "3008:101:2" + "src": "3008:101:3" }, { "eventCall": { @@ -6105,18 +6105,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 276, + "id": 352, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3184:3:2", + "referencedDeclaration": 12128, + "src": "3184:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 277, + "id": 353, "isConstant": false, "isLValue": false, "isPure": false, @@ -6124,7 +6124,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "3184:10:2", + "src": "3184:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -6132,12 +6132,12 @@ }, { "argumentTypes": null, - "id": 278, + "id": 354, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 241, - "src": "3196:9:2", + "referencedDeclaration": 317, + "src": "3196:9:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6145,12 +6145,12 @@ }, { "argumentTypes": null, - "id": 279, + "id": 355, "name": "token_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 265, - "src": "3207:12:2", + "referencedDeclaration": 341, + "src": "3207:12:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6172,18 +6172,18 @@ "typeString": "uint256" } ], - "id": 275, + "id": 351, "name": "ethToToken", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 100, - "src": "3173:10:2", + "referencedDeclaration": 176, + "src": "3173:10:3", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256)" } }, - "id": 280, + "id": 356, "isConstant": false, "isLValue": false, "isPure": false, @@ -6191,36 +6191,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3173:47:2", + "src": "3173:47:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 281, + "id": 357, "nodeType": "EmitStatement", - "src": "3168:52:2" + "src": "3168:52:3" } ] }, "documentation": null, - "id": 283, + "id": 359, "implemented": true, "kind": "function", "modifiers": [], "name": "tradeEthToToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 242, + "id": 318, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 235, + "id": 311, "name": "kyberExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 283, - "src": "2679:28:2", + "scope": 359, + "src": "2679:28:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6228,10 +6228,10 @@ "typeString": "address" }, "typeName": { - "id": 234, + "id": 310, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2679:7:2", + "src": "2679:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -6243,11 +6243,11 @@ }, { "constant": false, - "id": 237, + "id": 313, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 283, - "src": "2713:20:2", + "scope": 359, + "src": "2713:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6255,10 +6255,10 @@ "typeString": "address" }, "typeName": { - "id": 236, + "id": 312, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2713:7:2", + "src": "2713:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -6270,11 +6270,11 @@ }, { "constant": false, - "id": 239, + "id": 315, "name": "kyberMinConversionRate", "nodeType": "VariableDeclaration", - "scope": 283, - "src": "2739:30:2", + "scope": 359, + "src": "2739:30:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6282,10 +6282,10 @@ "typeString": "uint256" }, "typeName": { - "id": 238, + "id": 314, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2739:7:2", + "src": "2739:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6296,11 +6296,11 @@ }, { "constant": false, - "id": 241, + "id": 317, "name": "ethToSell", "nodeType": "VariableDeclaration", - "scope": 283, - "src": "2775:17:2", + "scope": 359, + "src": "2775:17:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6308,10 +6308,10 @@ "typeString": "uint256" }, "typeName": { - "id": 240, + "id": 316, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2775:7:2", + "src": "2775:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6321,53 +6321,53 @@ "visibility": "internal" } ], - "src": "2673:120:2" + "src": "2673:120:3" }, "returnParameters": { - "id": 243, + "id": 319, "nodeType": "ParameterList", "parameters": [], - "src": "2813:0:2" + "src": "2813:0:3" }, - "scope": 332, - "src": "2649:576:2", + "scope": 408, + "src": "2649:576:3", "stateMutability": "payable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 319, + "id": 395, "nodeType": "Block", - "src": "3377:335:2", + "src": "3377:335:3", "statements": [ { "assignments": [ - 295 + 371 ], "declarations": [ { "constant": false, - "id": 295, + "id": 371, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 319, - "src": "3438:31:2", + "scope": 395, + "src": "3438:31:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 294, + "id": 370, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "3438:15:2", + "referencedDeclaration": 920, + "src": "3438:15:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -6375,18 +6375,18 @@ "visibility": "internal" } ], - "id": 299, + "id": 375, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 297, + "id": 373, "name": "uniSwapExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 285, - "src": "3488:22:2", + "referencedDeclaration": 361, + "src": "3488:22:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -6400,18 +6400,18 @@ "typeString": "address" } ], - "id": 296, + "id": 372, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "3472:15:2", + "referencedDeclaration": 920, + "src": "3472:15:3", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 298, + "id": 374, "isConstant": false, "isLValue": false, "isPure": false, @@ -6419,27 +6419,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3472:39:2", + "src": "3472:39:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "3438:73:2" + "src": "3438:73:3" }, { "assignments": [ - 301 + 377 ], "declarations": [ { "constant": false, - "id": 301, + "id": 377, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 319, - "src": "3520:19:2", + "scope": 395, + "src": "3520:19:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6447,10 +6447,10 @@ "typeString": "uint256" }, "typeName": { - "id": 300, + "id": 376, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3520:7:2", + "src": "3520:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6460,18 +6460,18 @@ "visibility": "internal" } ], - "id": 310, + "id": 386, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 304, + "id": 380, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 291, - "src": "3583:8:2", + "referencedDeclaration": 367, + "src": "3583:8:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6479,12 +6479,12 @@ }, { "argumentTypes": null, - "id": 305, + "id": 381, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 287, - "src": "3593:13:2", + "referencedDeclaration": 363, + "src": "3593:13:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6492,12 +6492,12 @@ }, { "argumentTypes": null, - "id": 306, + "id": 382, "name": "sellDeadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 289, - "src": "3608:12:2", + "referencedDeclaration": 365, + "src": "3608:12:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6507,18 +6507,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 307, + "id": 383, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3622:3:2", + "referencedDeclaration": 12128, + "src": "3622:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 308, + "id": 384, "isConstant": false, "isLValue": false, "isPure": false, @@ -6526,7 +6526,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "3622:10:2", + "src": "3622:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -6554,32 +6554,32 @@ ], "expression": { "argumentTypes": null, - "id": 302, + "id": 378, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 295, - "src": "3542:15:2", + "referencedDeclaration": 371, + "src": "3542:15:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 303, + "id": 379, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "tokenToEthTransferOutput", "nodeType": "MemberAccess", - "referencedDeclaration": 839, - "src": "3542:40:2", + "referencedDeclaration": 915, + "src": "3542:40:3", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_payable_$returns$_t_uint256_$", "typeString": "function (uint256,uint256,uint256,address payable) external returns (uint256)" } }, - "id": 309, + "id": 385, "isConstant": false, "isLValue": false, "isPure": false, @@ -6587,14 +6587,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3542:91:2", + "src": "3542:91:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "3520:113:2" + "src": "3520:113:3" }, { "eventCall": { @@ -6604,18 +6604,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 312, + "id": 388, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "3658:3:2", + "referencedDeclaration": 12128, + "src": "3658:3:3", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 313, + "id": 389, "isConstant": false, "isLValue": false, "isPure": false, @@ -6623,7 +6623,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "3658:10:2", + "src": "3658:10:3", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -6631,12 +6631,12 @@ }, { "argumentTypes": null, - "id": 314, + "id": 390, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 291, - "src": "3670:8:2", + "referencedDeclaration": 367, + "src": "3670:8:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6644,12 +6644,12 @@ }, { "argumentTypes": null, - "id": 315, + "id": 391, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 287, - "src": "3680:13:2", + "referencedDeclaration": 363, + "src": "3680:13:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6657,12 +6657,12 @@ }, { "argumentTypes": null, - "id": 316, + "id": 392, "name": "tokens_sold", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 301, - "src": "3695:11:2", + "referencedDeclaration": 377, + "src": "3695:11:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6688,18 +6688,18 @@ "typeString": "uint256" } ], - "id": 311, + "id": 387, "name": "tokenToEth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 110, - "src": "3647:10:2", + "referencedDeclaration": 186, + "src": "3647:10:3", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 317, + "id": 393, "isConstant": false, "isLValue": false, "isPure": false, @@ -6707,36 +6707,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3647:60:2", + "src": "3647:60:3", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 318, + "id": 394, "nodeType": "EmitStatement", - "src": "3642:65:2" + "src": "3642:65:3" } ] }, "documentation": null, - "id": 320, + "id": 396, "implemented": true, "kind": "function", "modifiers": [], "name": "tradeTokenToEth", "nodeType": "FunctionDefinition", "parameters": { - "id": 292, + "id": 368, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 285, + "id": 361, "name": "uniSwapExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 320, - "src": "3259:30:2", + "scope": 396, + "src": "3259:30:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6744,10 +6744,10 @@ "typeString": "address" }, "typeName": { - "id": 284, + "id": 360, "name": "address", "nodeType": "ElementaryTypeName", - "src": "3259:7:2", + "src": "3259:7:3", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -6759,11 +6759,11 @@ }, { "constant": false, - "id": 287, + "id": 363, "name": "maxTokensSell", "nodeType": "VariableDeclaration", - "scope": 320, - "src": "3295:21:2", + "scope": 396, + "src": "3295:21:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6771,10 +6771,10 @@ "typeString": "uint256" }, "typeName": { - "id": 286, + "id": 362, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3295:7:2", + "src": "3295:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6785,11 +6785,11 @@ }, { "constant": false, - "id": 289, + "id": 365, "name": "sellDeadline", "nodeType": "VariableDeclaration", - "scope": 320, - "src": "3322:20:2", + "scope": 396, + "src": "3322:20:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6797,10 +6797,10 @@ "typeString": "uint256" }, "typeName": { - "id": 288, + "id": 364, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3322:7:2", + "src": "3322:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6811,11 +6811,11 @@ }, { "constant": false, - "id": 291, + "id": 367, "name": "ethToBuy", "nodeType": "VariableDeclaration", - "scope": 320, - "src": "3348:16:2", + "scope": 396, + "src": "3348:16:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6823,10 +6823,10 @@ "typeString": "uint256" }, "typeName": { - "id": 290, + "id": 366, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3348:7:2", + "src": "3348:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6836,25 +6836,25 @@ "visibility": "internal" } ], - "src": "3253:112:2" + "src": "3253:112:3" }, "returnParameters": { - "id": 293, + "id": 369, "nodeType": "ParameterList", "parameters": [], - "src": "3377:0:2" + "src": "3377:0:3" }, - "scope": 332, - "src": "3229:483:2", + "scope": 408, + "src": "3229:483:3", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 330, + "id": 406, "nodeType": "Block", - "src": "3768:39:2", + "src": "3768:39:3", "statements": [ { "expression": { @@ -6864,14 +6864,14 @@ "arguments": [ { "argumentTypes": null, - "id": 326, + "id": 402, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1484, - "src": "3789:4:2", + "referencedDeclaration": 12186, + "src": "3789:4:3", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberTestContract_$332", + "typeIdentifier": "t_contract$_KyberTestContract_$408", "typeString": "contract KyberTestContract" } } @@ -6879,24 +6879,24 @@ "expression": { "argumentTypes": [ { - "typeIdentifier": "t_contract$_KyberTestContract_$332", + "typeIdentifier": "t_contract$_KyberTestContract_$408", "typeString": "contract KyberTestContract" } ], - "id": 325, + "id": 401, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "3781:7:2", + "src": "3781:7:3", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 327, + "id": 403, "isConstant": false, "isLValue": false, "isPure": false, @@ -6904,13 +6904,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3781:13:2", + "src": "3781:13:3", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 328, + "id": 404, "isConstant": false, "isLValue": false, "isPure": false, @@ -6918,43 +6918,43 @@ "memberName": "balance", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "3781:21:2", + "src": "3781:21:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 324, - "id": 329, + "functionReturnParameters": 400, + "id": 405, "nodeType": "Return", - "src": "3774:28:2" + "src": "3774:28:3" } ] }, "documentation": null, - "id": 331, + "id": 407, "implemented": true, "kind": "function", "modifiers": [], "name": "getBalance", "nodeType": "FunctionDefinition", "parameters": { - "id": 321, + "id": 397, "nodeType": "ParameterList", "parameters": [], - "src": "3735:2:2" + "src": "3735:2:3" }, "returnParameters": { - "id": 324, + "id": 400, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 323, + "id": 399, "name": "", "nodeType": "VariableDeclaration", - "scope": 331, - "src": "3759:7:2", + "scope": 407, + "src": "3759:7:3", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6962,10 +6962,10 @@ "typeString": "uint256" }, "typeName": { - "id": 322, + "id": 398, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3759:7:2", + "src": "3759:7:3", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6975,20 +6975,20 @@ "visibility": "internal" } ], - "src": "3758:9:2" + "src": "3758:9:3" }, - "scope": 332, - "src": "3716:91:2", + "scope": 408, + "src": "3716:91:3", "stateMutability": "view", "superFunction": null, "visibility": "public" } ], - "scope": 333, - "src": "148:3661:2" + "scope": 409, + "src": "148:3661:3" } ], - "src": "0:3810:2" + "src": "0:3810:3" }, "compiler": { "name": "solc", @@ -6996,7 +6996,7 @@ }, "networks": {}, "schemaVersion": "3.0.16", - "updatedAt": "2019-11-04T18:56:07.471Z", + "updatedAt": "2019-11-07T14:57:54.558Z", "devdoc": { "methods": { "approveToken(address,address,uint256)": { diff --git a/client/src/contracts/KyberUniArbContract.json b/client/src/contracts/KyberUniArbContract.json index 0db5cf4..d490490 100644 --- a/client/src/contracts/KyberUniArbContract.json +++ b/client/src/contracts/KyberUniArbContract.json @@ -138,22 +138,22 @@ "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"kyberExchangeAddress\",\"type\":\"address\"},{\"name\":\"tokenAddress\",\"type\":\"address\"},{\"name\":\"kyberMinConversionRate\",\"type\":\"uint256\"},{\"name\":\"uniSwapExchangeAddress\",\"type\":\"address\"},{\"name\":\"ethToSell\",\"type\":\"uint256\"},{\"name\":\"maxTokensSell\",\"type\":\"uint256\"},{\"name\":\"sellDeadline\",\"type\":\"uint256\"},{\"name\":\"ethToBuy\",\"type\":\"uint256\"}],\"name\":\"trade\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"tokenAddress\",\"type\":\"address\"},{\"name\":\"exchangeAddress\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approveToken\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"trader\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"tokens\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"token_bought\",\"type\":\"uint256\"}],\"name\":\"ethToToken\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"trader\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"ethToBuy\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"maxTokensSell\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"tokens_sold\",\"type\":\"uint256\"}],\"name\":\"tokenToEth\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"approveToken(address,address,uint256)\":{\"details\":\"Approves UniSwap exchange to transfer tokens from contract.\",\"params\":{\"amount\":\"Token amount to approve\",\"exchangeAddress\":\"UniSwap Exchange address\",\"tokenAddress\":\"Address of the token to approve\"}},\"constructor\":{\"details\":\"Contract constructor. Set owner of contract as deployer.\"},\"trade(address,address,uint256,address,uint256,uint256,uint256,uint256)\":{\"details\":\"Executes trade.\",\"params\":{\"ethToBuy\":\"Amount of Eth bought in Uniswap trade.\",\"ethToSell\":\"Amount of Eth that is being traded via Kyber. Should be sent as value too.\",\"kyberExchangeAddress\":\"Kyber network address\",\"kyberMinConversionRate\":\"Min conversion rate for Kyber\",\"maxTokensSell\":\"Maximum ERC20 tokens sold in Uniswap trade.\",\"sellDeadline\":\"Uniswap transaction deadline.\",\"tokenAddress\":\"Address of the token that is being traded\",\"uniSwapExchangeAddress\":\"UniSwap exchange address\"}}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/KyberUniArbContract.sol\":\"KyberUniArbContract\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/ERC20Token.sol\":{\"keccak256\":\"0x15bb1784c5ce15ba060c56edf16b91843a45cf16dea3b300670a8a8c2b204460\",\"urls\":[\"bzzr://05fdf03f7c00bb78604f2d2790bad68f7c4048eab1f04b8636ce7dc7cc88263a\"]},\"/Users/jg/Documents/aaveBot/contracts/KyberNetworkProxy.sol\":{\"keccak256\":\"0x2fd6874b83795c5bdefc5fb0590c38508728a6e02c15ce63da00cac3789ba2af\",\"urls\":[\"bzzr://bc3bd85ae5d2dc5ad5c9351462dfdb853a7d04ad470fcfe90ab706476267be03\"]},\"/Users/jg/Documents/aaveBot/contracts/KyberUniArbContract.sol\":{\"keccak256\":\"0x28bf913ed9564b3de2f7d3a40f4dc51186b290385204104383dab8487af82a2c\",\"urls\":[\"bzzr://b43144a3052e961034d3c95e337e6799c0aedf1ca716b86265dc42858123e69a\"]},\"/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol\":{\"keccak256\":\"0x35ce204d214fb0d5b2e05df0b9e45833a2e8db564c995db36bfc023ff4a3f4f4\",\"urls\":[\"bzzr://5d4c7bc352bb1accf85e754811b6c0acc9bf0be87e852ba011c92b1344cfa463\"]},\"@openzeppelin/contracts/math/SafeMath.sol\":{\"keccak256\":\"0xd1804d04fb39689453f673601429a99a0c68c422a981fc338773df9a59180fe9\",\"urls\":[\"bzzr://a7dfb6fc259d0074da840a848461487567e2a6309105dd5c050a4e025f0fa7cb\"]},\"@openzeppelin/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x852793a3c2f86d336a683b30d688ec3dcfc57451af5a2bf5975cda3b7191a901\",\"urls\":[\"bzzr://07fb42206812a17c1f71e548cfa5cec6f9aa1ae0ca5df870718ca4aa9759d1a5\"]},\"@openzeppelin/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0x90e8c2521653bbb1768b05889c5760031e688d9cd361f167489b89215e201b95\",\"urls\":[\"bzzr://aa8b45b57edafc3d67bc5d916327ea16807fae33f753ca163ae0c4061b789766\"]}},\"version\":1}", "bytecode": "0x608060405234801561001057600080fd5b50336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506106c2806100606000396000f3fe6080604052600436106100345760003560e01c80635a1b2c78146100395780638da5cb5b146100f0578063da3e339714610147575b600080fd5b6100ee600480360361010081101561005057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035906020019092919080359060200190929190803590602001909291905050506101c2565b005b3480156100fc57600080fd5b506101056104e1565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561015357600080fd5b506101c06004803603606081101561016a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610506565b005b83341015610238576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4e6f7420456e6f756768204574682053656e740000000000000000000000000081525060200191505060405180910390fd5b6000889050600088905060008273ffffffffffffffffffffffffffffffffffffffff16637a2a045688848c6040518463ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001925050506020604051808303818588803b1580156102cb57600080fd5b505af11580156102df573d6000803e3d6000fd5b50505050506040513d60208110156102f657600080fd5b810190808051906020019092919050505090507fef501080e89b7bbe29cfb8e1eb48a349f22c4777a3c85d770104c8a80f45b68d338883604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a1600088905060008173ffffffffffffffffffffffffffffffffffffffff1663d4e4841d878a8a336040518563ffffffff1660e01b8152600401808581526020018481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b15801561041a57600080fd5b505af115801561042e573d6000803e3d6000fd5b505050506040513d602081101561044457600080fd5b810190808051906020019092919050505090507fe9c245f1c1a4a7a621218231e7ed679594b1c02c80e4fe05a465ecb46dc37f4733878a84604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a150505050505050505050505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146105c8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260168152602001807f4f6e6c79204f776e65722043616e20417070726f76650000000000000000000081525060200191505060405180910390fd5b60008390508073ffffffffffffffffffffffffffffffffffffffff1663095ea7b384846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b15801561065457600080fd5b505af1158015610668573d6000803e3d6000fd5b505050506040513d602081101561067e57600080fd5b8101908080519060200190929190505050505050505056fea165627a7a7230582022a23b80193dd2aaa8f3a88fa68862ddf54b0b9e430fea47dbc18d8d382cdd680029", "deployedBytecode": "0x6080604052600436106100345760003560e01c80635a1b2c78146100395780638da5cb5b146100f0578063da3e339714610147575b600080fd5b6100ee600480360361010081101561005057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035906020019092919080359060200190929190803590602001909291905050506101c2565b005b3480156100fc57600080fd5b506101056104e1565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561015357600080fd5b506101c06004803603606081101561016a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610506565b005b83341015610238576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4e6f7420456e6f756768204574682053656e740000000000000000000000000081525060200191505060405180910390fd5b6000889050600088905060008273ffffffffffffffffffffffffffffffffffffffff16637a2a045688848c6040518463ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001925050506020604051808303818588803b1580156102cb57600080fd5b505af11580156102df573d6000803e3d6000fd5b50505050506040513d60208110156102f657600080fd5b810190808051906020019092919050505090507fef501080e89b7bbe29cfb8e1eb48a349f22c4777a3c85d770104c8a80f45b68d338883604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a1600088905060008173ffffffffffffffffffffffffffffffffffffffff1663d4e4841d878a8a336040518563ffffffff1660e01b8152600401808581526020018481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b15801561041a57600080fd5b505af115801561042e573d6000803e3d6000fd5b505050506040513d602081101561044457600080fd5b810190808051906020019092919050505090507fe9c245f1c1a4a7a621218231e7ed679594b1c02c80e4fe05a465ecb46dc37f4733878a84604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a150505050505050505050505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146105c8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260168152602001807f4f6e6c79204f776e65722043616e20417070726f76650000000000000000000081525060200191505060405180910390fd5b60008390508073ffffffffffffffffffffffffffffffffffffffff1663095ea7b384846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b15801561065457600080fd5b505af1158015610668573d6000803e3d6000fd5b505050506040513d602081101561067e57600080fd5b8101908080519060200190929190505050505050505056fea165627a7a7230582022a23b80193dd2aaa8f3a88fa68862ddf54b0b9e430fea47dbc18d8d382cdd680029", - "sourceMap": "119:2521:3:-;;;497:50;8:9:-1;5:2;;;30:1;27;20:12;5:2;497:50:3;532:10;524:5;;:18;;;;;;;;;;;;;;;;;;119:2521;;;;;;", - "deployedSourceMap": "119:2521:3:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1604:1034;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;1604:1034:3;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;208:20;;8:9:-1;5:2;;;30:1;27;20:12;5:2;208:20:3;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;786:247;;8:9:-1;5:2;;;30:1;27;20:12;5:2;786:247:3;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;786:247:3;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;1604:1034;1901:9;1888;:22;;1880:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1963:31;2015:20;1963:73;;2042:16;2072:12;2042:43;;2138:20;2161:13;:30;;;2198:9;2209:5;2216:22;2161:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2161:78:3;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2161:78:3;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2161:78:3;;;;;;;;;;;;;;;;2138:101;;2250:47;2261:10;2273:9;2284:12;2250:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2370:31;2420:22;2370:73;;2449:19;2471:15;:40;;;2512:8;2522:13;2537:12;2551:10;2471:91;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2471:91:3;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2471:91:3;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2471:91:3;;;;;;;;;;;;;;;;2449:113;;2573:60;2584:10;2596:8;2606:13;2621:11;2573:60;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1604:1034;;;;;;;;;;;;;:::o;208:20::-;;;;;;;;;;;;;:::o;786:247::-;903:5;;;;;;;;;;;889:19;;:10;:19;;;881:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;941:16;971:12;941:43;;990:5;:13;;;1004:15;1021:6;990:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;990:38:3;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;990:38:3;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;990:38:3;;;;;;;;;;;;;;;;;786:247;;;;:::o", + "sourceMap": "119:2521:4:-;;;497:50;8:9:-1;5:2;;;30:1;27;20:12;5:2;497:50:4;532:10;524:5;;:18;;;;;;;;;;;;;;;;;;119:2521;;;;;;", + "deployedSourceMap": "119:2521:4:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1604:1034;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;1604:1034:4;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;208:20;;8:9:-1;5:2;;;30:1;27;20:12;5:2;208:20:4;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;786:247;;8:9:-1;5:2;;;30:1;27;20:12;5:2;786:247:4;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;786:247:4;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;1604:1034;1901:9;1888;:22;;1880:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1963:31;2015:20;1963:73;;2042:16;2072:12;2042:43;;2138:20;2161:13;:30;;;2198:9;2209:5;2216:22;2161:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2161:78:4;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2161:78:4;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2161:78:4;;;;;;;;;;;;;;;;2138:101;;2250:47;2261:10;2273:9;2284:12;2250:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2370:31;2420:22;2370:73;;2449:19;2471:15;:40;;;2512:8;2522:13;2537:12;2551:10;2471:91;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2471:91:4;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2471:91:4;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2471:91:4;;;;;;;;;;;;;;;;2449:113;;2573:60;2584:10;2596:8;2606:13;2621:11;2573:60;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1604:1034;;;;;;;;;;;;;:::o;208:20::-;;;;;;;;;;;;;:::o;786:247::-;903:5;;;;;;;;;;;889:19;;:10;:19;;;881:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;941:16;971:12;941:43;;990:5;:13;;;1004:15;1021:6;990:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;990:38:4;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;990:38:4;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;990:38:4;;;;;;;;;;;;;;;;;786:247;;;;:::o", "source": "pragma solidity ^0.5.0;\n\nimport \"./UniswapExchange.sol\";\nimport \"./ERC20Token.sol\";\nimport \"./KyberNetworkProxy.sol\";\n\ncontract KyberUniArbContract {\n // Variable to hold owner of contract. Set on deploy.\n address public owner;\n\n // Events\n event ethToToken(address trader, uint256 tokens, uint256 token_bought);\n event tokenToEth(address trader, uint256 ethToBuy, uint256 maxTokensSell, uint256 tokens_sold);\n\n /**\n * @dev Contract constructor. Set owner of contract as deployer.\n */\n constructor() public {\n owner = msg.sender;\n }\n\n /**\n * @dev Approves UniSwap exchange to transfer tokens from contract.\n * @param tokenAddress Address of the token to approve\n * @param exchangeAddress UniSwap Exchange address\n * @param amount Token amount to approve\n */\n function approveToken(address tokenAddress, address exchangeAddress, uint amount) public {\n require(msg.sender == owner, \"Only Owner Can Approve\");\n ERC20Token token = ERC20Token(tokenAddress);\n token.approve(exchangeAddress, amount);\n }\n\n /**\n * @dev Executes trade.\n * @param kyberExchangeAddress Kyber network address\n * @param tokenAddress Address of the token that is being traded\n * @param kyberMinConversionRate Min conversion rate for Kyber\n * @param uniSwapExchangeAddress UniSwap exchange address\n * @param ethToSell Amount of Eth that is being traded via Kyber. Should be sent as value too.\n * @param maxTokensSell Maximum ERC20 tokens sold in Uniswap trade.\n * @param sellDeadline Uniswap transaction deadline.\n * @param ethToBuy Amount of Eth bought in Uniswap trade.\n */\n function trade(\n address kyberExchangeAddress,\n address tokenAddress,\n uint256 kyberMinConversionRate,\n address uniSwapExchangeAddress,\n uint256 ethToSell,\n uint256 maxTokensSell,\n uint256 sellDeadline,\n uint256 ethToBuy\n ) public\n payable\n {\n require(msg.value >= ethToSell, \"Not Enough Eth Sent\");\n // check approval\n\n KyberNetworkProxy kyberExchange = KyberNetworkProxy(kyberExchangeAddress);\n ERC20Token token = ERC20Token(tokenAddress);\n\n // Swaps Eth for Token via Kyber Exchange\n uint256 token_bought = kyberExchange.swapEtherToToken.value(ethToSell)(token, kyberMinConversionRate);\n emit ethToToken(msg.sender, ethToSell, token_bought);\n\n // Swaps token to Eth and transfers Eth to msg sender address\n UniswapExchange uniSwapExchange = UniswapExchange(uniSwapExchangeAddress);\n uint256 tokens_sold = uniSwapExchange.tokenToEthTransferOutput(ethToBuy, maxTokensSell, sellDeadline, msg.sender);\n emit tokenToEth(msg.sender, ethToBuy, maxTokensSell, tokens_sold);\n }\n}\n", "sourcePath": "/Users/jg/Documents/aaveBot/contracts/KyberUniArbContract.sol", "ast": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/KyberUniArbContract.sol", "exportedSymbols": { "KyberUniArbContract": [ - 481 + 557 ] }, - "id": 482, + "id": 558, "nodeType": "SourceUnit", "nodes": [ { - "id": 334, + "id": 410, "literals": [ "solidity", "^", @@ -161,38 +161,38 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:3" + "src": "0:23:4" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol", "file": "./UniswapExchange.sol", - "id": 335, + "id": 411, "nodeType": "ImportDirective", - "scope": 482, - "sourceUnit": 845, - "src": "25:31:3", + "scope": 558, + "sourceUnit": 921, + "src": "25:31:4", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/ERC20Token.sol", "file": "./ERC20Token.sol", - "id": 336, + "id": 412, "nodeType": "ImportDirective", - "scope": 482, + "scope": 558, "sourceUnit": 6, - "src": "57:26:3", + "src": "57:26:4", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/KyberNetworkProxy.sol", "file": "./KyberNetworkProxy.sol", - "id": 337, + "id": 413, "nodeType": "ImportDirective", - "scope": 482, - "sourceUnit": 86, - "src": "84:33:3", + "scope": 558, + "sourceUnit": 162, + "src": "84:33:4", "symbolAliases": [], "unitAlias": "" }, @@ -202,20 +202,20 @@ "contractKind": "contract", "documentation": null, "fullyImplemented": true, - "id": 481, + "id": 557, "linearizedBaseContracts": [ - 481 + 557 ], "name": "KyberUniArbContract", "nodeType": "ContractDefinition", "nodes": [ { "constant": false, - "id": 339, + "id": 415, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 481, - "src": "208:20:3", + "scope": 557, + "src": "208:20:4", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -223,10 +223,10 @@ "typeString": "address" }, "typeName": { - "id": 338, + "id": 414, "name": "address", "nodeType": "ElementaryTypeName", - "src": "208:7:3", + "src": "208:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -239,21 +239,21 @@ { "anonymous": false, "documentation": null, - "id": 347, + "id": 423, "name": "ethToToken", "nodeType": "EventDefinition", "parameters": { - "id": 346, + "id": 422, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 341, + "id": 417, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 347, - "src": "262:14:3", + "scope": 423, + "src": "262:14:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -261,10 +261,10 @@ "typeString": "address" }, "typeName": { - "id": 340, + "id": 416, "name": "address", "nodeType": "ElementaryTypeName", - "src": "262:7:3", + "src": "262:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -276,12 +276,12 @@ }, { "constant": false, - "id": 343, + "id": 419, "indexed": false, "name": "tokens", "nodeType": "VariableDeclaration", - "scope": 347, - "src": "278:14:3", + "scope": 423, + "src": "278:14:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -289,10 +289,10 @@ "typeString": "uint256" }, "typeName": { - "id": 342, + "id": 418, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "278:7:3", + "src": "278:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -303,12 +303,12 @@ }, { "constant": false, - "id": 345, + "id": 421, "indexed": false, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 347, - "src": "294:20:3", + "scope": 423, + "src": "294:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -316,10 +316,10 @@ "typeString": "uint256" }, "typeName": { - "id": 344, + "id": 420, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "294:7:3", + "src": "294:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -329,28 +329,28 @@ "visibility": "internal" } ], - "src": "261:54:3" + "src": "261:54:4" }, - "src": "245:71:3" + "src": "245:71:4" }, { "anonymous": false, "documentation": null, - "id": 357, + "id": 433, "name": "tokenToEth", "nodeType": "EventDefinition", "parameters": { - "id": 356, + "id": 432, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 349, + "id": 425, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 357, - "src": "336:14:3", + "scope": 433, + "src": "336:14:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -358,10 +358,10 @@ "typeString": "address" }, "typeName": { - "id": 348, + "id": 424, "name": "address", "nodeType": "ElementaryTypeName", - "src": "336:7:3", + "src": "336:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -373,12 +373,12 @@ }, { "constant": false, - "id": 351, + "id": 427, "indexed": false, "name": "ethToBuy", "nodeType": "VariableDeclaration", - "scope": 357, - "src": "352:16:3", + "scope": 433, + "src": "352:16:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -386,10 +386,10 @@ "typeString": "uint256" }, "typeName": { - "id": 350, + "id": 426, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "352:7:3", + "src": "352:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -400,12 +400,12 @@ }, { "constant": false, - "id": 353, + "id": 429, "indexed": false, "name": "maxTokensSell", "nodeType": "VariableDeclaration", - "scope": 357, - "src": "370:21:3", + "scope": 433, + "src": "370:21:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -413,10 +413,10 @@ "typeString": "uint256" }, "typeName": { - "id": 352, + "id": 428, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "370:7:3", + "src": "370:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -427,12 +427,12 @@ }, { "constant": false, - "id": 355, + "id": 431, "indexed": false, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 357, - "src": "393:19:3", + "scope": 433, + "src": "393:19:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -440,10 +440,10 @@ "typeString": "uint256" }, "typeName": { - "id": 354, + "id": 430, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "393:7:3", + "src": "393:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -453,32 +453,32 @@ "visibility": "internal" } ], - "src": "335:78:3" + "src": "335:78:4" }, - "src": "319:95:3" + "src": "319:95:4" }, { "body": { - "id": 365, + "id": 441, "nodeType": "Block", - "src": "518:29:3", + "src": "518:29:4", "statements": [ { "expression": { "argumentTypes": null, - "id": 363, + "id": 439, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 360, + "id": 436, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 339, - "src": "524:5:3", + "referencedDeclaration": 415, + "src": "524:5:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -490,18 +490,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 361, + "id": 437, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "532:3:3", + "referencedDeclaration": 12128, + "src": "532:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 362, + "id": 438, "isConstant": false, "isLValue": false, "isPure": false, @@ -509,54 +509,54 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "532:10:3", + "src": "532:10:4", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "524:18:3", + "src": "524:18:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 364, + "id": 440, "nodeType": "ExpressionStatement", - "src": "524:18:3" + "src": "524:18:4" } ] }, "documentation": "@dev Contract constructor. Set owner of contract as deployer.", - "id": 366, + "id": 442, "implemented": true, "kind": "constructor", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "parameters": { - "id": 358, + "id": 434, "nodeType": "ParameterList", "parameters": [], - "src": "508:2:3" + "src": "508:2:4" }, "returnParameters": { - "id": 359, + "id": 435, "nodeType": "ParameterList", "parameters": [], - "src": "518:0:3" + "src": "518:0:4" }, - "scope": 481, - "src": "497:50:3", + "scope": 557, + "src": "497:50:4", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 396, + "id": 472, "nodeType": "Block", - "src": "875:158:3", + "src": "875:158:4", "statements": [ { "expression": { @@ -568,7 +568,7 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 379, + "id": 455, "isConstant": false, "isLValue": false, "isPure": false, @@ -577,18 +577,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 376, + "id": 452, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "889:3:3", + "referencedDeclaration": 12128, + "src": "889:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 377, + "id": 453, "isConstant": false, "isLValue": false, "isPure": false, @@ -596,7 +596,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "889:10:3", + "src": "889:10:4", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -606,18 +606,18 @@ "operator": "==", "rightExpression": { "argumentTypes": null, - "id": 378, + "id": 454, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 339, - "src": "903:5:3", + "referencedDeclaration": 415, + "src": "903:5:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "src": "889:19:3", + "src": "889:19:4", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -626,14 +626,14 @@ { "argumentTypes": null, "hexValue": "4f6e6c79204f776e65722043616e20417070726f7665", - "id": 380, + "id": 456, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "910:24:3", + "src": "910:24:4", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_ec0b1a840a8a6c4384575556c3817abb58aac6b2bc4e7741e1c712be8067937e", @@ -653,21 +653,21 @@ "typeString": "literal_string \"Only Owner Can Approve\"" } ], - "id": 375, + "id": 451, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "881:7:3", + "referencedDeclaration": 12132, + "src": "881:7:4", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 381, + "id": 457, "isConstant": false, "isLValue": false, "isPure": false, @@ -675,28 +675,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "881:54:3", + "src": "881:54:4", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 382, + "id": 458, "nodeType": "ExpressionStatement", - "src": "881:54:3" + "src": "881:54:4" }, { "assignments": [ - 384 + 460 ], "declarations": [ { "constant": false, - "id": 384, + "id": 460, "name": "token", "nodeType": "VariableDeclaration", - "scope": 396, - "src": "941:16:3", + "scope": 472, + "src": "941:16:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -705,11 +705,11 @@ }, "typeName": { "contractScope": null, - "id": 383, + "id": 459, "name": "ERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 5, - "src": "941:10:3", + "src": "941:10:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" @@ -719,18 +719,18 @@ "visibility": "internal" } ], - "id": 388, + "id": 464, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 386, + "id": 462, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 368, - "src": "971:12:3", + "referencedDeclaration": 444, + "src": "971:12:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -744,18 +744,18 @@ "typeString": "address" } ], - "id": 385, + "id": 461, "name": "ERC20Token", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, - "src": "960:10:3", + "src": "960:10:4", "typeDescriptions": { "typeIdentifier": "t_type$_t_contract$_ERC20Token_$5_$", "typeString": "type(contract ERC20Token)" } }, - "id": 387, + "id": 463, "isConstant": false, "isLValue": false, "isPure": false, @@ -763,14 +763,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "960:24:3", + "src": "960:24:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" } }, "nodeType": "VariableDeclarationStatement", - "src": "941:43:3" + "src": "941:43:4" }, { "expression": { @@ -778,12 +778,12 @@ "arguments": [ { "argumentTypes": null, - "id": 392, + "id": 468, "name": "exchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 370, - "src": "1004:15:3", + "referencedDeclaration": 446, + "src": "1004:15:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -791,12 +791,12 @@ }, { "argumentTypes": null, - "id": 393, + "id": 469, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 372, - "src": "1021:6:3", + "referencedDeclaration": 448, + "src": "1021:6:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -816,32 +816,32 @@ ], "expression": { "argumentTypes": null, - "id": 389, + "id": 465, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 384, - "src": "990:5:3", + "referencedDeclaration": 460, + "src": "990:5:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" } }, - "id": 391, + "id": 467, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "approve", "nodeType": "MemberAccess", - "referencedDeclaration": 1072, - "src": "990:13:3", + "referencedDeclaration": 10555, + "src": "990:13:4", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,uint256) external returns (bool)" } }, - "id": 394, + "id": 470, "isConstant": false, "isLValue": false, "isPure": false, @@ -849,36 +849,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "990:38:3", + "src": "990:38:4", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, - "id": 395, + "id": 471, "nodeType": "ExpressionStatement", - "src": "990:38:3" + "src": "990:38:4" } ] }, "documentation": "@dev Approves UniSwap exchange to transfer tokens from contract.\n@param tokenAddress Address of the token to approve\n@param exchangeAddress UniSwap Exchange address\n@param amount Token amount to approve", - "id": 397, + "id": 473, "implemented": true, "kind": "function", "modifiers": [], "name": "approveToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 373, + "id": 449, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 368, + "id": 444, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 397, - "src": "808:20:3", + "scope": 473, + "src": "808:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -886,10 +886,10 @@ "typeString": "address" }, "typeName": { - "id": 367, + "id": 443, "name": "address", "nodeType": "ElementaryTypeName", - "src": "808:7:3", + "src": "808:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -901,11 +901,11 @@ }, { "constant": false, - "id": 370, + "id": 446, "name": "exchangeAddress", "nodeType": "VariableDeclaration", - "scope": 397, - "src": "830:23:3", + "scope": 473, + "src": "830:23:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -913,10 +913,10 @@ "typeString": "address" }, "typeName": { - "id": 369, + "id": 445, "name": "address", "nodeType": "ElementaryTypeName", - "src": "830:7:3", + "src": "830:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -928,11 +928,11 @@ }, { "constant": false, - "id": 372, + "id": 448, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 397, - "src": "855:11:3", + "scope": 473, + "src": "855:11:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -940,10 +940,10 @@ "typeString": "uint256" }, "typeName": { - "id": 371, + "id": 447, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "855:4:3", + "src": "855:4:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -953,25 +953,25 @@ "visibility": "internal" } ], - "src": "807:60:3" + "src": "807:60:4" }, "returnParameters": { - "id": 374, + "id": 450, "nodeType": "ParameterList", "parameters": [], - "src": "875:0:3" + "src": "875:0:4" }, - "scope": 481, - "src": "786:247:3", + "scope": 557, + "src": "786:247:4", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 479, + "id": 555, "nodeType": "Block", - "src": "1874:764:3", + "src": "1874:764:4", "statements": [ { "expression": { @@ -983,7 +983,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 420, + "id": 496, "isConstant": false, "isLValue": false, "isPure": false, @@ -992,18 +992,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 417, + "id": 493, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1888:3:3", + "referencedDeclaration": 12128, + "src": "1888:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 418, + "id": 494, "isConstant": false, "isLValue": false, "isPure": false, @@ -1011,7 +1011,7 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1888:9:3", + "src": "1888:9:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1021,18 +1021,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 419, + "id": 495, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 407, - "src": "1901:9:3", + "referencedDeclaration": 483, + "src": "1901:9:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "1888:22:3", + "src": "1888:22:4", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1041,14 +1041,14 @@ { "argumentTypes": null, "hexValue": "4e6f7420456e6f756768204574682053656e74", - "id": 421, + "id": 497, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "1912:21:3", + "src": "1912:21:4", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30b29beae4cdbb7acc80a8e1229a071d1d9114e20038f0c713ecf8dbdd0dcc4e", @@ -1068,21 +1068,21 @@ "typeString": "literal_string \"Not Enough Eth Sent\"" } ], - "id": 416, + "id": 492, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "1880:7:3", + "referencedDeclaration": 12132, + "src": "1880:7:4", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 422, + "id": 498, "isConstant": false, "isLValue": false, "isPure": false, @@ -1090,43 +1090,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1880:54:3", + "src": "1880:54:4", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 423, + "id": 499, "nodeType": "ExpressionStatement", - "src": "1880:54:3" + "src": "1880:54:4" }, { "assignments": [ - 425 + 501 ], "declarations": [ { "constant": false, - "id": 425, + "id": 501, "name": "kyberExchange", "nodeType": "VariableDeclaration", - "scope": 479, - "src": "1963:31:3", + "scope": 555, + "src": "1963:31:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" }, "typeName": { "contractScope": null, - "id": 424, + "id": 500, "name": "KyberNetworkProxy", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 85, - "src": "1963:17:3", + "referencedDeclaration": 161, + "src": "1963:17:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, @@ -1134,18 +1134,18 @@ "visibility": "internal" } ], - "id": 429, + "id": 505, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 427, + "id": 503, "name": "kyberExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 399, - "src": "2015:20:3", + "referencedDeclaration": 475, + "src": "2015:20:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1159,18 +1159,18 @@ "typeString": "address" } ], - "id": 426, + "id": 502, "name": "KyberNetworkProxy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 85, - "src": "1997:17:3", + "referencedDeclaration": 161, + "src": "1997:17:4", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$85_$", + "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$161_$", "typeString": "type(contract KyberNetworkProxy)" } }, - "id": 428, + "id": 504, "isConstant": false, "isLValue": false, "isPure": false, @@ -1178,27 +1178,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1997:39:3", + "src": "1997:39:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, "nodeType": "VariableDeclarationStatement", - "src": "1963:73:3" + "src": "1963:73:4" }, { "assignments": [ - 431 + 507 ], "declarations": [ { "constant": false, - "id": 431, + "id": 507, "name": "token", "nodeType": "VariableDeclaration", - "scope": 479, - "src": "2042:16:3", + "scope": 555, + "src": "2042:16:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1207,11 +1207,11 @@ }, "typeName": { "contractScope": null, - "id": 430, + "id": 506, "name": "ERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 5, - "src": "2042:10:3", + "src": "2042:10:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" @@ -1221,18 +1221,18 @@ "visibility": "internal" } ], - "id": 435, + "id": 511, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 433, + "id": 509, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 401, - "src": "2072:12:3", + "referencedDeclaration": 477, + "src": "2072:12:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1246,18 +1246,18 @@ "typeString": "address" } ], - "id": 432, + "id": 508, "name": "ERC20Token", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, - "src": "2061:10:3", + "src": "2061:10:4", "typeDescriptions": { "typeIdentifier": "t_type$_t_contract$_ERC20Token_$5_$", "typeString": "type(contract ERC20Token)" } }, - "id": 434, + "id": 510, "isConstant": false, "isLValue": false, "isPure": false, @@ -1265,27 +1265,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2061:24:3", + "src": "2061:24:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" } }, "nodeType": "VariableDeclarationStatement", - "src": "2042:43:3" + "src": "2042:43:4" }, { "assignments": [ - 437 + 513 ], "declarations": [ { "constant": false, - "id": 437, + "id": 513, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 479, - "src": "2138:20:3", + "scope": 555, + "src": "2138:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1293,10 +1293,10 @@ "typeString": "uint256" }, "typeName": { - "id": 436, + "id": 512, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2138:7:3", + "src": "2138:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1306,18 +1306,18 @@ "visibility": "internal" } ], - "id": 446, + "id": 522, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 443, + "id": 519, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 431, - "src": "2209:5:3", + "referencedDeclaration": 507, + "src": "2209:5:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" @@ -1325,12 +1325,12 @@ }, { "argumentTypes": null, - "id": 444, + "id": 520, "name": "kyberMinConversionRate", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 403, - "src": "2216:22:3", + "referencedDeclaration": 479, + "src": "2216:22:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1351,12 +1351,12 @@ "arguments": [ { "argumentTypes": null, - "id": 441, + "id": 517, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 407, - "src": "2198:9:3", + "referencedDeclaration": 483, + "src": "2198:9:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1374,32 +1374,32 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 438, + "id": 514, "name": "kyberExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 425, - "src": "2161:13:3", + "referencedDeclaration": 501, + "src": "2161:13:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, - "id": 439, + "id": 515, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "swapEtherToToken", "nodeType": "MemberAccess", - "referencedDeclaration": 84, - "src": "2161:30:3", + "referencedDeclaration": 160, + "src": "2161:30:4", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 440, + "id": 516, "isConstant": false, "isLValue": false, "isPure": false, @@ -1407,13 +1407,13 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2161:36:3", + "src": "2161:36:4", "typeDescriptions": { - "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value_$", + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value_$", "typeString": "function (uint256) returns (function (contract ERC20,uint256) payable external returns (uint256))" } }, - "id": 442, + "id": 518, "isConstant": false, "isLValue": false, "isPure": false, @@ -1421,13 +1421,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2161:47:3", + "src": "2161:47:4", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 445, + "id": 521, "isConstant": false, "isLValue": false, "isPure": false, @@ -1435,14 +1435,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2161:78:3", + "src": "2161:78:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2138:101:3" + "src": "2138:101:4" }, { "eventCall": { @@ -1452,18 +1452,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 448, + "id": 524, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2261:3:3", + "referencedDeclaration": 12128, + "src": "2261:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 449, + "id": 525, "isConstant": false, "isLValue": false, "isPure": false, @@ -1471,7 +1471,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2261:10:3", + "src": "2261:10:4", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1479,12 +1479,12 @@ }, { "argumentTypes": null, - "id": 450, + "id": 526, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 407, - "src": "2273:9:3", + "referencedDeclaration": 483, + "src": "2273:9:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1492,12 +1492,12 @@ }, { "argumentTypes": null, - "id": 451, + "id": 527, "name": "token_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 437, - "src": "2284:12:3", + "referencedDeclaration": 513, + "src": "2284:12:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1519,18 +1519,18 @@ "typeString": "uint256" } ], - "id": 447, + "id": 523, "name": "ethToToken", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 347, - "src": "2250:10:3", + "referencedDeclaration": 423, + "src": "2250:10:4", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256)" } }, - "id": 452, + "id": 528, "isConstant": false, "isLValue": false, "isPure": false, @@ -1538,43 +1538,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2250:47:3", + "src": "2250:47:4", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 453, + "id": 529, "nodeType": "EmitStatement", - "src": "2245:52:3" + "src": "2245:52:4" }, { "assignments": [ - 455 + 531 ], "declarations": [ { "constant": false, - "id": 455, + "id": 531, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 479, - "src": "2370:31:3", + "scope": 555, + "src": "2370:31:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 454, + "id": 530, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "2370:15:3", + "referencedDeclaration": 920, + "src": "2370:15:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -1582,18 +1582,18 @@ "visibility": "internal" } ], - "id": 459, + "id": 535, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 457, + "id": 533, "name": "uniSwapExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 405, - "src": "2420:22:3", + "referencedDeclaration": 481, + "src": "2420:22:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1607,18 +1607,18 @@ "typeString": "address" } ], - "id": 456, + "id": 532, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "2404:15:3", + "referencedDeclaration": 920, + "src": "2404:15:4", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 458, + "id": 534, "isConstant": false, "isLValue": false, "isPure": false, @@ -1626,27 +1626,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2404:39:3", + "src": "2404:39:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "2370:73:3" + "src": "2370:73:4" }, { "assignments": [ - 461 + 537 ], "declarations": [ { "constant": false, - "id": 461, + "id": 537, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 479, - "src": "2449:19:3", + "scope": 555, + "src": "2449:19:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1654,10 +1654,10 @@ "typeString": "uint256" }, "typeName": { - "id": 460, + "id": 536, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2449:7:3", + "src": "2449:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1667,18 +1667,18 @@ "visibility": "internal" } ], - "id": 470, + "id": 546, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 464, + "id": 540, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 413, - "src": "2512:8:3", + "referencedDeclaration": 489, + "src": "2512:8:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1686,12 +1686,12 @@ }, { "argumentTypes": null, - "id": 465, + "id": 541, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 409, - "src": "2522:13:3", + "referencedDeclaration": 485, + "src": "2522:13:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1699,12 +1699,12 @@ }, { "argumentTypes": null, - "id": 466, + "id": 542, "name": "sellDeadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 411, - "src": "2537:12:3", + "referencedDeclaration": 487, + "src": "2537:12:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1714,18 +1714,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 467, + "id": 543, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2551:3:3", + "referencedDeclaration": 12128, + "src": "2551:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 468, + "id": 544, "isConstant": false, "isLValue": false, "isPure": false, @@ -1733,7 +1733,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2551:10:3", + "src": "2551:10:4", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1761,32 +1761,32 @@ ], "expression": { "argumentTypes": null, - "id": 462, + "id": 538, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 455, - "src": "2471:15:3", + "referencedDeclaration": 531, + "src": "2471:15:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 463, + "id": 539, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "tokenToEthTransferOutput", "nodeType": "MemberAccess", - "referencedDeclaration": 839, - "src": "2471:40:3", + "referencedDeclaration": 915, + "src": "2471:40:4", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_payable_$returns$_t_uint256_$", "typeString": "function (uint256,uint256,uint256,address payable) external returns (uint256)" } }, - "id": 469, + "id": 545, "isConstant": false, "isLValue": false, "isPure": false, @@ -1794,14 +1794,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2471:91:3", + "src": "2471:91:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2449:113:3" + "src": "2449:113:4" }, { "eventCall": { @@ -1811,18 +1811,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 472, + "id": 548, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2584:3:3", + "referencedDeclaration": 12128, + "src": "2584:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 473, + "id": 549, "isConstant": false, "isLValue": false, "isPure": false, @@ -1830,7 +1830,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2584:10:3", + "src": "2584:10:4", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1838,12 +1838,12 @@ }, { "argumentTypes": null, - "id": 474, + "id": 550, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 413, - "src": "2596:8:3", + "referencedDeclaration": 489, + "src": "2596:8:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1851,12 +1851,12 @@ }, { "argumentTypes": null, - "id": 475, + "id": 551, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 409, - "src": "2606:13:3", + "referencedDeclaration": 485, + "src": "2606:13:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1864,12 +1864,12 @@ }, { "argumentTypes": null, - "id": 476, + "id": 552, "name": "tokens_sold", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 461, - "src": "2621:11:3", + "referencedDeclaration": 537, + "src": "2621:11:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1895,18 +1895,18 @@ "typeString": "uint256" } ], - "id": 471, + "id": 547, "name": "tokenToEth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 357, - "src": "2573:10:3", + "referencedDeclaration": 433, + "src": "2573:10:4", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 477, + "id": 553, "isConstant": false, "isLValue": false, "isPure": false, @@ -1914,36 +1914,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2573:60:3", + "src": "2573:60:4", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 478, + "id": 554, "nodeType": "EmitStatement", - "src": "2568:65:3" + "src": "2568:65:4" } ] }, "documentation": "@dev Executes trade.\n@param kyberExchangeAddress Kyber network address\n@param tokenAddress Address of the token that is being traded\n@param kyberMinConversionRate Min conversion rate for Kyber\n@param uniSwapExchangeAddress UniSwap exchange address\n@param ethToSell Amount of Eth that is being traded via Kyber. Should be sent as value too.\n@param maxTokensSell Maximum ERC20 tokens sold in Uniswap trade.\n@param sellDeadline Uniswap transaction deadline.\n@param ethToBuy Amount of Eth bought in Uniswap trade.", - "id": 480, + "id": 556, "implemented": true, "kind": "function", "modifiers": [], "name": "trade", "nodeType": "FunctionDefinition", "parameters": { - "id": 414, + "id": 490, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 399, + "id": 475, "name": "kyberExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1624:28:3", + "scope": 556, + "src": "1624:28:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1951,10 +1951,10 @@ "typeString": "address" }, "typeName": { - "id": 398, + "id": 474, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1624:7:3", + "src": "1624:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1966,11 +1966,11 @@ }, { "constant": false, - "id": 401, + "id": 477, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1658:20:3", + "scope": 556, + "src": "1658:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1978,10 +1978,10 @@ "typeString": "address" }, "typeName": { - "id": 400, + "id": 476, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1658:7:3", + "src": "1658:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1993,11 +1993,11 @@ }, { "constant": false, - "id": 403, + "id": 479, "name": "kyberMinConversionRate", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1684:30:3", + "scope": 556, + "src": "1684:30:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2005,10 +2005,10 @@ "typeString": "uint256" }, "typeName": { - "id": 402, + "id": 478, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1684:7:3", + "src": "1684:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2019,11 +2019,11 @@ }, { "constant": false, - "id": 405, + "id": 481, "name": "uniSwapExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1720:30:3", + "scope": 556, + "src": "1720:30:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2031,10 +2031,10 @@ "typeString": "address" }, "typeName": { - "id": 404, + "id": 480, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1720:7:3", + "src": "1720:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2046,11 +2046,11 @@ }, { "constant": false, - "id": 407, + "id": 483, "name": "ethToSell", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1756:17:3", + "scope": 556, + "src": "1756:17:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2058,10 +2058,10 @@ "typeString": "uint256" }, "typeName": { - "id": 406, + "id": 482, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1756:7:3", + "src": "1756:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2072,11 +2072,11 @@ }, { "constant": false, - "id": 409, + "id": 485, "name": "maxTokensSell", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1779:21:3", + "scope": 556, + "src": "1779:21:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2084,10 +2084,10 @@ "typeString": "uint256" }, "typeName": { - "id": 408, + "id": 484, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1779:7:3", + "src": "1779:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2098,11 +2098,11 @@ }, { "constant": false, - "id": 411, + "id": 487, "name": "sellDeadline", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1806:20:3", + "scope": 556, + "src": "1806:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2110,10 +2110,10 @@ "typeString": "uint256" }, "typeName": { - "id": 410, + "id": 486, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1806:7:3", + "src": "1806:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2124,11 +2124,11 @@ }, { "constant": false, - "id": 413, + "id": 489, "name": "ethToBuy", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1832:16:3", + "scope": 556, + "src": "1832:16:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2136,10 +2136,10 @@ "typeString": "uint256" }, "typeName": { - "id": 412, + "id": 488, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1832:7:3", + "src": "1832:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2149,39 +2149,39 @@ "visibility": "internal" } ], - "src": "1618:234:3" + "src": "1618:234:4" }, "returnParameters": { - "id": 415, + "id": 491, "nodeType": "ParameterList", "parameters": [], - "src": "1874:0:3" + "src": "1874:0:4" }, - "scope": 481, - "src": "1604:1034:3", + "scope": 557, + "src": "1604:1034:4", "stateMutability": "payable", "superFunction": null, "visibility": "public" } ], - "scope": 482, - "src": "119:2521:3" + "scope": 558, + "src": "119:2521:4" } ], - "src": "0:2641:3" + "src": "0:2641:4" }, "legacyAST": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/KyberUniArbContract.sol", "exportedSymbols": { "KyberUniArbContract": [ - 481 + 557 ] }, - "id": 482, + "id": 558, "nodeType": "SourceUnit", "nodes": [ { - "id": 334, + "id": 410, "literals": [ "solidity", "^", @@ -2189,38 +2189,38 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:3" + "src": "0:23:4" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol", "file": "./UniswapExchange.sol", - "id": 335, + "id": 411, "nodeType": "ImportDirective", - "scope": 482, - "sourceUnit": 845, - "src": "25:31:3", + "scope": 558, + "sourceUnit": 921, + "src": "25:31:4", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/ERC20Token.sol", "file": "./ERC20Token.sol", - "id": 336, + "id": 412, "nodeType": "ImportDirective", - "scope": 482, + "scope": 558, "sourceUnit": 6, - "src": "57:26:3", + "src": "57:26:4", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/KyberNetworkProxy.sol", "file": "./KyberNetworkProxy.sol", - "id": 337, + "id": 413, "nodeType": "ImportDirective", - "scope": 482, - "sourceUnit": 86, - "src": "84:33:3", + "scope": 558, + "sourceUnit": 162, + "src": "84:33:4", "symbolAliases": [], "unitAlias": "" }, @@ -2230,20 +2230,20 @@ "contractKind": "contract", "documentation": null, "fullyImplemented": true, - "id": 481, + "id": 557, "linearizedBaseContracts": [ - 481 + 557 ], "name": "KyberUniArbContract", "nodeType": "ContractDefinition", "nodes": [ { "constant": false, - "id": 339, + "id": 415, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 481, - "src": "208:20:3", + "scope": 557, + "src": "208:20:4", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -2251,10 +2251,10 @@ "typeString": "address" }, "typeName": { - "id": 338, + "id": 414, "name": "address", "nodeType": "ElementaryTypeName", - "src": "208:7:3", + "src": "208:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2267,21 +2267,21 @@ { "anonymous": false, "documentation": null, - "id": 347, + "id": 423, "name": "ethToToken", "nodeType": "EventDefinition", "parameters": { - "id": 346, + "id": 422, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 341, + "id": 417, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 347, - "src": "262:14:3", + "scope": 423, + "src": "262:14:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2289,10 +2289,10 @@ "typeString": "address" }, "typeName": { - "id": 340, + "id": 416, "name": "address", "nodeType": "ElementaryTypeName", - "src": "262:7:3", + "src": "262:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2304,12 +2304,12 @@ }, { "constant": false, - "id": 343, + "id": 419, "indexed": false, "name": "tokens", "nodeType": "VariableDeclaration", - "scope": 347, - "src": "278:14:3", + "scope": 423, + "src": "278:14:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2317,10 +2317,10 @@ "typeString": "uint256" }, "typeName": { - "id": 342, + "id": 418, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "278:7:3", + "src": "278:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2331,12 +2331,12 @@ }, { "constant": false, - "id": 345, + "id": 421, "indexed": false, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 347, - "src": "294:20:3", + "scope": 423, + "src": "294:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2344,10 +2344,10 @@ "typeString": "uint256" }, "typeName": { - "id": 344, + "id": 420, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "294:7:3", + "src": "294:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2357,28 +2357,28 @@ "visibility": "internal" } ], - "src": "261:54:3" + "src": "261:54:4" }, - "src": "245:71:3" + "src": "245:71:4" }, { "anonymous": false, "documentation": null, - "id": 357, + "id": 433, "name": "tokenToEth", "nodeType": "EventDefinition", "parameters": { - "id": 356, + "id": 432, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 349, + "id": 425, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 357, - "src": "336:14:3", + "scope": 433, + "src": "336:14:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2386,10 +2386,10 @@ "typeString": "address" }, "typeName": { - "id": 348, + "id": 424, "name": "address", "nodeType": "ElementaryTypeName", - "src": "336:7:3", + "src": "336:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2401,12 +2401,12 @@ }, { "constant": false, - "id": 351, + "id": 427, "indexed": false, "name": "ethToBuy", "nodeType": "VariableDeclaration", - "scope": 357, - "src": "352:16:3", + "scope": 433, + "src": "352:16:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2414,10 +2414,10 @@ "typeString": "uint256" }, "typeName": { - "id": 350, + "id": 426, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "352:7:3", + "src": "352:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2428,12 +2428,12 @@ }, { "constant": false, - "id": 353, + "id": 429, "indexed": false, "name": "maxTokensSell", "nodeType": "VariableDeclaration", - "scope": 357, - "src": "370:21:3", + "scope": 433, + "src": "370:21:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2441,10 +2441,10 @@ "typeString": "uint256" }, "typeName": { - "id": 352, + "id": 428, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "370:7:3", + "src": "370:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2455,12 +2455,12 @@ }, { "constant": false, - "id": 355, + "id": 431, "indexed": false, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 357, - "src": "393:19:3", + "scope": 433, + "src": "393:19:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2468,10 +2468,10 @@ "typeString": "uint256" }, "typeName": { - "id": 354, + "id": 430, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "393:7:3", + "src": "393:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2481,32 +2481,32 @@ "visibility": "internal" } ], - "src": "335:78:3" + "src": "335:78:4" }, - "src": "319:95:3" + "src": "319:95:4" }, { "body": { - "id": 365, + "id": 441, "nodeType": "Block", - "src": "518:29:3", + "src": "518:29:4", "statements": [ { "expression": { "argumentTypes": null, - "id": 363, + "id": 439, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 360, + "id": 436, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 339, - "src": "524:5:3", + "referencedDeclaration": 415, + "src": "524:5:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2518,18 +2518,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 361, + "id": 437, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "532:3:3", + "referencedDeclaration": 12128, + "src": "532:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 362, + "id": 438, "isConstant": false, "isLValue": false, "isPure": false, @@ -2537,54 +2537,54 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "532:10:3", + "src": "532:10:4", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "524:18:3", + "src": "524:18:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 364, + "id": 440, "nodeType": "ExpressionStatement", - "src": "524:18:3" + "src": "524:18:4" } ] }, "documentation": "@dev Contract constructor. Set owner of contract as deployer.", - "id": 366, + "id": 442, "implemented": true, "kind": "constructor", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "parameters": { - "id": 358, + "id": 434, "nodeType": "ParameterList", "parameters": [], - "src": "508:2:3" + "src": "508:2:4" }, "returnParameters": { - "id": 359, + "id": 435, "nodeType": "ParameterList", "parameters": [], - "src": "518:0:3" + "src": "518:0:4" }, - "scope": 481, - "src": "497:50:3", + "scope": 557, + "src": "497:50:4", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 396, + "id": 472, "nodeType": "Block", - "src": "875:158:3", + "src": "875:158:4", "statements": [ { "expression": { @@ -2596,7 +2596,7 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 379, + "id": 455, "isConstant": false, "isLValue": false, "isPure": false, @@ -2605,18 +2605,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 376, + "id": 452, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "889:3:3", + "referencedDeclaration": 12128, + "src": "889:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 377, + "id": 453, "isConstant": false, "isLValue": false, "isPure": false, @@ -2624,7 +2624,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "889:10:3", + "src": "889:10:4", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -2634,18 +2634,18 @@ "operator": "==", "rightExpression": { "argumentTypes": null, - "id": 378, + "id": 454, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 339, - "src": "903:5:3", + "referencedDeclaration": 415, + "src": "903:5:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "src": "889:19:3", + "src": "889:19:4", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -2654,14 +2654,14 @@ { "argumentTypes": null, "hexValue": "4f6e6c79204f776e65722043616e20417070726f7665", - "id": 380, + "id": 456, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "910:24:3", + "src": "910:24:4", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_ec0b1a840a8a6c4384575556c3817abb58aac6b2bc4e7741e1c712be8067937e", @@ -2681,21 +2681,21 @@ "typeString": "literal_string \"Only Owner Can Approve\"" } ], - "id": 375, + "id": 451, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "881:7:3", + "referencedDeclaration": 12132, + "src": "881:7:4", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 381, + "id": 457, "isConstant": false, "isLValue": false, "isPure": false, @@ -2703,28 +2703,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "881:54:3", + "src": "881:54:4", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 382, + "id": 458, "nodeType": "ExpressionStatement", - "src": "881:54:3" + "src": "881:54:4" }, { "assignments": [ - 384 + 460 ], "declarations": [ { "constant": false, - "id": 384, + "id": 460, "name": "token", "nodeType": "VariableDeclaration", - "scope": 396, - "src": "941:16:3", + "scope": 472, + "src": "941:16:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2733,11 +2733,11 @@ }, "typeName": { "contractScope": null, - "id": 383, + "id": 459, "name": "ERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 5, - "src": "941:10:3", + "src": "941:10:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" @@ -2747,18 +2747,18 @@ "visibility": "internal" } ], - "id": 388, + "id": 464, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 386, + "id": 462, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 368, - "src": "971:12:3", + "referencedDeclaration": 444, + "src": "971:12:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2772,18 +2772,18 @@ "typeString": "address" } ], - "id": 385, + "id": 461, "name": "ERC20Token", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, - "src": "960:10:3", + "src": "960:10:4", "typeDescriptions": { "typeIdentifier": "t_type$_t_contract$_ERC20Token_$5_$", "typeString": "type(contract ERC20Token)" } }, - "id": 387, + "id": 463, "isConstant": false, "isLValue": false, "isPure": false, @@ -2791,14 +2791,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "960:24:3", + "src": "960:24:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" } }, "nodeType": "VariableDeclarationStatement", - "src": "941:43:3" + "src": "941:43:4" }, { "expression": { @@ -2806,12 +2806,12 @@ "arguments": [ { "argumentTypes": null, - "id": 392, + "id": 468, "name": "exchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 370, - "src": "1004:15:3", + "referencedDeclaration": 446, + "src": "1004:15:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2819,12 +2819,12 @@ }, { "argumentTypes": null, - "id": 393, + "id": 469, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 372, - "src": "1021:6:3", + "referencedDeclaration": 448, + "src": "1021:6:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2844,32 +2844,32 @@ ], "expression": { "argumentTypes": null, - "id": 389, + "id": 465, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 384, - "src": "990:5:3", + "referencedDeclaration": 460, + "src": "990:5:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" } }, - "id": 391, + "id": 467, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "approve", "nodeType": "MemberAccess", - "referencedDeclaration": 1072, - "src": "990:13:3", + "referencedDeclaration": 10555, + "src": "990:13:4", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,uint256) external returns (bool)" } }, - "id": 394, + "id": 470, "isConstant": false, "isLValue": false, "isPure": false, @@ -2877,36 +2877,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "990:38:3", + "src": "990:38:4", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, - "id": 395, + "id": 471, "nodeType": "ExpressionStatement", - "src": "990:38:3" + "src": "990:38:4" } ] }, "documentation": "@dev Approves UniSwap exchange to transfer tokens from contract.\n@param tokenAddress Address of the token to approve\n@param exchangeAddress UniSwap Exchange address\n@param amount Token amount to approve", - "id": 397, + "id": 473, "implemented": true, "kind": "function", "modifiers": [], "name": "approveToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 373, + "id": 449, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 368, + "id": 444, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 397, - "src": "808:20:3", + "scope": 473, + "src": "808:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2914,10 +2914,10 @@ "typeString": "address" }, "typeName": { - "id": 367, + "id": 443, "name": "address", "nodeType": "ElementaryTypeName", - "src": "808:7:3", + "src": "808:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2929,11 +2929,11 @@ }, { "constant": false, - "id": 370, + "id": 446, "name": "exchangeAddress", "nodeType": "VariableDeclaration", - "scope": 397, - "src": "830:23:3", + "scope": 473, + "src": "830:23:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2941,10 +2941,10 @@ "typeString": "address" }, "typeName": { - "id": 369, + "id": 445, "name": "address", "nodeType": "ElementaryTypeName", - "src": "830:7:3", + "src": "830:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2956,11 +2956,11 @@ }, { "constant": false, - "id": 372, + "id": 448, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 397, - "src": "855:11:3", + "scope": 473, + "src": "855:11:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2968,10 +2968,10 @@ "typeString": "uint256" }, "typeName": { - "id": 371, + "id": 447, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "855:4:3", + "src": "855:4:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2981,25 +2981,25 @@ "visibility": "internal" } ], - "src": "807:60:3" + "src": "807:60:4" }, "returnParameters": { - "id": 374, + "id": 450, "nodeType": "ParameterList", "parameters": [], - "src": "875:0:3" + "src": "875:0:4" }, - "scope": 481, - "src": "786:247:3", + "scope": 557, + "src": "786:247:4", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 479, + "id": 555, "nodeType": "Block", - "src": "1874:764:3", + "src": "1874:764:4", "statements": [ { "expression": { @@ -3011,7 +3011,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 420, + "id": 496, "isConstant": false, "isLValue": false, "isPure": false, @@ -3020,18 +3020,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 417, + "id": 493, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1888:3:3", + "referencedDeclaration": 12128, + "src": "1888:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 418, + "id": 494, "isConstant": false, "isLValue": false, "isPure": false, @@ -3039,7 +3039,7 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1888:9:3", + "src": "1888:9:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3049,18 +3049,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 419, + "id": 495, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 407, - "src": "1901:9:3", + "referencedDeclaration": 483, + "src": "1901:9:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "1888:22:3", + "src": "1888:22:4", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -3069,14 +3069,14 @@ { "argumentTypes": null, "hexValue": "4e6f7420456e6f756768204574682053656e74", - "id": 421, + "id": 497, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "1912:21:3", + "src": "1912:21:4", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30b29beae4cdbb7acc80a8e1229a071d1d9114e20038f0c713ecf8dbdd0dcc4e", @@ -3096,21 +3096,21 @@ "typeString": "literal_string \"Not Enough Eth Sent\"" } ], - "id": 416, + "id": 492, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "1880:7:3", + "referencedDeclaration": 12132, + "src": "1880:7:4", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 422, + "id": 498, "isConstant": false, "isLValue": false, "isPure": false, @@ -3118,43 +3118,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1880:54:3", + "src": "1880:54:4", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 423, + "id": 499, "nodeType": "ExpressionStatement", - "src": "1880:54:3" + "src": "1880:54:4" }, { "assignments": [ - 425 + 501 ], "declarations": [ { "constant": false, - "id": 425, + "id": 501, "name": "kyberExchange", "nodeType": "VariableDeclaration", - "scope": 479, - "src": "1963:31:3", + "scope": 555, + "src": "1963:31:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" }, "typeName": { "contractScope": null, - "id": 424, + "id": 500, "name": "KyberNetworkProxy", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 85, - "src": "1963:17:3", + "referencedDeclaration": 161, + "src": "1963:17:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, @@ -3162,18 +3162,18 @@ "visibility": "internal" } ], - "id": 429, + "id": 505, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 427, + "id": 503, "name": "kyberExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 399, - "src": "2015:20:3", + "referencedDeclaration": 475, + "src": "2015:20:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3187,18 +3187,18 @@ "typeString": "address" } ], - "id": 426, + "id": 502, "name": "KyberNetworkProxy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 85, - "src": "1997:17:3", + "referencedDeclaration": 161, + "src": "1997:17:4", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$85_$", + "typeIdentifier": "t_type$_t_contract$_KyberNetworkProxy_$161_$", "typeString": "type(contract KyberNetworkProxy)" } }, - "id": 428, + "id": 504, "isConstant": false, "isLValue": false, "isPure": false, @@ -3206,27 +3206,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1997:39:3", + "src": "1997:39:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, "nodeType": "VariableDeclarationStatement", - "src": "1963:73:3" + "src": "1963:73:4" }, { "assignments": [ - 431 + 507 ], "declarations": [ { "constant": false, - "id": 431, + "id": 507, "name": "token", "nodeType": "VariableDeclaration", - "scope": 479, - "src": "2042:16:3", + "scope": 555, + "src": "2042:16:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3235,11 +3235,11 @@ }, "typeName": { "contractScope": null, - "id": 430, + "id": 506, "name": "ERC20Token", "nodeType": "UserDefinedTypeName", "referencedDeclaration": 5, - "src": "2042:10:3", + "src": "2042:10:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" @@ -3249,18 +3249,18 @@ "visibility": "internal" } ], - "id": 435, + "id": 511, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 433, + "id": 509, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 401, - "src": "2072:12:3", + "referencedDeclaration": 477, + "src": "2072:12:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3274,18 +3274,18 @@ "typeString": "address" } ], - "id": 432, + "id": 508, "name": "ERC20Token", "nodeType": "Identifier", "overloadedDeclarations": [], "referencedDeclaration": 5, - "src": "2061:10:3", + "src": "2061:10:4", "typeDescriptions": { "typeIdentifier": "t_type$_t_contract$_ERC20Token_$5_$", "typeString": "type(contract ERC20Token)" } }, - "id": 434, + "id": 510, "isConstant": false, "isLValue": false, "isPure": false, @@ -3293,27 +3293,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2061:24:3", + "src": "2061:24:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" } }, "nodeType": "VariableDeclarationStatement", - "src": "2042:43:3" + "src": "2042:43:4" }, { "assignments": [ - 437 + 513 ], "declarations": [ { "constant": false, - "id": 437, + "id": 513, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 479, - "src": "2138:20:3", + "scope": 555, + "src": "2138:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3321,10 +3321,10 @@ "typeString": "uint256" }, "typeName": { - "id": 436, + "id": 512, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2138:7:3", + "src": "2138:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3334,18 +3334,18 @@ "visibility": "internal" } ], - "id": 446, + "id": 522, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 443, + "id": 519, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 431, - "src": "2209:5:3", + "referencedDeclaration": 507, + "src": "2209:5:4", "typeDescriptions": { "typeIdentifier": "t_contract$_ERC20Token_$5", "typeString": "contract ERC20Token" @@ -3353,12 +3353,12 @@ }, { "argumentTypes": null, - "id": 444, + "id": 520, "name": "kyberMinConversionRate", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 403, - "src": "2216:22:3", + "referencedDeclaration": 479, + "src": "2216:22:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3379,12 +3379,12 @@ "arguments": [ { "argumentTypes": null, - "id": 441, + "id": 517, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 407, - "src": "2198:9:3", + "referencedDeclaration": 483, + "src": "2198:9:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3402,32 +3402,32 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 438, + "id": 514, "name": "kyberExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 425, - "src": "2161:13:3", + "referencedDeclaration": 501, + "src": "2161:13:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_KyberNetworkProxy_$85", + "typeIdentifier": "t_contract$_KyberNetworkProxy_$161", "typeString": "contract KyberNetworkProxy" } }, - "id": 439, + "id": 515, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "swapEtherToToken", "nodeType": "MemberAccess", - "referencedDeclaration": 84, - "src": "2161:30:3", + "referencedDeclaration": 160, + "src": "2161:30:4", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 440, + "id": 516, "isConstant": false, "isLValue": false, "isPure": false, @@ -3435,13 +3435,13 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2161:36:3", + "src": "2161:36:4", "typeDescriptions": { - "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value_$", + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value_$", "typeString": "function (uint256) returns (function (contract ERC20,uint256) payable external returns (uint256))" } }, - "id": 442, + "id": 518, "isConstant": false, "isLValue": false, "isPure": false, @@ -3449,13 +3449,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2161:47:3", + "src": "2161:47:4", "typeDescriptions": { - "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$1374_$_t_uint256_$returns$_t_uint256_$value", + "typeIdentifier": "t_function_external_payable$_t_contract$_ERC20_$10857_$_t_uint256_$returns$_t_uint256_$value", "typeString": "function (contract ERC20,uint256) payable external returns (uint256)" } }, - "id": 445, + "id": 521, "isConstant": false, "isLValue": false, "isPure": false, @@ -3463,14 +3463,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2161:78:3", + "src": "2161:78:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2138:101:3" + "src": "2138:101:4" }, { "eventCall": { @@ -3480,18 +3480,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 448, + "id": 524, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2261:3:3", + "referencedDeclaration": 12128, + "src": "2261:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 449, + "id": 525, "isConstant": false, "isLValue": false, "isPure": false, @@ -3499,7 +3499,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2261:10:3", + "src": "2261:10:4", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -3507,12 +3507,12 @@ }, { "argumentTypes": null, - "id": 450, + "id": 526, "name": "ethToSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 407, - "src": "2273:9:3", + "referencedDeclaration": 483, + "src": "2273:9:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3520,12 +3520,12 @@ }, { "argumentTypes": null, - "id": 451, + "id": 527, "name": "token_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 437, - "src": "2284:12:3", + "referencedDeclaration": 513, + "src": "2284:12:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3547,18 +3547,18 @@ "typeString": "uint256" } ], - "id": 447, + "id": 523, "name": "ethToToken", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 347, - "src": "2250:10:3", + "referencedDeclaration": 423, + "src": "2250:10:4", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256)" } }, - "id": 452, + "id": 528, "isConstant": false, "isLValue": false, "isPure": false, @@ -3566,43 +3566,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2250:47:3", + "src": "2250:47:4", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 453, + "id": 529, "nodeType": "EmitStatement", - "src": "2245:52:3" + "src": "2245:52:4" }, { "assignments": [ - 455 + 531 ], "declarations": [ { "constant": false, - "id": 455, + "id": 531, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 479, - "src": "2370:31:3", + "scope": 555, + "src": "2370:31:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 454, + "id": 530, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "2370:15:3", + "referencedDeclaration": 920, + "src": "2370:15:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -3610,18 +3610,18 @@ "visibility": "internal" } ], - "id": 459, + "id": 535, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 457, + "id": 533, "name": "uniSwapExchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 405, - "src": "2420:22:3", + "referencedDeclaration": 481, + "src": "2420:22:4", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3635,18 +3635,18 @@ "typeString": "address" } ], - "id": 456, + "id": 532, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "2404:15:3", + "referencedDeclaration": 920, + "src": "2404:15:4", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 458, + "id": 534, "isConstant": false, "isLValue": false, "isPure": false, @@ -3654,27 +3654,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2404:39:3", + "src": "2404:39:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "2370:73:3" + "src": "2370:73:4" }, { "assignments": [ - 461 + 537 ], "declarations": [ { "constant": false, - "id": 461, + "id": 537, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 479, - "src": "2449:19:3", + "scope": 555, + "src": "2449:19:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3682,10 +3682,10 @@ "typeString": "uint256" }, "typeName": { - "id": 460, + "id": 536, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2449:7:3", + "src": "2449:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3695,18 +3695,18 @@ "visibility": "internal" } ], - "id": 470, + "id": 546, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 464, + "id": 540, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 413, - "src": "2512:8:3", + "referencedDeclaration": 489, + "src": "2512:8:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3714,12 +3714,12 @@ }, { "argumentTypes": null, - "id": 465, + "id": 541, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 409, - "src": "2522:13:3", + "referencedDeclaration": 485, + "src": "2522:13:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3727,12 +3727,12 @@ }, { "argumentTypes": null, - "id": 466, + "id": 542, "name": "sellDeadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 411, - "src": "2537:12:3", + "referencedDeclaration": 487, + "src": "2537:12:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3742,18 +3742,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 467, + "id": 543, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2551:3:3", + "referencedDeclaration": 12128, + "src": "2551:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 468, + "id": 544, "isConstant": false, "isLValue": false, "isPure": false, @@ -3761,7 +3761,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2551:10:3", + "src": "2551:10:4", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -3789,32 +3789,32 @@ ], "expression": { "argumentTypes": null, - "id": 462, + "id": 538, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 455, - "src": "2471:15:3", + "referencedDeclaration": 531, + "src": "2471:15:4", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 463, + "id": 539, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "tokenToEthTransferOutput", "nodeType": "MemberAccess", - "referencedDeclaration": 839, - "src": "2471:40:3", + "referencedDeclaration": 915, + "src": "2471:40:4", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_payable_$returns$_t_uint256_$", "typeString": "function (uint256,uint256,uint256,address payable) external returns (uint256)" } }, - "id": 469, + "id": 545, "isConstant": false, "isLValue": false, "isPure": false, @@ -3822,14 +3822,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2471:91:3", + "src": "2471:91:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2449:113:3" + "src": "2449:113:4" }, { "eventCall": { @@ -3839,18 +3839,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 472, + "id": 548, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2584:3:3", + "referencedDeclaration": 12128, + "src": "2584:3:4", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 473, + "id": 549, "isConstant": false, "isLValue": false, "isPure": false, @@ -3858,7 +3858,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2584:10:3", + "src": "2584:10:4", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -3866,12 +3866,12 @@ }, { "argumentTypes": null, - "id": 474, + "id": 550, "name": "ethToBuy", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 413, - "src": "2596:8:3", + "referencedDeclaration": 489, + "src": "2596:8:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3879,12 +3879,12 @@ }, { "argumentTypes": null, - "id": 475, + "id": 551, "name": "maxTokensSell", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 409, - "src": "2606:13:3", + "referencedDeclaration": 485, + "src": "2606:13:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3892,12 +3892,12 @@ }, { "argumentTypes": null, - "id": 476, + "id": 552, "name": "tokens_sold", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 461, - "src": "2621:11:3", + "referencedDeclaration": 537, + "src": "2621:11:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3923,18 +3923,18 @@ "typeString": "uint256" } ], - "id": 471, + "id": 547, "name": "tokenToEth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 357, - "src": "2573:10:3", + "referencedDeclaration": 433, + "src": "2573:10:4", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 477, + "id": 553, "isConstant": false, "isLValue": false, "isPure": false, @@ -3942,36 +3942,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2573:60:3", + "src": "2573:60:4", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 478, + "id": 554, "nodeType": "EmitStatement", - "src": "2568:65:3" + "src": "2568:65:4" } ] }, "documentation": "@dev Executes trade.\n@param kyberExchangeAddress Kyber network address\n@param tokenAddress Address of the token that is being traded\n@param kyberMinConversionRate Min conversion rate for Kyber\n@param uniSwapExchangeAddress UniSwap exchange address\n@param ethToSell Amount of Eth that is being traded via Kyber. Should be sent as value too.\n@param maxTokensSell Maximum ERC20 tokens sold in Uniswap trade.\n@param sellDeadline Uniswap transaction deadline.\n@param ethToBuy Amount of Eth bought in Uniswap trade.", - "id": 480, + "id": 556, "implemented": true, "kind": "function", "modifiers": [], "name": "trade", "nodeType": "FunctionDefinition", "parameters": { - "id": 414, + "id": 490, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 399, + "id": 475, "name": "kyberExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1624:28:3", + "scope": 556, + "src": "1624:28:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3979,10 +3979,10 @@ "typeString": "address" }, "typeName": { - "id": 398, + "id": 474, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1624:7:3", + "src": "1624:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3994,11 +3994,11 @@ }, { "constant": false, - "id": 401, + "id": 477, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1658:20:3", + "scope": 556, + "src": "1658:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4006,10 +4006,10 @@ "typeString": "address" }, "typeName": { - "id": 400, + "id": 476, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1658:7:3", + "src": "1658:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -4021,11 +4021,11 @@ }, { "constant": false, - "id": 403, + "id": 479, "name": "kyberMinConversionRate", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1684:30:3", + "scope": 556, + "src": "1684:30:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4033,10 +4033,10 @@ "typeString": "uint256" }, "typeName": { - "id": 402, + "id": 478, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1684:7:3", + "src": "1684:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4047,11 +4047,11 @@ }, { "constant": false, - "id": 405, + "id": 481, "name": "uniSwapExchangeAddress", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1720:30:3", + "scope": 556, + "src": "1720:30:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4059,10 +4059,10 @@ "typeString": "address" }, "typeName": { - "id": 404, + "id": 480, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1720:7:3", + "src": "1720:7:4", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -4074,11 +4074,11 @@ }, { "constant": false, - "id": 407, + "id": 483, "name": "ethToSell", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1756:17:3", + "scope": 556, + "src": "1756:17:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4086,10 +4086,10 @@ "typeString": "uint256" }, "typeName": { - "id": 406, + "id": 482, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1756:7:3", + "src": "1756:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4100,11 +4100,11 @@ }, { "constant": false, - "id": 409, + "id": 485, "name": "maxTokensSell", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1779:21:3", + "scope": 556, + "src": "1779:21:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4112,10 +4112,10 @@ "typeString": "uint256" }, "typeName": { - "id": 408, + "id": 484, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1779:7:3", + "src": "1779:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4126,11 +4126,11 @@ }, { "constant": false, - "id": 411, + "id": 487, "name": "sellDeadline", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1806:20:3", + "scope": 556, + "src": "1806:20:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4138,10 +4138,10 @@ "typeString": "uint256" }, "typeName": { - "id": 410, + "id": 486, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1806:7:3", + "src": "1806:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4152,11 +4152,11 @@ }, { "constant": false, - "id": 413, + "id": 489, "name": "ethToBuy", "nodeType": "VariableDeclaration", - "scope": 480, - "src": "1832:16:3", + "scope": 556, + "src": "1832:16:4", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4164,10 +4164,10 @@ "typeString": "uint256" }, "typeName": { - "id": 412, + "id": 488, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1832:7:3", + "src": "1832:7:4", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4177,26 +4177,26 @@ "visibility": "internal" } ], - "src": "1618:234:3" + "src": "1618:234:4" }, "returnParameters": { - "id": 415, + "id": 491, "nodeType": "ParameterList", "parameters": [], - "src": "1874:0:3" + "src": "1874:0:4" }, - "scope": 481, - "src": "1604:1034:3", + "scope": 557, + "src": "1604:1034:4", "stateMutability": "payable", "superFunction": null, "visibility": "public" } ], - "scope": 482, - "src": "119:2521:3" + "scope": 558, + "src": "119:2521:4" } ], - "src": "0:2641:3" + "src": "0:2641:4" }, "compiler": { "name": "solc", @@ -4204,7 +4204,7 @@ }, "networks": {}, "schemaVersion": "3.0.16", - "updatedAt": "2019-11-04T18:56:07.476Z", + "updatedAt": "2019-11-07T15:21:05.381Z", "devdoc": { "methods": { "approveToken(address,address,uint256)": { diff --git a/client/src/contracts/LendingPool.json b/client/src/contracts/LendingPool.json new file mode 100644 index 0000000..0bf7122 --- /dev/null +++ b/client/src/contracts/LendingPool.json @@ -0,0 +1,51443 @@ +{ + "contractName": "LendingPool", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "addressesProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "name": "_addressesProvider", + "type": "address" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": true, + "name": "_user", + "type": "address" + }, + { + "indexed": false, + "name": "_amount", + "type": "uint256" + }, + { + "indexed": true, + "name": "_referral", + "type": "uint16" + }, + { + "indexed": false, + "name": "timestamp", + "type": "uint256" + } + ], + "name": "Deposit", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": true, + "name": "_user", + "type": "address" + }, + { + "indexed": false, + "name": "_amount", + "type": "uint256" + }, + { + "indexed": false, + "name": "timestamp", + "type": "uint256" + } + ], + "name": "RedeemUnderlying", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": true, + "name": "_user", + "type": "address" + }, + { + "indexed": false, + "name": "_amount", + "type": "uint256" + }, + { + "indexed": true, + "name": "_referral", + "type": "uint16" + }, + { + "indexed": false, + "name": "timestamp", + "type": "uint256" + } + ], + "name": "Borrow", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": true, + "name": "_user", + "type": "address" + }, + { + "indexed": false, + "name": "_amount", + "type": "uint256" + }, + { + "indexed": false, + "name": "timestamp", + "type": "uint256" + } + ], + "name": "Repay", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_collateral", + "type": "address" + }, + { + "indexed": true, + "name": "_user", + "type": "address" + }, + { + "indexed": false, + "name": "_amount", + "type": "uint256" + }, + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": false, + "name": "timestamp", + "type": "uint256" + } + ], + "name": "LiquidationCall", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": true, + "name": "_user", + "type": "address" + }, + { + "indexed": false, + "name": "timestamp", + "type": "uint256" + } + ], + "name": "Swap", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_target", + "type": "address" + }, + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": false, + "name": "_amount", + "type": "uint256" + }, + { + "indexed": false, + "name": "_fee", + "type": "uint256" + }, + { + "indexed": false, + "name": "timestamp", + "type": "uint256" + } + ], + "name": "FlashLoan", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": true, + "name": "_user", + "type": "address" + } + ], + "name": "ReserveUsedAsCollateralEnabled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": true, + "name": "_user", + "type": "address" + } + ], + "name": "ReserveUsedAsCollateralDisabled", + "type": "event" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + }, + { + "name": "_referralCode", + "type": "uint16" + } + ], + "name": "deposit", + "outputs": [], + "payable": true, + "stateMutability": "payable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "redeemUnderlying", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + }, + { + "name": "_interestRateMode", + "type": "uint256" + }, + { + "name": "_referralCode", + "type": "uint16" + } + ], + "name": "borrow", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + }, + { + "name": "_onBehalfOf", + "type": "address" + } + ], + "name": "repay", + "outputs": [], + "payable": true, + "stateMutability": "payable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "swapBorrowRateMode", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "rebalanceFixedBorrowRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_useAsCollateral", + "type": "bool" + } + ], + "name": "setUserUseReserveAsCollateral", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_collateral", + "type": "address" + }, + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_purchaseAmount", + "type": "uint256" + }, + { + "name": "_receiveAToken", + "type": "bool" + } + ], + "name": "liquidationCall", + "outputs": [], + "payable": true, + "stateMutability": "payable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_receiver", + "type": "address" + }, + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "flashLoan", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveConfigurationData", + "outputs": [ + { + "name": "ltv", + "type": "uint256" + }, + { + "name": "liquidationThreshold", + "type": "uint256" + }, + { + "name": "liquidationDiscount", + "type": "uint256" + }, + { + "name": "interestRateStrategyAddress", + "type": "address" + }, + { + "name": "usageAsCollateralEnabled", + "type": "bool" + }, + { + "name": "borrowingEnabled", + "type": "bool" + }, + { + "name": "fixedBorrowRateEnabled", + "type": "bool" + }, + { + "name": "isActive", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveData", + "outputs": [ + { + "name": "totalLiquidity", + "type": "uint256" + }, + { + "name": "availableLiquidity", + "type": "uint256" + }, + { + "name": "totalBorrowsFixed", + "type": "uint256" + }, + { + "name": "totalBorrowsVariable", + "type": "uint256" + }, + { + "name": "liquidityRate", + "type": "uint256" + }, + { + "name": "variableBorrowRate", + "type": "uint256" + }, + { + "name": "fixedBorrowRate", + "type": "uint256" + }, + { + "name": "averageFixedBorrowRate", + "type": "uint256" + }, + { + "name": "utilizationRate", + "type": "uint256" + }, + { + "name": "liquidityIndex", + "type": "uint256" + }, + { + "name": "variableBorrowIndex", + "type": "uint256" + }, + { + "name": "aTokenAddress", + "type": "address" + }, + { + "name": "lastUpdateTimestamp", + "type": "uint40" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserAccountData", + "outputs": [ + { + "name": "totalLiquidityETH", + "type": "uint256" + }, + { + "name": "totalCollateralETH", + "type": "uint256" + }, + { + "name": "totalBorrowsETH", + "type": "uint256" + }, + { + "name": "availableBorrowsETH", + "type": "uint256" + }, + { + "name": "currentLiquidationThreshold", + "type": "uint256" + }, + { + "name": "ltv", + "type": "uint256" + }, + { + "name": "healthFactor", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserReserveData", + "outputs": [ + { + "name": "currentATokenBalance", + "type": "uint256" + }, + { + "name": "currentUnderlyingBalance", + "type": "uint256" + }, + { + "name": "currentBorrowBalance", + "type": "uint256" + }, + { + "name": "principalBorrowBalance", + "type": "uint256" + }, + { + "name": "borrowRateMode", + "type": "uint256" + }, + { + "name": "borrowRate", + "type": "uint256" + }, + { + "name": "liquidityRate", + "type": "uint256" + }, + { + "name": "originationFee", + "type": "uint256" + }, + { + "name": "variableBorrowIndex", + "type": "uint256" + }, + { + "name": "lastUpdateTimestamp", + "type": "uint256" + }, + { + "name": "usageAsCollateralEnabled", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getReserves", + "outputs": [ + { + "name": "", + "type": "address[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_collateral\",\"type\":\"address\"},{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_purchaseAmount\",\"type\":\"uint256\"},{\"name\":\"_receiveAToken\",\"type\":\"bool\"}],\"name\":\"liquidationCall\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getReserves\",\"outputs\":[{\"name\":\"\",\"type\":\"address[]\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserReserveData\",\"outputs\":[{\"name\":\"currentATokenBalance\",\"type\":\"uint256\"},{\"name\":\"currentUnderlyingBalance\",\"type\":\"uint256\"},{\"name\":\"currentBorrowBalance\",\"type\":\"uint256\"},{\"name\":\"principalBorrowBalance\",\"type\":\"uint256\"},{\"name\":\"borrowRateMode\",\"type\":\"uint256\"},{\"name\":\"borrowRate\",\"type\":\"uint256\"},{\"name\":\"liquidityRate\",\"type\":\"uint256\"},{\"name\":\"originationFee\",\"type\":\"uint256\"},{\"name\":\"variableBorrowIndex\",\"type\":\"uint256\"},{\"name\":\"lastUpdateTimestamp\",\"type\":\"uint256\"},{\"name\":\"usageAsCollateralEnabled\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveData\",\"outputs\":[{\"name\":\"totalLiquidity\",\"type\":\"uint256\"},{\"name\":\"availableLiquidity\",\"type\":\"uint256\"},{\"name\":\"totalBorrowsFixed\",\"type\":\"uint256\"},{\"name\":\"totalBorrowsVariable\",\"type\":\"uint256\"},{\"name\":\"liquidityRate\",\"type\":\"uint256\"},{\"name\":\"variableBorrowRate\",\"type\":\"uint256\"},{\"name\":\"fixedBorrowRate\",\"type\":\"uint256\"},{\"name\":\"averageFixedBorrowRate\",\"type\":\"uint256\"},{\"name\":\"utilizationRate\",\"type\":\"uint256\"},{\"name\":\"liquidityIndex\",\"type\":\"uint256\"},{\"name\":\"variableBorrowIndex\",\"type\":\"uint256\"},{\"name\":\"aTokenAddress\",\"type\":\"address\"},{\"name\":\"lastUpdateTimestamp\",\"type\":\"uint40\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveConfigurationData\",\"outputs\":[{\"name\":\"ltv\",\"type\":\"uint256\"},{\"name\":\"liquidationThreshold\",\"type\":\"uint256\"},{\"name\":\"liquidationDiscount\",\"type\":\"uint256\"},{\"name\":\"interestRateStrategyAddress\",\"type\":\"address\"},{\"name\":\"usageAsCollateralEnabled\",\"type\":\"bool\"},{\"name\":\"borrowingEnabled\",\"type\":\"bool\"},{\"name\":\"fixedBorrowRateEnabled\",\"type\":\"bool\"},{\"name\":\"isActive\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"swapBorrowRateMode\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_useAsCollateral\",\"type\":\"bool\"}],\"name\":\"setUserUseReserveAsCollateral\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_onBehalfOf\",\"type\":\"address\"}],\"name\":\"repay\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"rebalanceFixedBorrowRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"redeemUnderlying\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_receiver\",\"type\":\"address\"},{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"flashLoan\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserAccountData\",\"outputs\":[{\"name\":\"totalLiquidityETH\",\"type\":\"uint256\"},{\"name\":\"totalCollateralETH\",\"type\":\"uint256\"},{\"name\":\"totalBorrowsETH\",\"type\":\"uint256\"},{\"name\":\"availableBorrowsETH\",\"type\":\"uint256\"},{\"name\":\"currentLiquidationThreshold\",\"type\":\"uint256\"},{\"name\":\"ltv\",\"type\":\"uint256\"},{\"name\":\"healthFactor\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"addressesProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_interestRateMode\",\"type\":\"uint256\"},{\"name\":\"_referralCode\",\"type\":\"uint16\"}],\"name\":\"borrow\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_referralCode\",\"type\":\"uint16\"}],\"name\":\"deposit\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_addressesProvider\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_user\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":true,\"name\":\"_referral\",\"type\":\"uint16\"},{\"indexed\":false,\"name\":\"timestamp\",\"type\":\"uint256\"}],\"name\":\"Deposit\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_user\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"timestamp\",\"type\":\"uint256\"}],\"name\":\"RedeemUnderlying\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_user\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":true,\"name\":\"_referral\",\"type\":\"uint16\"},{\"indexed\":false,\"name\":\"timestamp\",\"type\":\"uint256\"}],\"name\":\"Borrow\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_user\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"timestamp\",\"type\":\"uint256\"}],\"name\":\"Repay\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_collateral\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_user\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"timestamp\",\"type\":\"uint256\"}],\"name\":\"LiquidationCall\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_user\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"timestamp\",\"type\":\"uint256\"}],\"name\":\"Swap\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_target\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_fee\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"timestamp\",\"type\":\"uint256\"}],\"name\":\"FlashLoan\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"ReserveUsedAsCollateralEnabled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"ReserveUsedAsCollateralDisabled\",\"type\":\"event\"}],\"devdoc\":{\"author\":\"Aave\",\"methods\":{\"getReserveConfigurationData(address)\":{\"details\":\"accessory methods to fetch data from the core contract\"},\"liquidationCall(address,address,address,uint256,bool)\":{\"details\":\"_receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset.\"},\"rebalanceFixedBorrowRate(address,address)\":{\"details\":\"this is regulated by Aave to ensure that the protocol is not abused, and the user is paying a fair rate. Anyone can call this function though.\"},\"redeemUnderlying(address,address,uint256)\":{\"details\":\"only aToken contracts can call this function\"},\"repay(address,uint256,address)\":{\"details\":\"the target user is defined by _onBehalfOf. If there is no repayment on behalf of another account, _onBehalfOf must be equal to msg.sender.\"}},\"title\":\"LendingPool contract\"},\"userdoc\":{\"methods\":{\"borrow(address,uint256,uint256,uint16)\":{\"notice\":\"executes a borrow on the reserve of the specific amount with the interestRateMode specified.\"},\"deposit(address,uint256,uint16)\":{\"notice\":\"deposits The underlying asset into the reserve. A corresponding amount of the overlying asset (aTokens) is minted.\"},\"getReserveConfigurationData(address)\":{\"notice\":\"*************\"},\"liquidationCall(address,address,address,uint256,bool)\":{\"notice\":\"implements loan liquidation\"},\"rebalanceFixedBorrowRate(address,address)\":{\"notice\":\"rebalances the fixed interest rate of a user if current liquidity rate > user fixed rate.\"},\"redeemUnderlying(address,address,uint256)\":{\"notice\":\"Allows to redeem a specific amount of underlying asset.\"},\"repay(address,uint256,address)\":{\"notice\":\"repays a borrow on the specific reserve, for the specified amount.\"},\"setUserUseReserveAsCollateral(address,bool)\":{\"notice\":\"allows user to enable or disable a specific deposit as collateral\"},\"swapBorrowRateMode(address)\":{\"notice\":\"allows the user to swap the current borrow rate mode, from fixed to variable and viceversa.\"}},\"notice\":\"***********************************************************************************Implements the actions of the LendingPool, and exposes accessory methods to access the core information************************************************************************************\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol\":\"LendingPool\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x0ae6004410cd58a1c5151e67959167cf58cd5e77e8b625677826e295905fb318\",\"urls\":[\"bzzr://d223bea23f0e9bd70844e9852f490be93d30fc1c31bf114c807d0e4fe07d929b\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol\":{\"keccak256\":\"0xcd8c22e8b9f5c5c4bdb5b5262beafa93486c3b15262283c053afd423eca6e16b\",\"urls\":[\"bzzr://a9a5076a121f51ea42d9ebddc2684f299a0b57c0321837b5776c3a9eb26be97e\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol\":{\"keccak256\":\"0x479a8627304b58f37a4adbe06a72c7a056ad7ce6793a4ea66deeba04c6e443c8\",\"urls\":[\"bzzr://92bb0ae9b38ab361638c71c81f650ff8115da42cb4f50a0ee7a6fb5e03e5e640\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol\":{\"keccak256\":\"0x3f74e899243a66d556c0fa81875ab95ed1e3af1909b0281d03fe89590b95121f\",\"urls\":[\"bzzr://ef6ed6edeb1ec124bf1749991346f0708214f7e12c353175d36b491bce45d7a4\"]},\"/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol\":{\"keccak256\":\"0x3b825dc98b6a7aa21e9c9b05e1951bec7b5d7c84b7a0e8de0750069ccb31ebac\",\"urls\":[\"bzzr://8a616caca158d63de8db6037a2162c1effaaa71f6d7095a11516e03f7ea391d0\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol\":{\"keccak256\":\"0xdf72f6345d96ca2731656811b508db7f8e4975776d6de39ab24dbe4a13794fd8\",\"urls\":[\"bzzr://687ac9b4f396f264af2645041f5532b6881ec8c92dad3e505ca96477957c784d\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":{\"keccak256\":\"0xeeae2b67fa36103fe1c3a4e346b9c04171f9065949953abd00104c357834b0e3\",\"urls\":[\"bzzr://4e3bd29abfa796726532c3e42dd8039ab0f93388d7bbf358428dbc9b0399664a\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x0adf744884b9262f507aba565d1c96c82397f58d399a2dc2c60a452953197574\",\"urls\":[\"bzzr://03099f88c041565b5ac13ea7e645a8f9bff0c29bfa584c7969372ce12c5473f5\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol\":{\"keccak256\":\"0x35a7f1a34259948cdcb03084718f765215fe69559f557b395d9d6e18c63ac823\",\"urls\":[\"bzzr://f529e265dd06192a1d552f1f41c245790419562dfb52e7be9d443c758ccb72d0\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol\":{\"keccak256\":\"0x3f4ef00886795fb781b76e1fab7ce2f0422de9d0941bc8d5d9c377ad100e9a33\",\"urls\":[\"bzzr://8aff91a48f36ed3d3da74fc48d65cbc20e56e45172790ae38f18e234883ece70\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol\":{\"keccak256\":\"0xca757f989e0e7519d03d4e3086028e3022306ec4bb7f610fa78bff866f04c998\",\"urls\":[\"bzzr://f381f642ecce43d76d9e0011ea3c7c6218d1eaa2e0d3a7d5aecd55552cc0fb27\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol\":{\"keccak256\":\"0xe9e88d47e58f59345bb70a48960878e8b6d7525e3fe4f03c63f575599123957a\",\"urls\":[\"bzzr://ab72dddd7f00500a59b72b7f2f938ca25ae859517d524e446dc92a37f5f4a4e3\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol\":{\"keccak256\":\"0x8cd409571214e2d2f9196b8a31ce04bb44919ce7b12e66301c216c3de70a3f5f\",\"urls\":[\"bzzr://87f2c373a1f51ca84ac1132e72e3ef5a43e7a4f4f10341a63993c2cbdb769b64\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol\":{\"keccak256\":\"0xb8b4844881a9ea5c3f0f2584061efcbfb6c96863ca3a07b960d2f9d323293cac\",\"urls\":[\"bzzr://8cb1c5dcce198c0f60c21bd9807b361fc214a60d4b3aa3442153b045b51a4325\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol\":{\"keccak256\":\"0x547550bb7c7e61190fddae1b4dbe71932c9acdaf1d196524ee99c3340a5bec2d\",\"urls\":[\"bzzr://4a9ee0d136529517d7586cb3842177dbd767d9c34fdb035b0a90e8f4cc4d1b35\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol\":{\"keccak256\":\"0x4a3a810b7ebe742e897e1fd428b3eeed2196d3acea58eaf9c566ed10d545d2ed\",\"urls\":[\"bzzr://729aefb3f89f616c954a0735f8b4dd8804bdd0351e96f8e904fdb3e78a109b6c\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]},\"openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol\":{\"keccak256\":\"0xe86fdc15fbc379ecf14d6aa4f51b87c0be8476e114e23c171b790a6717230655\",\"urls\":[\"bzzr://364c5847b4ee3ac37a6ad6e54a288889ac3d2a85757b7999c00c719db6cd871d\"]}},\"version\":1}", + "bytecode": "0x60806040523480156200001157600080fd5b5060405160208062009c34833981018060405260208110156200003357600080fd5b8101908080519060200190929190505050600160008190555080600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b158015620000f657600080fd5b505afa1580156200010b573d6000803e3d6000fd5b505050506040513d60208110156200012257600080fd5b8101908080519060200190929190505050600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f58b80d6040518163ffffffff1660e01b815260040160206040518083038186803b158015620001dc57600080fd5b505afa158015620001f1573d6000803e3d6000fd5b505050506040513d60208110156200020857600080fd5b8101908080519060200190929190505050600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166304061d8e6040518163ffffffff1660e01b815260040160206040518083038186803b158015620002c257600080fd5b505afa158015620002d7573d6000803e3d6000fd5b505050506040513d6020811015620002ee57600080fd5b8101908080519060200190929190505050600460006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550506198e480620003506000396000f3fe6080604052600436106100e75760003560e01c80635ceae9c41161008a578063bf92857c11610059578063bf92857c14610709578063c72c4d1014610798578063c858f5f9146107ef578063d2d0e06614610862576100e7565b80635ceae9c41461053457806366f8cd93146105a2578063935642cf146106135780639d9638a11461068e576100e7565b806335ea6a75116100c657806335ea6a75146102c15780633e150141146103b457806348ca1300146104865780635a3b74b9146104d7576100e7565b8062a718a9146100ec5780630902f1ac1461018657806328dd2d01146101f2575b600080fd5b610184600480360360a081101561010257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035151590602001909291905050506108be565b005b34801561019257600080fd5b5061019b610ea4565b6040518080602001828103825283818151815260200191508051906020019060200280838360005b838110156101de5780820151818401526020810190506101c3565b505050509050019250505060405180910390f35b3480156101fe57600080fd5b506102616004803603604081101561021557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610fa4565b604051808c81526020018b81526020018a8152602001898152602001888152602001878152602001868152602001858152602001848152602001838152602001821515151581526020019b50505050505050505050505060405180910390f35b3480156102cd57600080fd5b50610310600480360360208110156102e457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061114f565b604051808e81526020018d81526020018c81526020018b81526020018a81526020018981526020018881526020018781526020018681526020018581526020018481526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018264ffffffffff1664ffffffffff1681526020019d505050505050505050505050505060405180910390f35b3480156103c057600080fd5b50610403600480360360208110156103d757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506112e2565b604051808981526020018881526020018781526020018673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001851515151581526020018415151515815260200183151515158152602001821515151581526020019850505050505050505060405180910390f35b34801561049257600080fd5b506104d5600480360360208110156104a957600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061142b565b005b3480156104e357600080fd5b50610532600480360360408110156104fa57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803515159060200190929190505050612914565b005b6105a06004803603606081101561054a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612e35565b005b3480156105ae57600080fd5b50610611600480360360408110156105c557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061451b565b005b34801561061f57600080fd5b5061068c6004803603606081101561063657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050615285565b005b34801561069a57600080fd5b50610707600480360360608110156106b157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050615a08565b005b34801561071557600080fd5b506107586004803603602081101561072c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506166e5565b6040518088815260200187815260200186815260200185815260200184815260200183815260200182815260200197505050505050505060405180910390f35b3480156107a457600080fd5b506107ad61681f565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b3480156107fb57600080fd5b506108606004803603608081101561081257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190803561ffff169060200190929190505050616845565b005b6108bc6004803603606081101561087857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803561ffff16906020019092919050505061859f565b005b60016000808282540192505081905550600080549050846108de81618dca565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635834eb9a6040518163ffffffff1660e01b815260040160206040518083038186803b15801561094857600080fd5b505afa15801561095c573d6000803e3d6000fd5b505050506040513d602081101561097257600080fd5b81019080805190602001909291905050509050600060608273ffffffffffffffffffffffffffffffffffffffff168a8a8a8a8a604051602401808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200183815260200182151515158152602001955050505050506040516020818303038152906040527ea718a9000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506040518082805190602001908083835b60208310610b085780518252602082019150602081019050602083039250610ae5565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855af49150503d8060008114610b68576040519150601f19603f3d011682016040523d82523d6000602084013e610b6d565b606091505b509150915081610be5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260178152602001807f4c69717569646174696f6e2063616c6c206661696c656400000000000000000081525060200191505060405180910390fd5b60006060828060200190516040811015610bfe57600080fd5b81019080805190602001909291908051640100000000811115610c2057600080fd5b82810190506020810184811115610c3657600080fd5b8151856001820283011164010000000082111715610c5357600080fd5b50509291905050509150915060008214610d9b578060405160200180807f4c69717569646174696f6e206661696c65643a2000000000000000000000000081525060140182805190602001908083835b60208310610cc65780518252602082019150602081019050602083039250610ca3565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040526040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610d60578082015181840152602081019050610d45565b50505050905090810190601f168015610d8d5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b8a73ffffffffffffffffffffffffffffffffffffffff168a73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167f9b814b27a8422f419c399a2f2029752425ba6ebf0d0bdf82eafc1c069a0f42a38c42604051808381526020018281526020019250505060405180910390a45050505050506000548114610e9c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b505050505050565b6060600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630902f1ac6040518163ffffffff1660e01b815260040160006040518083038186803b158015610f0e57600080fd5b505afa158015610f22573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052506020811015610f4c57600080fd5b810190808051640100000000811115610f6457600080fd5b82810190506020810184811115610f7a57600080fd5b8151856020820283011164010000000082111715610f9757600080fd5b5050929190505050905090565b6000806000806000806000806000806000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166328dd2d018e8e6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001925050506101606040518083038186803b15801561108957600080fd5b505afa15801561109d573d6000803e3d6000fd5b505050506040513d6101608110156110b457600080fd5b8101908080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509a509a509a509a509a509a509a509a509a509a509a509295989b509295989b9093969950565b6000806000806000806000806000806000806000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166335ea6a758f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019150506101a06040518083038186803b15801561120357600080fd5b505afa158015611217573d6000803e3d6000fd5b505050506040513d6101a081101561122e57600080fd5b81019080805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509c509c509c509c509c509c509c509c509c509c509c509c509c5091939597999b9d90929496989a9c50565b600080600080600080600080600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633e1501418a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019150506101006040518083038186803b15801561138e57600080fd5b505afa1580156113a2573d6000803e3d6000fd5b505050506040513d6101008110156113b957600080fd5b81019080805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919050505097509750975097509750975097509750919395975091939597565b600160008082825401925050819055506000805490508161144b81618dca565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631ca19f1985336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561152057600080fd5b505afa158015611534573d6000803e3d6000fd5b505050506040513d602081101561154a57600080fd5b810190808051906020019092919050505090506000806000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b15801561163557600080fd5b505afa158015611649573d6000803e3d6000fd5b505050506040513d606081101561165f57600080fd5b81019080805190602001909291908051906020019092919080519060200190929190505050925092509250600082116116e3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806195e06037913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561178457600080fd5b505af1158015611798573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b70fba188336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561187157600080fd5b505af1158015611885573d6000803e3d6000fd5b505050506000600181111561189657fe5b8460018111156118a257fe5b1415611c37576000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166344e636b789336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561197d57600080fd5b505afa158015611991573d6000803e3d6000fd5b505050506040513d60208110156119a757600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b6e1f7028986846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b158015611a6b57600080fd5b505af1158015611a7f573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634d79c1c289856040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015611b2c57600080fd5b505af1158015611b40573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f03e79ff89336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015611c1957600080fd5b505af1158015611c2d573d6000803e3d6000fd5b505050505061241a565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166353cf36e8886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611cd657600080fd5b505afa158015611cea573d6000803e3d6000fd5b505050506040513d6020811015611d0057600080fd5b8101908080519060200190929190505050611d66576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260328152602001806194a26032913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015611e3957600080fd5b505afa158015611e4d573d6000803e3d6000fd5b505050506040513d6020811015611e6357600080fd5b81019080805190602001909291905050501580611f575750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318f9bbae886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611f1a57600080fd5b505afa158015611f2e573d6000803e3d6000fd5b505050506040513d6020811015611f4457600080fd5b8101908080519060200190929190505050155b8061206e5750600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318a4dbca88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561203057600080fd5b505afa158015612044573d6000803e3d6000fd5b505050506040513d602081101561205a57600080fd5b810190808051906020019092919050505082115b6120c3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604a815260200180619696604a913960600191505060405180910390fd5b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e7d3b96896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561216457600080fd5b505afa158015612178573d6000803e3d6000fd5b505050506040513d602081101561218e57600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663cc6ae76389866040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801561224a57600080fd5b505af115801561225e573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634aaa347a8985846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b15801561231357600080fd5b505af1158015612327573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663385c91b089336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561240057600080fd5b505af1158015612414573d6000803e3d6000fd5b50505050505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b088836040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156124c357600080fd5b505af11580156124d7573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd653886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561257c57600080fd5b505af1158015612590573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166320840f6b8833846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561267157600080fd5b505af1158015612685573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561272a57600080fd5b505af115801561273e573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663405300df88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561281757600080fd5b505af115801561282b573d6000803e3d6000fd5b505050503373ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fea368a40e9570069bb8e6511d668293ad2e1f03b0d982431fd223de9f3b70ca6426040518082815260200191505060405180910390a350505050506000548114612910576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b5050565b600160008082825401925050819055506000805490506000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318a4dbca85336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156129ff57600080fd5b505afa158015612a13573d6000803e3d6000fd5b505050506040513d6020811015612a2957600080fd5b8101908080519060200190929190505050905060008111612a95576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180619737602a913960400191505060405180910390fd5b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166376e9d6158533846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001935050505060206040518083038186803b158015612b7057600080fd5b505afa158015612b84573d6000803e3d6000fd5b505050506040513d6020811015612b9a57600080fd5b8101908080519060200190929190505050612c00576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260308152602001806194726030913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa51854c8533866040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001821515151581526020019350505050600060405180830381600087803b158015612ce157600080fd5b505af1158015612cf5573d6000803e3d6000fd5b505050508215612d5d573373ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167e058a56ea94653cdf4f152d227ace22d4c00ad99e2a43f58cb7d9e3feb295f260405160405180910390a3612db8565b3373ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f44c58d81365b66dd4b1a7f36c25aa97b8c71c361ee4937adc1a00000227db5dd60405160405180910390a35b506000548114612e30576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b505050565b6001600080828254019250508190555060008054905083612e5581618dca565b6000806000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd89886040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b158015612f2d57600080fd5b505afa158015612f41573d6000803e3d6000fd5b505050506040513d6060811015612f5757600080fd5b810190808051906020019092919080519060200190929190805190602001909291905050509250925092506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663feab31ac8a896040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561305757600080fd5b505afa15801561306b573d6000803e3d6000fd5b505050506040513d602081101561308157600080fd5b81019080805190602001909291905050509050600083116130ed576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806197936029913960400191505060405180910390fd5b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8814158061314757508673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b61319c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604481526020018061983a6044913960600191505060405180910390fd5b60006131b18285618efc90919063ffffffff16565b90507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff89141580156131e257508089105b156131eb578890505b81811161353d57600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a0fca8398b8a846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b1580156132cf57600080fd5b505af11580156132e3573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c7d14237348c8b85600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fbeefc3c6040518163ffffffff1660e01b815260040160206040518083038186803b15801561339157600080fd5b505afa1580156133a5573d6000803e3d6000fd5b505050506040513d60208110156133bb57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1663bc6156686040518163ffffffff1660e01b815260040160206040518083038186803b15801561341157600080fd5b505afa158015613425573d6000803e3d6000fd5b505050506040513d602081101561343b57600080fd5b81019080805190602001909291905050506040518663ffffffff1660e01b8152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019450505050506000604051808303818588803b15801561351a57600080fd5b505af115801561352e573d6000803e3d6000fd5b5050505050505050505061449d565b60006135528383618f8490919063ffffffff16565b905060006135698583618f8490919063ffffffff16565b9050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a0fca8398d8c876040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561364857600080fd5b505af115801561365c573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c7d14237348e8d88600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fbeefc3c6040518163ffffffff1660e01b815260040160206040518083038186803b15801561370a57600080fd5b505afa15801561371e573d6000803e3d6000fd5b505050506040513d602081101561373457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1663bc6156686040518163ffffffff1660e01b815260040160206040518083038186803b15801561378a57600080fd5b505afa15801561379e573d6000803e3d6000fd5b505050506040513d60208110156137b457600080fd5b81019080805190602001909291905050506040518663ffffffff1660e01b8152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019450505050506000604051808303818588803b15801561389357600080fd5b505af11580156138a7573d6000803e3d6000fd5b5050505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e8d6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561394d57600080fd5b505af1158015613961573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b70fba18d8c6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015613a3a57600080fd5b505af1158015613a4e573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b08d876040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015613afb57600080fd5b505af1158015613b0f573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a37b19578d8c846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b158015613bf057600080fd5b505af1158015613c04573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631ca19f198e8d6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015613cdd57600080fd5b505afa158015613cf1573d6000803e3d6000fd5b505050506040513d6020811015613d0757600080fd5b8101908080519060200190929190505050905060006001811115613d2757fe5b816001811115613d3357fe5b1415614010576000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166344e636b78f8e6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015613e0e57600080fd5b505afa158015613e22573d6000803e3d6000fd5b505050506040513d6020811015613e3857600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b6e1f7028f85846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b158015613efc57600080fd5b505af1158015613f10573d6000803e3d6000fd5b505050508883141561400a57600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f03e79ff8f8e6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015613ff157600080fd5b505af1158015614005573d6000803e3d6000fd5b505050505b506140d2565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663cc6ae7638e846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156140b957600080fd5b505af11580156140cd573d6000803e3d6000fd5b505050505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd6538e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561417357600080fd5b505af1158015614187573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb8e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561422c57600080fd5b505af1158015614240573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663405300df8e8d6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561431957600080fd5b505af115801561432d573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166328fcf4d3348f8e876040518563ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200193505050506000604051808303818588803b15801561440e57600080fd5b505af1158015614422573d6000803e3d6000fd5b50505050508a73ffffffffffffffffffffffffffffffffffffffff168d73ffffffffffffffffffffffffffffffffffffffff167fe4a1ae657f49cb1fb1c7d3a94ae6093565c4c8c0e03de488f79c377c3c3a24e08e42604051808381526020018281526020019250505060405180910390a350505050505050505b506000548114614515576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b50505050565b600160008082825401925050819055506000805490506000600181111561453e57fe5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631ca19f1985856040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561461157600080fd5b505afa158015614625573d6000803e3d6000fd5b505050506040513d602081101561463b57600080fd5b8101908080519060200190929190505050600181111561465757fe5b146146ad576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260348152602001806195296034913960400191505060405180910390fd5b600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd86336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b15801561478357600080fd5b505afa158015614797573d6000803e3d6000fd5b505050506040513d60608110156147ad57600080fd5b81019080805190602001909291908051906020019092919080519060200190929190505050925092505060008211614830576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e815260200180619444602e913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156148d157600080fd5b505af11580156148e5573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166344e636b787876040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156149be57600080fd5b505afa1580156149d2573d6000803e3d6000fd5b505050506040513d60208110156149e857600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634aaa347a8784846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b158015614aac57600080fd5b505af1158015614ac0573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166320840f6b8787856040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b158015614ba157600080fd5b505af1158015614bb5573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b087846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015614c6257600080fd5b505af1158015614c76573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb876040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b158015614d1b57600080fd5b505af1158015614d2f573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c540148e886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015614dd457600080fd5b505afa158015614de8573d6000803e3d6000fd5b505050506040513d6020811015614dfe57600080fd5b810190808051906020019092919050505090506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e7d3b96896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015614eb257600080fd5b505afa158015614ec6573d6000803e3d6000fd5b505050506040513d6020811015614edc57600080fd5b810190808051906020019092919050505090506000614fbf614fb0600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166346f4f8d16040518163ffffffff1660e01b815260040160206040518083038186803b158015614f5f57600080fd5b505afa158015614f73573d6000803e3d6000fd5b505050506040513d6020811015614f8957600080fd5b8101908080519060200190929190505050614fa2618fce565b618efc90919063ffffffff16565b83618fe290919063ffffffff16565b905082841080614fce57508084115b156151b857600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663385c91b08a336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b1580156150a857600080fd5b505af11580156150bc573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663405300df8a8a6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561519557600080fd5b505af11580156151a9573d6000803e3d6000fd5b50505050505050505050615209565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603081526020018061957e6030913960400191505060405180910390fd5b6000548114615280576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b505050565b6001600080828254019250508190555060008054905083600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee826040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561533b57600080fd5b505afa15801561534f573d6000803e3d6000fd5b505050506040513d602081101561536557600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146153f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604b81526020018061964b604b913960600191505060405180910390fd5b8461540381618dca565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e2403019886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156154a457600080fd5b505afa1580156154b8573d6000803e3d6000fd5b505050506040513d60208110156154ce57600080fd5b810190808051906020019092919050505090508481101561553a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260318152602001806194f86031913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156155db57600080fd5b505af11580156155ef573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663352ed9d488876040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801561569c57600080fd5b505af11580156156b0573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd653886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561575557600080fd5b505af1158015615769573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561580e57600080fd5b505af1158015615822573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa93b2a58888886040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561590357600080fd5b505af1158015615917573d6000803e3d6000fd5b505050508573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f9c4ed599cd8555b9c1e8cd7643240d7d71eb76b792948c49fcb4d411f7b6b3c68742604051808381526020018281526020019250505060405180910390a35050506000548114615a02576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b50505050565b6001600080828254019250508190555060008054905082615a2881618dca565b615a478573ffffffffffffffffffffffffffffffffffffffff16619045565b615a9c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e8152602001806197bc602e913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635cf2e656856040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015615b3b57600080fd5b505afa158015615b4f573d6000803e3d6000fd5b505050506040513d6020811015615b6557600080fd5b8101908080519060200190929190505050615bcb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806194d46024913960400191505060405180910390fd5b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e2403019866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015615c6c57600080fd5b505afa158015615c80573d6000803e3d6000fd5b505050506040513d6020811015615c9657600080fd5b81019080805190602001909291905050509050838111615d01576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260318152602001806193f06031913960400191505060405180910390fd5b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b7b2e0b1876040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015615da257600080fd5b505afa158015615db6573d6000803e3d6000fd5b505050506040513d6020811015615dcc57600080fd5b81019080805190602001909291905050509050808214615e54576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f496e76616c6964206c697175696469747920617661696c61626c65000000000081525060200191505060405180910390fd5b6000615e6a60648761909090919063ffffffff16565b905060008111615ec5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260328152602001806197616032913960400191505060405180910390fd5b6000889050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa93b2a5898b8a6040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b158015615fa757600080fd5b505af1158015615fbb573d6000803e3d6000fd5b5050505060008173ffffffffffffffffffffffffffffffffffffffff16638b514f8c8a8a866040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050602060405180830381600087803b15801561605057600080fd5b505af1158015616064573d6000803e3d6000fd5b505050506040513d602081101561607a57600080fd5b810190808051906020019092919050505090506160a08389618efc90919063ffffffff16565b81146160f7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806197ea6026913960400191505060405180910390fd5b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b7b2e0b18b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561619857600080fd5b505afa1580156161ac573d6000803e3d6000fd5b505050506040513d60208110156161c257600080fd5b810190808051906020019092919050505090506161e88486618efc90919063ffffffff16565b811461623f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260328152602001806195ae6032913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e8b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156162e057600080fd5b505af11580156162f4573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631a95129f8b866040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156163a157600080fd5b505af11580156163b5573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b08b866040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801561646257600080fd5b505af1158015616476573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd6538b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561651b57600080fd5b505af115801561652f573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb8b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156165d457600080fd5b505af11580156165e8573d6000803e3d6000fd5b505050508973ffffffffffffffffffffffffffffffffffffffff168b73ffffffffffffffffffffffffffffffffffffffff167fea9aac78e0e48af4897630506e75b1ddba28503b58e70fe7bd92bce4f6efde7c8b874260405180848152602001838152602001828152602001935050505060405180910390a35050505050505060005481146166df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b50505050565b6000806000806000806000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663bf92857c896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060e06040518083038186803b15801561678f57600080fd5b505afa1580156167a3573d6000803e3d6000fd5b505050506040513d60e08110156167b957600080fd5b81019080805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509650965096509650965096509650919395979092949650565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600160008082825401925050819055506000805490508461686581618dca565b61686d619341565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635cf2e656886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561690c57600080fd5b505afa158015616920573d6000803e3d6000fd5b505050506040513d602081101561693657600080fd5b810190808051906020019092919050505061699c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806194d46024913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e2403019886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015616a3b57600080fd5b505afa158015616a4f573d6000803e3d6000fd5b505050506040513d6020811015616a6557600080fd5b8101908080519060200190929190505050816101a001818152505085816101a001511015616ade576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806197016036913960400191505060405180910390fd5b84600180811115616aeb57fe5b1015616b42576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806194216023913960400191505060405180910390fd5b60006001811115616b4f57fe5b85141561712957600180811115616b6257fe5b851480616c455750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166353cf36e8886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015616c0957600080fd5b505afa158015616c1d573d6000803e3d6000fd5b505050506040513d6020811015616c3357600080fd5b81019080805190602001909291905050505b616c9a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260328152602001806194a26032913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015616d6d57600080fd5b505afa158015616d81573d6000803e3d6000fd5b505050506040513d6020811015616d9757600080fd5b81019080805190602001909291905050501580616e8b5750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318f9bbae886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015616e4e57600080fd5b505afa158015616e62573d6000803e3d6000fd5b505050506040513d6020811015616e7857600080fd5b8101908080519060200190929190505050155b80616fa25750600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318a4dbca88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015616f6457600080fd5b505afa158015616f78573d6000803e3d6000fd5b505050506040513d6020811015616f8e57600080fd5b810190808051906020019092919050505086115b616ff7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180619810602a913960400191505060405180910390fd5b6000600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2d8c796040518163ffffffff1660e01b815260040160206040518083038186803b15801561706157600080fd5b505afa158015617075573d6000803e3d6000fd5b505050506040513d602081101561708b57600080fd5b8101908080519060200190929190505050905060006170cb60646170bd84866101a001516190da90919063ffffffff16565b61909090919063ffffffff16565b905080881115617126576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603b81526020018061987e603b913960400191505060405180910390fd5b50505b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632c6d0e9b336040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060c06040518083038186803b1580156171c857600080fd5b505afa1580156171dc573d6000803e3d6000fd5b505050506040513d60c08110156171f257600080fd5b810190808051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509091929394508561010001866101200187600001886020018961014001858152508581525085815250858152508581525050505050506000816101000151116172e6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f54686520636f6c6c61746572616c2062616c616e63652069732030000000000081525060200191505060405180910390fd5b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633e44bee86040518163ffffffff1660e01b815260040160206040518083038186803b15801561734e57600080fd5b505afa158015617362573d6000803e3d6000fd5b505050506040513d602081101561737857600080fd5b8101908080519060200190929190505050816101400151116173e5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603f8152602001806193b1603f913960400191505060405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fbeefc3c6040518163ffffffff1660e01b815260040160206040518083038186803b15801561744d57600080fd5b505afa158015617461573d6000803e3d6000fd5b505050506040513d602081101561747757600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1663e563a7d033886040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019250505060206040518083038186803b15801561750c57600080fd5b505afa158015617520573d6000803e3d6000fd5b505050506040513d602081101561753657600080fd5b81019080805190602001909291905050508160400181815250506000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fca513a86040518163ffffffff1660e01b815260040160206040518083038186803b1580156175ba57600080fd5b505afa1580156175ce573d6000803e3d6000fd5b505050506040513d60208110156175e457600080fd5b810190808051906020019092919050505090506176d7617611836040015189618efc90919063ffffffff16565b8273ffffffffffffffffffffffffffffffffffffffff1663b3596f078b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561768e57600080fd5b505afa1580156176a2573d6000803e3d6000fd5b505050506040513d60208110156176b857600080fd5b810190808051906020019092919050505061916090919063ffffffff16565b826060018181525050617725826000015161771760646177098660600151876101200151618efc90919063ffffffff16565b6190da90919063ffffffff16565b61909090919063ffffffff16565b82608001818152505081610100015182608001511115617790576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260348152602001806196176034913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561783157600080fd5b505af1158015617845573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b70fba189336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561791e57600080fd5b505af1158015617932573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd89336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b158015617a0957600080fd5b505afa158015617a1d573d6000803e3d6000fd5b505050506040513d6060811015617a3357600080fd5b810190808051906020019092919080519060200190929190805190602001909291905050508460a0018560c0018660e001838152508381525083815250505050617a8a878360e00151618efc90919063ffffffff16565b82610160018181525050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e7d3b96896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015617b3357600080fd5b505afa158015617b47573d6000803e3d6000fd5b505050506040513d6020811015617b5d57600080fd5b810190808051906020019092919050505082610180018181525050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633ef563ad89338560a001518661016001518b6001811115617bcf57fe5b8861018001516040518763ffffffff1660e01b8152600401808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001858152602001848152602001836001811115617c6457fe5b60ff1681526020018281526020019650505050505050600060405180830381600087803b158015617c9457600080fd5b505af1158015617ca8573d6000803e3d6000fd5b5050505060006001811115617cb957fe5b861415617db257600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663385c91b089336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015617d9557600080fd5b505af1158015617da9573d6000803e3d6000fd5b50505050617ea0565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f03e79ff89336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015617e8757600080fd5b505af1158015617e9b573d6000803e3d6000fd5b505050505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b0898460e001516040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015617f4d57600080fd5b505af1158015617f61573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd653896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561800657600080fd5b505af115801561801a573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156180bf57600080fd5b505af11580156180d3573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166320840f6b89338561016001516040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b1580156181b957600080fd5b505af11580156181cd573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663da2f7879893385604001516040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b1580156182b257600080fd5b505af11580156182c6573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663405300df89336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561839f57600080fd5b505af11580156183b3573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa93b2a589338a6040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561849457600080fd5b505af11580156184a8573d6000803e3d6000fd5b505050508461ffff163373ffffffffffffffffffffffffffffffffffffffff168973ffffffffffffffffffffffffffffffffffffffff167ffeef05588fd69ddcec0c74bf28610594dca9a265074eaa9d5f2f022e13bf00798a42604051808381526020018281526020019250505060405180910390a45050506000548114618598576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b5050505050565b60016000808282540192505081905550600080549050836185bf81618dca565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561866057600080fd5b505af1158015618674573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b086866040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801561872157600080fd5b505af1158015618735573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd653866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156187da57600080fd5b505af11580156187ee573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561889357600080fd5b505af11580156188a7573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee876040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561894c57600080fd5b505afa158015618960573d6000803e3d6000fd5b505050506040513d602081101561897657600080fd5b8101908080519060200190929190505050905060008173ffffffffffffffffffffffffffffffffffffffff166370a08231336040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015618a0857600080fd5b505afa158015618a1c573d6000803e3d6000fd5b505050506040513d6020811015618a3257600080fd5b81019080805190602001909291905050501415618b4457600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa51854c873360016040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001821515151581526020019350505050600060405180830381600087803b158015618b2b57600080fd5b505af1158015618b3f573d6000803e3d6000fd5b505050505b8073ffffffffffffffffffffffffffffffffffffffff166394362e8b33876040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015618bcb57600080fd5b505af1158015618bdf573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166328fcf4d3348833896040518563ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200193505050506000604051808303818588803b158015618cc057600080fd5b505af1158015618cd4573d6000803e3d6000fd5b50505050508361ffff163373ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fc12c57b1c73a2c3a2ea4613e9476abb3d8d146857aab7329e24243fb59710c828842604051808381526020018281526020019250505060405180910390a450506000548114618dc4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b50505050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166305075d6e826040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015618e6957600080fd5b505afa158015618e7d573d6000803e3d6000fd5b505050506040513d6020811015618e9357600080fd5b8101908080519060200190929190505050618ef9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602181526020018061955d6021913960400191505060405180910390fd5b50565b600080828401905083811015618f7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b6000618fc683836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506191bb565b905092915050565b60006b033b2e3c9fd0803ce8000000905090565b600061903d6b033b2e3c9fd0803ce800000061902f61900a85876190da90919063ffffffff16565b60026b033b2e3c9fd0803ce80000008161902057fe5b04618efc90919063ffffffff16565b61909090919063ffffffff16565b905092915050565b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f91506000801b82141580156190875750808214155b92505050919050565b60006190d283836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061927b565b905092915050565b6000808314156190ed576000905061915a565b60008284029050828482816190fe57fe5b0414619155576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806196e06021913960400191505060405180910390fd5b809150505b92915050565b60006191b3670de0b6b3a76400006191a561918485876190da90919063ffffffff16565b6002670de0b6b3a76400008161919657fe5b04618efc90919063ffffffff16565b61909090919063ffffffff16565b905092915050565b6000838311158290619268576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561922d578082015181840152602081019050619212565b50505050905090810190601f16801561925a5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b60008083118290619327576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156192ec5780820151818401526020810190506192d1565b50505050905090810190601f1680156193195780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50600083858161933357fe5b049050809150509392505050565b604051806101c001604052806000815260200160008152602001600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000815260200160008152509056fe54686520626f72726f7765722063616e20616c7265616479206265206c69717569646174656420736f2068652063616e6e6f7420626f72726f77206d6f72655468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520746f20626f72726f77496e76616c696420696e7465726573742072617465206d6f64652073656c65637465645573657220646f6573206e6f74206861766520616e7920626f72726f7720666f722074686973207265736572766555736572206465706f73697420697320616c7265616479206265696e67207573656420617320636f6c6c61746572616c466978656420626f72726f7773207261746520617265206e6f7420656e61626c6564206f6e2074686973207265736572766552657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e675468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520746f2072656465656d546865207573657220626f72726f77206973207661726961626c6520616e642063616e6e6f7420626520726562616c616e636564416374696f6e20726571756972657320616e206163746976652072657365727665496e746572657374207261746520726562616c616e636520636f6e646974696f6e73207768657265206e6f74206d65745468652061637475616c2062616c616e6365206f66207468652070726f746f636f6c20696e20696e636f6e73697374656e745573657220646f6573206e6f742068617665206120626f72726f7720696e2070726f6772657373206f6e207468697320726573657276655468657265206973206e6f7420656e6f75676820636f6c6c61746572616c20746f20636f7665722061206e657720626f72726f775468652063616c6c6572206f6620746869732066756e6374696f6e2063616e206f6e6c79206265207468652061546f6b656e20636f6e7472616374206f66207468697320726573657276655573657220697320747279696e6720746f20626f72726f7720616e20616d6f756e74207468617420697320736d616c6c6572207468616e2077686174206865206465706f73697465642e536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f775468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520696e2074686520726573657276655573657220646f6573206e6f74206861766520616e79206c6971756964697479206465706f736974656454686520616d6f756e7420697320746f6f20736d616c6c20746875732069742063616e6e6f7420626520626f72726f776564546865207573657220646f6573206e6f74206861766520616e7920626f72726f772070656e64696e675468652063616c6c6572206f6620746869732066756e6374696f6e206d757374206265206120636f6e7472616374546865206e6f6d696e616c2072657475726e656420616d6f756e7420697320696e76616c69645573657220697320747279696e6720746f20626f72726f7720616e20696e76616c696420616d6f756e74546f207265706179206f6e20626568616c66206f6620616e207573657220616e206578706c6963697420616d6f756e7420746f207265706179206973206e65656465642e5573657220697320747279696e6720746f20626f72726f7720746f6f206d756368206c697175696469747920617420612066697865642072617465a165627a7a72305820050d07bf285bb8c7e46e8cfca9d245a990417491728c9fe8f724f81fd99143680029", + "deployedBytecode": "0x6080604052600436106100e75760003560e01c80635ceae9c41161008a578063bf92857c11610059578063bf92857c14610709578063c72c4d1014610798578063c858f5f9146107ef578063d2d0e06614610862576100e7565b80635ceae9c41461053457806366f8cd93146105a2578063935642cf146106135780639d9638a11461068e576100e7565b806335ea6a75116100c657806335ea6a75146102c15780633e150141146103b457806348ca1300146104865780635a3b74b9146104d7576100e7565b8062a718a9146100ec5780630902f1ac1461018657806328dd2d01146101f2575b600080fd5b610184600480360360a081101561010257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035151590602001909291905050506108be565b005b34801561019257600080fd5b5061019b610ea4565b6040518080602001828103825283818151815260200191508051906020019060200280838360005b838110156101de5780820151818401526020810190506101c3565b505050509050019250505060405180910390f35b3480156101fe57600080fd5b506102616004803603604081101561021557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610fa4565b604051808c81526020018b81526020018a8152602001898152602001888152602001878152602001868152602001858152602001848152602001838152602001821515151581526020019b50505050505050505050505060405180910390f35b3480156102cd57600080fd5b50610310600480360360208110156102e457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061114f565b604051808e81526020018d81526020018c81526020018b81526020018a81526020018981526020018881526020018781526020018681526020018581526020018481526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018264ffffffffff1664ffffffffff1681526020019d505050505050505050505050505060405180910390f35b3480156103c057600080fd5b50610403600480360360208110156103d757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506112e2565b604051808981526020018881526020018781526020018673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001851515151581526020018415151515815260200183151515158152602001821515151581526020019850505050505050505060405180910390f35b34801561049257600080fd5b506104d5600480360360208110156104a957600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061142b565b005b3480156104e357600080fd5b50610532600480360360408110156104fa57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803515159060200190929190505050612914565b005b6105a06004803603606081101561054a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612e35565b005b3480156105ae57600080fd5b50610611600480360360408110156105c557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061451b565b005b34801561061f57600080fd5b5061068c6004803603606081101561063657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050615285565b005b34801561069a57600080fd5b50610707600480360360608110156106b157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050615a08565b005b34801561071557600080fd5b506107586004803603602081101561072c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506166e5565b6040518088815260200187815260200186815260200185815260200184815260200183815260200182815260200197505050505050505060405180910390f35b3480156107a457600080fd5b506107ad61681f565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b3480156107fb57600080fd5b506108606004803603608081101561081257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190803561ffff169060200190929190505050616845565b005b6108bc6004803603606081101561087857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803561ffff16906020019092919050505061859f565b005b60016000808282540192505081905550600080549050846108de81618dca565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635834eb9a6040518163ffffffff1660e01b815260040160206040518083038186803b15801561094857600080fd5b505afa15801561095c573d6000803e3d6000fd5b505050506040513d602081101561097257600080fd5b81019080805190602001909291905050509050600060608273ffffffffffffffffffffffffffffffffffffffff168a8a8a8a8a604051602401808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200183815260200182151515158152602001955050505050506040516020818303038152906040527ea718a9000000000000000000000000000000000000000000000000000000007bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff83818316178352505050506040518082805190602001908083835b60208310610b085780518252602082019150602081019050602083039250610ae5565b6001836020036101000a038019825116818451168082178552505050505050905001915050600060405180830381855af49150503d8060008114610b68576040519150601f19603f3d011682016040523d82523d6000602084013e610b6d565b606091505b509150915081610be5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260178152602001807f4c69717569646174696f6e2063616c6c206661696c656400000000000000000081525060200191505060405180910390fd5b60006060828060200190516040811015610bfe57600080fd5b81019080805190602001909291908051640100000000811115610c2057600080fd5b82810190506020810184811115610c3657600080fd5b8151856001820283011164010000000082111715610c5357600080fd5b50509291905050509150915060008214610d9b578060405160200180807f4c69717569646174696f6e206661696c65643a2000000000000000000000000081525060140182805190602001908083835b60208310610cc65780518252602082019150602081019050602083039250610ca3565b6001836020036101000a0380198251168184511680821785525050505050509050019150506040516020818303038152906040526040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610d60578082015181840152602081019050610d45565b50505050905090810190601f168015610d8d5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b8a73ffffffffffffffffffffffffffffffffffffffff168a73ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff167f9b814b27a8422f419c399a2f2029752425ba6ebf0d0bdf82eafc1c069a0f42a38c42604051808381526020018281526020019250505060405180910390a45050505050506000548114610e9c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b505050505050565b6060600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630902f1ac6040518163ffffffff1660e01b815260040160006040518083038186803b158015610f0e57600080fd5b505afa158015610f22573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f820116820180604052506020811015610f4c57600080fd5b810190808051640100000000811115610f6457600080fd5b82810190506020810184811115610f7a57600080fd5b8151856020820283011164010000000082111715610f9757600080fd5b5050929190505050905090565b6000806000806000806000806000806000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166328dd2d018e8e6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001925050506101606040518083038186803b15801561108957600080fd5b505afa15801561109d573d6000803e3d6000fd5b505050506040513d6101608110156110b457600080fd5b8101908080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509a509a509a509a509a509a509a509a509a509a509a509295989b509295989b9093969950565b6000806000806000806000806000806000806000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166335ea6a758f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019150506101a06040518083038186803b15801561120357600080fd5b505afa158015611217573d6000803e3d6000fd5b505050506040513d6101a081101561122e57600080fd5b81019080805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509c509c509c509c509c509c509c509c509c509c509c509c509c5091939597999b9d90929496989a9c50565b600080600080600080600080600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633e1501418a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019150506101006040518083038186803b15801561138e57600080fd5b505afa1580156113a2573d6000803e3d6000fd5b505050506040513d6101008110156113b957600080fd5b81019080805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919050505097509750975097509750975097509750919395975091939597565b600160008082825401925050819055506000805490508161144b81618dca565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631ca19f1985336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561152057600080fd5b505afa158015611534573d6000803e3d6000fd5b505050506040513d602081101561154a57600080fd5b810190808051906020019092919050505090506000806000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b15801561163557600080fd5b505afa158015611649573d6000803e3d6000fd5b505050506040513d606081101561165f57600080fd5b81019080805190602001909291908051906020019092919080519060200190929190505050925092509250600082116116e3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806195e06037913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561178457600080fd5b505af1158015611798573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b70fba188336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561187157600080fd5b505af1158015611885573d6000803e3d6000fd5b505050506000600181111561189657fe5b8460018111156118a257fe5b1415611c37576000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166344e636b789336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561197d57600080fd5b505afa158015611991573d6000803e3d6000fd5b505050506040513d60208110156119a757600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b6e1f7028986846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b158015611a6b57600080fd5b505af1158015611a7f573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634d79c1c289856040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015611b2c57600080fd5b505af1158015611b40573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f03e79ff89336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015611c1957600080fd5b505af1158015611c2d573d6000803e3d6000fd5b505050505061241a565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166353cf36e8886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611cd657600080fd5b505afa158015611cea573d6000803e3d6000fd5b505050506040513d6020811015611d0057600080fd5b8101908080519060200190929190505050611d66576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260328152602001806194a26032913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015611e3957600080fd5b505afa158015611e4d573d6000803e3d6000fd5b505050506040513d6020811015611e6357600080fd5b81019080805190602001909291905050501580611f575750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318f9bbae886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611f1a57600080fd5b505afa158015611f2e573d6000803e3d6000fd5b505050506040513d6020811015611f4457600080fd5b8101908080519060200190929190505050155b8061206e5750600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318a4dbca88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561203057600080fd5b505afa158015612044573d6000803e3d6000fd5b505050506040513d602081101561205a57600080fd5b810190808051906020019092919050505082115b6120c3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604a815260200180619696604a913960600191505060405180910390fd5b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e7d3b96896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561216457600080fd5b505afa158015612178573d6000803e3d6000fd5b505050506040513d602081101561218e57600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663cc6ae76389866040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801561224a57600080fd5b505af115801561225e573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634aaa347a8985846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b15801561231357600080fd5b505af1158015612327573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663385c91b089336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561240057600080fd5b505af1158015612414573d6000803e3d6000fd5b50505050505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b088836040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156124c357600080fd5b505af11580156124d7573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd653886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561257c57600080fd5b505af1158015612590573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166320840f6b8833846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561267157600080fd5b505af1158015612685573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561272a57600080fd5b505af115801561273e573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663405300df88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561281757600080fd5b505af115801561282b573d6000803e3d6000fd5b505050503373ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fea368a40e9570069bb8e6511d668293ad2e1f03b0d982431fd223de9f3b70ca6426040518082815260200191505060405180910390a350505050506000548114612910576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b5050565b600160008082825401925050819055506000805490506000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318a4dbca85336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156129ff57600080fd5b505afa158015612a13573d6000803e3d6000fd5b505050506040513d6020811015612a2957600080fd5b8101908080519060200190929190505050905060008111612a95576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180619737602a913960400191505060405180910390fd5b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166376e9d6158533846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001935050505060206040518083038186803b158015612b7057600080fd5b505afa158015612b84573d6000803e3d6000fd5b505050506040513d6020811015612b9a57600080fd5b8101908080519060200190929190505050612c00576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260308152602001806194726030913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa51854c8533866040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001821515151581526020019350505050600060405180830381600087803b158015612ce157600080fd5b505af1158015612cf5573d6000803e3d6000fd5b505050508215612d5d573373ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167e058a56ea94653cdf4f152d227ace22d4c00ad99e2a43f58cb7d9e3feb295f260405160405180910390a3612db8565b3373ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f44c58d81365b66dd4b1a7f36c25aa97b8c71c361ee4937adc1a00000227db5dd60405160405180910390a35b506000548114612e30576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b505050565b6001600080828254019250508190555060008054905083612e5581618dca565b6000806000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd89886040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b158015612f2d57600080fd5b505afa158015612f41573d6000803e3d6000fd5b505050506040513d6060811015612f5757600080fd5b810190808051906020019092919080519060200190929190805190602001909291905050509250925092506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663feab31ac8a896040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561305757600080fd5b505afa15801561306b573d6000803e3d6000fd5b505050506040513d602081101561308157600080fd5b81019080805190602001909291905050509050600083116130ed576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806197936029913960400191505060405180910390fd5b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8814158061314757508673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16145b61319c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604481526020018061983a6044913960600191505060405180910390fd5b60006131b18285618efc90919063ffffffff16565b90507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff89141580156131e257508089105b156131eb578890505b81811161353d57600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a0fca8398b8a846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b1580156132cf57600080fd5b505af11580156132e3573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c7d14237348c8b85600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fbeefc3c6040518163ffffffff1660e01b815260040160206040518083038186803b15801561339157600080fd5b505afa1580156133a5573d6000803e3d6000fd5b505050506040513d60208110156133bb57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1663bc6156686040518163ffffffff1660e01b815260040160206040518083038186803b15801561341157600080fd5b505afa158015613425573d6000803e3d6000fd5b505050506040513d602081101561343b57600080fd5b81019080805190602001909291905050506040518663ffffffff1660e01b8152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019450505050506000604051808303818588803b15801561351a57600080fd5b505af115801561352e573d6000803e3d6000fd5b5050505050505050505061449d565b60006135528383618f8490919063ffffffff16565b905060006135698583618f8490919063ffffffff16565b9050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a0fca8398d8c876040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561364857600080fd5b505af115801561365c573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c7d14237348e8d88600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fbeefc3c6040518163ffffffff1660e01b815260040160206040518083038186803b15801561370a57600080fd5b505afa15801561371e573d6000803e3d6000fd5b505050506040513d602081101561373457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1663bc6156686040518163ffffffff1660e01b815260040160206040518083038186803b15801561378a57600080fd5b505afa15801561379e573d6000803e3d6000fd5b505050506040513d60208110156137b457600080fd5b81019080805190602001909291905050506040518663ffffffff1660e01b8152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019450505050506000604051808303818588803b15801561389357600080fd5b505af11580156138a7573d6000803e3d6000fd5b5050505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e8d6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561394d57600080fd5b505af1158015613961573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b70fba18d8c6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015613a3a57600080fd5b505af1158015613a4e573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b08d876040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015613afb57600080fd5b505af1158015613b0f573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a37b19578d8c846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b158015613bf057600080fd5b505af1158015613c04573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631ca19f198e8d6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015613cdd57600080fd5b505afa158015613cf1573d6000803e3d6000fd5b505050506040513d6020811015613d0757600080fd5b8101908080519060200190929190505050905060006001811115613d2757fe5b816001811115613d3357fe5b1415614010576000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166344e636b78f8e6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015613e0e57600080fd5b505afa158015613e22573d6000803e3d6000fd5b505050506040513d6020811015613e3857600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b6e1f7028f85846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b158015613efc57600080fd5b505af1158015613f10573d6000803e3d6000fd5b505050508883141561400a57600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f03e79ff8f8e6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015613ff157600080fd5b505af1158015614005573d6000803e3d6000fd5b505050505b506140d2565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663cc6ae7638e846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156140b957600080fd5b505af11580156140cd573d6000803e3d6000fd5b505050505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd6538e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561417357600080fd5b505af1158015614187573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb8e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561422c57600080fd5b505af1158015614240573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663405300df8e8d6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561431957600080fd5b505af115801561432d573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166328fcf4d3348f8e876040518563ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200193505050506000604051808303818588803b15801561440e57600080fd5b505af1158015614422573d6000803e3d6000fd5b50505050508a73ffffffffffffffffffffffffffffffffffffffff168d73ffffffffffffffffffffffffffffffffffffffff167fe4a1ae657f49cb1fb1c7d3a94ae6093565c4c8c0e03de488f79c377c3c3a24e08e42604051808381526020018281526020019250505060405180910390a350505050505050505b506000548114614515576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b50505050565b600160008082825401925050819055506000805490506000600181111561453e57fe5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631ca19f1985856040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561461157600080fd5b505afa158015614625573d6000803e3d6000fd5b505050506040513d602081101561463b57600080fd5b8101908080519060200190929190505050600181111561465757fe5b146146ad576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260348152602001806195296034913960400191505060405180910390fd5b600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd86336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b15801561478357600080fd5b505afa158015614797573d6000803e3d6000fd5b505050506040513d60608110156147ad57600080fd5b81019080805190602001909291908051906020019092919080519060200190929190505050925092505060008211614830576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e815260200180619444602e913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156148d157600080fd5b505af11580156148e5573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166344e636b787876040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156149be57600080fd5b505afa1580156149d2573d6000803e3d6000fd5b505050506040513d60208110156149e857600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634aaa347a8784846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b158015614aac57600080fd5b505af1158015614ac0573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166320840f6b8787856040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b158015614ba157600080fd5b505af1158015614bb5573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b087846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015614c6257600080fd5b505af1158015614c76573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb876040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b158015614d1b57600080fd5b505af1158015614d2f573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c540148e886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015614dd457600080fd5b505afa158015614de8573d6000803e3d6000fd5b505050506040513d6020811015614dfe57600080fd5b810190808051906020019092919050505090506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e7d3b96896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015614eb257600080fd5b505afa158015614ec6573d6000803e3d6000fd5b505050506040513d6020811015614edc57600080fd5b810190808051906020019092919050505090506000614fbf614fb0600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166346f4f8d16040518163ffffffff1660e01b815260040160206040518083038186803b158015614f5f57600080fd5b505afa158015614f73573d6000803e3d6000fd5b505050506040513d6020811015614f8957600080fd5b8101908080519060200190929190505050614fa2618fce565b618efc90919063ffffffff16565b83618fe290919063ffffffff16565b905082841080614fce57508084115b156151b857600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663385c91b08a336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b1580156150a857600080fd5b505af11580156150bc573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663405300df8a8a6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561519557600080fd5b505af11580156151a9573d6000803e3d6000fd5b50505050505050505050615209565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603081526020018061957e6030913960400191505060405180910390fd5b6000548114615280576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b505050565b6001600080828254019250508190555060008054905083600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee826040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561533b57600080fd5b505afa15801561534f573d6000803e3d6000fd5b505050506040513d602081101561536557600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146153f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604b81526020018061964b604b913960600191505060405180910390fd5b8461540381618dca565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e2403019886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156154a457600080fd5b505afa1580156154b8573d6000803e3d6000fd5b505050506040513d60208110156154ce57600080fd5b810190808051906020019092919050505090508481101561553a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260318152602001806194f86031913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156155db57600080fd5b505af11580156155ef573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663352ed9d488876040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801561569c57600080fd5b505af11580156156b0573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd653886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561575557600080fd5b505af1158015615769573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561580e57600080fd5b505af1158015615822573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa93b2a58888886040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561590357600080fd5b505af1158015615917573d6000803e3d6000fd5b505050508573ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167f9c4ed599cd8555b9c1e8cd7643240d7d71eb76b792948c49fcb4d411f7b6b3c68742604051808381526020018281526020019250505060405180910390a35050506000548114615a02576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b50505050565b6001600080828254019250508190555060008054905082615a2881618dca565b615a478573ffffffffffffffffffffffffffffffffffffffff16619045565b615a9c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e8152602001806197bc602e913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635cf2e656856040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015615b3b57600080fd5b505afa158015615b4f573d6000803e3d6000fd5b505050506040513d6020811015615b6557600080fd5b8101908080519060200190929190505050615bcb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806194d46024913960400191505060405180910390fd5b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e2403019866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015615c6c57600080fd5b505afa158015615c80573d6000803e3d6000fd5b505050506040513d6020811015615c9657600080fd5b81019080805190602001909291905050509050838111615d01576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260318152602001806193f06031913960400191505060405180910390fd5b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b7b2e0b1876040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015615da257600080fd5b505afa158015615db6573d6000803e3d6000fd5b505050506040513d6020811015615dcc57600080fd5b81019080805190602001909291905050509050808214615e54576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f496e76616c6964206c697175696469747920617661696c61626c65000000000081525060200191505060405180910390fd5b6000615e6a60648761909090919063ffffffff16565b905060008111615ec5576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260328152602001806197616032913960400191505060405180910390fd5b6000889050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa93b2a5898b8a6040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b158015615fa757600080fd5b505af1158015615fbb573d6000803e3d6000fd5b5050505060008173ffffffffffffffffffffffffffffffffffffffff16638b514f8c8a8a866040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050602060405180830381600087803b15801561605057600080fd5b505af1158015616064573d6000803e3d6000fd5b505050506040513d602081101561607a57600080fd5b810190808051906020019092919050505090506160a08389618efc90919063ffffffff16565b81146160f7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806197ea6026913960400191505060405180910390fd5b6000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b7b2e0b18b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561619857600080fd5b505afa1580156161ac573d6000803e3d6000fd5b505050506040513d60208110156161c257600080fd5b810190808051906020019092919050505090506161e88486618efc90919063ffffffff16565b811461623f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260328152602001806195ae6032913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e8b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156162e057600080fd5b505af11580156162f4573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631a95129f8b866040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156163a157600080fd5b505af11580156163b5573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b08b866040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801561646257600080fd5b505af1158015616476573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd6538b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561651b57600080fd5b505af115801561652f573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb8b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156165d457600080fd5b505af11580156165e8573d6000803e3d6000fd5b505050508973ffffffffffffffffffffffffffffffffffffffff168b73ffffffffffffffffffffffffffffffffffffffff167fea9aac78e0e48af4897630506e75b1ddba28503b58e70fe7bd92bce4f6efde7c8b874260405180848152602001838152602001828152602001935050505060405180910390a35050505050505060005481146166df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b50505050565b6000806000806000806000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663bf92857c896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060e06040518083038186803b15801561678f57600080fd5b505afa1580156167a3573d6000803e3d6000fd5b505050506040513d60e08110156167b957600080fd5b81019080805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509650965096509650965096509650919395979092949650565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600160008082825401925050819055506000805490508461686581618dca565b61686d619341565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635cf2e656886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561690c57600080fd5b505afa158015616920573d6000803e3d6000fd5b505050506040513d602081101561693657600080fd5b810190808051906020019092919050505061699c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806194d46024913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e2403019886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015616a3b57600080fd5b505afa158015616a4f573d6000803e3d6000fd5b505050506040513d6020811015616a6557600080fd5b8101908080519060200190929190505050816101a001818152505085816101a001511015616ade576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806197016036913960400191505060405180910390fd5b84600180811115616aeb57fe5b1015616b42576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806194216023913960400191505060405180910390fd5b60006001811115616b4f57fe5b85141561712957600180811115616b6257fe5b851480616c455750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166353cf36e8886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015616c0957600080fd5b505afa158015616c1d573d6000803e3d6000fd5b505050506040513d6020811015616c3357600080fd5b81019080805190602001909291905050505b616c9a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260328152602001806194a26032913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015616d6d57600080fd5b505afa158015616d81573d6000803e3d6000fd5b505050506040513d6020811015616d9757600080fd5b81019080805190602001909291905050501580616e8b5750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318f9bbae886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015616e4e57600080fd5b505afa158015616e62573d6000803e3d6000fd5b505050506040513d6020811015616e7857600080fd5b8101908080519060200190929190505050155b80616fa25750600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318a4dbca88336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015616f6457600080fd5b505afa158015616f78573d6000803e3d6000fd5b505050506040513d6020811015616f8e57600080fd5b810190808051906020019092919050505086115b616ff7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180619810602a913960400191505060405180910390fd5b6000600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663dd2d8c796040518163ffffffff1660e01b815260040160206040518083038186803b15801561706157600080fd5b505afa158015617075573d6000803e3d6000fd5b505050506040513d602081101561708b57600080fd5b8101908080519060200190929190505050905060006170cb60646170bd84866101a001516190da90919063ffffffff16565b61909090919063ffffffff16565b905080881115617126576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603b81526020018061987e603b913960400191505060405180910390fd5b50505b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632c6d0e9b336040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060c06040518083038186803b1580156171c857600080fd5b505afa1580156171dc573d6000803e3d6000fd5b505050506040513d60c08110156171f257600080fd5b810190808051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509091929394508561010001866101200187600001886020018961014001858152508581525085815250858152508581525050505050506000816101000151116172e6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f54686520636f6c6c61746572616c2062616c616e63652069732030000000000081525060200191505060405180910390fd5b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633e44bee86040518163ffffffff1660e01b815260040160206040518083038186803b15801561734e57600080fd5b505afa158015617362573d6000803e3d6000fd5b505050506040513d602081101561737857600080fd5b8101908080519060200190929190505050816101400151116173e5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252603f8152602001806193b1603f913960400191505060405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fbeefc3c6040518163ffffffff1660e01b815260040160206040518083038186803b15801561744d57600080fd5b505afa158015617461573d6000803e3d6000fd5b505050506040513d602081101561747757600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1663e563a7d033886040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019250505060206040518083038186803b15801561750c57600080fd5b505afa158015617520573d6000803e3d6000fd5b505050506040513d602081101561753657600080fd5b81019080805190602001909291905050508160400181815250506000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fca513a86040518163ffffffff1660e01b815260040160206040518083038186803b1580156175ba57600080fd5b505afa1580156175ce573d6000803e3d6000fd5b505050506040513d60208110156175e457600080fd5b810190808051906020019092919050505090506176d7617611836040015189618efc90919063ffffffff16565b8273ffffffffffffffffffffffffffffffffffffffff1663b3596f078b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561768e57600080fd5b505afa1580156176a2573d6000803e3d6000fd5b505050506040513d60208110156176b857600080fd5b810190808051906020019092919050505061916090919063ffffffff16565b826060018181525050617725826000015161771760646177098660600151876101200151618efc90919063ffffffff16565b6190da90919063ffffffff16565b61909090919063ffffffff16565b82608001818152505081610100015182608001511115617790576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260348152602001806196176034913960400191505060405180910390fd5b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561783157600080fd5b505af1158015617845573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631b70fba189336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561791e57600080fd5b505af1158015617932573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd89336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b158015617a0957600080fd5b505afa158015617a1d573d6000803e3d6000fd5b505050506040513d6060811015617a3357600080fd5b810190808051906020019092919080519060200190929190805190602001909291905050508460a0018560c0018660e001838152508381525083815250505050617a8a878360e00151618efc90919063ffffffff16565b82610160018181525050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e7d3b96896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015617b3357600080fd5b505afa158015617b47573d6000803e3d6000fd5b505050506040513d6020811015617b5d57600080fd5b810190808051906020019092919050505082610180018181525050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633ef563ad89338560a001518661016001518b6001811115617bcf57fe5b8861018001516040518763ffffffff1660e01b8152600401808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001858152602001848152602001836001811115617c6457fe5b60ff1681526020018281526020019650505050505050600060405180830381600087803b158015617c9457600080fd5b505af1158015617ca8573d6000803e3d6000fd5b5050505060006001811115617cb957fe5b861415617db257600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663385c91b089336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015617d9557600080fd5b505af1158015617da9573d6000803e3d6000fd5b50505050617ea0565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f03e79ff89336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b158015617e8757600080fd5b505af1158015617e9b573d6000803e3d6000fd5b505050505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b0898460e001516040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015617f4d57600080fd5b505af1158015617f61573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd653896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561800657600080fd5b505af115801561801a573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156180bf57600080fd5b505af11580156180d3573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166320840f6b89338561016001516040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b1580156181b957600080fd5b505af11580156181cd573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663da2f7879893385604001516040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b1580156182b257600080fd5b505af11580156182c6573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663405300df89336040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561839f57600080fd5b505af11580156183b3573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa93b2a589338a6040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561849457600080fd5b505af11580156184a8573d6000803e3d6000fd5b505050508461ffff163373ffffffffffffffffffffffffffffffffffffffff168973ffffffffffffffffffffffffffffffffffffffff167ffeef05588fd69ddcec0c74bf28610594dca9a265074eaa9d5f2f022e13bf00798a42604051808381526020018281526020019250505060405180910390a45050506000548114618598576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b5050505050565b60016000808282540192505081905550600080549050836185bf81618dca565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561866057600080fd5b505af1158015618674573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b086866040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801561872157600080fd5b505af1158015618735573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd653866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156187da57600080fd5b505af11580156187ee573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561889357600080fd5b505af11580156188a7573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee876040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561894c57600080fd5b505afa158015618960573d6000803e3d6000fd5b505050506040513d602081101561897657600080fd5b8101908080519060200190929190505050905060008173ffffffffffffffffffffffffffffffffffffffff166370a08231336040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015618a0857600080fd5b505afa158015618a1c573d6000803e3d6000fd5b505050506040513d6020811015618a3257600080fd5b81019080805190602001909291905050501415618b4457600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa51854c873360016040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001821515151581526020019350505050600060405180830381600087803b158015618b2b57600080fd5b505af1158015618b3f573d6000803e3d6000fd5b505050505b8073ffffffffffffffffffffffffffffffffffffffff166394362e8b33876040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015618bcb57600080fd5b505af1158015618bdf573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166328fcf4d3348833896040518563ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200193505050506000604051808303818588803b158015618cc057600080fd5b505af1158015618cd4573d6000803e3d6000fd5b50505050508361ffff163373ffffffffffffffffffffffffffffffffffffffff168773ffffffffffffffffffffffffffffffffffffffff167fc12c57b1c73a2c3a2ea4613e9476abb3d8d146857aab7329e24243fb59710c828842604051808381526020018281526020019250505060405180910390a450506000548114618dc4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0081525060200191505060405180910390fd5b50505050565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166305075d6e826040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015618e6957600080fd5b505afa158015618e7d573d6000803e3d6000fd5b505050506040513d6020811015618e9357600080fd5b8101908080519060200190929190505050618ef9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602181526020018061955d6021913960400191505060405180910390fd5b50565b600080828401905083811015618f7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b6000618fc683836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506191bb565b905092915050565b60006b033b2e3c9fd0803ce8000000905090565b600061903d6b033b2e3c9fd0803ce800000061902f61900a85876190da90919063ffffffff16565b60026b033b2e3c9fd0803ce80000008161902057fe5b04618efc90919063ffffffff16565b61909090919063ffffffff16565b905092915050565b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f91506000801b82141580156190875750808214155b92505050919050565b60006190d283836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061927b565b905092915050565b6000808314156190ed576000905061915a565b60008284029050828482816190fe57fe5b0414619155576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806196e06021913960400191505060405180910390fd5b809150505b92915050565b60006191b3670de0b6b3a76400006191a561918485876190da90919063ffffffff16565b6002670de0b6b3a76400008161919657fe5b04618efc90919063ffffffff16565b61909090919063ffffffff16565b905092915050565b6000838311158290619268576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561922d578082015181840152602081019050619212565b50505050905090810190601f16801561925a5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b60008083118290619327576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156192ec5780820151818401526020810190506192d1565b50505050905090810190601f1680156193195780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50600083858161933357fe5b049050809150509392505050565b604051806101c001604052806000815260200160008152602001600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000815260200160008152509056fe54686520626f72726f7765722063616e20616c7265616479206265206c69717569646174656420736f2068652063616e6e6f7420626f72726f77206d6f72655468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520746f20626f72726f77496e76616c696420696e7465726573742072617465206d6f64652073656c65637465645573657220646f6573206e6f74206861766520616e7920626f72726f7720666f722074686973207265736572766555736572206465706f73697420697320616c7265616479206265696e67207573656420617320636f6c6c61746572616c466978656420626f72726f7773207261746520617265206e6f7420656e61626c6564206f6e2074686973207265736572766552657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e675468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520746f2072656465656d546865207573657220626f72726f77206973207661726961626c6520616e642063616e6e6f7420626520726562616c616e636564416374696f6e20726571756972657320616e206163746976652072657365727665496e746572657374207261746520726562616c616e636520636f6e646974696f6e73207768657265206e6f74206d65745468652061637475616c2062616c616e6365206f66207468652070726f746f636f6c20696e20696e636f6e73697374656e745573657220646f6573206e6f742068617665206120626f72726f7720696e2070726f6772657373206f6e207468697320726573657276655468657265206973206e6f7420656e6f75676820636f6c6c61746572616c20746f20636f7665722061206e657720626f72726f775468652063616c6c6572206f6620746869732066756e6374696f6e2063616e206f6e6c79206265207468652061546f6b656e20636f6e7472616374206f66207468697320726573657276655573657220697320747279696e6720746f20626f72726f7720616e20616d6f756e74207468617420697320736d616c6c6572207468616e2077686174206865206465706f73697465642e536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f775468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520696e2074686520726573657276655573657220646f6573206e6f74206861766520616e79206c6971756964697479206465706f736974656454686520616d6f756e7420697320746f6f20736d616c6c20746875732069742063616e6e6f7420626520626f72726f776564546865207573657220646f6573206e6f74206861766520616e7920626f72726f772070656e64696e675468652063616c6c6572206f6620746869732066756e6374696f6e206d757374206265206120636f6e7472616374546865206e6f6d696e616c2072657475726e656420616d6f756e7420697320696e76616c69645573657220697320747279696e6720746f20626f72726f7720616e20696e76616c696420616d6f756e74546f207265706179206f6e20626568616c66206f6620616e207573657220616e206578706c6963697420616d6f756e7420746f207265706179206973206e65656465642e5573657220697320747279696e6720746f20626f72726f7720746f6f206d756368206c697175696469747920617420612066697865642072617465a165627a7a72305820050d07bf285bb8c7e46e8cfca9d245a990417491728c9fe8f724f81fd99143680029", + "sourceMap": "1118:29528:23:-;;;2988:406;8:9:-1;5:2;;;30:1;27;20:12;5:2;2988:406:23;;;;;;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2988:406:23;;;;;;;;;;;;;;;;879:1:63;863:13;:17;;;;3087:18:23;3067:17;;:38;;;;;;;;;;;;;;;;;;3138:17;;;;;;;;;;;:36;;;:38;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3138:38:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3138:38:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3138:38:23;;;;;;;;;;;;;;;;3115:4;;:62;;;;;;;;;;;;;;;;;;3226:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3226:46:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3226:46:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3226:46:23;;;;;;;;;;;;;;;;3187:12;;:86;;;;;;;;;;;;;;;;;;3334:17;;;;;;;;;;;:50;;;:52;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3334:52:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3334:52:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3334:52:23;;;;;;;;;;;;;;;;3283:18;;:104;;;;;;;;;;;;;;;;;;2988:406;1118:29528;;;;;;", + "deployedSourceMap": "1118:29528:23:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;24047:1121;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;24047:1121:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;30235:104;;8:9:-1;5:2;;;30:1;27;20:12;5:2;30235:104:23;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;30235:104:23;;;;;;;;;;;;;;;;;29597:632;;8:9:-1;5:2;;;30:1;27;20:12;5:2;29597:632:23;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;29597:632:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;28488:666;;8:9:-1;5:2;;;30:1;27;20:12;5:2;28488:666:23;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;28488:666:23;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;27997:484;;8:9:-1;5:2;;;30:1;27;20:12;5:2;27997:484:23;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;27997:484:23;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;17229:3083;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17229:3083:23;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;17229:3083:23;;;;;;;;;;;;;;;;;;;:::i;:::-;;23106:773;;8:9:-1;5:2;;;30:1;27;20:12;5:2;23106:773:23;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;23106:773:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;13125:3976;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13125:3976:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;20601:2402;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20601:2402:23;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;20601:2402:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;4859:902;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4859:902:23;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4859:902:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;25174:2723;;8:9:-1;5:2;;;30:1;27;20:12;5:2;25174:2723:23;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;25174:2723:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;29160:431;;8:9:-1;5:2;;;30:1;27;20:12;5:2;29160:431:23;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;29160:431:23;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1270:53;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1270:53:23;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;6538:6328;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6538:6328:23;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;6538:6328:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;3550:1162;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3550:1162:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;24047:1121;1313:1:63;1296:13;;:18;;;;;;;;;;;1324:20;1347:13;;1324:36;;24251:8:23;2874:38;2903:8;2874:28;:38::i;:::-;24275:26;24304:17;;;;;;;;;;;:50;;;:52;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;24304:52:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;24304:52:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;24304:52:23;;;;;;;;;;;;;;;;24275:81;;24403:12;24417:19;24440:18;:31;;24588:11;24618:8;24645:5;24669:15;24703:14;24490:241;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;49:4:-1;39:7;30;26:21;22:32;13:7;6:49;24490:241:23;;;;;;;38:4:-1;29:7;25:18;67:10;61:17;96:58;199:8;192:4;186;182:15;179:29;167:10;160:49;0:215;;;24490:241:23;24440:292;;;;;;;;;;;;;36:153:-1;66:2;61:3;58:11;36:153;;182:3;176:10;171:3;164:23;98:2;93:3;89:12;82:19;;123:2;118:3;114:12;107:19;;148:2;143:3;139:12;132:19;;36:153;;;274:1;267:3;263:2;259:12;254:3;250:22;246:30;315:4;311:9;305:3;299:10;295:26;356:4;350:3;344:10;340:21;389:7;380;377:20;372:3;365:33;3:399;;;24440:292:23;;;;;;;;;;;;;;;;;;;;;;;14:1:-1;21;16:31;;;;75:4;69:11;64:16;;144:4;140:9;133:4;115:16;111:27;107:43;104:1;100:51;94:4;87:65;169:16;166:1;159:27;225:16;222:1;215:4;212:1;208:12;193:49;7:242;;16:31;36:4;31:9;;7:242;;24402:330:23;;;;24750:7;24742:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;24797:18;24817:27;24859:6;24848:37;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;24848:37:23;;;;;;;;;;;;;;;19:11:-1;14:3;11:20;8:2;;;44:1;41;34:12;8:2;71:11;66:3;62:21;55:28;;123:4;118:3;114:14;159:9;141:16;138:31;135:2;;;182:1;179;172:12;135:2;219:3;213:10;330:9;325:1;311:12;307:20;289:16;285:43;282:58;261:11;247:12;244:29;233:115;230:2;;;361:1;358;351:12;230:2;0:372;;24848:37:23;;;;;;24796:89;;;;24913:1;24899:10;:15;24896:130;;24999:13;24958:55;;;;;;;;;;;;;;;;;;;;;;36:153:-1;66:2;61:3;58:11;36:153;;182:3;176:10;171:3;164:23;98:2;93:3;89:12;82:19;;123:2;118:3;114:12;107:19;;148:2;143:3;139:12;132:19;;36:153;;;274:1;267:3;263:2;259:12;254:3;250:22;246:30;315:4;311:9;305:3;299:10;295:26;356:4;350:3;344:10;340:21;389:7;380;377:20;372:3;365:33;3:399;;;24958:55:23;;;;;;;;;;;49:4:-1;39:7;30;26:21;22:32;13:7;6:49;24958:55:23;;;24944:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;24944:71:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;24896:130;25135:8;25075:86;;25111:5;25075:86;;25091:18;25075:86;;;25118:15;25145;25075:86;;;;;;;;;;;;;;;;;;;;;;;;2922:1;;;;;1370::63;1405:13;;1389:12;:29;1381:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;24047:1121:23;;;;;;:::o;30235:104::-;30280:16;30314:4;;;;;;;;;;;:16;;;:18;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;30314:18:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;30314:18:23;;;;;;39:16:-1;36:1;17:17;2:54;30314:18:23;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;13:2;8:3;5:11;2:2;;;29:1;26;19:12;2:2;30314:18:23;;;;;;19:11:-1;14:3;11:20;8:2;;;44:1;41;34:12;8:2;71:11;66:3;62:21;55:28;;123:4;118:3;114:14;159:9;141:16;138:31;135:2;;;182:1;179;172:12;135:2;219:3;213:10;331:9;325:2;311:12;307:21;289:16;285:44;282:59;261:11;247:12;244:29;233:116;230:2;;;362:1;359;352:12;230:2;0:373;;30314:18:23;;;;;;30307:25;;30235:104;:::o;29597:632::-;29718:28;29760:32;29806:28;29848:30;29892:22;29928:18;29960:21;29995:22;30031:27;30072;30113:29;30174:12;;;;;;;;;;;:31;;;30206:8;30216:5;30174:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;30174:48:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;30174:48:23;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;30174:48:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30167:55;;;;;;;;;;;;;;;;;;;;;;29597:632;;;;;;;;;;;;;;:::o;28488:666::-;28590:22;28626:26;28666:25;28705:28;28747:21;28782:26;28822:23;28859:30;28903:23;28940:22;28976:27;29017:21;29052:26;29110:12;;;;;;;;;;;:27;;;29138:8;29110:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;29110:37:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;29110:37:23;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;29110:37:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;29103:44;;;;;;;;;;;;;;;;;;;;;;;;;;28488:666;;;;;;;;;;;;;;;:::o;27997:484::-;28112:11;28137:28;28179:27;28220:35;28269:29;28312:21;28347:27;28388:13;28424:12;;;;;;;;;;;:40;;;28465:8;28424:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;28424:50:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;28424:50:23;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;28424:50:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;28417:57;;;;;;;;;;;;;;;;27997:484;;;;;;;;;:::o;17229:3083::-;1313:1:63;1296:13;;:18;;;;;;;;;;;1324:20;1347:13;;1324:36;;17315:8:23;2874:38;2903:8;2874:28;:38::i;:::-;17336:44;17383:4;;;;;;;;;;;:33;;;17417:8;17427:10;17383:55;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17383:55:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;17383:55:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;17383:55:23;;;;;;;;;;;;;;;;17336:102;;17449:30;17489:31;17530:23;17557:4;;;;;;;;;;;:26;;;17584:8;17594:10;17557:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17557:48:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;17557:48:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;17557:48:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;17448:157;;;;;;17650:1;17624:23;:27;17616:95;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;17760:4;;;;;;;;;;;:35;;;17796:8;17760:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17760:45:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;17760:45:23;;;;17815:4;;;;;;;;;;;:48;;;17864:8;17874:10;17815:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17815:70:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;17815:70:23;;;;17918:34;17899:53;;;;;;;;:15;:53;;;;;;;;;17896:1963;;;17968:21;17992:4;;;;;;;;;;;:34;;;18027:8;18037:10;17992:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17992:56:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;17992:56:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;17992:56:23;;;;;;;;;;;;;;;;17968:80;;18096:4;;;;;;;;;;;:57;;;18154:8;18164:22;18188:13;18096:106;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;18096:106:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;18096:106:23;;;;18262:4;;;;;;;;;;;:40;;;18303:8;18313:23;18262:75;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;18262:75:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;18262:75:23;;;;18379:4;;;;;;;;;;;:29;;;18409:8;18419:10;18379:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;18379:51:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;18379:51:23;;;;17896:1963;;;;18917:4;;;;;;;;;;;:39;;;18957:8;18917:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;18917:49:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;18917:49:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;18917:49:23;;;;;;;;;;;;;;;;18892:158;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19091:4;;;;;;;;;;;:40;;;19132:8;19142:10;19091:62;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19091:62:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19091:62:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;19091:62:23;;;;;;;;;;;;;;;;19090:63;:132;;;;19174:4;;;;;;;;;;;:38;;;19213:8;19174:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19174:48:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19174:48:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;19174:48:23;;;;;;;;;;;;;;;;19173:49;19090:132;:242;;;;19268:12;;;;;;;;;;;:42;;;19311:8;19321:10;19268:64;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19268:64:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19268:64:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;19268:64:23;;;;;;;;;;;;;;;;19242:23;:90;19090:242;19065:375;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;19497:24;19524:4;;;;;;;;;;;:37;;;19562:8;19524:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19524:47:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19524:47:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;19524:47:23;;;;;;;;;;;;;;;;19497:74;;19585:4;;;;;;;;;;;:40;;;19626:8;19636:22;19585:74;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19585:74:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19585:74:23;;;;19673:4;;;;;;;;;;;:57;;;19731:8;19741:23;19766:16;19673:110;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19673:110:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19673:110:23;;;;19797:4;;;;;;;;;;;:30;;;19828:8;19837:10;19797:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19797:51:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19797:51:23;;;;17896:1963;;19869:4;;;;;;;;;;;:34;;;19904:8;19914:15;19869:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19869:61:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19869:61:23;;;;19940:4;;;;;;;;;;;:31;;;19972:8;19940:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19940:41:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;19940:41:23;;;;20034:4;;;;;;;;;;;:39;;;20074:8;20084:10;20096:15;20034:78;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20034:78:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;20034:78:23;;;;20122:4;;;;;;;;;;;:25;;;20148:8;20122:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20122:35:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;20122:35:23;;;;20167:4;;;;;;;;;;;:22;;;20190:8;20200:10;20167:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20167:44:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;20167:44:23;;;;20277:10;20262:43;;20267:8;20262:43;;;20289:15;20262:43;;;;;;;;;;;;;;;;;;2922:1;;;;1370::63;1405:13;;1389:12;:29;1381:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;17229:3083:23;;:::o;23106:773::-;1313:1:63;1296:13;;:18;;;;;;;;;;;1324:20;1347:13;;1324:36;;23219:25:23;23247:12;;;;;;;;;;;:42;;;23290:8;23299:10;23247:63;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;23247:63:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;23247:63:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;23247:63:23;;;;;;;;;;;;;;;;23219:91;;23349:1;23329:17;:21;23321:76;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23429:12;;;;;;;;;;;:35;;;23465:8;23475:10;23487:17;23429:76;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;23429:76:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;23429:76:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;23429:76:23;;;;;;;;;;;;;;;;23408:171;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23590:4;;;;;;;;;;;:34;;;23625:8;23635:10;23647:16;23590:74;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;23590:74:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;23590:74:23;;;;23678:16;23675:198;;;23755:10;23714:52;;23745:8;23714:52;;;;;;;;;;;;23675:198;;;23851:10;23809:53;;23841:8;23809:53;;;;;;;;;;;;23675:198;1370:1:63;1405:13;;1389:12;:29;1381:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23106:773:23;;;:::o;13125:3976::-;1313:1:63;1296:13;;:18;;;;;;;;;;;1324:20;1347:13;;1324:36;;13309:8:23;2874:38;2903:8;2874:28;:38::i;:::-;13331:30;13371:31;13412:29;13445:4;;;;;;;;;;;:26;;;13472:8;13482:11;13445:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13445:49:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13445:49:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13445:49:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13330:164;;;;;;13505:22;13530:4;;;;;;;;;;;:26;;;13557:8;13567:11;13530:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13530:49:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13530:49:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13530:49:23;;;;;;;;;;;;;;;;13505:74;;13624:1;13598:23;:27;13590:81;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2978:2;13703:7;:25;;:54;;;;13746:11;13732:25;;:10;:25;;;13703:54;13682:169;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13894:21;13918:43;13946:14;13918:23;:27;;:43;;;;:::i;:::-;13894:67;;2978:2;13976:7;:25;;:52;;;;;14015:13;14005:7;:23;13976:52;13972:106;;;14060:7;14044:23;;13972:106;14226:14;14209:13;:31;14205:440;;14256:4;;;;;;;;;;;:31;;;14288:8;14298:11;14311:13;14256:69;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14256:69:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14256:69:23;;;;14339:4;;;;;;;;;;;:35;;;14381:9;14409:8;14435:11;14464:13;14508:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14508:34:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14508:34:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14508:34:23;;;;;;;;;;;;;;;;14495:73;;;:75;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14495:75:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14495:75:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14495:75:23;;;;;;;;;;;;;;;;14339:245;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14339:245:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14339:245:23;;;;;14628:7;;;;;;;14205:440;14655:30;14688:33;14706:14;14688:13;:17;;:33;;;;:::i;:::-;14655:66;;14731:29;14763:49;14790:21;14763:22;:26;;:49;;;;:::i;:::-;14731:81;;14875:4;;;;;;;;;;;:31;;;14907:8;14917:11;14930:14;14875:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14875:70:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14875:70:23;;;;14955:4;;;;;;;;;;;:35;;;14997:9;15021:8;15043:11;15068:14;15109:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15109:34:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;15109:34:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;15109:34:23;;;;;;;;;;;;;;;;15096:73;;;:75;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15096:75:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;15096:75:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;15096:75:23;;;;;;;;;;;;;;;;14955:226;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14955:226:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14955:226:23;;;;;15312:4;;;;;;;;;;;:35;;;15348:8;15312:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15312:45:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;15312:45:23;;;;15367:4;;;;;;;;;;;:48;;;15416:8;15426:11;15367:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15367:71:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;15367:71:23;;;;15488:4;;;;;;;;;;;:34;;;15523:8;15533:21;15488:67;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15488:67:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;15488:67:23;;;;15690:4;;;;;;;;;;;:39;;;15730:8;15740:11;15753:21;15690:85;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15690:85:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;15690:85:23;;;;15891:43;15937:4;;;;;;;;;;;:33;;;15971:8;15981:11;15937:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15937:56:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;15937:56:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;15937:56:23;;;;;;;;;;;;;;;;15891:102;;16026:34;16008:52;;;;;;;;:14;:52;;;;;;;;;16004:736;;;16076:24;16103:4;;;;;;;;;;;:34;;;16138:8;16148:11;16103:57;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;16103:57:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;16103:57:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;16103:57:23;;;;;;;;;;;;;;;;16076:84;;16174:4;;;;;;;;;;;:57;;;16232:8;16242:21;16265:16;16174:108;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;16174:108:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;16174:108:23;;;;16517:22;16492:21;:47;16489:137;;;16559:4;;;;;;;;;;;:29;;;16589:8;16599:11;16559:52;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;16559:52:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;16559:52:23;;;;16489:137;16004:736;;;;16656:4;;;;;;;;;;;:40;;;16697:8;16707:21;16656:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;16656:73:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;16656:73:23;;;;16004:736;16750:4;;;;;;;;;;;:31;;;16782:8;16750:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;16750:41:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;16750:41:23;;;;16802:4;;;;;;;;;;;:25;;;16828:8;16802:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;16802:35:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;16802:35:23;;;;16847:4;;;;;;;;;;;:22;;;16870:8;16880:11;16847:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;16847:45:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;16847:45:23;;;;16903:4;;;;;;;;;;;:22;;;16932:9;16943:8;16953:11;16966:22;16903:86;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;16903:86:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;16903:86:23;;;;;17056:11;17040:54;;17046:8;17040:54;;;17069:7;17078:15;17040:54;;;;;;;;;;;;;;;;;;;;;;;;2922:1;;;;;;;;;1370::63;1405:13;;1389:12;:29;1381:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13125:3976:23;;;;:::o;20601:2402::-;1313:1:63;1296:13;;:18;;;;;;;;;;;1324:20;1347:13;;1324:36;;20775:34:23;20722:87;;;;;;;;:4;;;;;;;;;;;:33;;;20756:8;20765:5;20722:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20722:49:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;20722:49:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;20722:49:23;;;;;;;;;;;;;;;;:87;;;;;;;;;20701:190;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20913:25;20948:23;20975:4;;;;;;;;;;;:26;;;21002:8;21012:10;20975:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20975:48:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;20975:48:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;20975:48:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20902:121;;;;;21144:1;21124:17;:21;21103:105;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21277:4;;;;;;;;;;;:35;;;21313:8;21277:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21277:45:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;21277:45:23;;;;21333:25;21361:4;;;;;;;;;;;:34;;;21396:8;21405:5;21361:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21361:50:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;21361:50:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;21361:50:23;;;;;;;;;;;;;;;;21333:78;;21421:4;;;;;;;;;;;:57;;;21479:8;21489:15;21506:20;21421:106;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21421:106:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;21421:106:23;;;;21537:4;;;;;;;;;;;:39;;;21577:8;21587:5;21594:15;21537:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21537:73:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;21537:73:23;;;;21620:4;;;;;;;;;;;:34;;;21655:8;21665:15;21620:61;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21620:61:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;21620:61:23;;;;21691:4;;;;;;;;;;;:25;;;21717:8;21691:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21691:35:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;21691:35:23;;;;21737:21;21761:4;;;;;;;;;;;:35;;;21797:8;21761:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21761:45:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;21761:45:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;21761:45:23;;;;;;;;;;;;;;;;21737:69;;21816:31;21850:4;;;;;;;;;;;:37;;;21888:8;21850:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21850:47:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;21850:47:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;21850:47:23;;;;;;;;;;;;;;;;21816:81;;21907:34;21944:169;21988:124;22052:18;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22052:46:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22052:46:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;22052:46:23;;;;;;;;;;;;;;;;21988:29;:27;:29::i;:::-;:46;;:124;;;;:::i;:::-;21944:23;:30;;:169;;;;:::i;:::-;21907:206;;22659:13;22636:20;:36;:97;;;;22707:26;22684:20;:49;22636:97;22633:295;;;22793:4;;;;;;;;;;;:30;;;22824:8;22833:10;22793:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22793:51:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22793:51:23;;;;22858:4;;;;;;;;;;;:22;;;22881:8;22891:5;22858:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22858:39:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22858:39:23;;;;22911:7;;;;;;;;22633:295;22938:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1370:1:63;1405:13;;1389:12;:29;1381:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20601:2402:23;;;:::o;4859:902::-;1313:1:63;1296:13;;:18;;;;;;;;;;;1324:20;1347:13;;1324:36;;5018:8:23;2656:4;;;;;;;;;;;:28;;;2685:8;2656:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2656:38:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2656:38:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2656:38:23;;;;;;;;;;;;;;;;2642:52;;:10;:52;;;2621:174;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5046:8;2874:38;2903:8;2874:28;:38::i;:::-;5067:33;5103:4;;;;;;;;;;;:33;;;5137:8;5103:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5103:43:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5103:43:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5103:43:23;;;;;;;;;;;;;;;;5067:79;;5193:7;5164:25;:36;;5156:98;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5324:4;;;;;;;;;;;:35;;;5360:8;5324:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5324:45:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5324:45:23;;;;5438:4;;;;;;;;;;;:34;;;5473:8;5483:7;5438:53;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5438:53:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5438:53:23;;;;5501:4;;;;;;;;;;;:31;;;5533:8;5501:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5501:41:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5501:41:23;;;;5552:4;;;;;;;;;;;:25;;;5578:8;5552:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5552:35:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5552:35:23;;;;5598:4;;;;;;;;;;;:19;;;5618:8;5628:5;5635:7;5598:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5598:45:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5598:45:23;;;;5721:5;5694:59;;5711:8;5694:59;;;5728:7;5737:15;5694:59;;;;;;;;;;;;;;;;;;;;;;;;2922:1;2805;1370::63;1405:13;;1389:12;:29;1381:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4859:902:23;;;;:::o;25174:2723::-;1313:1:63;1296:13;;:18;;;;;;;;;;;1324:20;1347:13;;1324:36;;25333:8:23;2874:38;2903:8;2874:28;:38::i;:::-;25409:22;:9;:20;;;:22::i;:::-;25401:81;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;25559:4;;;;;;;;;;;:30;;;25590:8;25559:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;25559:40:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;25559:40:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;25559:40:23;;;;;;;;;;;;;;;;25551:88;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;25714:23;25740:4;;;;;;;;;;;:33;;;25774:8;25740:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;25740:43:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;25740:43:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;25740:43:23;;;;;;;;;;;;;;;;25714:69;;25822:7;25801:18;:28;25793:90;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;25894:24;25921:12;;;;;;;;;;;:40;;;25962:8;25921:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;25921:50:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;25921:50:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;25921:50:23;;;;;;;;;;;;;;;;25894:77;;26136:19;26114:18;:41;26106:81;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;26279:14;26296:16;26308:3;26296:7;:11;;:16;;;;:::i;:::-;26279:33;;26343:1;26331:9;:13;26323:76;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;26455:27;26504:9;26455:59;;26566:4;;;;;;;;;;;:19;;;26586:8;26596:9;26607:7;26566:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;26566:49:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;26566:49:23;;;;26667:22;26692:8;:25;;;26718:8;26728:7;26737:9;26692:55;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;26692:55:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;26692:55:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;26692:55:23;;;;;;;;;;;;;;;;26667:80;;26884:22;26896:9;26884:7;:11;;:22;;;;:::i;:::-;26866:14;:40;26858:91;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;27050:26;27079:12;;;;;;;;;;;:40;;;27120:8;27079:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;27079:50:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;27079:50:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;27079:50:23;;;;;;;;;;;;;;;;27050:79;;27170:34;27194:9;27170:19;:23;;:34;;;;:::i;:::-;27148:18;:56;27140:119;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;27344:4;;;;;;;;;;;:35;;;27380:8;27344:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;27344:45:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;27344:45:23;;;;27456:4;;;;;;;;;;;:45;;;27502:8;27512:9;27456:66;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;27456:66:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;27456:66:23;;;;27588:4;;;;;;;;;;;:34;;;27623:8;27632:9;27588:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;27588:54:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;27588:54:23;;;;27685:4;;;;;;;;;;;:31;;;27717:8;27685:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;27685:41:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;27685:41:23;;;;27736:4;;;;;;;;;;;:25;;;27762:8;27736:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;27736:35:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;27736:35:23;;;;27843:8;27822:67;;27832:9;27822:67;;;27853:7;27862:9;27873:15;27822:67;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2922:1;;;;;;1370::63;1405:13;;1389:12;:29;1381:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;25174:2723:23;;;;:::o;29160:431::-;29263:25;29302:26;29342:23;29379:27;29420:35;29469:11;29494:20;29546:12;;;;;;;;;;;:31;;;29578:5;29546:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;29546:38:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;29546:38:23;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;29546:38:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;29539:45;;;;;;;;;;;;;;29160:431;;;;;;;;;:::o;1270:53::-;;;;;;;;;;;;;:::o;6538:6328::-;1313:1:63;1296:13;;:18;;;;;;;;;;;1324:20;1347:13;;1324:36;;6719:8:23;2874:38;2903:8;2874:28;:38::i;:::-;6740:27;;:::i;:::-;6844:4;;;;;;;;;;;:30;;;6875:8;6844:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6844:40:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6844:40:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6844:40:23;;;;;;;;;;;;;;;;6836:89;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7022:4;;;;;;;;;;;:33;;;7056:8;7022:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7022:43:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7022:43:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;7022:43:23;;;;;;;;;;;;;;;;6996:4;:23;;:69;;;;;7124:7;7097:4;:23;;;:34;;7076:135;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7315:17;7273:37;7268:43;;;;;;;;:64;;7260:112;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7879:34;7871:43;;;;;;;;7850:17;:64;7847:1246;;;8084:37;8076:46;;;;;;;;8055:17;:67;:136;;;;8142:4;;;;;;;;;;;:39;;;8182:8;8142:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8142:49:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8142:49:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8142:49:23;;;;;;;;;;;;;;;;8055:136;8030:245;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8316:4;;;;;;;;;;;:40;;;8357:8;8367:10;8316:62;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8316:62:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8316:62:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8316:62:23;;;;;;;;;;;;;;;;8315:63;:132;;;;8399:4;;;;;;;;;;;:38;;;8438:8;8399:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8399:48:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8399:48:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8399:48:23;;;;;;;;;;;;;;;;8398:49;8315:132;:226;;;;8477:12;;;;;;;;;;;:42;;;8520:8;8530:10;8477:64;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8477:64:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8477:64:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8477:64:23;;;;;;;;;;;;;;;;8467:7;:74;8315:226;8290:327;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8797:22;8822:18;;;;;;;;;;;:51;;;:53;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8822:53:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8822:53:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8822:53:23;;;;;;;;;;;;;;;;8797:78;;8889:24;8916:52;8964:3;8916:43;8944:14;8916:4;:23;;;:27;;:43;;;;:::i;:::-;:47;;:52;;;;:::i;:::-;8889:79;;9002:16;8991:7;:27;;8983:99;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7847:1246;;;9276:12;;;;;;;;;;;:36;;;9313:10;9276:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9276:48:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9276:48:23;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;9276:48:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9103:221;;;;;;9114:4;:29;;9153:4;:25;;9188:4;:15;;9213:4;:32;;9255:4;:17;;9103:221;;;;;;;;;;;;;;;;;;;;;;;;;9375:1;9343:4;:29;;;:33;9335:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9460:12;;;;;;;;;;;:48;;;:50;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9460:50:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9460:50:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9460:50:23;;;;;;;;;;;;;;;;9440:4;:17;;;:70;9419:180;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9668:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9668:34:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9668:34:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9668:34:23;;;;;;;;;;;;;;;;9655:76;;;9745:10;9769:7;9655:131;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9655:131:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9655:131:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9655:131:23;;;;;;;;;;;;;;;;9638:4;:14;;:148;;;;;9797:19;9832:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9832:34:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9832:34:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9832:34:23;;;;;;;;;;;;;;;;9797:70;;9909:66;9947:27;9959:4;:14;;;9947:7;:11;;:27;;;;:::i;:::-;9909:6;:20;;;9930:8;9909:30;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9909:30:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9909:30:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9909:30:23;;;;;;;;;;;;;;;;:37;;:66;;;;:::i;:::-;9877:4;:29;;:98;;;;;10157:112;10244:4;:15;;;10157:69;10222:3;10157:60;10187:4;:29;;;10157:4;:25;;;:29;;:60;;;;:::i;:::-;:64;;:69;;;;:::i;:::-;:73;;:112;;;;:::i;:::-;10122:4;:32;;:147;;;;;10371:4;:29;;;10335:4;:32;;;:65;;10314:164;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10666:4;;;;;;;;;;;:35;;;10702:8;10666:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;10666:45:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;10666:45:23;;;;10721:4;;;;;;;;;;;:48;;;10770:8;10780:10;10721:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;10721:70:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;10721:70:23;;;;11031:4;;;;;;;;;;;:26;;;11058:8;11068:10;11031:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11031:48:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11031:48:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11031:48:23;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10931:4;:27;;10968:4;:28;;11006:4;:21;;10930:149;;;;;;;;;;;;;;;11113:34;11139:7;11113:4;:21;;;:25;;:34;;;;:::i;:::-;11090:4;:20;;:57;;;;;11452:4;;;;;;;;;;;:37;;;11490:8;11452:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11452:47:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11452:47:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11452:47:23;;;;;;;;;;;;;;;;11421:4;:28;;:78;;;;;11510:4;;;;;;;;;;;:40;;;11564:8;11586:10;11610:4;:27;;;11651:4;:20;;;11714:17;11685:47;;;;;;;;11746:4;:28;;;11510:274;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11510:274:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11510:274:23;;;;11880:34;11872:43;;;;;;;;11851:17;:64;11847:252;;;11931:4;;;;;;;;;;;:30;;;11962:8;11972:10;11931:52;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11931:52:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11931:52:23;;;;11847:252;;;12037:4;;;;;;;;;;;:29;;;12067:8;12077:10;12037:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12037:51:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;12037:51:23;;;;11847:252;12188:4;;;;;;;;;;;:34;;;12223:8;12233:4;:21;;;12188:67;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12188:67:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;12188:67:23;;;;12266:4;;;;;;;;;;;:31;;;12298:8;12266:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12266:41:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;12266:41:23;;;;12317:4;;;;;;;;;;;:25;;;12343:8;12317:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12317:35:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;12317:35:23;;;;12410:4;;;;;;;;;;;:39;;;12450:8;12460:10;12472:4;:20;;;12410:83;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12410:83:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;12410:83:23;;;;12503:4;;;;;;;;;;;:31;;;12535:8;12545:10;12557:4;:14;;;12503:69;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12503:69:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;12503:69:23;;;;12582:4;;;;;;;;;;;:22;;;12605:8;12615:10;12582:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12582:44:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;12582:44:23;;;;12689:4;;;;;;;;;;;:19;;;12709:8;12719:10;12731:7;12689:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12689:50:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;12689:50:23;;;;12828:13;12790:69;;12807:10;12790:69;;12797:8;12790:69;;;12819:7;12843:15;12790:69;;;;;;;;;;;;;;;;;;;;;;;;2922:1;;1370::63;1405:13;;1389:12;:29;1381:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6538:6328:23;;;;;:::o;3550:1162::-;1313:1:63;1296:13;;:18;;;;;;;;;;;1324:20;1347:13;;1324:36;;3705:8:23;2874:38;2903:8;2874:28;:38::i;:::-;3779:4;;;;;;;;;;;:35;;;3815:8;3779:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3779:45:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3779:45:23;;;;3867:4;;;;;;;;;;;:34;;;3902:8;3912:7;3867:53;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3867:53:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3867:53:23;;;;3930:4;;;;;;;;;;;:31;;;3962:8;3930:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3930:41:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3930:41:23;;;;3981:4;;;;;;;;;;;:25;;;4007:8;3981:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3981:35:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3981:35:23;;;;4027:13;4050:4;;;;;;;;;;;:28;;;4079:8;4050:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4050:38:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4050:38:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4050:38:23;;;;;;;;;;;;;;;;4027:62;;4135:1;4103:6;:16;;;4120:10;4103:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4103:28:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4103:28:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4103:28:23;;;;;;;;;;;;;;;;:33;4100:241;;;4268:4;;;;;;;;;;;:34;;;4303:8;4313:10;4325:4;4268:62;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4268:62:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4268:62:23;;;;4100:241;4420:6;:20;;;4441:10;4453:7;4420:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4420:41:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4420:41:23;;;;4513:4;;;;;;;;;;;:22;;;4542:9;4553:8;4563:10;4575:7;4513:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4513:70:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4513:70:23;;;;;4673:13;4634:70;;4652:10;4634:70;;4642:8;4634:70;;;4664:7;4688:15;4634:70;;;;;;;;;;;;;;;;;;;;;;;;2922:1;1370::63;1405:13;;1389:12;:29;1381:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3550:1162:23;;;;:::o;30444:200::-;30545:4;;;;;;;;;;;:23;;;30569:8;30545:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;30545:33:23;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;30545:33:23;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;30545:33:23;;;;;;;;;;;;;;;;30524:113;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30444:200;:::o;834:176:56:-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;1274:134::-;1332:7;1358:43;1362:1;1365;1358:43;;;;;;;;;;;;;;;;;:3;:43::i;:::-;1351:50;;1274:134;;;;:::o;557:74:29:-;595:7;454:4;614:10;;557:74;:::o;1183:124::-;1244:7;1270:30;454:4;1270:21;1282:8;1288:1;1282;:5;;:8;;;;:::i;:::-;506:1;454:4;500:7;;;;;;1270:11;;:21;;;;:::i;:::-;:25;;:30;;;;:::i;:::-;1263:37;;1183:124;;;;:::o;557:797:62:-;617:4;1062:16;1088:19;1110:66;1088:88;;;;1277:7;1265:20;1253:32;;1316:3;1304:15;;:8;:15;;:42;;;;;1335:11;1323:8;:23;;1304:42;1296:51;;;;557:797;;;:::o;3073:130:56:-;3131:7;3157:39;3161:1;3164;3157:39;;;;;;;;;;;;;;;;;:3;:39::i;:::-;3150:46;;3073:130;;;;:::o;2159:459::-;2217:7;2463:1;2458;:6;2454:45;;;2487:1;2480:8;;;;2454:45;2509:9;2525:1;2521;:5;2509:17;;2553:1;2548;2544;:5;;;;;;:10;2536:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2610:1;2603:8;;;2159:459;;;;;:::o;893:124:29:-;954:7;980:30;362:4;980:21;992:8;998:1;992;:5;;:8;;;;:::i;:::-;414:1;362:4;408:7;;;;;;980:11;;:21;;;;:::i;:::-;:25;;:30;;;;:::i;:::-;973:37;;893:124;;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;3718:338::-;3804:7;3901:1;3897;:5;3904:12;3889:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;3889:28:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3927:9;3943:1;3939;:5;;;;;;3927:17;;4048:1;4041:8;;;3718:338;;;;;:::o;1118:29528:23:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\nimport \"openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol\";\nimport \"openzeppelin-solidity/contracts/utils/Address.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\";\n\nimport \"../configuration/LendingPoolAddressesProvider.sol\";\nimport \"../configuration/LendingPoolParametersProvider.sol\";\nimport \"../configuration/NetworkMetadataProvider.sol\";\nimport \"../tokenization/AToken.sol\";\nimport \"../libraries/CoreLibrary.sol\";\nimport \"../libraries/WadRayMath.sol\";\nimport \"../interfaces/IFeeProvider.sol\";\nimport \"../flashloan/interfaces/IFlashLoanReceiver.sol\";\nimport \"./LendingPoolCore.sol\";\nimport \"./LendingPoolDataProvider.sol\";\nimport \"./LendingPoolLiquidationManager.sol\";\n\n\n\n/*************************************************************************************\n@title LendingPool contract\n@author Aave\n@notice Implements the actions of the LendingPool, and exposes accessory methods to access the core information\n *************************************************************************************/\n\n\ncontract LendingPool is ReentrancyGuard {\n using SafeMath for uint256;\n using WadRayMath for uint256;\n using Address for address payable;\n\n LendingPoolAddressesProvider public addressesProvider;\n LendingPoolCore core;\n LendingPoolDataProvider dataProvider;\n LendingPoolParametersProvider parametersProvider;\n\n /**\n @dev events\n */\n event Deposit(address indexed _reserve, address indexed _user, uint256 _amount, uint16 indexed _referral, uint256 timestamp);\n event RedeemUnderlying(\n address indexed _reserve,\n address indexed _user,\n uint256 _amount,\n uint256 timestamp\n );\n\n event Borrow(address indexed _reserve, address indexed _user, uint256 _amount, uint16 indexed _referral, uint256 timestamp);\n event Repay(address indexed _reserve, address indexed _user, uint256 _amount, uint256 timestamp);\n event LiquidationCall(address indexed _collateral, address indexed _user, uint256 _amount, address indexed _reserve, uint256 timestamp);\n event Swap(address indexed _reserve, address indexed _user, uint256 timestamp);\n event FlashLoan(address indexed _target, address indexed _reserve, uint256 _amount, uint256 _fee, uint256 timestamp);\n event ReserveUsedAsCollateralEnabled(address indexed _reserve, address indexed _user);\n event ReserveUsedAsCollateralDisabled(address indexed _reserve, address indexed _user);\n\n\n /**\n @dev modifiers\n */\n\n modifier onlyOverlyingAToken(address _reserve) {\n require(\n msg.sender == core.getReserveATokenAddress(_reserve),\n \"The caller of this function can only be the aToken contract of this reserve\"\n );\n _;\n }\n\n modifier onlyActiveReserve(address _reserve) {\n requireReserveActiveInternal(_reserve);\n _;\n }\n\n uint256 constant UINT_MAX_VALUE = uint256(-1);\n\n constructor(LendingPoolAddressesProvider _addressesProvider) public {\n\n addressesProvider = _addressesProvider;\n core = LendingPoolCore(addressesProvider.getLendingPoolCore());\n dataProvider = LendingPoolDataProvider(addressesProvider.getLendingPoolDataProvider());\n parametersProvider = LendingPoolParametersProvider(addressesProvider.getLendingPoolParametersProvider());\n }\n\n /**\n * @notice deposits The underlying asset into the reserve. A corresponding amount of the overlying asset (aTokens)\n * is minted.\n */\n function deposit(\n address _reserve,\n uint256 _amount,\n uint16 _referralCode)\n external payable nonReentrant onlyActiveReserve(_reserve) {\n\n //compounding liquidity and borrow interests\n core.updateReserveCumulativeIndexes(_reserve);\n\n //updating reserve data\n core.increaseReserveTotalLiquidity(_reserve, _amount);\n core.updateReserveInterestRates(_reserve);\n core.setReserveLastUpdate(_reserve);\n\n AToken aToken = AToken(core.getReserveATokenAddress(_reserve));\n\n if(aToken.balanceOf(msg.sender) == 0){\n //if this is the first deposit of the user, we configure the deposit as enabled to be used as collateral\n core.setUserUseReserveAsCollateral(_reserve, msg.sender, true);\n }\n\n //minting AToken to user 1:1 with the specific exchange rate\n aToken.mintOnDeposit(msg.sender, _amount);\n\n //transfer to the core contract\n\n core.transferToReserve.value(msg.value)(_reserve, msg.sender, _amount);\n\n //solium-disable-next-line\n emit Deposit(_reserve, msg.sender, _amount, _referralCode, block.timestamp);\n\n }\n\n /**\n * @notice Allows to redeem a specific amount of underlying asset.\n * @dev only aToken contracts can call this function\n */\n function redeemUnderlying(\n address _reserve,\n address payable _user,\n uint256 _amount)\n external nonReentrant onlyOverlyingAToken(_reserve) onlyActiveReserve(_reserve) {\n\n uint256 currentAvailableLiquidity = core.getReserveAvailableLiquidity(_reserve);\n require(currentAvailableLiquidity >= _amount, \"There is not enough liquidity available to redeem\");\n\n //compound liquidity and variable borrow interests\n core.updateReserveCumulativeIndexes(_reserve);\n\n /**\n @dev update reserve data\n */\n\n core.decreaseReserveTotalLiquidity(_reserve, _amount);\n core.updateReserveInterestRates(_reserve);\n core.setReserveLastUpdate(_reserve);\n\n core.transferToUser(_reserve, _user, _amount);\n\n //solium-disable-next-line\n emit RedeemUnderlying(_reserve, _user, _amount, block.timestamp);\n\n }\n\n /**\n * @dev data structures for local computations in the borrow() method.\n */\n\n struct BorrowLocalVars {\n uint256 currentLtv;\n uint256 currentLiquidationThreshold;\n uint256 borrowFee;\n uint256 requestedBorrowAmountETH;\n uint256 amountOfCollateralNeededETH;\n uint256 principalBorrowBalance;\n uint256 compoundedBorrowBalance;\n uint256 compoundedAmount;\n uint256 userCollateralBalanceETH;\n uint256 userBorrowBalanceETH;\n uint256 healthFactor;\n uint256 balanceIncrease;\n uint256 currentReserveFixedRate;\n uint256 availableLiquidity;\n }\n\n /**\n * @notice executes a borrow on the reserve of the specific amount with the interestRateMode specified.\n */\n\n function borrow(\n address _reserve,\n uint256 _amount,\n uint256 _interestRateMode,\n uint16 _referralCode)\n external nonReentrant onlyActiveReserve(_reserve) {\n\n BorrowLocalVars memory vars;\n\n //check that the reserve is enabled for borrowing\n require(core.isReserveBorrowingEnabled(_reserve), \"Reserve is not enabled for borrowing\");\n\n //check that the amount is available in the reserve\n vars.availableLiquidity = core.getReserveAvailableLiquidity(_reserve);\n\n require(\n vars.availableLiquidity >= _amount,\n \"There is not enough liquidity available in the reserve\"\n );\n\n //validate interest rate mode\n require(uint(CoreLibrary.InterestRateMode.VARIABLE) >= _interestRateMode, \"Invalid interest rate mode selected\");\n\n /**\n @dev Following conditions needs to be met if the user is borrowing at a fixed rate:\n 1. Reserve must be enabled for fixed rate borrowing\n 2. Users cannot borrow from the reserve if their collateral is (mostly) the same currency\n they are borrowing, to prevent abuses.\n 3. Users will be able to borrow only a relatively small, configurable amount of the total\n liquidity\n */\n\n if(_interestRateMode == uint256(CoreLibrary.InterestRateMode.FIXED)) {\n\n //check if the borrow mode is fixed and if fixed rate borrowing is enabled on this reserve\n require(\n _interestRateMode == uint256(CoreLibrary.InterestRateMode.VARIABLE) ||\n core.getReserveIsFixedBorrowRateEnabled(_reserve),\n \"Fixed borrows rate are not enabled on this reserve\"\n );\n\n require(\n !core.isUserUseReserveAsCollateralEnabled(_reserve, msg.sender) ||\n !core.isReserveUsageAsCollateralEnabled(_reserve) ||\n _amount > dataProvider.getUserUnderlyingAssetBalance(_reserve, msg.sender),\n \"User is trying to borrow an invalid amount\"\n );\n\n /**\n @dev calculate the max available loan size in fixed rate mode as a percentage of the\n available liquidity\n */\n uint256 maxLoanPercent = parametersProvider.getMaxFixedRateBorrowSizePercent();\n uint256 maxLoanSizeFixed = vars.availableLiquidity.mul(maxLoanPercent).div(100);\n\n require(_amount <= maxLoanSizeFixed, \"User is trying to borrow too much liquidity at a fixed rate\");\n }\n\n (,\n vars.userCollateralBalanceETH,\n vars.userBorrowBalanceETH,\n vars.currentLtv,\n vars.currentLiquidationThreshold,\n vars.healthFactor) = dataProvider.calculateUserGlobalData(msg.sender);\n\n require(vars.userCollateralBalanceETH > 0, \"The collateral balance is 0\");\n\n require(\n vars.healthFactor > dataProvider.getHealthFactorLiquidationThreshold(),\n \"The borrower can already be liquidated so he cannot borrow more\"\n );\n\n\n //calculating fees\n vars.borrowFee = IFeeProvider(addressesProvider.getFeeProvider()).calculateLoanOriginationFee(\n msg.sender,\n _amount\n );\n\n IPriceOracle oracle = IPriceOracle(addressesProvider.getPriceOracle());\n vars.requestedBorrowAmountETH = oracle.getAssetPrice(_reserve).wadMul(_amount.add(vars.borrowFee)); //price is in ether\n\n //add the current already borrowed amount to the amount requested to calculate the total collateral needed.\n vars.amountOfCollateralNeededETH = vars.userBorrowBalanceETH.add(vars.requestedBorrowAmountETH).mul(100).div(\n vars.currentLtv\n ); //LTV is calculated in percentage\n\n require(\n vars.amountOfCollateralNeededETH <= vars.userCollateralBalanceETH,\n \"There is not enough collateral to cover a new borrow\"\n );\n\n //all conditions passed - borrow is accepted\n\n //step 1: update liquidity index and variable borrow index to allow proper calculation of the compounded interests\n core.updateReserveCumulativeIndexes(_reserve);\n core.updateUserLastVariableBorrowCumulativeIndex(_reserve, msg.sender);\n\n //step 2: calculating new borrow principal for the user, which is previous principal + compounded interest + new borrow\n (vars.principalBorrowBalance,\n vars.compoundedBorrowBalance,\n vars.compoundedAmount) = core.getUserBorrowBalances(_reserve, msg.sender);\n\n vars.balanceIncrease = vars.compoundedAmount.add(_amount);\n\n /**\n @notice increasing reserve total borrows to account for the new borrow balance of the user\n @dev NOTE: Depending on the previous borrow mode, the borrows might need to be switched from variable to fixed or viceversa\n */\n\n vars.currentReserveFixedRate = core.getReserveCurrentFixedBorrowRate(_reserve);\n\n core.updateReserveTotalBorrowsByRateMode(\n _reserve,\n msg.sender,\n vars.principalBorrowBalance,\n vars.balanceIncrease,\n CoreLibrary.InterestRateMode(_interestRateMode),\n vars.currentReserveFixedRate\n );\n\n //step 4: update user borrow interest rate\n\n if (_interestRateMode == uint256(CoreLibrary.InterestRateMode.FIXED)) {\n core.updateUserFixedBorrowRate(_reserve, msg.sender);\n } else {\n //variable\n core.resetUserFixedBorrowRate(_reserve, msg.sender);\n }\n\n //step 5: add the compounded amount to the total liquidity of the pool\n core.increaseReserveTotalLiquidity(_reserve, vars.compoundedAmount);\n\n core.updateReserveInterestRates(_reserve);\n core.setReserveLastUpdate(_reserve);\n\n //step 6: updating remaining user data\n core.increaseUserPrincipalBorrowBalance(_reserve, msg.sender, vars.balanceIncrease);\n core.increaseUserOriginationFee(_reserve, msg.sender, vars.borrowFee);\n core.setUserLastUpdate(_reserve, msg.sender);\n\n //if we reached this point, we can transfer\n core.transferToUser(_reserve, msg.sender, _amount);\n\n //solium-disable-next-line\n emit Borrow(_reserve, msg.sender, _amount, _referralCode, block.timestamp);\n }\n\n /**\n * @notice repays a borrow on the specific reserve, for the specified amount.\n @dev the target user is defined by _onBehalfOf. If there is no repayment on behalf of another account,\n _onBehalfOf must be equal to msg.sender.\n */\n\n function repay(\n address _reserve,\n uint256 _amount,\n address payable _onBehalfOf)\n external\n payable\n nonReentrant\n onlyActiveReserve(_reserve) {\n\n (uint256 principalBorrowBalance,\n uint256 compoundedBorrowBalance,\n uint256 borrowBalanceIncrease) = core.getUserBorrowBalances(_reserve, _onBehalfOf);\n\n uint256 originationFee = core.getUserOriginationFee(_reserve, _onBehalfOf);\n\n require(compoundedBorrowBalance > 0, \"The user does not have any borrow pending\");\n\n require(\n _amount != UINT_MAX_VALUE || msg.sender == _onBehalfOf,\n \"To repay on behalf of an user an explicit amount to repay is needed.\"\n );\n\n //default to max amount\n uint256 paybackAmount = compoundedBorrowBalance.add(originationFee);\n\n if (_amount != UINT_MAX_VALUE && _amount < paybackAmount) {\n paybackAmount = _amount;\n }\n\n //if the amount is smaller than the origination fee, just transfer the amount to the fee destination address\n if (paybackAmount <= originationFee) {\n core.decreaseUserOriginationFee(_reserve, _onBehalfOf, paybackAmount);\n core.transferToFeeCollectionAddress.value(msg.value)(\n _reserve,\n _onBehalfOf,\n paybackAmount,\n IFeeProvider(addressesProvider.getFeeProvider()).getFeesCollectionAddress()\n ); //cast the address to payable\n return;\n }\n\n uint256 paybackAmountMinusFees = paybackAmount.sub(originationFee);\n uint256 actualBalanceDecrease = paybackAmountMinusFees.sub(borrowBalanceIncrease);\n\n //transfer the fee amount to the fee wallet\n core.decreaseUserOriginationFee(_reserve, _onBehalfOf, originationFee);\n core.transferToFeeCollectionAddress.value(msg.value)(\n _reserve,\n _onBehalfOf,\n originationFee,\n IFeeProvider(addressesProvider.getFeeProvider()).getFeesCollectionAddress()\n ); //cast the address to payable\n\n //update the liquidity and borrow index to comulate the interest until this point\n core.updateReserveCumulativeIndexes(_reserve);\n core.updateUserLastVariableBorrowCumulativeIndex(_reserve, _onBehalfOf);\n\n //update the reserve liquidity\n core.increaseReserveTotalLiquidity(_reserve, borrowBalanceIncrease);\n\n //update the user principal borrow balance, adding the cumulated interest and then substracting the payaback amount\n core.decreaseUserPrincipalBorrowBalance(_reserve, _onBehalfOf, actualBalanceDecrease);\n\n //compound the cumulated interest to the borrow balance and then substracting the payback amount\n CoreLibrary.InterestRateMode borrowRateMode = core.getUserCurrentBorrowRateMode(_reserve, _onBehalfOf);\n\n if (borrowRateMode == CoreLibrary.InterestRateMode.FIXED) {\n uint256 currentFixedRate = core.getUserCurrentFixedBorrowRate(_reserve, _onBehalfOf);\n core.decreaseReserveTotalBorrowsFixedAndUpdateAverageRate(_reserve, actualBalanceDecrease, currentFixedRate);\n //if the balance decrease is equal to the previous principal (user is repaying the whole loan)\n //and the rate mode is fixed, we reset the interest rate mode of the user\n if(actualBalanceDecrease == principalBorrowBalance) {\n core.resetUserFixedBorrowRate(_reserve, _onBehalfOf);\n }\n } else {\n core.decreaseReserveTotalBorrowsVariable(_reserve, actualBalanceDecrease);\n }\n\n core.updateReserveInterestRates(_reserve);\n\n core.setReserveLastUpdate(_reserve);\n core.setUserLastUpdate(_reserve, _onBehalfOf);\n\n core.transferToReserve.value(msg.value)(_reserve, _onBehalfOf, paybackAmountMinusFees);\n\n //solium-disable-next-line\n emit Repay(_reserve, _onBehalfOf, _amount, block.timestamp);\n }\n\n /**\n * @notice allows the user to swap the current borrow rate mode, from fixed to variable and viceversa.\n */\n\n function swapBorrowRateMode(address _reserve) external nonReentrant onlyActiveReserve(_reserve) {\n\n CoreLibrary.InterestRateMode currentRateMode = core.getUserCurrentBorrowRateMode(_reserve, msg.sender);\n (uint256 principalBorrowBalance,\n uint256 compoundedBorrowBalance,\n uint256 balanceIncrease) = core.getUserBorrowBalances(_reserve, msg.sender);\n\n require(compoundedBorrowBalance > 0, \"User does not have a borrow in progress on this reserve\");\n\n //compounding reserve indexes\n core.updateReserveCumulativeIndexes(_reserve);\n core.updateUserLastVariableBorrowCumulativeIndex(_reserve, msg.sender);\n\n if(currentRateMode == CoreLibrary.InterestRateMode.FIXED){\n\n uint256 userFixedRate = core.getUserCurrentFixedBorrowRate(_reserve, msg.sender);\n\n //switch to variable\n core.decreaseReserveTotalBorrowsFixedAndUpdateAverageRate(_reserve, principalBorrowBalance, userFixedRate); //decreasing fixed from old principal balance\n core.increaseReserveTotalBorrowsVariable(_reserve, compoundedBorrowBalance); //increase variable borrows\n core.resetUserFixedBorrowRate(_reserve, msg.sender);\n }\n else {\n //switch to fixed\n\n /**\n @dev before switching we need to ensure that\n 1. fixed borrow rate is enabled on the reserve\n 2. user is not trying to abuse the reserve by depositing\n more collateral than he is borrowing, artificially lowering\n the interest rate, borrowing at variable, and switching to fixed\n */\n require(\n core.getReserveIsFixedBorrowRateEnabled(_reserve),\n \"Fixed borrows rate are not enabled on this reserve\"\n );\n\n require(\n !core.isUserUseReserveAsCollateralEnabled(_reserve, msg.sender) ||\n !core.isReserveUsageAsCollateralEnabled(_reserve) ||\n compoundedBorrowBalance > dataProvider.getUserUnderlyingAssetBalance(_reserve, msg.sender),\n \"User is trying to borrow an amount that is smaller than what he deposited.\"\n );\n\n //all clear - user can switch\n uint256 currentFixedRate = core.getReserveCurrentFixedBorrowRate(_reserve);\n core.decreaseReserveTotalBorrowsVariable(_reserve, principalBorrowBalance);\n core.increaseReserveTotalBorrowsFixedAndUpdateAverageRate(_reserve, compoundedBorrowBalance, currentFixedRate);\n core.updateUserFixedBorrowRate(_reserve,msg.sender);\n }\n\n core.increaseReserveTotalLiquidity(_reserve, balanceIncrease);\n core.updateReserveInterestRates(_reserve);\n\n\n //compounding cumulated interest\n core.increaseUserPrincipalBorrowBalance(_reserve, msg.sender, balanceIncrease);\n core.setReserveLastUpdate(_reserve);\n core.setUserLastUpdate(_reserve, msg.sender);\n\n //solium-disable-next-line\n emit Swap(_reserve, msg.sender, block.timestamp);\n }\n\n\n /**\n @notice rebalances the fixed interest rate of a user if current liquidity rate > user fixed rate.\n @dev this is regulated by Aave to ensure that the protocol is not abused, and the user is paying a fair\n rate. Anyone can call this function though.\n */\n\n function rebalanceFixedBorrowRate(address _reserve, address _user) external nonReentrant {\n\n require(\n core.getUserCurrentBorrowRateMode(_reserve,_user) == CoreLibrary.InterestRateMode.FIXED,\n \"The user borrow is variable and cannot be rebalanced\"\n );\n\n (,\n uint256 compoundedBalance,\n uint256 balanceIncrease) = core.getUserBorrowBalances(_reserve, msg.sender);\n\n //step 1: user must be borrowing on _reserve at a fixed rate\n require(\n compoundedBalance > 0,\n \"User does not have any borrow for this reserve\");\n\n //step 2: compound the balances, updating indices\n core.updateReserveCumulativeIndexes(_reserve);\n\n uint userCurrentFixedRate = core.getUserCurrentFixedBorrowRate(_reserve,_user);\n core.increaseReserveTotalBorrowsFixedAndUpdateAverageRate(_reserve, balanceIncrease, userCurrentFixedRate);\n core.increaseUserPrincipalBorrowBalance(_reserve, _user, balanceIncrease);\n core.increaseReserveTotalLiquidity(_reserve, balanceIncrease);\n core.setReserveLastUpdate(_reserve);\n\n uint256 liquidityRate = core.getReserveCurrentLiquidityRate(_reserve);\n uint256 reserveCurrentFixedRate = core.getReserveCurrentFixedBorrowRate(_reserve);\n uint256 rebalanceDownRateThreshold = reserveCurrentFixedRate.rayMul(\n WadRayMath\n .ray()\n .add(\n parametersProvider.getRebalanceDownRateDelta()\n ));\n\n //step 3: we have two possible situations to rebalance:\n\n //1. user fixed borrow rate is below the current liquidity rate. The loan needs to be rebalanced,\n //as this situation can be abused (user putting back the borrowed liquidity in the same reserve to earn on it)\n //2. user fixed rate is above the market avg borrow rate of a certain delta, and utilization rate is low.\n //In this case, the user is paying an interest that is too high, and needs to be rescaled down.\n if(userCurrentFixedRate < liquidityRate ||\n userCurrentFixedRate > rebalanceDownRateThreshold\n ) {\n //rebalance fixed rate\n core.updateUserFixedBorrowRate(_reserve,msg.sender);\n core.setUserLastUpdate(_reserve, _user);\n return;\n }\n\n revert(\"Interest rate rebalance conditions where not met\");\n }\n\n /**\n * @notice allows user to enable or disable a specific deposit as collateral\n */\n\n function setUserUseReserveAsCollateral(address _reserve, bool _useAsCollateral) external nonReentrant {\n\n uint256 underlyingBalance = dataProvider.getUserUnderlyingAssetBalance(_reserve,msg.sender);\n\n require(underlyingBalance > 0, \"User does not have any liquidity deposited\");\n\n require(\n dataProvider.balanceDecreaseAllowed(_reserve, msg.sender, underlyingBalance),\n \"User deposit is already being used as collateral\"\n );\n\n core.setUserUseReserveAsCollateral(_reserve, msg.sender, _useAsCollateral);\n\n if(_useAsCollateral){\n emit ReserveUsedAsCollateralEnabled(_reserve, msg.sender);\n }\n else{\n emit ReserveUsedAsCollateralDisabled(_reserve, msg.sender);\n }\n }\n\n /**\n * @notice implements loan liquidation\n * @dev _receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset.\n */\n function liquidationCall(address _collateral, address _reserve, address _user, uint256 _purchaseAmount, bool _receiveAToken)\n external\n payable\n nonReentrant\n onlyActiveReserve(_reserve)\n {\n address liquidationManager = addressesProvider.getLendingPoolLiquidationManager();\n\n //solium-disable-next-line\n (bool success, bytes memory result) = liquidationManager.delegatecall(\n abi.encodeWithSignature(\"liquidationCall(address,address,address,uint256,bool)\",\n _collateral,\n _reserve,\n _user,\n _purchaseAmount,\n _receiveAToken\n ));\n require(success, \"Liquidation call failed\");\n\n (uint256 returnCode, string memory returnMessage) = abi.decode(result, (uint256, string));\n\n if(returnCode != 0) { //error found\n revert(string(abi.encodePacked(\"Liquidation failed: \", returnMessage)));\n }\n //solium-disable-next-line\n emit LiquidationCall(liquidationManager, _user, _purchaseAmount, _reserve, block.timestamp);\n }\n\n function flashLoan(\n address payable _receiver,\n address _reserve,\n uint _amount)\n external\n nonReentrant onlyActiveReserve(_reserve) {\n\n //check that the address is a contract\n require(_receiver.isContract(), \"The caller of this function must be a contract\");\n\n //check that the reserve is enabled for borrowing\n require(core.isReserveBorrowingEnabled(_reserve),\"Reserve is not enabled for borrowing\");\n\n //check that the reserve has enough available liquidity\n uint availableLiquidity = core.getReserveAvailableLiquidity(_reserve);\n require(availableLiquidity > _amount, \"There is not enough liquidity available to borrow\");\n\n uint actualBalanceBefore = dataProvider.getCoreActualReserveBalance(_reserve);\n\n /**\n @dev note: this is always true as it's ensured by the protocol, checking for added security\n */\n require(availableLiquidity == actualBalanceBefore, \"Invalid liquidity available\");\n\n //calculate amount fee\n //TODO refactor this to a global variable\n uint amountFee = _amount.div(100);\n\n require(amountFee > 0, \"The amount is too small thus it cannot be borrowed\");\n\n //get the FlashLoanReceiver instance\n IFlashLoanReceiver receiver = IFlashLoanReceiver(_receiver);\n\n //transfer funds to the receiver\n core.transferToUser(_reserve, _receiver, _amount);\n\n //execute action of the receiver\n uint256 returnedAmount = receiver.executeOperation(_reserve, _amount, amountFee);\n\n //check that the nominal returned amount is greater of equal than borrowed amount plus fees\n require(returnedAmount == _amount.add(amountFee), \"The nominal returned amount is invalid\");\n\n //check that the actual balance of the core contract includes the returned amount\n uint256 actualBalanceAfter = dataProvider.getCoreActualReserveBalance(_reserve);\n\n require(actualBalanceAfter == actualBalanceBefore.add(amountFee), \"The actual balance of the protocol in inconsistent\");\n\n //amount returned is correct - compounding the cumulated interest\n core.updateReserveCumulativeIndexes(_reserve);\n\n //compounding the received fee into the reserve\n core.cumulateLiquidityToReserveLiquidityIndex(_reserve, amountFee);\n\n //increase total liquidity by the received fee\n core.increaseReserveTotalLiquidity(_reserve,amountFee);\n\n //recalculate interests\n core.updateReserveInterestRates(_reserve);\n core.setReserveLastUpdate(_reserve);\n\n //solium-disable-next-line\n emit FlashLoan(_receiver, _reserve, _amount, amountFee, block.timestamp);\n\n }\n\n /***************\n @dev accessory methods to fetch data from the core contract\n */\n\n function getReserveConfigurationData(address _reserve)\n external\n view\n returns (\n uint256 ltv,\n uint256 liquidationThreshold,\n uint256 liquidationDiscount,\n address interestRateStrategyAddress,\n bool usageAsCollateralEnabled,\n bool borrowingEnabled,\n bool fixedBorrowRateEnabled,\n bool isActive)\n {\n return dataProvider.getReserveConfigurationData(_reserve);\n }\n\n\n function getReserveData(address _reserve)\n external\n view\n returns (\n uint256 totalLiquidity,\n uint256 availableLiquidity,\n uint256 totalBorrowsFixed,\n uint256 totalBorrowsVariable,\n uint256 liquidityRate,\n uint256 variableBorrowRate,\n uint256 fixedBorrowRate,\n uint256 averageFixedBorrowRate,\n uint256 utilizationRate,\n uint256 liquidityIndex,\n uint256 variableBorrowIndex,\n address aTokenAddress,\n uint40 lastUpdateTimestamp\n )\n {\n return dataProvider.getReserveData(_reserve);\n }\n\n function getUserAccountData(address _user)\n external\n view\n returns (\n uint256 totalLiquidityETH,\n uint256 totalCollateralETH,\n uint256 totalBorrowsETH,\n uint256 availableBorrowsETH,\n uint256 currentLiquidationThreshold,\n uint256 ltv,\n uint256 healthFactor\n )\n {\n return dataProvider.getUserAccountData(_user);\n }\n\n function getUserReserveData(address _reserve, address _user)\n external\n view\n returns (\n uint256 currentATokenBalance,\n uint256 currentUnderlyingBalance,\n uint256 currentBorrowBalance,\n uint256 principalBorrowBalance,\n uint256 borrowRateMode,\n uint256 borrowRate,\n uint256 liquidityRate,\n uint256 originationFee,\n uint256 variableBorrowIndex,\n uint256 lastUpdateTimestamp,\n bool usageAsCollateralEnabled\n )\n {\n return dataProvider.getUserReserveData(_reserve, _user);\n }\n\n function getReserves() external view returns(address[] memory){\n return core.getReserves();\n }\n\n /**\n @dev internal function to save on code size for the onlyActiveReserve modifier\n */\n function requireReserveActiveInternal(address _reserve) internal view {\n require(\n core.getReserveIsActive(_reserve),\n \"Action requires an active reserve\"\n );\n }\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol", + "exportedSymbols": { + "LendingPool": [ + 4094 + ] + }, + "id": 4095, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 2235, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:23" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 2236, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 11141, + "src": "25:59:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "file": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "id": 2237, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 12114, + "src": "85:67:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "file": "openzeppelin-solidity/contracts/utils/Address.sol", + "id": 2238, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 12082, + "src": "153:59:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "id": 2239, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 11787, + "src": "213:64:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 2240, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 1358, + "src": "279:59:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol", + "file": "../configuration/LendingPoolParametersProvider.sol", + "id": 2241, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 1419, + "src": "339:60:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "file": "../configuration/NetworkMetadataProvider.sol", + "id": 2242, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 1479, + "src": "400:54:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "file": "../tokenization/AToken.sol", + "id": 2243, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 10328, + "src": "455:36:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "file": "../libraries/CoreLibrary.sol", + "id": 2244, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 8995, + "src": "492:38:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 2245, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 9175, + "src": "531:37:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "file": "../interfaces/IFeeProvider.sol", + "id": 2246, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 1766, + "src": "569:40:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol", + "file": "../flashloan/interfaces/IFlashLoanReceiver.sol", + "id": 2247, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 1734, + "src": "610:56:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "./LendingPoolCore.sol", + "id": 2248, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 6683, + "src": "667:31:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol", + "file": "./LendingPoolDataProvider.sol", + "id": 2249, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 7661, + "src": "699:39:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol", + "file": "./LendingPoolLiquidationManager.sol", + "id": 2250, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 8255, + "src": "739:45:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 2251, + "name": "ReentrancyGuard", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12113, + "src": "1142:15:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ReentrancyGuard_$12113", + "typeString": "contract ReentrancyGuard" + } + }, + "id": 2252, + "nodeType": "InheritanceSpecifier", + "src": "1142:15:23" + } + ], + "contractDependencies": [ + 12113 + ], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title LendingPool contract\n@author Aave\n@notice Implements the actions of the LendingPool, and exposes accessory methods to access the core information************************************************************************************", + "fullyImplemented": true, + "id": 4094, + "linearizedBaseContracts": [ + 4094, + 12113 + ], + "name": "LendingPool", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 2255, + "libraryName": { + "contractScope": null, + "id": 2253, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "1170:8:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1164:27:23", + "typeName": { + "id": 2254, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1183:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 2258, + "libraryName": { + "contractScope": null, + "id": 2256, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "1202:10:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1196:29:23", + "typeName": { + "id": 2257, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1217:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 2261, + "libraryName": { + "contractScope": null, + "id": 2259, + "name": "Address", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12081, + "src": "1236:7:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + }, + "nodeType": "UsingForDirective", + "src": "1230:34:23", + "typeName": { + "id": 2260, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1248:15:23", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + }, + { + "constant": false, + "id": 2263, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 4094, + "src": "1270:53:23", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 2262, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1270:28:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": false, + "id": 2265, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4094, + "src": "1329:20:23", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 2264, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "1329:15:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2267, + "name": "dataProvider", + "nodeType": "VariableDeclaration", + "scope": 4094, + "src": "1355:36:23", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + }, + "typeName": { + "contractScope": null, + "id": 2266, + "name": "LendingPoolDataProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 7660, + "src": "1355:23:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2269, + "name": "parametersProvider", + "nodeType": "VariableDeclaration", + "scope": 4094, + "src": "1397:48:23", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + }, + "typeName": { + "contractScope": null, + "id": 2268, + "name": "LendingPoolParametersProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1418, + "src": "1397:29:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "anonymous": false, + "documentation": "@dev events", + "id": 2281, + "name": "Deposit", + "nodeType": "EventDefinition", + "parameters": { + "id": 2280, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2271, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2281, + "src": "1497:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2270, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1497:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2273, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2281, + "src": "1523:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2272, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1523:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2275, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2281, + "src": "1546:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2274, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1546:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2277, + "indexed": true, + "name": "_referral", + "nodeType": "VariableDeclaration", + "scope": 2281, + "src": "1563:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + "typeName": { + "id": 2276, + "name": "uint16", + "nodeType": "ElementaryTypeName", + "src": "1563:6:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2279, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2281, + "src": "1589:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2278, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1589:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1496:111:23" + }, + "src": "1483:125:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2291, + "name": "RedeemUnderlying", + "nodeType": "EventDefinition", + "parameters": { + "id": 2290, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2283, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2291, + "src": "1645:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2282, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1645:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2285, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2291, + "src": "1679:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2284, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1679:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2287, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2291, + "src": "1710:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2286, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1710:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2289, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2291, + "src": "1735:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2288, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1735:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1635:123:23" + }, + "src": "1613:146:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2303, + "name": "Borrow", + "nodeType": "EventDefinition", + "parameters": { + "id": 2302, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2293, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2303, + "src": "1778:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2292, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1778:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2295, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2303, + "src": "1804:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2294, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1804:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2297, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2303, + "src": "1827:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2296, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1827:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2299, + "indexed": true, + "name": "_referral", + "nodeType": "VariableDeclaration", + "scope": 2303, + "src": "1844:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + "typeName": { + "id": 2298, + "name": "uint16", + "nodeType": "ElementaryTypeName", + "src": "1844:6:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2301, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2303, + "src": "1870:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2300, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1870:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1777:111:23" + }, + "src": "1765:124:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2313, + "name": "Repay", + "nodeType": "EventDefinition", + "parameters": { + "id": 2312, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2305, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2313, + "src": "1906:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2304, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1906:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2307, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2313, + "src": "1932:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2306, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1932:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2309, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2313, + "src": "1955:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2308, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1955:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2311, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2313, + "src": "1972:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2310, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1972:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1905:85:23" + }, + "src": "1894:97:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2325, + "name": "LiquidationCall", + "nodeType": "EventDefinition", + "parameters": { + "id": 2324, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2315, + "indexed": true, + "name": "_collateral", + "nodeType": "VariableDeclaration", + "scope": 2325, + "src": "2018:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2314, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2018:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2317, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2325, + "src": "2047:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2316, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2047:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2319, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2325, + "src": "2070:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2318, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2070:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2321, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2325, + "src": "2087:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2320, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2087:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2323, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2325, + "src": "2113:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2322, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2113:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2017:114:23" + }, + "src": "1996:136:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2333, + "name": "Swap", + "nodeType": "EventDefinition", + "parameters": { + "id": 2332, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2327, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2333, + "src": "2148:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2326, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2148:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2329, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2333, + "src": "2174:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2328, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2174:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2331, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2333, + "src": "2197:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2330, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2197:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2147:68:23" + }, + "src": "2137:79:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2345, + "name": "FlashLoan", + "nodeType": "EventDefinition", + "parameters": { + "id": 2344, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2335, + "indexed": true, + "name": "_target", + "nodeType": "VariableDeclaration", + "scope": 2345, + "src": "2237:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2334, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2237:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2337, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2345, + "src": "2262:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2336, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2262:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2339, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2345, + "src": "2288:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2338, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2288:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2341, + "indexed": false, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 2345, + "src": "2305:12:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2340, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2305:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2343, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2345, + "src": "2319:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2342, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2319:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2236:101:23" + }, + "src": "2221:117:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2351, + "name": "ReserveUsedAsCollateralEnabled", + "nodeType": "EventDefinition", + "parameters": { + "id": 2350, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2347, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2351, + "src": "2380:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2346, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2380:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2349, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2351, + "src": "2406:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2348, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2406:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2379:49:23" + }, + "src": "2343:86:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2357, + "name": "ReserveUsedAsCollateralDisabled", + "nodeType": "EventDefinition", + "parameters": { + "id": 2356, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2353, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2357, + "src": "2472:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2352, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2472:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2355, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2357, + "src": "2498:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2354, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2498:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2471:49:23" + }, + "src": "2434:87:23" + }, + { + "body": { + "id": 2373, + "nodeType": "Block", + "src": "2611:202:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 2368, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2362, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "2642:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2363, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2642:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2366, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2359, + "src": "2685:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2364, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "2656:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2365, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "2656:28:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 2367, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2656:38:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "2642:52:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206f6620746869732066756e6374696f6e2063616e206f6e6c79206265207468652061546f6b656e20636f6e7472616374206f6620746869732072657365727665", + "id": 2369, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2708:77:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_83c3af2909d739c11645c0ca81969a410eba1bfadc55dce1095355005feb4d3c", + "typeString": "literal_string \"The caller of this function can only be the aToken contract of this reserve\"" + }, + "value": "The caller of this function can only be the aToken contract of this reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_83c3af2909d739c11645c0ca81969a410eba1bfadc55dce1095355005feb4d3c", + "typeString": "literal_string \"The caller of this function can only be the aToken contract of this reserve\"" + } + ], + "id": 2361, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2621:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2370, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2621:174:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2371, + "nodeType": "ExpressionStatement", + "src": "2621:174:23" + }, + { + "id": 2372, + "nodeType": "PlaceholderStatement", + "src": "2805:1:23" + } + ] + }, + "documentation": "@dev modifiers", + "id": 2374, + "name": "onlyOverlyingAToken", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 2360, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2359, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2374, + "src": "2593:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2358, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2593:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2592:18:23" + }, + "src": "2564:249:23", + "visibility": "internal" + }, + { + "body": { + "id": 2383, + "nodeType": "Block", + "src": "2864:66:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2379, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2376, + "src": "2903:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2378, + "name": "requireReserveActiveInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4093, + "src": "2874:28:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$__$", + "typeString": "function (address) view" + } + }, + "id": 2380, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2874:38:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2381, + "nodeType": "ExpressionStatement", + "src": "2874:38:23" + }, + { + "id": 2382, + "nodeType": "PlaceholderStatement", + "src": "2922:1:23" + } + ] + }, + "documentation": null, + "id": 2384, + "name": "onlyActiveReserve", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 2377, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2376, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2384, + "src": "2846:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2375, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2846:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2845:18:23" + }, + "src": "2819:111:23", + "visibility": "internal" + }, + { + "constant": true, + "id": 2390, + "name": "UINT_MAX_VALUE", + "nodeType": "VariableDeclaration", + "scope": 4094, + "src": "2936:45:23", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2385, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2936:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2388, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "-", + "prefix": true, + "src": "2978:2:23", + "subExpression": { + "argumentTypes": null, + "hexValue": "31", + "id": 2387, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2979:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1_by_1", + "typeString": "int_const 1" + }, + "value": "1" + }, + "typeDescriptions": { + "typeIdentifier": "t_rational_minus_1_by_1", + "typeString": "int_const -1" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_minus_1_by_1", + "typeString": "int_const -1" + } + ], + "id": 2386, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2970:7:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 2389, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2970:11:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "body": { + "id": 2423, + "nodeType": "Block", + "src": "3056:338:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2397, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2395, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "3067:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2396, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2392, + "src": "3087:18:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "3067:38:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2398, + "nodeType": "ExpressionStatement", + "src": "3067:38:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2405, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2399, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "3115:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2401, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "3138:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2402, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "3138:36:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 2403, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3138:38:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 2400, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "3122:15:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 2404, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3122:55:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "src": "3115:62:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2406, + "nodeType": "ExpressionStatement", + "src": "3115:62:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2413, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2407, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "3187:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2409, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "3226:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2410, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolDataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1191, + "src": "3226:44:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 2411, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3226:46:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2408, + "name": "LendingPoolDataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7660, + "src": "3202:23:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolDataProvider_$7660_$", + "typeString": "type(contract LendingPoolDataProvider)" + } + }, + "id": 2412, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3202:71:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "src": "3187:86:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 2414, + "nodeType": "ExpressionStatement", + "src": "3187:86:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2421, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2415, + "name": "parametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2269, + "src": "3283:18:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2417, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "3334:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2418, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolParametersProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1241, + "src": "3334:50:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 2419, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3334:52:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2416, + "name": "LendingPoolParametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1418, + "src": "3304:29:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolParametersProvider_$1418_$", + "typeString": "type(contract LendingPoolParametersProvider)" + } + }, + "id": 2420, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3304:83:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "src": "3283:104:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "id": 2422, + "nodeType": "ExpressionStatement", + "src": "3283:104:23" + } + ] + }, + "documentation": null, + "id": 2424, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2393, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2392, + "name": "_addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 2424, + "src": "3000:47:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 2391, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "3000:28:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2999:49:23" + }, + "returnParameters": { + "id": 2394, + "nodeType": "ParameterList", + "parameters": [], + "src": "3056:0:23" + }, + "scope": 4094, + "src": "2988:406:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 2522, + "nodeType": "Block", + "src": "3715:997:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2441, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "3815:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2438, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "3779:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2440, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "3779:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2442, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3779:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2443, + "nodeType": "ExpressionStatement", + "src": "3779:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2447, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "3902:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 2448, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2428, + "src": "3912:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2444, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "3867:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2446, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "3867:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 2449, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3867:53:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2450, + "nodeType": "ExpressionStatement", + "src": "3867:53:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2454, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "3962:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2451, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "3930:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2453, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "3930:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2455, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3930:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2456, + "nodeType": "ExpressionStatement", + "src": "3930:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2460, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "4007:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2457, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "3981:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2459, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "3981:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2461, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3981:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2462, + "nodeType": "ExpressionStatement", + "src": "3981:35:23" + }, + { + "assignments": [ + 2464 + ], + "declarations": [ + { + "constant": false, + "id": 2464, + "name": "aToken", + "nodeType": "VariableDeclaration", + "scope": 2522, + "src": "4027:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + }, + "typeName": { + "contractScope": null, + "id": 2463, + "name": "AToken", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10327, + "src": "4027:6:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2471, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2468, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "4079:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2466, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "4050:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2467, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "4050:28:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 2469, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4050:38:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2465, + "name": "AToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10327, + "src": "4043:6:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_AToken_$10327_$", + "typeString": "type(contract AToken)" + } + }, + "id": 2470, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4043:46:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4027:62:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2478, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2474, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4120:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2475, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4120:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2472, + "name": "aToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2464, + "src": "4103:6:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 2473, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOf", + "nodeType": "MemberAccess", + "referencedDeclaration": 11298, + "src": "4103:16:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2476, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4103:28:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 2477, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4135:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "4103:33:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 2489, + "nodeType": "IfStatement", + "src": "4100:241:23", + "trueBody": { + "id": 2488, + "nodeType": "Block", + "src": "4137:204:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2482, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "4303:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2483, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4313:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2484, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4313:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "hexValue": "74727565", + "id": 2485, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4325:4:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "expression": { + "argumentTypes": null, + "id": 2479, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "4268:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2481, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserUseReserveAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 5337, + "src": "4268:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_bool_$returns$__$", + "typeString": "function (address,address,bool) external" + } + }, + "id": 2486, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4268:62:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2487, + "nodeType": "ExpressionStatement", + "src": "4268:62:23" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2493, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4441:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2494, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4441:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2495, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2428, + "src": "4453:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2490, + "name": "aToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2464, + "src": "4420:6:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 2492, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mintOnDeposit", + "nodeType": "MemberAccess", + "referencedDeclaration": 10119, + "src": "4420:20:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 2496, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4420:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2497, + "nodeType": "ExpressionStatement", + "src": "4420:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2506, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "4553:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2507, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4563:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2508, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4563:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2509, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2428, + "src": "4575:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2503, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4542:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2504, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4542:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2498, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "4513:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2501, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6619, + "src": "4513:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 2502, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4513:28:23", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value_$", + "typeString": "function (uint256) returns (function (address,address payable,uint256) payable external)" + } + }, + "id": 2505, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4513:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 2510, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4513:70:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2511, + "nodeType": "ExpressionStatement", + "src": "4513:70:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2513, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "4642:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2514, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4652:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2515, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4652:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2516, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2428, + "src": "4664:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 2517, + "name": "_referralCode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2430, + "src": "4673:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2518, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "4688:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 2519, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4688:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 2512, + "name": "Deposit", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2281, + "src": "4634:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint16_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint16,uint256)" + } + }, + "id": 2520, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4634:70:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2521, + "nodeType": "EmitStatement", + "src": "4629:75:23" + } + ] + }, + "documentation": "@notice deposits The underlying asset into the reserve. A corresponding amount of the overlying asset (aTokens)\nis minted.", + "id": 2523, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 2433, + "modifierName": { + "argumentTypes": null, + "id": 2432, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "3674:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "3674:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 2435, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "3705:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 2436, + "modifierName": { + "argumentTypes": null, + "id": 2434, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "3687:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "3687:27:23" + } + ], + "name": "deposit", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2431, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2426, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2523, + "src": "3576:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2425, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3576:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2428, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2523, + "src": "3602:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2427, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3602:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2430, + "name": "_referralCode", + "nodeType": "VariableDeclaration", + "scope": 2523, + "src": "3627:20:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + "typeName": { + "id": 2429, + "name": "uint16", + "nodeType": "ElementaryTypeName", + "src": "3627:6:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3566:82:23" + }, + "returnParameters": { + "id": 2437, + "nodeType": "ParameterList", + "parameters": [], + "src": "3715:0:23" + }, + "scope": 4094, + "src": "3550:1162:23", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 2595, + "nodeType": "Block", + "src": "5056:705:23", + "statements": [ + { + "assignments": [ + 2541 + ], + "declarations": [ + { + "constant": false, + "id": 2541, + "name": "currentAvailableLiquidity", + "nodeType": "VariableDeclaration", + "scope": 2595, + "src": "5067:33:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2540, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5067:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2546, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2544, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5137:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2542, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5103:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2543, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveAvailableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5482, + "src": "5103:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2545, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5103:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5067:79:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2550, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2548, + "name": "currentAvailableLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2541, + "src": "5164:25:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 2549, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2529, + "src": "5193:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5164:36:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520746f2072656465656d", + "id": 2551, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5202:51:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3c94a5b9cef94ef9c462cd4975c6dd27736560c06935c214144f6e100bc129d5", + "typeString": "literal_string \"There is not enough liquidity available to redeem\"" + }, + "value": "There is not enough liquidity available to redeem" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_3c94a5b9cef94ef9c462cd4975c6dd27736560c06935c214144f6e100bc129d5", + "typeString": "literal_string \"There is not enough liquidity available to redeem\"" + } + ], + "id": 2547, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "5156:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2552, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5156:98:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2553, + "nodeType": "ExpressionStatement", + "src": "5156:98:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2557, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5360:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2554, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5324:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2556, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "5324:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2558, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5324:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2559, + "nodeType": "ExpressionStatement", + "src": "5324:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2563, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5473:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 2564, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2529, + "src": "5483:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2560, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5438:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2562, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4911, + "src": "5438:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 2565, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5438:53:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2566, + "nodeType": "ExpressionStatement", + "src": "5438:53:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2570, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5533:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2567, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5501:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2569, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "5501:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2571, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5501:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2572, + "nodeType": "ExpressionStatement", + "src": "5501:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2576, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5578:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2573, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5552:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2575, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "5552:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2577, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5552:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2578, + "nodeType": "ExpressionStatement", + "src": "5552:35:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2582, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5618:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 2583, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2527, + "src": "5628:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2584, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2529, + "src": "5635:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2579, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5598:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2581, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToUser", + "nodeType": "MemberAccess", + "referencedDeclaration": 6486, + "src": "5598:19:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) external" + } + }, + "id": 2585, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5598:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2586, + "nodeType": "ExpressionStatement", + "src": "5598:45:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2588, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5711:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 2589, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2527, + "src": "5721:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2590, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2529, + "src": "5728:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2591, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "5737:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 2592, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "5737:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 2587, + "name": "RedeemUnderlying", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2291, + "src": "5694:16:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256)" + } + }, + "id": 2593, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5694:59:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2594, + "nodeType": "EmitStatement", + "src": "5689:64:23" + } + ] + }, + "documentation": "@notice Allows to redeem a specific amount of underlying asset.\n@dev only aToken contracts can call this function", + "id": 2596, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 2532, + "modifierName": { + "argumentTypes": null, + "id": 2531, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "4985:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4985:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 2534, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5018:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 2535, + "modifierName": { + "argumentTypes": null, + "id": 2533, + "name": "onlyOverlyingAToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2374, + "src": "4998:19:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "4998:29:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 2537, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5046:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 2538, + "modifierName": { + "argumentTypes": null, + "id": 2536, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "5028:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "5028:27:23" + } + ], + "name": "redeemUnderlying", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2530, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2525, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2596, + "src": "4894:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2524, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4894:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2527, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2596, + "src": "4920:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 2526, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4920:15:23", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2529, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2596, + "src": "4951:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2528, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4951:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4884:83:23" + }, + "returnParameters": { + "id": 2539, + "nodeType": "ParameterList", + "parameters": [], + "src": "5056:0:23" + }, + "scope": 4094, + "src": "4859:902:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "canonicalName": "LendingPool.BorrowLocalVars", + "id": 2625, + "members": [ + { + "constant": false, + "id": 2598, + "name": "currentLtv", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "5890:18:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2597, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5890:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2600, + "name": "currentLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "5918:35:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2599, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5918:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2602, + "name": "borrowFee", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "5963:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2601, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5963:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2604, + "name": "requestedBorrowAmountETH", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "5990:32:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2603, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5990:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2606, + "name": "amountOfCollateralNeededETH", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6032:35:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2605, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6032:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2608, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6077:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2607, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6077:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2610, + "name": "compoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6117:31:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2609, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6117:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2612, + "name": "compoundedAmount", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6158:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2611, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6158:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2614, + "name": "userCollateralBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6192:32:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2613, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6192:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2616, + "name": "userBorrowBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6234:28:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2615, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6234:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2618, + "name": "healthFactor", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6272:20:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2617, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6272:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2620, + "name": "balanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6302:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2619, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6302:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2622, + "name": "currentReserveFixedRate", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6335:31:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2621, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6335:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2624, + "name": "availableLiquidity", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6376:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2623, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6376:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "BorrowLocalVars", + "nodeType": "StructDefinition", + "scope": 4094, + "src": "5857:552:23", + "visibility": "public" + }, + { + "body": { + "id": 3018, + "nodeType": "Block", + "src": "6729:6137:23", + "statements": [ + { + "assignments": [ + 2642 + ], + "declarations": [ + { + "constant": false, + "id": 2642, + "name": "vars", + "nodeType": "VariableDeclaration", + "scope": 3018, + "src": "6740:27:23", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars" + }, + "typeName": { + "contractScope": null, + "id": 2641, + "name": "BorrowLocalVars", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 2625, + "src": "6740:15:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_storage_ptr", + "typeString": "struct LendingPool.BorrowLocalVars" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2643, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "6740:27:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2647, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "6875:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2645, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "6844:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2646, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isReserveBorrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5832, + "src": "6844:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 2648, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6844:40:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "52657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e67", + "id": 2649, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6886:38:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + }, + "value": "Reserve is not enabled for borrowing" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + } + ], + "id": 2644, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "6836:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2650, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6836:89:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2651, + "nodeType": "ExpressionStatement", + "src": "6836:89:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2659, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2652, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "6996:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2654, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "availableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 2624, + "src": "6996:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2657, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "7056:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2655, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "7022:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2656, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveAvailableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5482, + "src": "7022:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2658, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7022:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6996:69:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2660, + "nodeType": "ExpressionStatement", + "src": "6996:69:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2665, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2662, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "7097:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2663, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "availableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 2624, + "src": "7097:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 2664, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "7124:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7097:34:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520696e207468652072657365727665", + "id": 2666, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7145:56:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_9c10b6537900636d83ba7fbecf42285691e54773e6afce15a8e3073697e73afc", + "typeString": "literal_string \"There is not enough liquidity available in the reserve\"" + }, + "value": "There is not enough liquidity available in the reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_9c10b6537900636d83ba7fbecf42285691e54773e6afce15a8e3073697e73afc", + "typeString": "literal_string \"There is not enough liquidity available in the reserve\"" + } + ], + "id": 2661, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "7076:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2667, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7076:135:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2668, + "nodeType": "ExpressionStatement", + "src": "7076:135:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2676, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2671, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "7273:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 2672, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "7273:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 2673, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "VARIABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7273:37:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + ], + "id": 2670, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "7268:4:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint" + }, + "id": 2674, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7268:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 2675, + "name": "_interestRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2631, + "src": "7315:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7268:64:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c696420696e7465726573742072617465206d6f64652073656c6563746564", + "id": 2677, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7334:37:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_148e2463e2c3f171ceacd1c76e5aaf02bc1873c12d85a90861cac2f1c00ea851", + "typeString": "literal_string \"Invalid interest rate mode selected\"" + }, + "value": "Invalid interest rate mode selected" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_148e2463e2c3f171ceacd1c76e5aaf02bc1873c12d85a90861cac2f1c00ea851", + "typeString": "literal_string \"Invalid interest rate mode selected\"" + } + ], + "id": 2669, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "7260:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2678, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7260:112:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2679, + "nodeType": "ExpressionStatement", + "src": "7260:112:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2686, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2680, + "name": "_interestRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2631, + "src": "7850:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2682, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "7879:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 2683, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "7879:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 2684, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7879:34:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + ], + "id": 2681, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "7871:7:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 2685, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7871:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7850:64:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 2754, + "nodeType": "IfStatement", + "src": "7847:1246:23", + "trueBody": { + "id": 2753, + "nodeType": "Block", + "src": "7916:1177:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 2699, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2694, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2688, + "name": "_interestRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2631, + "src": "8055:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2690, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "8084:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 2691, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "8084:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 2692, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "VARIABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8084:37:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + ], + "id": 2689, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "8076:7:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 2693, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8076:46:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8055:67:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2697, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "8182:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2695, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "8142:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2696, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveIsFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5870, + "src": "8142:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 2698, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8142:49:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "8055:136:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "466978656420626f72726f7773207261746520617265206e6f7420656e61626c6564206f6e20746869732072657365727665", + "id": 2700, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8209:52:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_30ae1e787de81771fb5e541f596463a9e035feec07d62cf38eac51130f3d5751", + "typeString": "literal_string \"Fixed borrows rate are not enabled on this reserve\"" + }, + "value": "Fixed borrows rate are not enabled on this reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_30ae1e787de81771fb5e541f596463a9e035feec07d62cf38eac51130f3d5751", + "typeString": "literal_string \"Fixed borrows rate are not enabled on this reserve\"" + } + ], + "id": 2687, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "8030:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2701, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8030:245:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2702, + "nodeType": "ExpressionStatement", + "src": "8030:245:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 2725, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 2716, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2710, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "8315:63:23", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2706, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "8357:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2707, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "8367:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2708, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8367:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2704, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "8316:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2705, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "8316:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 2709, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8316:62:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "id": 2715, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "8398:49:23", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2713, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "8438:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2711, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "8399:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2712, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isReserveUsageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5851, + "src": "8399:38:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 2714, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8399:48:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "8315:132:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2724, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2717, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "8467:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2720, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "8520:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2721, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "8530:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2722, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8530:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2718, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "8477:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 2719, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserUnderlyingAssetBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7008, + "src": "8477:42:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 2723, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8477:64:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8467:74:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "8315:226:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220697320747279696e6720746f20626f72726f7720616e20696e76616c696420616d6f756e74", + "id": 2726, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8559:44:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_d828d5250cbd206210abf2bf1b651ea1c5f80f5dc1f96d117696388e19c48244", + "typeString": "literal_string \"User is trying to borrow an invalid amount\"" + }, + "value": "User is trying to borrow an invalid amount" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_d828d5250cbd206210abf2bf1b651ea1c5f80f5dc1f96d117696388e19c48244", + "typeString": "literal_string \"User is trying to borrow an invalid amount\"" + } + ], + "id": 2703, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "8290:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2727, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8290:327:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2728, + "nodeType": "ExpressionStatement", + "src": "8290:327:23" + }, + { + "assignments": [ + 2730 + ], + "declarations": [ + { + "constant": false, + "id": 2730, + "name": "maxLoanPercent", + "nodeType": "VariableDeclaration", + "scope": 2753, + "src": "8797:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2729, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8797:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2734, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2731, + "name": "parametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2269, + "src": "8822:18:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "id": 2732, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getMaxFixedRateBorrowSizePercent", + "nodeType": "MemberAccess", + "referencedDeclaration": 1381, + "src": "8822:51:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$", + "typeString": "function () view external returns (uint256)" + } + }, + "id": 2733, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8822:53:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8797:78:23" + }, + { + "assignments": [ + 2736 + ], + "declarations": [ + { + "constant": false, + "id": 2736, + "name": "maxLoanSizeFixed", + "nodeType": "VariableDeclaration", + "scope": 2753, + "src": "8889:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2735, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8889:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2745, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 2743, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8964:3:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2740, + "name": "maxLoanPercent", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2730, + "src": "8944:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2737, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "8916:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2738, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "availableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 2624, + "src": "8916:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2739, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "8916:27:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2741, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8916:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2742, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "8916:47:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2744, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8916:52:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8889:79:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2749, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2747, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "8991:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<=", + "rightExpression": { + "argumentTypes": null, + "id": 2748, + "name": "maxLoanSizeFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2736, + "src": "9002:16:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8991:27:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220697320747279696e6720746f20626f72726f7720746f6f206d756368206c697175696469747920617420612066697865642072617465", + "id": 2750, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9020:61:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e7334a70b1b6a5df69ac251546afd886a5c469b034042a77e0cd31fc8a6c3d78", + "typeString": "literal_string \"User is trying to borrow too much liquidity at a fixed rate\"" + }, + "value": "User is trying to borrow too much liquidity at a fixed rate" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_e7334a70b1b6a5df69ac251546afd886a5c469b034042a77e0cd31fc8a6c3d78", + "typeString": "literal_string \"User is trying to borrow too much liquidity at a fixed rate\"" + } + ], + "id": 2746, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "8983:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2751, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8983:99:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2752, + "nodeType": "ExpressionStatement", + "src": "8983:99:23" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 2772, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2755, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9114:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2757, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "userCollateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2614, + "src": "9114:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2758, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9153:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2759, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "userBorrowBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2616, + "src": "9153:25:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2760, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9188:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2761, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentLtv", + "nodeType": "MemberAccess", + "referencedDeclaration": 2598, + "src": "9188:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2762, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9213:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2763, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 2600, + "src": "9213:32:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2764, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9255:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2765, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "healthFactor", + "nodeType": "MemberAccess", + "referencedDeclaration": 2618, + "src": "9255:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 2766, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "9103:170:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(,uint256,uint256,uint256,uint256,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2769, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "9313:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2770, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "9313:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2767, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "9276:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 2768, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "calculateUserGlobalData", + "nodeType": "MemberAccess", + "referencedDeclaration": 6984, + "src": "9276:36:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "id": 2771, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9276:48:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "src": "9103:221:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2773, + "nodeType": "ExpressionStatement", + "src": "9103:221:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2778, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2775, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9343:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2776, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCollateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2614, + "src": "9343:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 2777, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9375:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "9343:33:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520636f6c6c61746572616c2062616c616e63652069732030", + "id": 2779, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9378:29:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_4906e71889877e86aca58c927ee977f528175254bbe737726eb5fd4d4cde529b", + "typeString": "literal_string \"The collateral balance is 0\"" + }, + "value": "The collateral balance is 0" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_4906e71889877e86aca58c927ee977f528175254bbe737726eb5fd4d4cde529b", + "typeString": "literal_string \"The collateral balance is 0\"" + } + ], + "id": 2774, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "9335:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2780, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9335:73:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2781, + "nodeType": "ExpressionStatement", + "src": "9335:73:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2788, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2783, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9440:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2784, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "healthFactor", + "nodeType": "MemberAccess", + "referencedDeclaration": 2618, + "src": "9440:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2785, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "9460:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 2786, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getHealthFactorLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7263, + "src": "9460:48:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_pure$__$returns$_t_uint256_$", + "typeString": "function () pure external returns (uint256)" + } + }, + "id": 2787, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9460:50:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9440:70:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520626f72726f7765722063616e20616c7265616479206265206c69717569646174656420736f2068652063616e6e6f7420626f72726f77206d6f7265", + "id": 2789, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9524:65:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_0109ccf99421c8b30c361b04565d2bb05311b96001568cf2dffb17e909b7d2ca", + "typeString": "literal_string \"The borrower can already be liquidated so he cannot borrow more\"" + }, + "value": "The borrower can already be liquidated so he cannot borrow more" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_0109ccf99421c8b30c361b04565d2bb05311b96001568cf2dffb17e909b7d2ca", + "typeString": "literal_string \"The borrower can already be liquidated so he cannot borrow more\"" + } + ], + "id": 2782, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "9419:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2790, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9419:180:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2791, + "nodeType": "ExpressionStatement", + "src": "9419:180:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2805, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2792, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9638:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2794, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "borrowFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 2602, + "src": "9638:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2801, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "9745:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2802, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "9745:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2803, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "9769:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2796, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "9668:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2797, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeeProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1316, + "src": "9668:32:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 2798, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9668:34:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2795, + "name": "IFeeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1765, + "src": "9655:12:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IFeeProvider_$1765_$", + "typeString": "type(contract IFeeProvider)" + } + }, + "id": 2799, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9655:48:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFeeProvider_$1765", + "typeString": "contract IFeeProvider" + } + }, + "id": 2800, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "calculateLoanOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 1744, + "src": "9655:76:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (address,uint256) view external returns (uint256)" + } + }, + "id": 2804, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9655:131:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9638:148:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2806, + "nodeType": "ExpressionStatement", + "src": "9638:148:23" + }, + { + "assignments": [ + 2808 + ], + "declarations": [ + { + "constant": false, + "id": 2808, + "name": "oracle", + "nodeType": "VariableDeclaration", + "scope": 3018, + "src": "9797:19:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + }, + "typeName": { + "contractScope": null, + "id": 2807, + "name": "IPriceOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1959, + "src": "9797:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2814, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2810, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "9832:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2811, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getPriceOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1266, + "src": "9832:32:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 2812, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9832:34:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2809, + "name": "IPriceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1959, + "src": "9819:12:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IPriceOracle_$1959_$", + "typeString": "type(contract IPriceOracle)" + } + }, + "id": 2813, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9819:48:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9797:70:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2829, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2815, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9877:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2817, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "requestedBorrowAmountETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2604, + "src": "9877:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2825, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9959:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2826, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 2602, + "src": "9959:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2823, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "9947:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2824, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "9947:11:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2827, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9947:27:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2820, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "9930:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2818, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2808, + "src": "9909:6:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 2819, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getAssetPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 1941, + "src": "9909:20:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2821, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9909:30:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2822, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9072, + "src": "9909:37:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2828, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9909:66:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9877:98:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2830, + "nodeType": "ExpressionStatement", + "src": "9877:98:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2847, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2831, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10122:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2833, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "amountOfCollateralNeededETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2606, + "src": "10122:32:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2844, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10244:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2845, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentLtv", + "nodeType": "MemberAccess", + "referencedDeclaration": 2598, + "src": "10244:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 2841, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "10222:3:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2837, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10187:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2838, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "requestedBorrowAmountETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2604, + "src": "10187:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2834, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10157:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2835, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userBorrowBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2616, + "src": "10157:25:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2836, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "10157:29:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2839, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10157:60:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2840, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "10157:64:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2842, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10157:69:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2843, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "10157:73:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2846, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10157:112:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10122:147:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2848, + "nodeType": "ExpressionStatement", + "src": "10122:147:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2854, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2850, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10335:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2851, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "amountOfCollateralNeededETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2606, + "src": "10335:32:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<=", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2852, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10371:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2853, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCollateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2614, + "src": "10371:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10335:65:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468657265206973206e6f7420656e6f75676820636f6c6c61746572616c20746f20636f7665722061206e657720626f72726f77", + "id": 2855, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "10414:54:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_7d9e5bd094433ef0185b4582b59e6f8f44b32836fb1b79d11b395d7492eda7cd", + "typeString": "literal_string \"There is not enough collateral to cover a new borrow\"" + }, + "value": "There is not enough collateral to cover a new borrow" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_7d9e5bd094433ef0185b4582b59e6f8f44b32836fb1b79d11b395d7492eda7cd", + "typeString": "literal_string \"There is not enough collateral to cover a new borrow\"" + } + ], + "id": 2849, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "10314:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2856, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10314:164:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2857, + "nodeType": "ExpressionStatement", + "src": "10314:164:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2861, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "10702:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2858, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "10666:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2860, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "10666:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2862, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10666:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2863, + "nodeType": "ExpressionStatement", + "src": "10666:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2867, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "10770:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2868, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "10780:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2869, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "10780:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2864, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "10721:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2866, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserLastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 5170, + "src": "10721:48:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 2870, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10721:70:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2871, + "nodeType": "ExpressionStatement", + "src": "10721:70:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2886, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2872, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10931:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2874, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 2608, + "src": "10931:27:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2875, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10968:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2876, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "compoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 2610, + "src": "10968:28:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2877, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11006:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2878, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "compoundedAmount", + "nodeType": "MemberAccess", + "referencedDeclaration": 2612, + "src": "11006:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 2879, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "10930:98:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2882, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "11058:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2883, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "11068:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2884, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11068:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2880, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "11031:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2881, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "11031:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 2885, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11031:48:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "src": "10930:149:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2887, + "nodeType": "ExpressionStatement", + "src": "10930:149:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2896, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2888, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11090:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2890, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "balanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 2620, + "src": "11090:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2894, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "11139:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2891, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11113:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2892, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedAmount", + "nodeType": "MemberAccess", + "referencedDeclaration": 2612, + "src": "11113:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2893, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "11113:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2895, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11113:34:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11090:57:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2897, + "nodeType": "ExpressionStatement", + "src": "11090:57:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2905, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2898, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11421:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2900, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentReserveFixedRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 2622, + "src": "11421:28:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2903, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "11490:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2901, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "11452:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2902, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5681, + "src": "11452:37:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2904, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11452:47:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11421:78:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2906, + "nodeType": "ExpressionStatement", + "src": "11421:78:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2910, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "11564:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2911, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "11586:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2912, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11586:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2913, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11610:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2914, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 2608, + "src": "11610:27:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2915, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11651:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2916, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 2620, + "src": "11651:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2919, + "name": "_interestRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2631, + "src": "11714:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2917, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "11685:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 2918, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "11685:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 2920, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11685:47:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2921, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11746:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2922, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentReserveFixedRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 2622, + "src": "11746:28:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2907, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "11510:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2909, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveTotalBorrowsByRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5121, + "src": "11510:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$_t_enum$_InterestRateMode_$8267_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256,enum CoreLibrary.InterestRateMode,uint256) external" + } + }, + "id": 2923, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11510:274:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2924, + "nodeType": "ExpressionStatement", + "src": "11510:274:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2931, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2925, + "name": "_interestRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2631, + "src": "11851:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2927, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "11880:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 2928, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "11880:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 2929, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11880:34:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + ], + "id": 2926, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "11872:7:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 2930, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11872:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11851:64:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 2949, + "nodeType": "Block", + "src": "12000:99:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2944, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12067:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2945, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12077:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2946, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12077:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2941, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12037:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2943, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "resetUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5420, + "src": "12037:29:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 2947, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12037:51:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2948, + "nodeType": "ExpressionStatement", + "src": "12037:51:23" + } + ] + }, + "id": 2950, + "nodeType": "IfStatement", + "src": "11847:252:23", + "trueBody": { + "id": 2940, + "nodeType": "Block", + "src": "11917:77:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2935, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "11962:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2936, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "11972:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2937, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11972:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2932, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "11931:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2934, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5394, + "src": "11931:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 2938, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11931:52:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2939, + "nodeType": "ExpressionStatement", + "src": "11931:52:23" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2954, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12223:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2955, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "12233:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2956, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedAmount", + "nodeType": "MemberAccess", + "referencedDeclaration": 2612, + "src": "12233:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2951, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12188:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2953, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "12188:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 2957, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12188:67:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2958, + "nodeType": "ExpressionStatement", + "src": "12188:67:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2962, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12298:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2959, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12266:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2961, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "12266:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2963, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12266:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2964, + "nodeType": "ExpressionStatement", + "src": "12266:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2968, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12343:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2965, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12317:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2967, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "12317:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2969, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12317:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2970, + "nodeType": "ExpressionStatement", + "src": "12317:35:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2974, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12450:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2975, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12460:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2976, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12460:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2977, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "12472:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2978, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 2620, + "src": "12472:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2971, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12410:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2973, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseUserPrincipalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 5269, + "src": "12410:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 2979, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12410:83:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2980, + "nodeType": "ExpressionStatement", + "src": "12410:83:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2984, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12535:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2985, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12545:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2986, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12545:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2987, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "12557:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2988, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 2602, + "src": "12557:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2981, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12503:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2983, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseUserOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 5202, + "src": "12503:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 2989, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12503:69:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2990, + "nodeType": "ExpressionStatement", + "src": "12503:69:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2994, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12605:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2995, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12615:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2996, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12615:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2991, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12582:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2993, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5366, + "src": "12582:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 2997, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12582:44:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2998, + "nodeType": "ExpressionStatement", + "src": "12582:44:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3002, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12709:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3003, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12719:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3004, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12719:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3005, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "12731:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2999, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12689:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3001, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToUser", + "nodeType": "MemberAccess", + "referencedDeclaration": 6486, + "src": "12689:19:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) external" + } + }, + "id": 3006, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12689:50:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3007, + "nodeType": "ExpressionStatement", + "src": "12689:50:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3009, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12797:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3010, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12807:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3011, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12807:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3012, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "12819:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3013, + "name": "_referralCode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2633, + "src": "12828:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3014, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "12843:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 3015, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12843:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 3008, + "name": "Borrow", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2303, + "src": "12790:6:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint16_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint16,uint256)" + } + }, + "id": 3016, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12790:69:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3017, + "nodeType": "EmitStatement", + "src": "12785:74:23" + } + ] + }, + "documentation": "@notice executes a borrow on the reserve of the specific amount with the interestRateMode specified.", + "id": 3019, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 2636, + "modifierName": { + "argumentTypes": null, + "id": 2635, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "6688:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6688:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 2638, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "6719:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 2639, + "modifierName": { + "argumentTypes": null, + "id": 2637, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "6701:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "6701:27:23" + } + ], + "name": "borrow", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2634, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2627, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3019, + "src": "6563:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2626, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6563:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2629, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 3019, + "src": "6589:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2628, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6589:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2631, + "name": "_interestRateMode", + "nodeType": "VariableDeclaration", + "scope": 3019, + "src": "6614:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2630, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6614:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2633, + "name": "_referralCode", + "nodeType": "VariableDeclaration", + "scope": 3019, + "src": "6649:20:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + "typeName": { + "id": 2632, + "name": "uint16", + "nodeType": "ElementaryTypeName", + "src": "6649:6:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6553:117:23" + }, + "returnParameters": { + "id": 2640, + "nodeType": "ParameterList", + "parameters": [], + "src": "6729:0:23" + }, + "scope": 4094, + "src": "6538:6328:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3289, + "nodeType": "Block", + "src": "13319:3782:23", + "statements": [ + { + "assignments": [ + 3034, + 3036, + 3038 + ], + "declarations": [ + { + "constant": false, + "id": 3034, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "13331:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3033, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13331:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3036, + "name": "compoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "13371:31:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3035, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13371:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3038, + "name": "borrowBalanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "13412:29:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3037, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13412:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3044, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3041, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "13472:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3042, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "13482:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3039, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "13445:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3040, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "13445:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 3043, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13445:49:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13330:164:23" + }, + { + "assignments": [ + 3046 + ], + "declarations": [ + { + "constant": false, + "id": 3046, + "name": "originationFee", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "13505:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3045, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13505:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3052, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3049, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "13557:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3050, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "13567:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3047, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "13530:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3048, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 5956, + "src": "13530:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3051, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13530:49:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13505:74:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3056, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3054, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3036, + "src": "13598:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3055, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "13624:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "13598:27:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "546865207573657220646f6573206e6f74206861766520616e7920626f72726f772070656e64696e67", + "id": 3057, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "13627:43:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c7917d465aa2240787bb76493308d4332358c1988a6a1162a1c5ffa34fc9f2c4", + "typeString": "literal_string \"The user does not have any borrow pending\"" + }, + "value": "The user does not have any borrow pending" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_c7917d465aa2240787bb76493308d4332358c1988a6a1162a1c5ffa34fc9f2c4", + "typeString": "literal_string \"The user does not have any borrow pending\"" + } + ], + "id": 3053, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "13590:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3058, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13590:81:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3059, + "nodeType": "ExpressionStatement", + "src": "13590:81:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 3068, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3063, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3061, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3023, + "src": "13703:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 3062, + "name": "UINT_MAX_VALUE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2390, + "src": "13714:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13703:25:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "id": 3067, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3064, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "13732:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "13732:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 3066, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "13746:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "13732:25:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "13703:54:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "546f207265706179206f6e20626568616c66206f6620616e207573657220616e206578706c6963697420616d6f756e7420746f207265706179206973206e65656465642e", + "id": 3069, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "13771:70:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e6331304cf90ad18bd8dda0978ea7dab720dfa02bd139bfa14dc42aa91cebb45", + "typeString": "literal_string \"To repay on behalf of an user an explicit amount to repay is needed.\"" + }, + "value": "To repay on behalf of an user an explicit amount to repay is needed." + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_e6331304cf90ad18bd8dda0978ea7dab720dfa02bd139bfa14dc42aa91cebb45", + "typeString": "literal_string \"To repay on behalf of an user an explicit amount to repay is needed.\"" + } + ], + "id": 3060, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "13682:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3070, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13682:169:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3071, + "nodeType": "ExpressionStatement", + "src": "13682:169:23" + }, + { + "assignments": [ + 3073 + ], + "declarations": [ + { + "constant": false, + "id": 3073, + "name": "paybackAmount", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "13894:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3072, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13894:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3078, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3076, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3046, + "src": "13946:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3074, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3036, + "src": "13918:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3075, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "13918:27:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3077, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13918:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13894:67:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 3085, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3081, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3079, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3023, + "src": "13976:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 3080, + "name": "UINT_MAX_VALUE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2390, + "src": "13987:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13976:25:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "&&", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3084, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3082, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3023, + "src": "14005:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "id": 3083, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14015:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "14005:23:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "13976:52:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 3091, + "nodeType": "IfStatement", + "src": "13972:106:23", + "trueBody": { + "id": 3090, + "nodeType": "Block", + "src": "14030:48:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 3088, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 3086, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14044:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 3087, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3023, + "src": "14060:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "14044:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3089, + "nodeType": "ExpressionStatement", + "src": "14044:23:23" + } + ] + } + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3094, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3092, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14209:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<=", + "rightExpression": { + "argumentTypes": null, + "id": 3093, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3046, + "src": "14226:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "14209:31:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 3125, + "nodeType": "IfStatement", + "src": "14205:440:23", + "trueBody": { + "id": 3124, + "nodeType": "Block", + "src": "14242:403:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3098, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "14288:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3099, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "14298:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3100, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14311:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3095, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "14256:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3097, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseUserOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 5234, + "src": "14256:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 3101, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14256:69:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3102, + "nodeType": "ExpressionStatement", + "src": "14256:69:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3111, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "14409:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3112, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "14435:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3113, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14464:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3115, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "14508:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 3116, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeeProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1316, + "src": "14508:32:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 3117, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14508:34:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 3114, + "name": "IFeeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1765, + "src": "14495:12:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IFeeProvider_$1765_$", + "typeString": "type(contract IFeeProvider)" + } + }, + "id": 3118, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14495:48:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFeeProvider_$1765", + "typeString": "contract IFeeProvider" + } + }, + "id": 3119, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeesCollectionAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1764, + "src": "14495:73:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 3120, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14495:75:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3108, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "14381:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3109, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "14381:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3103, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "14339:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3106, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToFeeCollectionAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 6537, + "src": "14339:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$", + "typeString": "function (address,address,uint256,address) payable external" + } + }, + "id": 3107, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "14339:41:23", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$value_$", + "typeString": "function (uint256) returns (function (address,address,uint256,address) payable external)" + } + }, + "id": 3110, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14339:52:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$value", + "typeString": "function (address,address,uint256,address) payable external" + } + }, + "id": 3121, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14339:245:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3122, + "nodeType": "ExpressionStatement", + "src": "14339:245:23" + }, + { + "expression": null, + "functionReturnParameters": 3032, + "id": 3123, + "nodeType": "Return", + "src": "14628:7:23" + } + ] + } + }, + { + "assignments": [ + 3127 + ], + "declarations": [ + { + "constant": false, + "id": 3127, + "name": "paybackAmountMinusFees", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "14655:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3126, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14655:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3132, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3130, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3046, + "src": "14706:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3128, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14688:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3129, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "14688:17:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3131, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14688:33:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14655:66:23" + }, + { + "assignments": [ + 3134 + ], + "declarations": [ + { + "constant": false, + "id": 3134, + "name": "actualBalanceDecrease", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "14731:29:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3133, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14731:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3139, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3137, + "name": "borrowBalanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3038, + "src": "14790:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3135, + "name": "paybackAmountMinusFees", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3127, + "src": "14763:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3136, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "14763:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3138, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14763:49:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14731:81:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3143, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "14907:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3144, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "14917:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3145, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3046, + "src": "14930:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3140, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "14875:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3142, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseUserOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 5234, + "src": "14875:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 3146, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14875:70:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3147, + "nodeType": "ExpressionStatement", + "src": "14875:70:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3156, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15021:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3157, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "15043:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3158, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3046, + "src": "15068:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3160, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "15109:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 3161, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeeProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1316, + "src": "15109:32:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 3162, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15109:34:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 3159, + "name": "IFeeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1765, + "src": "15096:12:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IFeeProvider_$1765_$", + "typeString": "type(contract IFeeProvider)" + } + }, + "id": 3163, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15096:48:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFeeProvider_$1765", + "typeString": "contract IFeeProvider" + } + }, + "id": 3164, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeesCollectionAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1764, + "src": "15096:73:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 3165, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15096:75:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3153, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "14997:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3154, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "14997:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3148, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "14955:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3151, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToFeeCollectionAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 6537, + "src": "14955:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$", + "typeString": "function (address,address,uint256,address) payable external" + } + }, + "id": 3152, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "14955:41:23", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$value_$", + "typeString": "function (uint256) returns (function (address,address,uint256,address) payable external)" + } + }, + "id": 3155, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14955:52:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$value", + "typeString": "function (address,address,uint256,address) payable external" + } + }, + "id": 3166, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14955:226:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3167, + "nodeType": "ExpressionStatement", + "src": "14955:226:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3171, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15348:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3168, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "15312:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3170, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "15312:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3172, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15312:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3173, + "nodeType": "ExpressionStatement", + "src": "15312:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3177, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15416:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3178, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "15426:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3174, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "15367:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3176, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserLastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 5170, + "src": "15367:48:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3179, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15367:71:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3180, + "nodeType": "ExpressionStatement", + "src": "15367:71:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3184, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15523:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3185, + "name": "borrowBalanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3038, + "src": "15533:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3181, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "15488:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3183, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "15488:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3186, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15488:67:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3187, + "nodeType": "ExpressionStatement", + "src": "15488:67:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3191, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15730:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3192, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "15740:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3193, + "name": "actualBalanceDecrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3134, + "src": "15753:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3188, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "15690:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3190, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseUserPrincipalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 5309, + "src": "15690:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 3194, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15690:85:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3195, + "nodeType": "ExpressionStatement", + "src": "15690:85:23" + }, + { + "assignments": [ + 3199 + ], + "declarations": [ + { + "constant": false, + "id": 3199, + "name": "borrowRateMode", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "15891:43:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 3198, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "15891:28:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3205, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3202, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15971:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3203, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "15981:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3200, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "15937:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3201, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentBorrowRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5988, + "src": "15937:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view external returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3204, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15937:56:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "15891:102:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 3210, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3206, + "name": "borrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3199, + "src": "16008:14:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3207, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "16026:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 3208, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "16026:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3209, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "16026:34:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "16008:52:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 3247, + "nodeType": "Block", + "src": "16642:98:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3243, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16697:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3244, + "name": "actualBalanceDecrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3134, + "src": "16707:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3240, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16656:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3242, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 4991, + "src": "16656:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3245, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16656:73:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3246, + "nodeType": "ExpressionStatement", + "src": "16656:73:23" + } + ] + }, + "id": 3248, + "nodeType": "IfStatement", + "src": "16004:736:23", + "trueBody": { + "id": 3239, + "nodeType": "Block", + "src": "16062:574:23", + "statements": [ + { + "assignments": [ + 3212 + ], + "declarations": [ + { + "constant": false, + "id": 3212, + "name": "currentFixedRate", + "nodeType": "VariableDeclaration", + "scope": 3239, + "src": "16076:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3211, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "16076:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3218, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3215, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16138:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3216, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "16148:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3213, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16103:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3214, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6011, + "src": "16103:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3217, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16103:57:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "16076:84:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3222, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16232:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3223, + "name": "actualBalanceDecrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3134, + "src": "16242:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3224, + "name": "currentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3212, + "src": "16265:16:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3219, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16174:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3221, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 4954, + "src": "16174:57:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 3225, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16174:108:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3226, + "nodeType": "ExpressionStatement", + "src": "16174:108:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3229, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3227, + "name": "actualBalanceDecrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3134, + "src": "16492:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 3228, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3034, + "src": "16517:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "16492:47:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 3238, + "nodeType": "IfStatement", + "src": "16489:137:23", + "trueBody": { + "id": 3237, + "nodeType": "Block", + "src": "16541:85:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3233, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16589:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3234, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "16599:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3230, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16559:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3232, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "resetUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5420, + "src": "16559:29:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3235, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16559:52:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3236, + "nodeType": "ExpressionStatement", + "src": "16559:52:23" + } + ] + } + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3252, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16782:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3249, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16750:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3251, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "16750:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3253, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16750:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3254, + "nodeType": "ExpressionStatement", + "src": "16750:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3258, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16828:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3255, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16802:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3257, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "16802:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3259, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16802:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3260, + "nodeType": "ExpressionStatement", + "src": "16802:35:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3264, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16870:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3265, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "16880:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3261, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16847:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3263, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5366, + "src": "16847:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3266, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16847:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3267, + "nodeType": "ExpressionStatement", + "src": "16847:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3276, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16943:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3277, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "16953:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3278, + "name": "paybackAmountMinusFees", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3127, + "src": "16966:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3273, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "16932:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3274, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "16932:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3268, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16903:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3271, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6619, + "src": "16903:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 3272, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "16903:28:23", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value_$", + "typeString": "function (uint256) returns (function (address,address payable,uint256) payable external)" + } + }, + "id": 3275, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16903:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 3279, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16903:86:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3280, + "nodeType": "ExpressionStatement", + "src": "16903:86:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3282, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "17046:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3283, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "17056:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3284, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3023, + "src": "17069:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3285, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "17078:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 3286, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "17078:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 3281, + "name": "Repay", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2313, + "src": "17040:5:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256)" + } + }, + "id": 3287, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17040:54:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3288, + "nodeType": "EmitStatement", + "src": "17035:59:23" + } + ] + }, + "documentation": "@notice repays a borrow on the specific reserve, for the specified amount.\n@dev the target user is defined by _onBehalfOf. If there is no repayment on behalf of another account,\n_onBehalfOf must be equal to msg.sender.", + "id": 3290, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3028, + "modifierName": { + "argumentTypes": null, + "id": 3027, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "13270:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "13270:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 3030, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "13309:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 3031, + "modifierName": { + "argumentTypes": null, + "id": 3029, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "13291:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "13291:27:23" + } + ], + "name": "repay", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3026, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3021, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3290, + "src": "13149:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3020, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13149:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3023, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 3290, + "src": "13175:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3022, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13175:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3025, + "name": "_onBehalfOf", + "nodeType": "VariableDeclaration", + "scope": 3290, + "src": "13200:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 3024, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13200:15:23", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13139:89:23" + }, + "returnParameters": { + "id": 3032, + "nodeType": "ParameterList", + "parameters": [], + "src": "13319:0:23" + }, + "scope": 4094, + "src": "13125:3976:23", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3493, + "nodeType": "Block", + "src": "17325:2987:23", + "statements": [ + { + "assignments": [ + 3303 + ], + "declarations": [ + { + "constant": false, + "id": 3303, + "name": "currentRateMode", + "nodeType": "VariableDeclaration", + "scope": 3493, + "src": "17336:44:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 3302, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "17336:28:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3310, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3306, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "17417:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3307, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "17427:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3308, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "17427:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3304, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "17383:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3305, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentBorrowRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5988, + "src": "17383:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view external returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3309, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17383:55:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17336:102:23" + }, + { + "assignments": [ + 3312, + 3314, + 3316 + ], + "declarations": [ + { + "constant": false, + "id": 3312, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 3493, + "src": "17449:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3311, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "17449:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3314, + "name": "compoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 3493, + "src": "17489:31:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3313, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "17489:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3316, + "name": "balanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 3493, + "src": "17530:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3315, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "17530:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3323, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3319, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "17584:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3320, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "17594:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3321, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "17594:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3317, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "17557:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3318, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "17557:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 3322, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17557:48:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17448:157:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3327, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3325, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3314, + "src": "17624:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3326, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "17650:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "17624:27:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220646f6573206e6f742068617665206120626f72726f7720696e2070726f6772657373206f6e20746869732072657365727665", + "id": 3328, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "17653:57:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_718668e522954015c4c3baf01c0871155fb82c8781867444b9071c1e053b8de3", + "typeString": "literal_string \"User does not have a borrow in progress on this reserve\"" + }, + "value": "User does not have a borrow in progress on this reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_718668e522954015c4c3baf01c0871155fb82c8781867444b9071c1e053b8de3", + "typeString": "literal_string \"User does not have a borrow in progress on this reserve\"" + } + ], + "id": 3324, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "17616:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3329, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17616:95:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3330, + "nodeType": "ExpressionStatement", + "src": "17616:95:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3334, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "17796:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3331, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "17760:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3333, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "17760:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3335, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17760:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3336, + "nodeType": "ExpressionStatement", + "src": "17760:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3340, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "17864:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3341, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "17874:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3342, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "17874:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3337, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "17815:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3339, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserLastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 5170, + "src": "17815:48:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3343, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17815:70:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3344, + "nodeType": "ExpressionStatement", + "src": "17815:70:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 3349, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3345, + "name": "currentRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3303, + "src": "17899:15:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3346, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "17918:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 3347, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "17918:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3348, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "17918:34:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "17899:53:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 3447, + "nodeType": "Block", + "src": "18455:1404:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3386, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "18957:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3384, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "18917:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3385, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveIsFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5870, + "src": "18917:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 3387, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "18917:49:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "466978656420626f72726f7773207261746520617265206e6f7420656e61626c6564206f6e20746869732072657365727665", + "id": 3388, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "18984:52:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_30ae1e787de81771fb5e541f596463a9e035feec07d62cf38eac51130f3d5751", + "typeString": "literal_string \"Fixed borrows rate are not enabled on this reserve\"" + }, + "value": "Fixed borrows rate are not enabled on this reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_30ae1e787de81771fb5e541f596463a9e035feec07d62cf38eac51130f3d5751", + "typeString": "literal_string \"Fixed borrows rate are not enabled on this reserve\"" + } + ], + "id": 3383, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "18892:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3389, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "18892:158:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3390, + "nodeType": "ExpressionStatement", + "src": "18892:158:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 3413, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 3404, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3398, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "19090:63:23", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3394, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19132:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3395, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "19142:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3396, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "19142:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3392, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19091:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3393, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "19091:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 3397, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19091:62:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "id": 3403, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "19173:49:23", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3401, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19213:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3399, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19174:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3400, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isReserveUsageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5851, + "src": "19174:38:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 3402, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19174:48:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "19090:132:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3412, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3405, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3314, + "src": "19242:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3408, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19311:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3409, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "19321:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3410, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "19321:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3406, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "19268:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3407, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserUnderlyingAssetBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7008, + "src": "19268:42:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3411, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19268:64:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "19242:90:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "19090:242:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220697320747279696e6720746f20626f72726f7720616e20616d6f756e74207468617420697320736d616c6c6572207468616e2077686174206865206465706f73697465642e", + "id": 3414, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "19350:76:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8e8988b95b250557994d0199f494f8a57e6ed9d03c97f897c930ab8fb8cdf6e8", + "typeString": "literal_string \"User is trying to borrow an amount that is smaller than what he deposited.\"" + }, + "value": "User is trying to borrow an amount that is smaller than what he deposited." + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_8e8988b95b250557994d0199f494f8a57e6ed9d03c97f897c930ab8fb8cdf6e8", + "typeString": "literal_string \"User is trying to borrow an amount that is smaller than what he deposited.\"" + } + ], + "id": 3391, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "19065:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3415, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19065:375:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3416, + "nodeType": "ExpressionStatement", + "src": "19065:375:23" + }, + { + "assignments": [ + 3418 + ], + "declarations": [ + { + "constant": false, + "id": 3418, + "name": "currentFixedRate", + "nodeType": "VariableDeclaration", + "scope": 3447, + "src": "19497:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3417, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "19497:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3423, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3421, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19562:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3419, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19524:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3420, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5681, + "src": "19524:37:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3422, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19524:47:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "19497:74:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3427, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19626:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3428, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3312, + "src": "19636:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3424, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19585:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3426, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 4991, + "src": "19585:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3429, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19585:74:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3430, + "nodeType": "ExpressionStatement", + "src": "19585:74:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3434, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19731:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3435, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3314, + "src": "19741:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3436, + "name": "currentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3418, + "src": "19766:16:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3431, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19673:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3433, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 4934, + "src": "19673:57:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 3437, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19673:110:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3438, + "nodeType": "ExpressionStatement", + "src": "19673:110:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3442, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19828:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3443, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "19837:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3444, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "19837:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3439, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19797:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3441, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5394, + "src": "19797:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3445, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19797:51:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3446, + "nodeType": "ExpressionStatement", + "src": "19797:51:23" + } + ] + }, + "id": 3448, + "nodeType": "IfStatement", + "src": "17896:1963:23", + "trueBody": { + "id": 3382, + "nodeType": "Block", + "src": "17953:488:23", + "statements": [ + { + "assignments": [ + 3351 + ], + "declarations": [ + { + "constant": false, + "id": 3351, + "name": "userFixedRate", + "nodeType": "VariableDeclaration", + "scope": 3382, + "src": "17968:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3350, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "17968:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3358, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3354, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "18027:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3355, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "18037:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3356, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "18037:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3352, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "17992:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3353, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6011, + "src": "17992:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3357, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17992:56:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17968:80:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3362, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "18154:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3363, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3312, + "src": "18164:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3364, + "name": "userFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3351, + "src": "18188:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3359, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "18096:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3361, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 4954, + "src": "18096:57:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 3365, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "18096:106:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3366, + "nodeType": "ExpressionStatement", + "src": "18096:106:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3370, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "18303:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3371, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3314, + "src": "18313:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3367, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "18262:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3369, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 4974, + "src": "18262:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3372, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "18262:75:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3373, + "nodeType": "ExpressionStatement", + "src": "18262:75:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3377, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "18409:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3378, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "18419:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3379, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "18419:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3374, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "18379:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3376, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "resetUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5420, + "src": "18379:29:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3380, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "18379:51:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3381, + "nodeType": "ExpressionStatement", + "src": "18379:51:23" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3452, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19904:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3453, + "name": "balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3316, + "src": "19914:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3449, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19869:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3451, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "19869:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3454, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19869:61:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3455, + "nodeType": "ExpressionStatement", + "src": "19869:61:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3459, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19972:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3456, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19940:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3458, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "19940:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3460, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19940:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3461, + "nodeType": "ExpressionStatement", + "src": "19940:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3465, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "20074:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3466, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "20084:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3467, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "20084:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3468, + "name": "balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3316, + "src": "20096:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3462, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "20034:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3464, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseUserPrincipalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 5269, + "src": "20034:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 3469, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20034:78:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3470, + "nodeType": "ExpressionStatement", + "src": "20034:78:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3474, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "20148:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3471, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "20122:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3473, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "20122:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3475, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20122:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3476, + "nodeType": "ExpressionStatement", + "src": "20122:35:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3480, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "20190:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3481, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "20200:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3482, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "20200:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3477, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "20167:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3479, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5366, + "src": "20167:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3483, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20167:44:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3484, + "nodeType": "ExpressionStatement", + "src": "20167:44:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3486, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "20267:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3487, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "20277:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3488, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "20277:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3489, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "20289:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 3490, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "20289:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 3485, + "name": "Swap", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2333, + "src": "20262:4:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256)" + } + }, + "id": 3491, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20262:43:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3492, + "nodeType": "EmitStatement", + "src": "20257:48:23" + } + ] + }, + "documentation": "@notice allows the user to swap the current borrow rate mode, from fixed to variable and viceversa.", + "id": 3494, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3295, + "modifierName": { + "argumentTypes": null, + "id": 3294, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "17284:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "17284:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 3297, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "17315:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 3298, + "modifierName": { + "argumentTypes": null, + "id": 3296, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "17297:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "17297:27:23" + } + ], + "name": "swapBorrowRateMode", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3293, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3292, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3494, + "src": "17257:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3291, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "17257:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17256:18:23" + }, + "returnParameters": { + "id": 3299, + "nodeType": "ParameterList", + "parameters": [], + "src": "17325:0:23" + }, + "scope": 4094, + "src": "17229:3083:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3634, + "nodeType": "Block", + "src": "20690:2313:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 3512, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3506, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "20756:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3507, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3498, + "src": "20765:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3504, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "20722:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3505, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentBorrowRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5988, + "src": "20722:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view external returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3508, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20722:49:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3509, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "20775:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 3510, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "20775:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3511, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "20775:34:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "20722:87:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "546865207573657220626f72726f77206973207661726961626c6520616e642063616e6e6f7420626520726562616c616e636564", + "id": 3513, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "20823:54:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5a98527d2c56c096e76351ae749fedf53c91d460e35716d4ed657129cb941c65", + "typeString": "literal_string \"The user borrow is variable and cannot be rebalanced\"" + }, + "value": "The user borrow is variable and cannot be rebalanced" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_5a98527d2c56c096e76351ae749fedf53c91d460e35716d4ed657129cb941c65", + "typeString": "literal_string \"The user borrow is variable and cannot be rebalanced\"" + } + ], + "id": 3503, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "20701:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3514, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20701:190:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3515, + "nodeType": "ExpressionStatement", + "src": "20701:190:23" + }, + { + "assignments": [ + null, + 3517, + 3519 + ], + "declarations": [ + null, + { + "constant": false, + "id": 3517, + "name": "compoundedBalance", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "20913:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3516, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "20913:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3519, + "name": "balanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "20948:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3518, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "20948:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3526, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3522, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21002:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3523, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "21012:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3524, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "21012:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3520, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "20975:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3521, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "20975:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 3525, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20975:48:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "20902:121:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3530, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3528, + "name": "compoundedBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3517, + "src": "21124:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3529, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "21144:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "21124:21:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220646f6573206e6f74206861766520616e7920626f72726f7720666f7220746869732072657365727665", + "id": 3531, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "21159:48:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_1915b15b36ed5f5832a0d8c5f32f46d29e23c7345a8bcbc53a2390a08be12a0a", + "typeString": "literal_string \"User does not have any borrow for this reserve\"" + }, + "value": "User does not have any borrow for this reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_1915b15b36ed5f5832a0d8c5f32f46d29e23c7345a8bcbc53a2390a08be12a0a", + "typeString": "literal_string \"User does not have any borrow for this reserve\"" + } + ], + "id": 3527, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "21103:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3532, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21103:105:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3533, + "nodeType": "ExpressionStatement", + "src": "21103:105:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3537, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21313:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3534, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21277:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3536, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "21277:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3538, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21277:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3539, + "nodeType": "ExpressionStatement", + "src": "21277:45:23" + }, + { + "assignments": [ + 3541 + ], + "declarations": [ + { + "constant": false, + "id": 3541, + "name": "userCurrentFixedRate", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "21333:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3540, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "21333:4:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3547, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3544, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21396:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3545, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3498, + "src": "21405:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3542, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21361:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3543, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6011, + "src": "21361:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3546, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21361:50:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "21333:78:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3551, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21479:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3552, + "name": "balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3519, + "src": "21489:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3553, + "name": "userCurrentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3541, + "src": "21506:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3548, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21421:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3550, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 4934, + "src": "21421:57:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 3554, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21421:106:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3555, + "nodeType": "ExpressionStatement", + "src": "21421:106:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3559, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21577:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3560, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3498, + "src": "21587:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3561, + "name": "balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3519, + "src": "21594:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3556, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21537:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3558, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseUserPrincipalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 5269, + "src": "21537:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 3562, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21537:73:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3563, + "nodeType": "ExpressionStatement", + "src": "21537:73:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3567, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21655:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3568, + "name": "balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3519, + "src": "21665:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3564, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21620:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3566, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "21620:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3569, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21620:61:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3570, + "nodeType": "ExpressionStatement", + "src": "21620:61:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3574, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21717:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3571, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21691:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3573, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "21691:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3575, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21691:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3576, + "nodeType": "ExpressionStatement", + "src": "21691:35:23" + }, + { + "assignments": [ + 3578 + ], + "declarations": [ + { + "constant": false, + "id": 3578, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "21737:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3577, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "21737:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3583, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3581, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21797:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3579, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21761:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3580, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5719, + "src": "21761:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3582, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21761:45:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "21737:69:23" + }, + { + "assignments": [ + 3585 + ], + "declarations": [ + { + "constant": false, + "id": 3585, + "name": "reserveCurrentFixedRate", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "21816:31:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3584, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "21816:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3590, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3588, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21888:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3586, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21850:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3587, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5681, + "src": "21850:37:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3589, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21850:47:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "21816:81:23" + }, + { + "assignments": [ + 3592 + ], + "declarations": [ + { + "constant": false, + "id": 3592, + "name": "rebalanceDownRateThreshold", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "21907:34:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3591, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "21907:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3604, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3599, + "name": "parametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2269, + "src": "22052:18:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "id": 3600, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getRebalanceDownRateDelta", + "nodeType": "MemberAccess", + "referencedDeclaration": 1404, + "src": "22052:44:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$", + "typeString": "function () view external returns (uint256)" + } + }, + "id": 3601, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22052:46:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3595, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "21988:10:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 3596, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "21988:27:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 3597, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21988:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3598, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "21988:46:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3602, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21988:124:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3593, + "name": "reserveCurrentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3585, + "src": "21944:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3594, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "21944:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3603, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21944:169:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "21907:206:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 3611, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3607, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3605, + "name": "userCurrentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3541, + "src": "22636:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "id": 3606, + "name": "liquidityRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3578, + "src": "22659:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "22636:36:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3610, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3608, + "name": "userCurrentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3541, + "src": "22684:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 3609, + "name": "rebalanceDownRateThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3592, + "src": "22707:26:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "22684:49:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "22636:97:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 3629, + "nodeType": "IfStatement", + "src": "22633:295:23", + "trueBody": { + "id": 3628, + "nodeType": "Block", + "src": "22744:184:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3615, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "22824:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3616, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "22833:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3617, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "22833:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3612, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "22793:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3614, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5394, + "src": "22793:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3618, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22793:51:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3619, + "nodeType": "ExpressionStatement", + "src": "22793:51:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3623, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "22881:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3624, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3498, + "src": "22891:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3620, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "22858:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3622, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5366, + "src": "22858:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3625, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22858:39:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3626, + "nodeType": "ExpressionStatement", + "src": "22858:39:23" + }, + { + "expression": null, + "functionReturnParameters": 3502, + "id": 3627, + "nodeType": "Return", + "src": "22911:7:23" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "496e746572657374207261746520726562616c616e636520636f6e646974696f6e73207768657265206e6f74206d6574", + "id": 3631, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "22945:50:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_6b84664b8ca5227a94caf7c150601896d3e2ce55785142f35c5271266a66d288", + "typeString": "literal_string \"Interest rate rebalance conditions where not met\"" + }, + "value": "Interest rate rebalance conditions where not met" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_6b84664b8ca5227a94caf7c150601896d3e2ce55785142f35c5271266a66d288", + "typeString": "literal_string \"Interest rate rebalance conditions where not met\"" + } + ], + "id": 3630, + "name": "revert", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12133, + 12134 + ], + "referencedDeclaration": 12134, + "src": "22938:6:23", + "typeDescriptions": { + "typeIdentifier": "t_function_revert_pure$_t_string_memory_ptr_$returns$__$", + "typeString": "function (string memory) pure" + } + }, + "id": 3632, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22938:58:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3633, + "nodeType": "ExpressionStatement", + "src": "22938:58:23" + } + ] + }, + "documentation": "@notice rebalances the fixed interest rate of a user if current liquidity rate > user fixed rate.\n@dev this is regulated by Aave to ensure that the protocol is not abused, and the user is paying a fair\nrate. Anyone can call this function though.", + "id": 3635, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3501, + "modifierName": { + "argumentTypes": null, + "id": 3500, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "20677:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "20677:12:23" + } + ], + "name": "rebalanceFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3499, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3496, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3635, + "src": "20635:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3495, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20635:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3498, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 3635, + "src": "20653:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3497, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20653:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20634:33:23" + }, + "returnParameters": { + "id": 3502, + "nodeType": "ParameterList", + "parameters": [], + "src": "20690:0:23" + }, + "scope": 4094, + "src": "20601:2402:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3696, + "nodeType": "Block", + "src": "23208:671:23", + "statements": [ + { + "assignments": [ + 3645 + ], + "declarations": [ + { + "constant": false, + "id": 3645, + "name": "underlyingBalance", + "nodeType": "VariableDeclaration", + "scope": 3696, + "src": "23219:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3644, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "23219:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3652, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3648, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3637, + "src": "23290:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3649, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "23299:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3650, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "23299:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3646, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "23247:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3647, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserUnderlyingAssetBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7008, + "src": "23247:42:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3651, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23247:63:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "23219:91:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3656, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3654, + "name": "underlyingBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3645, + "src": "23329:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3655, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23349:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "23329:21:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220646f6573206e6f74206861766520616e79206c6971756964697479206465706f7369746564", + "id": 3657, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23352:44:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a33f09dca6de47688a656ef882b2d46916d7bc325f5e2fda81e0afcea3ff2528", + "typeString": "literal_string \"User does not have any liquidity deposited\"" + }, + "value": "User does not have any liquidity deposited" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_a33f09dca6de47688a656ef882b2d46916d7bc325f5e2fda81e0afcea3ff2528", + "typeString": "literal_string \"User does not have any liquidity deposited\"" + } + ], + "id": 3653, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "23321:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3658, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23321:76:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3659, + "nodeType": "ExpressionStatement", + "src": "23321:76:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3663, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3637, + "src": "23465:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3664, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "23475:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3665, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "23475:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3666, + "name": "underlyingBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3645, + "src": "23487:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3661, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "23429:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3662, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceDecreaseAllowed", + "nodeType": "MemberAccess", + "referencedDeclaration": 7168, + "src": "23429:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,address,uint256) view external returns (bool)" + } + }, + "id": 3667, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23429:76:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "55736572206465706f73697420697320616c7265616479206265696e67207573656420617320636f6c6c61746572616c", + "id": 3668, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23519:50:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_1dc41e041ef7eb197e3fc50f36480baac7e4721c211d7b6652e582c6eb00756a", + "typeString": "literal_string \"User deposit is already being used as collateral\"" + }, + "value": "User deposit is already being used as collateral" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_1dc41e041ef7eb197e3fc50f36480baac7e4721c211d7b6652e582c6eb00756a", + "typeString": "literal_string \"User deposit is already being used as collateral\"" + } + ], + "id": 3660, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "23408:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3669, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23408:171:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3670, + "nodeType": "ExpressionStatement", + "src": "23408:171:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3674, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3637, + "src": "23625:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3675, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "23635:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3676, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "23635:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3677, + "name": "_useAsCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3639, + "src": "23647:16:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "expression": { + "argumentTypes": null, + "id": 3671, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "23590:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3673, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserUseReserveAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 5337, + "src": "23590:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_bool_$returns$__$", + "typeString": "function (address,address,bool) external" + } + }, + "id": 3678, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23590:74:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3679, + "nodeType": "ExpressionStatement", + "src": "23590:74:23" + }, + { + "condition": { + "argumentTypes": null, + "id": 3680, + "name": "_useAsCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3639, + "src": "23678:16:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 3694, + "nodeType": "Block", + "src": "23790:83:23", + "statements": [ + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3689, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3637, + "src": "23841:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3690, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "23851:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3691, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "23851:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 3688, + "name": "ReserveUsedAsCollateralDisabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2357, + "src": "23809:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address)" + } + }, + "id": 3692, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23809:53:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3693, + "nodeType": "EmitStatement", + "src": "23804:58:23" + } + ] + }, + "id": 3695, + "nodeType": "IfStatement", + "src": "23675:198:23", + "trueBody": { + "id": 3687, + "nodeType": "Block", + "src": "23695:82:23", + "statements": [ + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3682, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3637, + "src": "23745:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3683, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "23755:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3684, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "23755:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 3681, + "name": "ReserveUsedAsCollateralEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2351, + "src": "23714:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address)" + } + }, + "id": 3685, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23714:52:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3686, + "nodeType": "EmitStatement", + "src": "23709:57:23" + } + ] + } + } + ] + }, + "documentation": "@notice allows user to enable or disable a specific deposit as collateral", + "id": 3697, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3642, + "modifierName": { + "argumentTypes": null, + "id": 3641, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "23195:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "23195:12:23" + } + ], + "name": "setUserUseReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3640, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3637, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3697, + "src": "23145:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3636, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "23145:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3639, + "name": "_useAsCollateral", + "nodeType": "VariableDeclaration", + "scope": 3697, + "src": "23163:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3638, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "23163:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "23144:41:23" + }, + "returnParameters": { + "id": 3643, + "nodeType": "ParameterList", + "parameters": [], + "src": "23208:0:23" + }, + "scope": 4094, + "src": "23106:773:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3779, + "nodeType": "Block", + "src": "24265:903:23", + "statements": [ + { + "assignments": [ + 3716 + ], + "declarations": [ + { + "constant": false, + "id": 3716, + "name": "liquidationManager", + "nodeType": "VariableDeclaration", + "scope": 3779, + "src": "24275:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3715, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24275:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3720, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3717, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "24304:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 3718, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolLiquidationManager", + "nodeType": "MemberAccess", + "referencedDeclaration": 1341, + "src": "24304:50:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 3719, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24304:52:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "24275:81:23" + }, + { + "assignments": [ + 3722, + 3724 + ], + "declarations": [ + { + "constant": false, + "id": 3722, + "name": "success", + "nodeType": "VariableDeclaration", + "scope": 3779, + "src": "24403:12:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3721, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "24403:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3724, + "name": "result", + "nodeType": "VariableDeclaration", + "scope": 3779, + "src": "24417:19:23", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 3723, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "24417:5:23", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3737, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "6c69717569646174696f6e43616c6c28616464726573732c616464726573732c616464726573732c75696e743235362c626f6f6c29", + "id": 3729, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "24514:55:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_00a718a9d9ad23be6d712c3f743c97c344c043a2f5b8915b20cad9ae11f3f067", + "typeString": "literal_string \"liquidationCall(address,address,address,uint256,bool)\"" + }, + "value": "liquidationCall(address,address,address,uint256,bool)" + }, + { + "argumentTypes": null, + "id": 3730, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3699, + "src": "24588:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3731, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3701, + "src": "24618:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3732, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3703, + "src": "24645:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3733, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3705, + "src": "24669:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3734, + "name": "_receiveAToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3707, + "src": "24703:14:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_00a718a9d9ad23be6d712c3f743c97c344c043a2f5b8915b20cad9ae11f3f067", + "typeString": "literal_string \"liquidationCall(address,address,address,uint256,bool)\"" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "expression": { + "argumentTypes": null, + "id": 3727, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "24490:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 3728, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSignature", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "24490:23:23", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithsignature_pure$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (string memory) pure returns (bytes memory)" + } + }, + "id": 3735, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24490:241:23", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "expression": { + "argumentTypes": null, + "id": 3725, + "name": "liquidationManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3716, + "src": "24440:18:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 3726, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "delegatecall", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "24440:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_baredelegatecall_nonpayable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "function (bytes memory) returns (bool,bytes memory)" + } + }, + "id": 3736, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24440:292:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "tuple(bool,bytes memory)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "24402:330:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3739, + "name": "success", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3722, + "src": "24750:7:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "4c69717569646174696f6e2063616c6c206661696c6564", + "id": 3740, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "24759:25:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_b356d22163a9c42322b8eafa62927566857100ccc3ad6afcdfad7d317ea12a53", + "typeString": "literal_string \"Liquidation call failed\"" + }, + "value": "Liquidation call failed" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_b356d22163a9c42322b8eafa62927566857100ccc3ad6afcdfad7d317ea12a53", + "typeString": "literal_string \"Liquidation call failed\"" + } + ], + "id": 3738, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "24742:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3741, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24742:43:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3742, + "nodeType": "ExpressionStatement", + "src": "24742:43:23" + }, + { + "assignments": [ + 3744, + 3746 + ], + "declarations": [ + { + "constant": false, + "id": 3744, + "name": "returnCode", + "nodeType": "VariableDeclaration", + "scope": 3779, + "src": "24797:18:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3743, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "24797:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3746, + "name": "returnMessage", + "nodeType": "VariableDeclaration", + "scope": 3779, + "src": "24817:27:23", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 3745, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "24817:6:23", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3754, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3749, + "name": "result", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3724, + "src": "24859:6:23", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + }, + { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 3750, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "24868:7:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + { + "argumentTypes": null, + "id": 3751, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "24877:6:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_string_storage_ptr_$", + "typeString": "type(string storage pointer)" + }, + "typeName": "string" + } + ], + "id": 3752, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "24867:17:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_type$_t_uint256_$_$_t_type$_t_string_storage_ptr_$_$", + "typeString": "tuple(type(uint256),type(string storage pointer))" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + }, + { + "typeIdentifier": "t_tuple$_t_type$_t_uint256_$_$_t_type$_t_string_storage_ptr_$_$", + "typeString": "tuple(type(uint256),type(string storage pointer))" + } + ], + "expression": { + "argumentTypes": null, + "id": 3747, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "24848:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 3748, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "decode", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "24848:10:23", + "typeDescriptions": { + "typeIdentifier": "t_function_abidecode_pure$__$returns$__$", + "typeString": "function () pure" + } + }, + "id": 3753, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24848:37:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_string_memory_$", + "typeString": "tuple(uint256,string memory)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "24796:89:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3757, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3755, + "name": "returnCode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3744, + "src": "24899:10:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3756, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "24913:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "24899:15:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 3769, + "nodeType": "IfStatement", + "src": "24896:130:23", + "trueBody": { + "id": 3768, + "nodeType": "Block", + "src": "24916:110:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "4c69717569646174696f6e206661696c65643a20", + "id": 3762, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "24975:22:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_adca2f3137c54d8ddf7be034c60a44503a67c3111ba840b9211405ef6fb06777", + "typeString": "literal_string \"Liquidation failed: \"" + }, + "value": "Liquidation failed: " + }, + { + "argumentTypes": null, + "id": 3763, + "name": "returnMessage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3746, + "src": "24999:13:23", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_adca2f3137c54d8ddf7be034c60a44503a67c3111ba840b9211405ef6fb06777", + "typeString": "literal_string \"Liquidation failed: \"" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + ], + "expression": { + "argumentTypes": null, + "id": 3760, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "24958:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 3761, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodePacked", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "24958:16:23", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodepacked_pure$__$returns$_t_bytes_memory_ptr_$", + "typeString": "function () pure returns (bytes memory)" + } + }, + "id": 3764, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24958:55:23", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 3759, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "24951:6:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_string_storage_ptr_$", + "typeString": "type(string storage pointer)" + }, + "typeName": "string" + }, + "id": 3765, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24951:63:23", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + ], + "id": 3758, + "name": "revert", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12133, + 12134 + ], + "referencedDeclaration": 12134, + "src": "24944:6:23", + "typeDescriptions": { + "typeIdentifier": "t_function_revert_pure$_t_string_memory_ptr_$returns$__$", + "typeString": "function (string memory) pure" + } + }, + "id": 3766, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24944:71:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3767, + "nodeType": "ExpressionStatement", + "src": "24944:71:23" + } + ] + } + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3771, + "name": "liquidationManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3716, + "src": "25091:18:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3772, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3703, + "src": "25111:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3773, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3705, + "src": "25118:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3774, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3701, + "src": "25135:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3775, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "25145:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 3776, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "25145:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 3770, + "name": "LiquidationCall", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2325, + "src": "25075:15:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,address,uint256)" + } + }, + "id": 3777, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25075:86:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3778, + "nodeType": "EmitStatement", + "src": "25070:91:23" + } + ] + }, + "documentation": "@notice implements loan liquidation\n@dev _receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset.", + "id": 3780, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3710, + "modifierName": { + "argumentTypes": null, + "id": 3709, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "24212:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "24212:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 3712, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3701, + "src": "24251:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 3713, + "modifierName": { + "argumentTypes": null, + "id": 3711, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "24233:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "24233:27:23" + } + ], + "name": "liquidationCall", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3708, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3699, + "name": "_collateral", + "nodeType": "VariableDeclaration", + "scope": 3780, + "src": "24072:19:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3698, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24072:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3701, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3780, + "src": "24093:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3700, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24093:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3703, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 3780, + "src": "24111:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3702, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24111:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3705, + "name": "_purchaseAmount", + "nodeType": "VariableDeclaration", + "scope": 3780, + "src": "24126:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3704, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "24126:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3707, + "name": "_receiveAToken", + "nodeType": "VariableDeclaration", + "scope": 3780, + "src": "24151:19:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3706, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "24151:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "24071:100:23" + }, + "returnParameters": { + "id": 3714, + "nodeType": "ParameterList", + "parameters": [], + "src": "24265:0:23" + }, + "scope": 4094, + "src": "24047:1121:23", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3942, + "nodeType": "Block", + "src": "25343:2554:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3795, + "name": "_receiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3782, + "src": "25409:9:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 3796, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isContract", + "nodeType": "MemberAccess", + "referencedDeclaration": 12033, + "src": "25409:20:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$bound_to$_t_address_$", + "typeString": "function (address) view returns (bool)" + } + }, + "id": 3797, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25409:22:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206f6620746869732066756e6374696f6e206d757374206265206120636f6e7472616374", + "id": 3798, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "25433:48:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c8d8b88b818c84a1935af7a142e1fb9bc75b2783890eabbb56c5c096178bad7d", + "typeString": "literal_string \"The caller of this function must be a contract\"" + }, + "value": "The caller of this function must be a contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_c8d8b88b818c84a1935af7a142e1fb9bc75b2783890eabbb56c5c096178bad7d", + "typeString": "literal_string \"The caller of this function must be a contract\"" + } + ], + "id": 3794, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "25401:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3799, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25401:81:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3800, + "nodeType": "ExpressionStatement", + "src": "25401:81:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3804, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "25590:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3802, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "25559:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3803, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isReserveBorrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5832, + "src": "25559:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 3805, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25559:40:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "52657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e67", + "id": 3806, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "25600:38:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + }, + "value": "Reserve is not enabled for borrowing" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + } + ], + "id": 3801, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "25551:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3807, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25551:88:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3808, + "nodeType": "ExpressionStatement", + "src": "25551:88:23" + }, + { + "assignments": [ + 3810 + ], + "declarations": [ + { + "constant": false, + "id": 3810, + "name": "availableLiquidity", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "25714:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3809, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "25714:4:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3815, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3813, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "25774:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3811, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "25740:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3812, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveAvailableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5482, + "src": "25740:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3814, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25740:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "25714:69:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3819, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3817, + "name": "availableLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3810, + "src": "25801:18:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 3818, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "25822:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "25801:28:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520746f20626f72726f77", + "id": 3820, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "25831:51:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_12f1ea40393a7e170dfca23cc7ab5cb81fe067367db50831941a05793fe5fe30", + "typeString": "literal_string \"There is not enough liquidity available to borrow\"" + }, + "value": "There is not enough liquidity available to borrow" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_12f1ea40393a7e170dfca23cc7ab5cb81fe067367db50831941a05793fe5fe30", + "typeString": "literal_string \"There is not enough liquidity available to borrow\"" + } + ], + "id": 3816, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "25793:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3821, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25793:90:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3822, + "nodeType": "ExpressionStatement", + "src": "25793:90:23" + }, + { + "assignments": [ + 3824 + ], + "declarations": [ + { + "constant": false, + "id": 3824, + "name": "actualBalanceBefore", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "25894:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3823, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "25894:4:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3829, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3827, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "25962:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3825, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "25921:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3826, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getCoreActualReserveBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7659, + "src": "25921:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3828, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25921:50:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "25894:77:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3833, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3831, + "name": "availableLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3810, + "src": "26114:18:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 3832, + "name": "actualBalanceBefore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3824, + "src": "26136:19:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "26114:41:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c6964206c697175696469747920617661696c61626c65", + "id": 3834, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26157:29:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_fb154cd6ec907608200ef716d76ea73f441de4aed8415de07b317869251935a3", + "typeString": "literal_string \"Invalid liquidity available\"" + }, + "value": "Invalid liquidity available" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_fb154cd6ec907608200ef716d76ea73f441de4aed8415de07b317869251935a3", + "typeString": "literal_string \"Invalid liquidity available\"" + } + ], + "id": 3830, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "26106:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3835, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26106:81:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3836, + "nodeType": "ExpressionStatement", + "src": "26106:81:23" + }, + { + "assignments": [ + 3838 + ], + "declarations": [ + { + "constant": false, + "id": 3838, + "name": "amountFee", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "26279:14:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3837, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "26279:4:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3843, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 3841, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26308:3:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "id": 3839, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "26296:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3840, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "26296:11:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3842, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26296:16:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "26279:33:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3847, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3845, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "26331:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3846, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26343:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "26331:13:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520616d6f756e7420697320746f6f20736d616c6c20746875732069742063616e6e6f7420626520626f72726f776564", + "id": 3848, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26346:52:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c313f75adce18cb0a1646d87d7e4e84d9d8728feec6c4c3ee8a3083ac038de6e", + "typeString": "literal_string \"The amount is too small thus it cannot be borrowed\"" + }, + "value": "The amount is too small thus it cannot be borrowed" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_c313f75adce18cb0a1646d87d7e4e84d9d8728feec6c4c3ee8a3083ac038de6e", + "typeString": "literal_string \"The amount is too small thus it cannot be borrowed\"" + } + ], + "id": 3844, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "26323:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3849, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26323:76:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3850, + "nodeType": "ExpressionStatement", + "src": "26323:76:23" + }, + { + "assignments": [ + 3852 + ], + "declarations": [ + { + "constant": false, + "id": 3852, + "name": "receiver", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "26455:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFlashLoanReceiver_$1733", + "typeString": "contract IFlashLoanReceiver" + }, + "typeName": { + "contractScope": null, + "id": 3851, + "name": "IFlashLoanReceiver", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1733, + "src": "26455:18:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFlashLoanReceiver_$1733", + "typeString": "contract IFlashLoanReceiver" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3856, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3854, + "name": "_receiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3782, + "src": "26504:9:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 3853, + "name": "IFlashLoanReceiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1733, + "src": "26485:18:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IFlashLoanReceiver_$1733_$", + "typeString": "type(contract IFlashLoanReceiver)" + } + }, + "id": 3855, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26485:29:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFlashLoanReceiver_$1733", + "typeString": "contract IFlashLoanReceiver" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "26455:59:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3860, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "26586:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3861, + "name": "_receiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3782, + "src": "26596:9:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3862, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "26607:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3857, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "26566:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3859, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToUser", + "nodeType": "MemberAccess", + "referencedDeclaration": 6486, + "src": "26566:19:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) external" + } + }, + "id": 3863, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26566:49:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3864, + "nodeType": "ExpressionStatement", + "src": "26566:49:23" + }, + { + "assignments": [ + 3866 + ], + "declarations": [ + { + "constant": false, + "id": 3866, + "name": "returnedAmount", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "26667:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3865, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "26667:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3873, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3869, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "26718:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3870, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "26728:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3871, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "26737:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3867, + "name": "receiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3852, + "src": "26692:8:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFlashLoanReceiver_$1733", + "typeString": "contract IFlashLoanReceiver" + } + }, + "id": 3868, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "executeOperation", + "nodeType": "MemberAccess", + "referencedDeclaration": 1732, + "src": "26692:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (address,uint256,uint256) external returns (uint256)" + } + }, + "id": 3872, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26692:55:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "26667:80:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3880, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3875, + "name": "returnedAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3866, + "src": "26866:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3878, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "26896:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3876, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "26884:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3877, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "26884:11:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3879, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26884:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "26866:40:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "546865206e6f6d696e616c2072657475726e656420616d6f756e7420697320696e76616c6964", + "id": 3881, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26908:40:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_d3a984b42b567cdd6d54324436557ccb15b01cde8713f46fbff00a4c5ceff514", + "typeString": "literal_string \"The nominal returned amount is invalid\"" + }, + "value": "The nominal returned amount is invalid" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_d3a984b42b567cdd6d54324436557ccb15b01cde8713f46fbff00a4c5ceff514", + "typeString": "literal_string \"The nominal returned amount is invalid\"" + } + ], + "id": 3874, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "26858:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3882, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26858:91:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3883, + "nodeType": "ExpressionStatement", + "src": "26858:91:23" + }, + { + "assignments": [ + 3885 + ], + "declarations": [ + { + "constant": false, + "id": 3885, + "name": "actualBalanceAfter", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "27050:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3884, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "27050:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3890, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3888, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27120:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3886, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "27079:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3887, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getCoreActualReserveBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7659, + "src": "27079:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3889, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27079:50:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "27050:79:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3897, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3892, + "name": "actualBalanceAfter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3885, + "src": "27148:18:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3895, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "27194:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3893, + "name": "actualBalanceBefore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3824, + "src": "27170:19:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3894, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "27170:23:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3896, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27170:34:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "27148:56:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652061637475616c2062616c616e6365206f66207468652070726f746f636f6c20696e20696e636f6e73697374656e74", + "id": 3898, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "27206:52:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_6e665e32db13fc7cc07aaf3f821dbc3c5b2e2c9ee35188b5a0fa1aee3d1261b1", + "typeString": "literal_string \"The actual balance of the protocol in inconsistent\"" + }, + "value": "The actual balance of the protocol in inconsistent" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_6e665e32db13fc7cc07aaf3f821dbc3c5b2e2c9ee35188b5a0fa1aee3d1261b1", + "typeString": "literal_string \"The actual balance of the protocol in inconsistent\"" + } + ], + "id": 3891, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "27140:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3899, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27140:119:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3900, + "nodeType": "ExpressionStatement", + "src": "27140:119:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3904, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27380:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3901, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "27344:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3903, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "27344:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3905, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27344:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3906, + "nodeType": "ExpressionStatement", + "src": "27344:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3910, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27502:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3911, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "27512:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3907, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "27456:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3909, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "cumulateLiquidityToReserveLiquidityIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 4810, + "src": "27456:45:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3912, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27456:66:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3913, + "nodeType": "ExpressionStatement", + "src": "27456:66:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3917, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27623:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3918, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "27632:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3914, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "27588:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3916, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "27588:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3919, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27588:54:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3920, + "nodeType": "ExpressionStatement", + "src": "27588:54:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3924, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27717:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3921, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "27685:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3923, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "27685:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3925, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27685:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3926, + "nodeType": "ExpressionStatement", + "src": "27685:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3930, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27762:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3927, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "27736:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3929, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "27736:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3931, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27736:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3932, + "nodeType": "ExpressionStatement", + "src": "27736:35:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3934, + "name": "_receiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3782, + "src": "27832:9:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3935, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27843:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3936, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "27853:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3937, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "27862:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3938, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "27873:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 3939, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "27873:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 3933, + "name": "FlashLoan", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2345, + "src": "27822:9:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256,uint256)" + } + }, + "id": 3940, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27822:67:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3941, + "nodeType": "EmitStatement", + "src": "27817:72:23" + } + ] + }, + "documentation": null, + "id": 3943, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3789, + "modifierName": { + "argumentTypes": null, + "id": 3788, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "25302:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "25302:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 3791, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "25333:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 3792, + "modifierName": { + "argumentTypes": null, + "id": 3790, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "25315:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "25315:27:23" + } + ], + "name": "flashLoan", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3787, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3782, + "name": "_receiver", + "nodeType": "VariableDeclaration", + "scope": 3943, + "src": "25202:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 3781, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25202:15:23", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3784, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3943, + "src": "25237:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3783, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25237:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3786, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 3943, + "src": "25263:12:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3785, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "25263:4:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "25192:84:23" + }, + "returnParameters": { + "id": 3793, + "nodeType": "ParameterList", + "parameters": [], + "src": "25343:0:23" + }, + "scope": 4094, + "src": "25174:2723:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3969, + "nodeType": "Block", + "src": "28407:74:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3966, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3945, + "src": "28465:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3964, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "28424:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3965, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveConfigurationData", + "nodeType": "MemberAccess", + "referencedDeclaration": 7318, + "src": "28424:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_$_t_bool_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,address,bool,bool,bool,bool)" + } + }, + "id": 3967, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "28424:50:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_$_t_bool_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "tuple(uint256,uint256,uint256,address,bool,bool,bool,bool)" + } + }, + "functionReturnParameters": 3963, + "id": 3968, + "nodeType": "Return", + "src": "28417:57:23" + } + ] + }, + "documentation": "*************\n@dev accessory methods to fetch data from the core contract", + "id": 3970, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveConfigurationData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3946, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3945, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28034:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3944, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "28034:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "28033:18:23" + }, + "returnParameters": { + "id": 3963, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3948, + "name": "ltv", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28112:11:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3947, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28112:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3950, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28137:28:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3949, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28137:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3952, + "name": "liquidationDiscount", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28179:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3951, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28179:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3954, + "name": "interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28220:35:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3953, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "28220:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3956, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28269:29:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3955, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "28269:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3958, + "name": "borrowingEnabled", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28312:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3957, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "28312:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3960, + "name": "fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28347:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3959, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "28347:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3962, + "name": "isActive", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28388:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3961, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "28388:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "28098:304:23" + }, + "scope": 4094, + "src": "27997:484:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4006, + "nodeType": "Block", + "src": "29093:61:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4003, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3972, + "src": "29138:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4001, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "29110:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 4002, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveData", + "nodeType": "MemberAccess", + "referencedDeclaration": 7441, + "src": "29110:27:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_$_t_uint40_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address,uint40)" + } + }, + "id": 4004, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "29110:37:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_$_t_uint40_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address,uint40)" + } + }, + "functionReturnParameters": 4000, + "id": 4005, + "nodeType": "Return", + "src": "29103:44:23" + } + ] + }, + "documentation": null, + "id": 4007, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3973, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3972, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28512:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3971, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "28512:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "28511:18:23" + }, + "returnParameters": { + "id": 4000, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3975, + "name": "totalLiquidity", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28590:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3974, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28590:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3977, + "name": "availableLiquidity", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28626:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3976, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28626:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3979, + "name": "totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28666:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3978, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28666:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3981, + "name": "totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28705:28:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3980, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28705:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3983, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28747:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3982, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28747:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3985, + "name": "variableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28782:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3984, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28782:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3987, + "name": "fixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28822:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3986, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28822:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3989, + "name": "averageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28859:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3988, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28859:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3991, + "name": "utilizationRate", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28903:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3990, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28903:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3993, + "name": "liquidityIndex", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28940:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3992, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28940:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3995, + "name": "variableBorrowIndex", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28976:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3994, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28976:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3997, + "name": "aTokenAddress", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "29017:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3996, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "29017:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3999, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "29052:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 3998, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "29052:6:23", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "28576:512:23" + }, + "scope": 4094, + "src": "28488:666:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4031, + "nodeType": "Block", + "src": "29529:62:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4028, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4009, + "src": "29578:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4026, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "29546:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 4027, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserAccountData", + "nodeType": "MemberAccess", + "referencedDeclaration": 7481, + "src": "29546:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "id": 4029, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "29546:38:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "functionReturnParameters": 4025, + "id": 4030, + "nodeType": "Return", + "src": "29539:45:23" + } + ] + }, + "documentation": null, + "id": 4032, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserAccountData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4010, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4009, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29188:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4008, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "29188:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "29187:15:23" + }, + "returnParameters": { + "id": 4025, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4012, + "name": "totalLiquidityETH", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29263:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4011, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29263:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4014, + "name": "totalCollateralETH", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29302:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4013, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29302:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4016, + "name": "totalBorrowsETH", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29342:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4015, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29342:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4018, + "name": "availableBorrowsETH", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29379:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4017, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29379:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4020, + "name": "currentLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29420:35:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4019, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29420:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4022, + "name": "ltv", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29469:11:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4021, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29469:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4024, + "name": "healthFactor", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29494:20:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4023, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29494:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "29249:275:23" + }, + "scope": 4094, + "src": "29160:431:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4067, + "nodeType": "Block", + "src": "30157:72:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4063, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4034, + "src": "30206:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4064, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4036, + "src": "30216:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4061, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "30174:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 4062, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserReserveData", + "nodeType": "MemberAccess", + "referencedDeclaration": 7618, + "src": "30174:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,bool)" + } + }, + "id": 4065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "30174:48:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,bool)" + } + }, + "functionReturnParameters": 4060, + "id": 4066, + "nodeType": "Return", + "src": "30167:55:23" + } + ] + }, + "documentation": null, + "id": 4068, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserReserveData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4037, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4034, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29625:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4033, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "29625:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4036, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29643:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4035, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "29643:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "29624:33:23" + }, + "returnParameters": { + "id": 4060, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4039, + "name": "currentATokenBalance", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29718:28:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4038, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29718:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4041, + "name": "currentUnderlyingBalance", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29760:32:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4040, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29760:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4043, + "name": "currentBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29806:28:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4042, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29806:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4045, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29848:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4044, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29848:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4047, + "name": "borrowRateMode", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29892:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4046, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29892:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4049, + "name": "borrowRate", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29928:18:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4048, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29928:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4051, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29960:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4050, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29960:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4053, + "name": "originationFee", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29995:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4052, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29995:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4055, + "name": "variableBorrowIndex", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "30031:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4054, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "30031:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4057, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "30072:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4056, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "30072:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4059, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "30113:29:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 4058, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "30113:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "29704:448:23" + }, + "scope": 4094, + "src": "29597:632:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4078, + "nodeType": "Block", + "src": "30297:42:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4074, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "30314:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4075, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserves", + "nodeType": "MemberAccess", + "referencedDeclaration": 6134, + "src": "30314:16:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_array$_t_address_$dyn_memory_ptr_$", + "typeString": "function () view external returns (address[] memory)" + } + }, + "id": 4076, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "30314:18:23", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "functionReturnParameters": 4073, + "id": 4077, + "nodeType": "Return", + "src": "30307:25:23" + } + ] + }, + "documentation": null, + "id": 4079, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserves", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4069, + "nodeType": "ParameterList", + "parameters": [], + "src": "30255:2:23" + }, + "returnParameters": { + "id": 4073, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4072, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 4079, + "src": "30280:16:23", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 4070, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "30280:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 4071, + "length": null, + "nodeType": "ArrayTypeName", + "src": "30280:9:23", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "30279:18:23" + }, + "scope": 4094, + "src": "30235:104:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4092, + "nodeType": "Block", + "src": "30514:130:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4087, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4081, + "src": "30569:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4085, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "30545:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4086, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveIsActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 5889, + "src": "30545:23:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 4088, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "30545:33:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "416374696f6e20726571756972657320616e206163746976652072657365727665", + "id": 4089, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "30592:35:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_62ff4a583af39c5d4305dbf606abbf9562a2bd0263ebbe34037113a6623c8e7f", + "typeString": "literal_string \"Action requires an active reserve\"" + }, + "value": "Action requires an active reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_62ff4a583af39c5d4305dbf606abbf9562a2bd0263ebbe34037113a6623c8e7f", + "typeString": "literal_string \"Action requires an active reserve\"" + } + ], + "id": 4084, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "30524:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4090, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "30524:113:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4091, + "nodeType": "ExpressionStatement", + "src": "30524:113:23" + } + ] + }, + "documentation": "@dev internal function to save on code size for the onlyActiveReserve modifier", + "id": 4093, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "requireReserveActiveInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4082, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4081, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4093, + "src": "30482:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4080, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "30482:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "30481:18:23" + }, + "returnParameters": { + "id": 4083, + "nodeType": "ParameterList", + "parameters": [], + "src": "30514:0:23" + }, + "scope": 4094, + "src": "30444:200:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 4095, + "src": "1118:29528:23" + } + ], + "src": "0:30647:23" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol", + "exportedSymbols": { + "LendingPool": [ + 4094 + ] + }, + "id": 4095, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 2235, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:23" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 2236, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 11141, + "src": "25:59:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "file": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "id": 2237, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 12114, + "src": "85:67:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "file": "openzeppelin-solidity/contracts/utils/Address.sol", + "id": 2238, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 12082, + "src": "153:59:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "id": 2239, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 11787, + "src": "213:64:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 2240, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 1358, + "src": "279:59:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol", + "file": "../configuration/LendingPoolParametersProvider.sol", + "id": 2241, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 1419, + "src": "339:60:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "file": "../configuration/NetworkMetadataProvider.sol", + "id": 2242, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 1479, + "src": "400:54:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "file": "../tokenization/AToken.sol", + "id": 2243, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 10328, + "src": "455:36:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "file": "../libraries/CoreLibrary.sol", + "id": 2244, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 8995, + "src": "492:38:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 2245, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 9175, + "src": "531:37:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "file": "../interfaces/IFeeProvider.sol", + "id": 2246, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 1766, + "src": "569:40:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol", + "file": "../flashloan/interfaces/IFlashLoanReceiver.sol", + "id": 2247, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 1734, + "src": "610:56:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "./LendingPoolCore.sol", + "id": 2248, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 6683, + "src": "667:31:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol", + "file": "./LendingPoolDataProvider.sol", + "id": 2249, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 7661, + "src": "699:39:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol", + "file": "./LendingPoolLiquidationManager.sol", + "id": 2250, + "nodeType": "ImportDirective", + "scope": 4095, + "sourceUnit": 8255, + "src": "739:45:23", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 2251, + "name": "ReentrancyGuard", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12113, + "src": "1142:15:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ReentrancyGuard_$12113", + "typeString": "contract ReentrancyGuard" + } + }, + "id": 2252, + "nodeType": "InheritanceSpecifier", + "src": "1142:15:23" + } + ], + "contractDependencies": [ + 12113 + ], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title LendingPool contract\n@author Aave\n@notice Implements the actions of the LendingPool, and exposes accessory methods to access the core information************************************************************************************", + "fullyImplemented": true, + "id": 4094, + "linearizedBaseContracts": [ + 4094, + 12113 + ], + "name": "LendingPool", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 2255, + "libraryName": { + "contractScope": null, + "id": 2253, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "1170:8:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1164:27:23", + "typeName": { + "id": 2254, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1183:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 2258, + "libraryName": { + "contractScope": null, + "id": 2256, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "1202:10:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1196:29:23", + "typeName": { + "id": 2257, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1217:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 2261, + "libraryName": { + "contractScope": null, + "id": 2259, + "name": "Address", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12081, + "src": "1236:7:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + }, + "nodeType": "UsingForDirective", + "src": "1230:34:23", + "typeName": { + "id": 2260, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1248:15:23", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + }, + { + "constant": false, + "id": 2263, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 4094, + "src": "1270:53:23", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 2262, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1270:28:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": false, + "id": 2265, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4094, + "src": "1329:20:23", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 2264, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "1329:15:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2267, + "name": "dataProvider", + "nodeType": "VariableDeclaration", + "scope": 4094, + "src": "1355:36:23", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + }, + "typeName": { + "contractScope": null, + "id": 2266, + "name": "LendingPoolDataProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 7660, + "src": "1355:23:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2269, + "name": "parametersProvider", + "nodeType": "VariableDeclaration", + "scope": 4094, + "src": "1397:48:23", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + }, + "typeName": { + "contractScope": null, + "id": 2268, + "name": "LendingPoolParametersProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1418, + "src": "1397:29:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "anonymous": false, + "documentation": "@dev events", + "id": 2281, + "name": "Deposit", + "nodeType": "EventDefinition", + "parameters": { + "id": 2280, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2271, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2281, + "src": "1497:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2270, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1497:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2273, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2281, + "src": "1523:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2272, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1523:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2275, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2281, + "src": "1546:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2274, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1546:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2277, + "indexed": true, + "name": "_referral", + "nodeType": "VariableDeclaration", + "scope": 2281, + "src": "1563:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + "typeName": { + "id": 2276, + "name": "uint16", + "nodeType": "ElementaryTypeName", + "src": "1563:6:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2279, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2281, + "src": "1589:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2278, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1589:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1496:111:23" + }, + "src": "1483:125:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2291, + "name": "RedeemUnderlying", + "nodeType": "EventDefinition", + "parameters": { + "id": 2290, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2283, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2291, + "src": "1645:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2282, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1645:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2285, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2291, + "src": "1679:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2284, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1679:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2287, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2291, + "src": "1710:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2286, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1710:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2289, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2291, + "src": "1735:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2288, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1735:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1635:123:23" + }, + "src": "1613:146:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2303, + "name": "Borrow", + "nodeType": "EventDefinition", + "parameters": { + "id": 2302, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2293, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2303, + "src": "1778:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2292, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1778:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2295, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2303, + "src": "1804:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2294, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1804:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2297, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2303, + "src": "1827:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2296, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1827:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2299, + "indexed": true, + "name": "_referral", + "nodeType": "VariableDeclaration", + "scope": 2303, + "src": "1844:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + "typeName": { + "id": 2298, + "name": "uint16", + "nodeType": "ElementaryTypeName", + "src": "1844:6:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2301, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2303, + "src": "1870:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2300, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1870:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1777:111:23" + }, + "src": "1765:124:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2313, + "name": "Repay", + "nodeType": "EventDefinition", + "parameters": { + "id": 2312, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2305, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2313, + "src": "1906:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2304, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1906:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2307, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2313, + "src": "1932:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2306, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1932:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2309, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2313, + "src": "1955:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2308, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1955:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2311, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2313, + "src": "1972:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2310, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1972:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1905:85:23" + }, + "src": "1894:97:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2325, + "name": "LiquidationCall", + "nodeType": "EventDefinition", + "parameters": { + "id": 2324, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2315, + "indexed": true, + "name": "_collateral", + "nodeType": "VariableDeclaration", + "scope": 2325, + "src": "2018:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2314, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2018:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2317, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2325, + "src": "2047:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2316, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2047:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2319, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2325, + "src": "2070:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2318, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2070:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2321, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2325, + "src": "2087:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2320, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2087:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2323, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2325, + "src": "2113:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2322, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2113:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2017:114:23" + }, + "src": "1996:136:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2333, + "name": "Swap", + "nodeType": "EventDefinition", + "parameters": { + "id": 2332, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2327, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2333, + "src": "2148:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2326, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2148:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2329, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2333, + "src": "2174:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2328, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2174:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2331, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2333, + "src": "2197:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2330, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2197:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2147:68:23" + }, + "src": "2137:79:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2345, + "name": "FlashLoan", + "nodeType": "EventDefinition", + "parameters": { + "id": 2344, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2335, + "indexed": true, + "name": "_target", + "nodeType": "VariableDeclaration", + "scope": 2345, + "src": "2237:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2334, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2237:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2337, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2345, + "src": "2262:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2336, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2262:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2339, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2345, + "src": "2288:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2338, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2288:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2341, + "indexed": false, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 2345, + "src": "2305:12:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2340, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2305:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2343, + "indexed": false, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 2345, + "src": "2319:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2342, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2319:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2236:101:23" + }, + "src": "2221:117:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2351, + "name": "ReserveUsedAsCollateralEnabled", + "nodeType": "EventDefinition", + "parameters": { + "id": 2350, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2347, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2351, + "src": "2380:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2346, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2380:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2349, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2351, + "src": "2406:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2348, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2406:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2379:49:23" + }, + "src": "2343:86:23" + }, + { + "anonymous": false, + "documentation": null, + "id": 2357, + "name": "ReserveUsedAsCollateralDisabled", + "nodeType": "EventDefinition", + "parameters": { + "id": 2356, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2353, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2357, + "src": "2472:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2352, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2472:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2355, + "indexed": true, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2357, + "src": "2498:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2354, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2498:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2471:49:23" + }, + "src": "2434:87:23" + }, + { + "body": { + "id": 2373, + "nodeType": "Block", + "src": "2611:202:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 2368, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2362, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "2642:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2363, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2642:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2366, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2359, + "src": "2685:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2364, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "2656:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2365, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "2656:28:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 2367, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2656:38:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "2642:52:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206f6620746869732066756e6374696f6e2063616e206f6e6c79206265207468652061546f6b656e20636f6e7472616374206f6620746869732072657365727665", + "id": 2369, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2708:77:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_83c3af2909d739c11645c0ca81969a410eba1bfadc55dce1095355005feb4d3c", + "typeString": "literal_string \"The caller of this function can only be the aToken contract of this reserve\"" + }, + "value": "The caller of this function can only be the aToken contract of this reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_83c3af2909d739c11645c0ca81969a410eba1bfadc55dce1095355005feb4d3c", + "typeString": "literal_string \"The caller of this function can only be the aToken contract of this reserve\"" + } + ], + "id": 2361, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2621:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2370, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2621:174:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2371, + "nodeType": "ExpressionStatement", + "src": "2621:174:23" + }, + { + "id": 2372, + "nodeType": "PlaceholderStatement", + "src": "2805:1:23" + } + ] + }, + "documentation": "@dev modifiers", + "id": 2374, + "name": "onlyOverlyingAToken", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 2360, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2359, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2374, + "src": "2593:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2358, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2593:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2592:18:23" + }, + "src": "2564:249:23", + "visibility": "internal" + }, + { + "body": { + "id": 2383, + "nodeType": "Block", + "src": "2864:66:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2379, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2376, + "src": "2903:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2378, + "name": "requireReserveActiveInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4093, + "src": "2874:28:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$__$", + "typeString": "function (address) view" + } + }, + "id": 2380, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2874:38:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2381, + "nodeType": "ExpressionStatement", + "src": "2874:38:23" + }, + { + "id": 2382, + "nodeType": "PlaceholderStatement", + "src": "2922:1:23" + } + ] + }, + "documentation": null, + "id": 2384, + "name": "onlyActiveReserve", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 2377, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2376, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2384, + "src": "2846:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2375, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2846:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2845:18:23" + }, + "src": "2819:111:23", + "visibility": "internal" + }, + { + "constant": true, + "id": 2390, + "name": "UINT_MAX_VALUE", + "nodeType": "VariableDeclaration", + "scope": 4094, + "src": "2936:45:23", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2385, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2936:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2388, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "-", + "prefix": true, + "src": "2978:2:23", + "subExpression": { + "argumentTypes": null, + "hexValue": "31", + "id": 2387, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2979:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1_by_1", + "typeString": "int_const 1" + }, + "value": "1" + }, + "typeDescriptions": { + "typeIdentifier": "t_rational_minus_1_by_1", + "typeString": "int_const -1" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_minus_1_by_1", + "typeString": "int_const -1" + } + ], + "id": 2386, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2970:7:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 2389, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2970:11:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "body": { + "id": 2423, + "nodeType": "Block", + "src": "3056:338:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 2397, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2395, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "3067:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 2396, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2392, + "src": "3087:18:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "3067:38:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2398, + "nodeType": "ExpressionStatement", + "src": "3067:38:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2405, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2399, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "3115:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2401, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "3138:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2402, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "3138:36:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 2403, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3138:38:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 2400, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "3122:15:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 2404, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3122:55:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "src": "3115:62:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2406, + "nodeType": "ExpressionStatement", + "src": "3115:62:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2413, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2407, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "3187:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2409, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "3226:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2410, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolDataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1191, + "src": "3226:44:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 2411, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3226:46:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2408, + "name": "LendingPoolDataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7660, + "src": "3202:23:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolDataProvider_$7660_$", + "typeString": "type(contract LendingPoolDataProvider)" + } + }, + "id": 2412, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3202:71:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "src": "3187:86:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 2414, + "nodeType": "ExpressionStatement", + "src": "3187:86:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2421, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 2415, + "name": "parametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2269, + "src": "3283:18:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2417, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "3334:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2418, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolParametersProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1241, + "src": "3334:50:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 2419, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3334:52:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2416, + "name": "LendingPoolParametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1418, + "src": "3304:29:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolParametersProvider_$1418_$", + "typeString": "type(contract LendingPoolParametersProvider)" + } + }, + "id": 2420, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3304:83:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "src": "3283:104:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "id": 2422, + "nodeType": "ExpressionStatement", + "src": "3283:104:23" + } + ] + }, + "documentation": null, + "id": 2424, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2393, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2392, + "name": "_addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 2424, + "src": "3000:47:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 2391, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "3000:28:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2999:49:23" + }, + "returnParameters": { + "id": 2394, + "nodeType": "ParameterList", + "parameters": [], + "src": "3056:0:23" + }, + "scope": 4094, + "src": "2988:406:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 2522, + "nodeType": "Block", + "src": "3715:997:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2441, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "3815:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2438, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "3779:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2440, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "3779:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2442, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3779:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2443, + "nodeType": "ExpressionStatement", + "src": "3779:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2447, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "3902:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 2448, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2428, + "src": "3912:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2444, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "3867:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2446, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "3867:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 2449, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3867:53:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2450, + "nodeType": "ExpressionStatement", + "src": "3867:53:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2454, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "3962:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2451, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "3930:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2453, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "3930:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2455, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3930:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2456, + "nodeType": "ExpressionStatement", + "src": "3930:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2460, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "4007:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2457, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "3981:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2459, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "3981:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2461, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3981:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2462, + "nodeType": "ExpressionStatement", + "src": "3981:35:23" + }, + { + "assignments": [ + 2464 + ], + "declarations": [ + { + "constant": false, + "id": 2464, + "name": "aToken", + "nodeType": "VariableDeclaration", + "scope": 2522, + "src": "4027:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + }, + "typeName": { + "contractScope": null, + "id": 2463, + "name": "AToken", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10327, + "src": "4027:6:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2471, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2468, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "4079:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2466, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "4050:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2467, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "4050:28:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 2469, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4050:38:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2465, + "name": "AToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10327, + "src": "4043:6:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_AToken_$10327_$", + "typeString": "type(contract AToken)" + } + }, + "id": 2470, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4043:46:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4027:62:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2478, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2474, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4120:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2475, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4120:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2472, + "name": "aToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2464, + "src": "4103:6:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 2473, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOf", + "nodeType": "MemberAccess", + "referencedDeclaration": 11298, + "src": "4103:16:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2476, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4103:28:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 2477, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4135:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "4103:33:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 2489, + "nodeType": "IfStatement", + "src": "4100:241:23", + "trueBody": { + "id": 2488, + "nodeType": "Block", + "src": "4137:204:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2482, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "4303:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2483, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4313:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2484, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4313:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "hexValue": "74727565", + "id": 2485, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4325:4:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "expression": { + "argumentTypes": null, + "id": 2479, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "4268:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2481, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserUseReserveAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 5337, + "src": "4268:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_bool_$returns$__$", + "typeString": "function (address,address,bool) external" + } + }, + "id": 2486, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4268:62:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2487, + "nodeType": "ExpressionStatement", + "src": "4268:62:23" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2493, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4441:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2494, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4441:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2495, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2428, + "src": "4453:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2490, + "name": "aToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2464, + "src": "4420:6:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 2492, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mintOnDeposit", + "nodeType": "MemberAccess", + "referencedDeclaration": 10119, + "src": "4420:20:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 2496, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4420:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2497, + "nodeType": "ExpressionStatement", + "src": "4420:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2506, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "4553:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2507, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4563:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2508, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4563:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2509, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2428, + "src": "4575:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2503, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4542:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2504, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4542:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2498, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "4513:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2501, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6619, + "src": "4513:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 2502, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4513:28:23", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value_$", + "typeString": "function (uint256) returns (function (address,address payable,uint256) payable external)" + } + }, + "id": 2505, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4513:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 2510, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4513:70:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2511, + "nodeType": "ExpressionStatement", + "src": "4513:70:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2513, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "4642:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2514, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "4652:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2515, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4652:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2516, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2428, + "src": "4664:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 2517, + "name": "_referralCode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2430, + "src": "4673:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2518, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "4688:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 2519, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4688:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 2512, + "name": "Deposit", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2281, + "src": "4634:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint16_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint16,uint256)" + } + }, + "id": 2520, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4634:70:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2521, + "nodeType": "EmitStatement", + "src": "4629:75:23" + } + ] + }, + "documentation": "@notice deposits The underlying asset into the reserve. A corresponding amount of the overlying asset (aTokens)\nis minted.", + "id": 2523, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 2433, + "modifierName": { + "argumentTypes": null, + "id": 2432, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "3674:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "3674:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 2435, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2426, + "src": "3705:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 2436, + "modifierName": { + "argumentTypes": null, + "id": 2434, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "3687:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "3687:27:23" + } + ], + "name": "deposit", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2431, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2426, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2523, + "src": "3576:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2425, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3576:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2428, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2523, + "src": "3602:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2427, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3602:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2430, + "name": "_referralCode", + "nodeType": "VariableDeclaration", + "scope": 2523, + "src": "3627:20:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + "typeName": { + "id": 2429, + "name": "uint16", + "nodeType": "ElementaryTypeName", + "src": "3627:6:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3566:82:23" + }, + "returnParameters": { + "id": 2437, + "nodeType": "ParameterList", + "parameters": [], + "src": "3715:0:23" + }, + "scope": 4094, + "src": "3550:1162:23", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 2595, + "nodeType": "Block", + "src": "5056:705:23", + "statements": [ + { + "assignments": [ + 2541 + ], + "declarations": [ + { + "constant": false, + "id": 2541, + "name": "currentAvailableLiquidity", + "nodeType": "VariableDeclaration", + "scope": 2595, + "src": "5067:33:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2540, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5067:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2546, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2544, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5137:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2542, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5103:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2543, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveAvailableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5482, + "src": "5103:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2545, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5103:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5067:79:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2550, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2548, + "name": "currentAvailableLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2541, + "src": "5164:25:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 2549, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2529, + "src": "5193:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5164:36:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520746f2072656465656d", + "id": 2551, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5202:51:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3c94a5b9cef94ef9c462cd4975c6dd27736560c06935c214144f6e100bc129d5", + "typeString": "literal_string \"There is not enough liquidity available to redeem\"" + }, + "value": "There is not enough liquidity available to redeem" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_3c94a5b9cef94ef9c462cd4975c6dd27736560c06935c214144f6e100bc129d5", + "typeString": "literal_string \"There is not enough liquidity available to redeem\"" + } + ], + "id": 2547, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "5156:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2552, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5156:98:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2553, + "nodeType": "ExpressionStatement", + "src": "5156:98:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2557, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5360:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2554, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5324:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2556, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "5324:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2558, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5324:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2559, + "nodeType": "ExpressionStatement", + "src": "5324:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2563, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5473:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 2564, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2529, + "src": "5483:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2560, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5438:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2562, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4911, + "src": "5438:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 2565, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5438:53:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2566, + "nodeType": "ExpressionStatement", + "src": "5438:53:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2570, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5533:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2567, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5501:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2569, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "5501:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2571, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5501:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2572, + "nodeType": "ExpressionStatement", + "src": "5501:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2576, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5578:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2573, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5552:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2575, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "5552:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2577, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5552:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2578, + "nodeType": "ExpressionStatement", + "src": "5552:35:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2582, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5618:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 2583, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2527, + "src": "5628:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2584, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2529, + "src": "5635:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2579, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "5598:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2581, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToUser", + "nodeType": "MemberAccess", + "referencedDeclaration": 6486, + "src": "5598:19:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) external" + } + }, + "id": 2585, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5598:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2586, + "nodeType": "ExpressionStatement", + "src": "5598:45:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2588, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5711:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 2589, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2527, + "src": "5721:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2590, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2529, + "src": "5728:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2591, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "5737:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 2592, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "5737:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 2587, + "name": "RedeemUnderlying", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2291, + "src": "5694:16:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256)" + } + }, + "id": 2593, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5694:59:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2594, + "nodeType": "EmitStatement", + "src": "5689:64:23" + } + ] + }, + "documentation": "@notice Allows to redeem a specific amount of underlying asset.\n@dev only aToken contracts can call this function", + "id": 2596, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 2532, + "modifierName": { + "argumentTypes": null, + "id": 2531, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "4985:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4985:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 2534, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5018:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 2535, + "modifierName": { + "argumentTypes": null, + "id": 2533, + "name": "onlyOverlyingAToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2374, + "src": "4998:19:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "4998:29:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 2537, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2525, + "src": "5046:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 2538, + "modifierName": { + "argumentTypes": null, + "id": 2536, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "5028:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "5028:27:23" + } + ], + "name": "redeemUnderlying", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2530, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2525, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 2596, + "src": "4894:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2524, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4894:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2527, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 2596, + "src": "4920:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 2526, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4920:15:23", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2529, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 2596, + "src": "4951:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2528, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4951:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4884:83:23" + }, + "returnParameters": { + "id": 2539, + "nodeType": "ParameterList", + "parameters": [], + "src": "5056:0:23" + }, + "scope": 4094, + "src": "4859:902:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "canonicalName": "LendingPool.BorrowLocalVars", + "id": 2625, + "members": [ + { + "constant": false, + "id": 2598, + "name": "currentLtv", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "5890:18:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2597, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5890:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2600, + "name": "currentLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "5918:35:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2599, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5918:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2602, + "name": "borrowFee", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "5963:17:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2601, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5963:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2604, + "name": "requestedBorrowAmountETH", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "5990:32:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2603, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5990:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2606, + "name": "amountOfCollateralNeededETH", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6032:35:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2605, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6032:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2608, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6077:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2607, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6077:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2610, + "name": "compoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6117:31:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2609, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6117:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2612, + "name": "compoundedAmount", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6158:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2611, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6158:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2614, + "name": "userCollateralBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6192:32:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2613, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6192:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2616, + "name": "userBorrowBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6234:28:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2615, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6234:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2618, + "name": "healthFactor", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6272:20:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2617, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6272:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2620, + "name": "balanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6302:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2619, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6302:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2622, + "name": "currentReserveFixedRate", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6335:31:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2621, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6335:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2624, + "name": "availableLiquidity", + "nodeType": "VariableDeclaration", + "scope": 2625, + "src": "6376:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2623, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6376:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "BorrowLocalVars", + "nodeType": "StructDefinition", + "scope": 4094, + "src": "5857:552:23", + "visibility": "public" + }, + { + "body": { + "id": 3018, + "nodeType": "Block", + "src": "6729:6137:23", + "statements": [ + { + "assignments": [ + 2642 + ], + "declarations": [ + { + "constant": false, + "id": 2642, + "name": "vars", + "nodeType": "VariableDeclaration", + "scope": 3018, + "src": "6740:27:23", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars" + }, + "typeName": { + "contractScope": null, + "id": 2641, + "name": "BorrowLocalVars", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 2625, + "src": "6740:15:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_storage_ptr", + "typeString": "struct LendingPool.BorrowLocalVars" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2643, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "6740:27:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2647, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "6875:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2645, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "6844:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2646, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isReserveBorrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5832, + "src": "6844:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 2648, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6844:40:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "52657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e67", + "id": 2649, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6886:38:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + }, + "value": "Reserve is not enabled for borrowing" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + } + ], + "id": 2644, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "6836:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2650, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6836:89:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2651, + "nodeType": "ExpressionStatement", + "src": "6836:89:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2659, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2652, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "6996:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2654, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "availableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 2624, + "src": "6996:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2657, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "7056:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2655, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "7022:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2656, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveAvailableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5482, + "src": "7022:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2658, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7022:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6996:69:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2660, + "nodeType": "ExpressionStatement", + "src": "6996:69:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2665, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2662, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "7097:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2663, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "availableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 2624, + "src": "7097:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 2664, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "7124:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7097:34:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520696e207468652072657365727665", + "id": 2666, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7145:56:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_9c10b6537900636d83ba7fbecf42285691e54773e6afce15a8e3073697e73afc", + "typeString": "literal_string \"There is not enough liquidity available in the reserve\"" + }, + "value": "There is not enough liquidity available in the reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_9c10b6537900636d83ba7fbecf42285691e54773e6afce15a8e3073697e73afc", + "typeString": "literal_string \"There is not enough liquidity available in the reserve\"" + } + ], + "id": 2661, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "7076:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2667, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7076:135:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2668, + "nodeType": "ExpressionStatement", + "src": "7076:135:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2676, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2671, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "7273:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 2672, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "7273:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 2673, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "VARIABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7273:37:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + ], + "id": 2670, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "7268:4:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint" + }, + "id": 2674, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7268:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 2675, + "name": "_interestRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2631, + "src": "7315:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7268:64:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c696420696e7465726573742072617465206d6f64652073656c6563746564", + "id": 2677, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7334:37:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_148e2463e2c3f171ceacd1c76e5aaf02bc1873c12d85a90861cac2f1c00ea851", + "typeString": "literal_string \"Invalid interest rate mode selected\"" + }, + "value": "Invalid interest rate mode selected" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_148e2463e2c3f171ceacd1c76e5aaf02bc1873c12d85a90861cac2f1c00ea851", + "typeString": "literal_string \"Invalid interest rate mode selected\"" + } + ], + "id": 2669, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "7260:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2678, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7260:112:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2679, + "nodeType": "ExpressionStatement", + "src": "7260:112:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2686, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2680, + "name": "_interestRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2631, + "src": "7850:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2682, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "7879:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 2683, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "7879:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 2684, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7879:34:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + ], + "id": 2681, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "7871:7:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 2685, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7871:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7850:64:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 2754, + "nodeType": "IfStatement", + "src": "7847:1246:23", + "trueBody": { + "id": 2753, + "nodeType": "Block", + "src": "7916:1177:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 2699, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2694, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2688, + "name": "_interestRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2631, + "src": "8055:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2690, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "8084:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 2691, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "8084:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 2692, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "VARIABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8084:37:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + ], + "id": 2689, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "8076:7:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 2693, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8076:46:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8055:67:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2697, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "8182:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2695, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "8142:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2696, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveIsFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5870, + "src": "8142:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 2698, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8142:49:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "8055:136:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "466978656420626f72726f7773207261746520617265206e6f7420656e61626c6564206f6e20746869732072657365727665", + "id": 2700, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8209:52:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_30ae1e787de81771fb5e541f596463a9e035feec07d62cf38eac51130f3d5751", + "typeString": "literal_string \"Fixed borrows rate are not enabled on this reserve\"" + }, + "value": "Fixed borrows rate are not enabled on this reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_30ae1e787de81771fb5e541f596463a9e035feec07d62cf38eac51130f3d5751", + "typeString": "literal_string \"Fixed borrows rate are not enabled on this reserve\"" + } + ], + "id": 2687, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "8030:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2701, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8030:245:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2702, + "nodeType": "ExpressionStatement", + "src": "8030:245:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 2725, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 2716, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2710, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "8315:63:23", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2706, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "8357:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2707, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "8367:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2708, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8367:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2704, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "8316:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2705, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "8316:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 2709, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8316:62:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "id": 2715, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "8398:49:23", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2713, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "8438:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2711, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "8399:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2712, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isReserveUsageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5851, + "src": "8399:38:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 2714, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8399:48:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "8315:132:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2724, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2717, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "8467:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2720, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "8520:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2721, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "8530:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2722, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8530:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2718, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "8477:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 2719, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserUnderlyingAssetBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7008, + "src": "8477:42:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 2723, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8477:64:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8467:74:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "8315:226:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220697320747279696e6720746f20626f72726f7720616e20696e76616c696420616d6f756e74", + "id": 2726, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8559:44:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_d828d5250cbd206210abf2bf1b651ea1c5f80f5dc1f96d117696388e19c48244", + "typeString": "literal_string \"User is trying to borrow an invalid amount\"" + }, + "value": "User is trying to borrow an invalid amount" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_d828d5250cbd206210abf2bf1b651ea1c5f80f5dc1f96d117696388e19c48244", + "typeString": "literal_string \"User is trying to borrow an invalid amount\"" + } + ], + "id": 2703, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "8290:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2727, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8290:327:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2728, + "nodeType": "ExpressionStatement", + "src": "8290:327:23" + }, + { + "assignments": [ + 2730 + ], + "declarations": [ + { + "constant": false, + "id": 2730, + "name": "maxLoanPercent", + "nodeType": "VariableDeclaration", + "scope": 2753, + "src": "8797:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2729, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8797:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2734, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2731, + "name": "parametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2269, + "src": "8822:18:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "id": 2732, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getMaxFixedRateBorrowSizePercent", + "nodeType": "MemberAccess", + "referencedDeclaration": 1381, + "src": "8822:51:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$", + "typeString": "function () view external returns (uint256)" + } + }, + "id": 2733, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8822:53:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8797:78:23" + }, + { + "assignments": [ + 2736 + ], + "declarations": [ + { + "constant": false, + "id": 2736, + "name": "maxLoanSizeFixed", + "nodeType": "VariableDeclaration", + "scope": 2753, + "src": "8889:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2735, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8889:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2745, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 2743, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8964:3:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2740, + "name": "maxLoanPercent", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2730, + "src": "8944:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2737, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "8916:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2738, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "availableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 2624, + "src": "8916:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2739, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "8916:27:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2741, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8916:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2742, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "8916:47:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2744, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8916:52:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8889:79:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2749, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2747, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "8991:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<=", + "rightExpression": { + "argumentTypes": null, + "id": 2748, + "name": "maxLoanSizeFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2736, + "src": "9002:16:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8991:27:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220697320747279696e6720746f20626f72726f7720746f6f206d756368206c697175696469747920617420612066697865642072617465", + "id": 2750, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9020:61:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e7334a70b1b6a5df69ac251546afd886a5c469b034042a77e0cd31fc8a6c3d78", + "typeString": "literal_string \"User is trying to borrow too much liquidity at a fixed rate\"" + }, + "value": "User is trying to borrow too much liquidity at a fixed rate" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_e7334a70b1b6a5df69ac251546afd886a5c469b034042a77e0cd31fc8a6c3d78", + "typeString": "literal_string \"User is trying to borrow too much liquidity at a fixed rate\"" + } + ], + "id": 2746, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "8983:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2751, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8983:99:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2752, + "nodeType": "ExpressionStatement", + "src": "8983:99:23" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 2772, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2755, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9114:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2757, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "userCollateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2614, + "src": "9114:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2758, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9153:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2759, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "userBorrowBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2616, + "src": "9153:25:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2760, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9188:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2761, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentLtv", + "nodeType": "MemberAccess", + "referencedDeclaration": 2598, + "src": "9188:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2762, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9213:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2763, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 2600, + "src": "9213:32:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2764, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9255:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2765, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "healthFactor", + "nodeType": "MemberAccess", + "referencedDeclaration": 2618, + "src": "9255:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 2766, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "9103:170:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(,uint256,uint256,uint256,uint256,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2769, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "9313:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2770, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "9313:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2767, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "9276:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 2768, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "calculateUserGlobalData", + "nodeType": "MemberAccess", + "referencedDeclaration": 6984, + "src": "9276:36:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "id": 2771, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9276:48:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "src": "9103:221:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2773, + "nodeType": "ExpressionStatement", + "src": "9103:221:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2778, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2775, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9343:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2776, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCollateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2614, + "src": "9343:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 2777, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9375:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "9343:33:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520636f6c6c61746572616c2062616c616e63652069732030", + "id": 2779, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9378:29:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_4906e71889877e86aca58c927ee977f528175254bbe737726eb5fd4d4cde529b", + "typeString": "literal_string \"The collateral balance is 0\"" + }, + "value": "The collateral balance is 0" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_4906e71889877e86aca58c927ee977f528175254bbe737726eb5fd4d4cde529b", + "typeString": "literal_string \"The collateral balance is 0\"" + } + ], + "id": 2774, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "9335:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2780, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9335:73:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2781, + "nodeType": "ExpressionStatement", + "src": "9335:73:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2788, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2783, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9440:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2784, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "healthFactor", + "nodeType": "MemberAccess", + "referencedDeclaration": 2618, + "src": "9440:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2785, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "9460:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 2786, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getHealthFactorLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7263, + "src": "9460:48:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_pure$__$returns$_t_uint256_$", + "typeString": "function () pure external returns (uint256)" + } + }, + "id": 2787, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9460:50:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9440:70:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520626f72726f7765722063616e20616c7265616479206265206c69717569646174656420736f2068652063616e6e6f7420626f72726f77206d6f7265", + "id": 2789, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9524:65:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_0109ccf99421c8b30c361b04565d2bb05311b96001568cf2dffb17e909b7d2ca", + "typeString": "literal_string \"The borrower can already be liquidated so he cannot borrow more\"" + }, + "value": "The borrower can already be liquidated so he cannot borrow more" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_0109ccf99421c8b30c361b04565d2bb05311b96001568cf2dffb17e909b7d2ca", + "typeString": "literal_string \"The borrower can already be liquidated so he cannot borrow more\"" + } + ], + "id": 2782, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "9419:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2790, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9419:180:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2791, + "nodeType": "ExpressionStatement", + "src": "9419:180:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2805, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2792, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9638:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2794, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "borrowFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 2602, + "src": "9638:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2801, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "9745:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2802, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "9745:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 2803, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "9769:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2796, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "9668:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2797, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeeProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1316, + "src": "9668:32:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 2798, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9668:34:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2795, + "name": "IFeeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1765, + "src": "9655:12:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IFeeProvider_$1765_$", + "typeString": "type(contract IFeeProvider)" + } + }, + "id": 2799, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9655:48:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFeeProvider_$1765", + "typeString": "contract IFeeProvider" + } + }, + "id": 2800, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "calculateLoanOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 1744, + "src": "9655:76:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (address,uint256) view external returns (uint256)" + } + }, + "id": 2804, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9655:131:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9638:148:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2806, + "nodeType": "ExpressionStatement", + "src": "9638:148:23" + }, + { + "assignments": [ + 2808 + ], + "declarations": [ + { + "constant": false, + "id": 2808, + "name": "oracle", + "nodeType": "VariableDeclaration", + "scope": 3018, + "src": "9797:19:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + }, + "typeName": { + "contractScope": null, + "id": 2807, + "name": "IPriceOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1959, + "src": "9797:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 2814, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 2810, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "9832:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 2811, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getPriceOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1266, + "src": "9832:32:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 2812, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9832:34:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 2809, + "name": "IPriceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1959, + "src": "9819:12:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IPriceOracle_$1959_$", + "typeString": "type(contract IPriceOracle)" + } + }, + "id": 2813, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9819:48:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9797:70:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2829, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2815, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9877:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2817, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "requestedBorrowAmountETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2604, + "src": "9877:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2825, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "9959:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2826, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 2602, + "src": "9959:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2823, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "9947:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2824, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "9947:11:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2827, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9947:27:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2820, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "9930:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2818, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2808, + "src": "9909:6:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 2819, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getAssetPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 1941, + "src": "9909:20:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2821, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9909:30:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2822, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9072, + "src": "9909:37:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2828, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9909:66:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9877:98:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2830, + "nodeType": "ExpressionStatement", + "src": "9877:98:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2847, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2831, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10122:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2833, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "amountOfCollateralNeededETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2606, + "src": "10122:32:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2844, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10244:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2845, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentLtv", + "nodeType": "MemberAccess", + "referencedDeclaration": 2598, + "src": "10244:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 2841, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "10222:3:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2837, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10187:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2838, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "requestedBorrowAmountETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2604, + "src": "10187:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2834, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10157:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2835, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userBorrowBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2616, + "src": "10157:25:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2836, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "10157:29:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2839, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10157:60:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2840, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "10157:64:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2842, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10157:69:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2843, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "10157:73:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2846, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10157:112:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10122:147:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2848, + "nodeType": "ExpressionStatement", + "src": "10122:147:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2854, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2850, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10335:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2851, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "amountOfCollateralNeededETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2606, + "src": "10335:32:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<=", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2852, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10371:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2853, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCollateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 2614, + "src": "10371:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10335:65:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468657265206973206e6f7420656e6f75676820636f6c6c61746572616c20746f20636f7665722061206e657720626f72726f77", + "id": 2855, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "10414:54:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_7d9e5bd094433ef0185b4582b59e6f8f44b32836fb1b79d11b395d7492eda7cd", + "typeString": "literal_string \"There is not enough collateral to cover a new borrow\"" + }, + "value": "There is not enough collateral to cover a new borrow" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_7d9e5bd094433ef0185b4582b59e6f8f44b32836fb1b79d11b395d7492eda7cd", + "typeString": "literal_string \"There is not enough collateral to cover a new borrow\"" + } + ], + "id": 2849, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "10314:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 2856, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10314:164:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2857, + "nodeType": "ExpressionStatement", + "src": "10314:164:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2861, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "10702:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2858, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "10666:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2860, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "10666:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2862, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10666:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2863, + "nodeType": "ExpressionStatement", + "src": "10666:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2867, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "10770:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2868, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "10780:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2869, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "10780:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2864, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "10721:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2866, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserLastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 5170, + "src": "10721:48:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 2870, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10721:70:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2871, + "nodeType": "ExpressionStatement", + "src": "10721:70:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2886, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2872, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10931:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2874, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 2608, + "src": "10931:27:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2875, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "10968:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2876, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "compoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 2610, + "src": "10968:28:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2877, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11006:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2878, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "compoundedAmount", + "nodeType": "MemberAccess", + "referencedDeclaration": 2612, + "src": "11006:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 2879, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "10930:98:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2882, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "11058:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2883, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "11068:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2884, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11068:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2880, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "11031:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2881, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "11031:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 2885, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11031:48:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "src": "10930:149:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2887, + "nodeType": "ExpressionStatement", + "src": "10930:149:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2896, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2888, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11090:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2890, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "balanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 2620, + "src": "11090:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2894, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "11139:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2891, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11113:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2892, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedAmount", + "nodeType": "MemberAccess", + "referencedDeclaration": 2612, + "src": "11113:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2893, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "11113:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 2895, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11113:34:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11090:57:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2897, + "nodeType": "ExpressionStatement", + "src": "11090:57:23" + }, + { + "expression": { + "argumentTypes": null, + "id": 2905, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2898, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11421:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2900, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentReserveFixedRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 2622, + "src": "11421:28:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2903, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "11490:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2901, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "11452:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2902, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5681, + "src": "11452:37:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 2904, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11452:47:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11421:78:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 2906, + "nodeType": "ExpressionStatement", + "src": "11421:78:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2910, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "11564:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2911, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "11586:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2912, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11586:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2913, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11610:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2914, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 2608, + "src": "11610:27:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2915, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11651:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2916, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 2620, + "src": "11651:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2919, + "name": "_interestRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2631, + "src": "11714:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2917, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "11685:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 2918, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "11685:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 2920, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11685:47:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2921, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "11746:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2922, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentReserveFixedRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 2622, + "src": "11746:28:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2907, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "11510:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2909, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveTotalBorrowsByRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5121, + "src": "11510:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$_t_enum$_InterestRateMode_$8267_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256,enum CoreLibrary.InterestRateMode,uint256) external" + } + }, + "id": 2923, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11510:274:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2924, + "nodeType": "ExpressionStatement", + "src": "11510:274:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 2931, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 2925, + "name": "_interestRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2631, + "src": "11851:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2927, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "11880:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 2928, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "11880:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 2929, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11880:34:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + ], + "id": 2926, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "11872:7:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 2930, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11872:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11851:64:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 2949, + "nodeType": "Block", + "src": "12000:99:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2944, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12067:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2945, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12077:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2946, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12077:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2941, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12037:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2943, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "resetUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5420, + "src": "12037:29:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 2947, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12037:51:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2948, + "nodeType": "ExpressionStatement", + "src": "12037:51:23" + } + ] + }, + "id": 2950, + "nodeType": "IfStatement", + "src": "11847:252:23", + "trueBody": { + "id": 2940, + "nodeType": "Block", + "src": "11917:77:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2935, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "11962:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2936, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "11972:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2937, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11972:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2932, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "11931:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2934, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5394, + "src": "11931:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 2938, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11931:52:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2939, + "nodeType": "ExpressionStatement", + "src": "11931:52:23" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2954, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12223:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2955, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "12233:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2956, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedAmount", + "nodeType": "MemberAccess", + "referencedDeclaration": 2612, + "src": "12233:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2951, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12188:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2953, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "12188:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 2957, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12188:67:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2958, + "nodeType": "ExpressionStatement", + "src": "12188:67:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2962, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12298:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2959, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12266:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2961, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "12266:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2963, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12266:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2964, + "nodeType": "ExpressionStatement", + "src": "12266:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2968, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12343:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 2965, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12317:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2967, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "12317:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 2969, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12317:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2970, + "nodeType": "ExpressionStatement", + "src": "12317:35:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2974, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12450:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2975, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12460:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2976, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12460:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2977, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "12472:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2978, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 2620, + "src": "12472:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2971, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12410:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2973, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseUserPrincipalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 5269, + "src": "12410:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 2979, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12410:83:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2980, + "nodeType": "ExpressionStatement", + "src": "12410:83:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2984, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12535:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2985, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12545:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2986, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12545:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2987, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2642, + "src": "12557:4:23", + "typeDescriptions": { + "typeIdentifier": "t_struct$_BorrowLocalVars_$2625_memory_ptr", + "typeString": "struct LendingPool.BorrowLocalVars memory" + } + }, + "id": 2988, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 2602, + "src": "12557:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2981, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12503:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2983, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseUserOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 5202, + "src": "12503:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 2989, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12503:69:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2990, + "nodeType": "ExpressionStatement", + "src": "12503:69:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 2994, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12605:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 2995, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12615:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 2996, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12615:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 2991, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12582:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 2993, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5366, + "src": "12582:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 2997, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12582:44:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 2998, + "nodeType": "ExpressionStatement", + "src": "12582:44:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3002, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12709:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3003, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12719:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3004, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12719:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3005, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "12731:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 2999, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "12689:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3001, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToUser", + "nodeType": "MemberAccess", + "referencedDeclaration": 6486, + "src": "12689:19:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) external" + } + }, + "id": 3006, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12689:50:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3007, + "nodeType": "ExpressionStatement", + "src": "12689:50:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3009, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "12797:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3010, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "12807:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3011, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12807:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3012, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2629, + "src": "12819:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3013, + "name": "_referralCode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2633, + "src": "12828:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3014, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "12843:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 3015, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "12843:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 3008, + "name": "Borrow", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2303, + "src": "12790:6:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint16_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint16,uint256)" + } + }, + "id": 3016, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12790:69:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3017, + "nodeType": "EmitStatement", + "src": "12785:74:23" + } + ] + }, + "documentation": "@notice executes a borrow on the reserve of the specific amount with the interestRateMode specified.", + "id": 3019, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 2636, + "modifierName": { + "argumentTypes": null, + "id": 2635, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "6688:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6688:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 2638, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2627, + "src": "6719:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 2639, + "modifierName": { + "argumentTypes": null, + "id": 2637, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "6701:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "6701:27:23" + } + ], + "name": "borrow", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 2634, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 2627, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3019, + "src": "6563:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 2626, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6563:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2629, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 3019, + "src": "6589:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2628, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6589:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2631, + "name": "_interestRateMode", + "nodeType": "VariableDeclaration", + "scope": 3019, + "src": "6614:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 2630, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6614:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 2633, + "name": "_referralCode", + "nodeType": "VariableDeclaration", + "scope": 3019, + "src": "6649:20:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + }, + "typeName": { + "id": 2632, + "name": "uint16", + "nodeType": "ElementaryTypeName", + "src": "6649:6:23", + "typeDescriptions": { + "typeIdentifier": "t_uint16", + "typeString": "uint16" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6553:117:23" + }, + "returnParameters": { + "id": 2640, + "nodeType": "ParameterList", + "parameters": [], + "src": "6729:0:23" + }, + "scope": 4094, + "src": "6538:6328:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3289, + "nodeType": "Block", + "src": "13319:3782:23", + "statements": [ + { + "assignments": [ + 3034, + 3036, + 3038 + ], + "declarations": [ + { + "constant": false, + "id": 3034, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "13331:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3033, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13331:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3036, + "name": "compoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "13371:31:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3035, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13371:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3038, + "name": "borrowBalanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "13412:29:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3037, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13412:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3044, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3041, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "13472:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3042, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "13482:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3039, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "13445:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3040, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "13445:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 3043, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13445:49:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13330:164:23" + }, + { + "assignments": [ + 3046 + ], + "declarations": [ + { + "constant": false, + "id": 3046, + "name": "originationFee", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "13505:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3045, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13505:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3052, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3049, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "13557:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3050, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "13567:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3047, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "13530:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3048, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 5956, + "src": "13530:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3051, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13530:49:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13505:74:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3056, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3054, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3036, + "src": "13598:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3055, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "13624:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "13598:27:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "546865207573657220646f6573206e6f74206861766520616e7920626f72726f772070656e64696e67", + "id": 3057, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "13627:43:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c7917d465aa2240787bb76493308d4332358c1988a6a1162a1c5ffa34fc9f2c4", + "typeString": "literal_string \"The user does not have any borrow pending\"" + }, + "value": "The user does not have any borrow pending" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_c7917d465aa2240787bb76493308d4332358c1988a6a1162a1c5ffa34fc9f2c4", + "typeString": "literal_string \"The user does not have any borrow pending\"" + } + ], + "id": 3053, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "13590:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3058, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13590:81:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3059, + "nodeType": "ExpressionStatement", + "src": "13590:81:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 3068, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3063, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3061, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3023, + "src": "13703:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 3062, + "name": "UINT_MAX_VALUE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2390, + "src": "13714:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13703:25:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "id": 3067, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3064, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "13732:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "13732:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 3066, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "13746:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "13732:25:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "13703:54:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "546f207265706179206f6e20626568616c66206f6620616e207573657220616e206578706c6963697420616d6f756e7420746f207265706179206973206e65656465642e", + "id": 3069, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "13771:70:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e6331304cf90ad18bd8dda0978ea7dab720dfa02bd139bfa14dc42aa91cebb45", + "typeString": "literal_string \"To repay on behalf of an user an explicit amount to repay is needed.\"" + }, + "value": "To repay on behalf of an user an explicit amount to repay is needed." + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_e6331304cf90ad18bd8dda0978ea7dab720dfa02bd139bfa14dc42aa91cebb45", + "typeString": "literal_string \"To repay on behalf of an user an explicit amount to repay is needed.\"" + } + ], + "id": 3060, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "13682:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3070, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13682:169:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3071, + "nodeType": "ExpressionStatement", + "src": "13682:169:23" + }, + { + "assignments": [ + 3073 + ], + "declarations": [ + { + "constant": false, + "id": 3073, + "name": "paybackAmount", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "13894:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3072, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13894:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3078, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3076, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3046, + "src": "13946:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3074, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3036, + "src": "13918:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3075, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "13918:27:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3077, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13918:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13894:67:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 3085, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3081, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3079, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3023, + "src": "13976:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 3080, + "name": "UINT_MAX_VALUE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2390, + "src": "13987:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13976:25:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "&&", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3084, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3082, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3023, + "src": "14005:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "id": 3083, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14015:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "14005:23:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "13976:52:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 3091, + "nodeType": "IfStatement", + "src": "13972:106:23", + "trueBody": { + "id": 3090, + "nodeType": "Block", + "src": "14030:48:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 3088, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 3086, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14044:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 3087, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3023, + "src": "14060:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "14044:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3089, + "nodeType": "ExpressionStatement", + "src": "14044:23:23" + } + ] + } + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3094, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3092, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14209:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<=", + "rightExpression": { + "argumentTypes": null, + "id": 3093, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3046, + "src": "14226:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "14209:31:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 3125, + "nodeType": "IfStatement", + "src": "14205:440:23", + "trueBody": { + "id": 3124, + "nodeType": "Block", + "src": "14242:403:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3098, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "14288:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3099, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "14298:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3100, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14311:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3095, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "14256:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3097, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseUserOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 5234, + "src": "14256:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 3101, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14256:69:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3102, + "nodeType": "ExpressionStatement", + "src": "14256:69:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3111, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "14409:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3112, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "14435:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3113, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14464:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3115, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "14508:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 3116, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeeProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1316, + "src": "14508:32:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 3117, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14508:34:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 3114, + "name": "IFeeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1765, + "src": "14495:12:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IFeeProvider_$1765_$", + "typeString": "type(contract IFeeProvider)" + } + }, + "id": 3118, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14495:48:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFeeProvider_$1765", + "typeString": "contract IFeeProvider" + } + }, + "id": 3119, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeesCollectionAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1764, + "src": "14495:73:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 3120, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14495:75:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3108, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "14381:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3109, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "14381:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3103, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "14339:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3106, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToFeeCollectionAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 6537, + "src": "14339:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$", + "typeString": "function (address,address,uint256,address) payable external" + } + }, + "id": 3107, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "14339:41:23", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$value_$", + "typeString": "function (uint256) returns (function (address,address,uint256,address) payable external)" + } + }, + "id": 3110, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14339:52:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$value", + "typeString": "function (address,address,uint256,address) payable external" + } + }, + "id": 3121, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14339:245:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3122, + "nodeType": "ExpressionStatement", + "src": "14339:245:23" + }, + { + "expression": null, + "functionReturnParameters": 3032, + "id": 3123, + "nodeType": "Return", + "src": "14628:7:23" + } + ] + } + }, + { + "assignments": [ + 3127 + ], + "declarations": [ + { + "constant": false, + "id": 3127, + "name": "paybackAmountMinusFees", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "14655:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3126, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14655:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3132, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3130, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3046, + "src": "14706:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3128, + "name": "paybackAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3073, + "src": "14688:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3129, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "14688:17:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3131, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14688:33:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14655:66:23" + }, + { + "assignments": [ + 3134 + ], + "declarations": [ + { + "constant": false, + "id": 3134, + "name": "actualBalanceDecrease", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "14731:29:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3133, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14731:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3139, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3137, + "name": "borrowBalanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3038, + "src": "14790:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3135, + "name": "paybackAmountMinusFees", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3127, + "src": "14763:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3136, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "14763:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3138, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14763:49:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14731:81:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3143, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "14907:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3144, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "14917:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3145, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3046, + "src": "14930:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3140, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "14875:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3142, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseUserOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 5234, + "src": "14875:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 3146, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14875:70:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3147, + "nodeType": "ExpressionStatement", + "src": "14875:70:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3156, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15021:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3157, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "15043:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3158, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3046, + "src": "15068:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3160, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "15109:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 3161, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeeProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1316, + "src": "15109:32:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 3162, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15109:34:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 3159, + "name": "IFeeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1765, + "src": "15096:12:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IFeeProvider_$1765_$", + "typeString": "type(contract IFeeProvider)" + } + }, + "id": 3163, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15096:48:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFeeProvider_$1765", + "typeString": "contract IFeeProvider" + } + }, + "id": 3164, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeesCollectionAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1764, + "src": "15096:73:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 3165, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15096:75:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3153, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "14997:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3154, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "14997:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3148, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "14955:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3151, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToFeeCollectionAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 6537, + "src": "14955:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$", + "typeString": "function (address,address,uint256,address) payable external" + } + }, + "id": 3152, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "14955:41:23", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$value_$", + "typeString": "function (uint256) returns (function (address,address,uint256,address) payable external)" + } + }, + "id": 3155, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14955:52:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$value", + "typeString": "function (address,address,uint256,address) payable external" + } + }, + "id": 3166, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14955:226:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3167, + "nodeType": "ExpressionStatement", + "src": "14955:226:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3171, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15348:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3168, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "15312:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3170, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "15312:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3172, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15312:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3173, + "nodeType": "ExpressionStatement", + "src": "15312:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3177, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15416:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3178, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "15426:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3174, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "15367:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3176, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserLastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 5170, + "src": "15367:48:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3179, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15367:71:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3180, + "nodeType": "ExpressionStatement", + "src": "15367:71:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3184, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15523:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3185, + "name": "borrowBalanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3038, + "src": "15533:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3181, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "15488:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3183, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "15488:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3186, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15488:67:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3187, + "nodeType": "ExpressionStatement", + "src": "15488:67:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3191, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15730:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3192, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "15740:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3193, + "name": "actualBalanceDecrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3134, + "src": "15753:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3188, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "15690:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3190, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseUserPrincipalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 5309, + "src": "15690:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 3194, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15690:85:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3195, + "nodeType": "ExpressionStatement", + "src": "15690:85:23" + }, + { + "assignments": [ + 3199 + ], + "declarations": [ + { + "constant": false, + "id": 3199, + "name": "borrowRateMode", + "nodeType": "VariableDeclaration", + "scope": 3289, + "src": "15891:43:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 3198, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "15891:28:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3205, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3202, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "15971:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3203, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "15981:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3200, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "15937:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3201, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentBorrowRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5988, + "src": "15937:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view external returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3204, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15937:56:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "15891:102:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 3210, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3206, + "name": "borrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3199, + "src": "16008:14:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3207, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "16026:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 3208, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "16026:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3209, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "16026:34:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "16008:52:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 3247, + "nodeType": "Block", + "src": "16642:98:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3243, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16697:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3244, + "name": "actualBalanceDecrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3134, + "src": "16707:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3240, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16656:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3242, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 4991, + "src": "16656:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3245, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16656:73:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3246, + "nodeType": "ExpressionStatement", + "src": "16656:73:23" + } + ] + }, + "id": 3248, + "nodeType": "IfStatement", + "src": "16004:736:23", + "trueBody": { + "id": 3239, + "nodeType": "Block", + "src": "16062:574:23", + "statements": [ + { + "assignments": [ + 3212 + ], + "declarations": [ + { + "constant": false, + "id": 3212, + "name": "currentFixedRate", + "nodeType": "VariableDeclaration", + "scope": 3239, + "src": "16076:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3211, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "16076:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3218, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3215, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16138:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3216, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "16148:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3213, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16103:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3214, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6011, + "src": "16103:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3217, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16103:57:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "16076:84:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3222, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16232:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3223, + "name": "actualBalanceDecrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3134, + "src": "16242:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3224, + "name": "currentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3212, + "src": "16265:16:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3219, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16174:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3221, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 4954, + "src": "16174:57:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 3225, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16174:108:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3226, + "nodeType": "ExpressionStatement", + "src": "16174:108:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3229, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3227, + "name": "actualBalanceDecrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3134, + "src": "16492:21:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 3228, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3034, + "src": "16517:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "16492:47:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 3238, + "nodeType": "IfStatement", + "src": "16489:137:23", + "trueBody": { + "id": 3237, + "nodeType": "Block", + "src": "16541:85:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3233, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16589:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3234, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "16599:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3230, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16559:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3232, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "resetUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5420, + "src": "16559:29:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3235, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16559:52:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3236, + "nodeType": "ExpressionStatement", + "src": "16559:52:23" + } + ] + } + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3252, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16782:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3249, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16750:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3251, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "16750:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3253, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16750:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3254, + "nodeType": "ExpressionStatement", + "src": "16750:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3258, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16828:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3255, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16802:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3257, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "16802:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3259, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16802:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3260, + "nodeType": "ExpressionStatement", + "src": "16802:35:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3264, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16870:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3265, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "16880:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3261, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16847:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3263, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5366, + "src": "16847:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3266, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16847:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3267, + "nodeType": "ExpressionStatement", + "src": "16847:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3276, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "16943:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3277, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "16953:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3278, + "name": "paybackAmountMinusFees", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3127, + "src": "16966:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3273, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "16932:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3274, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "16932:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3268, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "16903:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3271, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6619, + "src": "16903:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 3272, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "16903:28:23", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value_$", + "typeString": "function (uint256) returns (function (address,address payable,uint256) payable external)" + } + }, + "id": 3275, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16903:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 3279, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "16903:86:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3280, + "nodeType": "ExpressionStatement", + "src": "16903:86:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3282, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "17046:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3283, + "name": "_onBehalfOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3025, + "src": "17056:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3284, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3023, + "src": "17069:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3285, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "17078:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 3286, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "17078:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 3281, + "name": "Repay", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2313, + "src": "17040:5:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256)" + } + }, + "id": 3287, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17040:54:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3288, + "nodeType": "EmitStatement", + "src": "17035:59:23" + } + ] + }, + "documentation": "@notice repays a borrow on the specific reserve, for the specified amount.\n@dev the target user is defined by _onBehalfOf. If there is no repayment on behalf of another account,\n_onBehalfOf must be equal to msg.sender.", + "id": 3290, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3028, + "modifierName": { + "argumentTypes": null, + "id": 3027, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "13270:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "13270:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 3030, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3021, + "src": "13309:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 3031, + "modifierName": { + "argumentTypes": null, + "id": 3029, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "13291:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "13291:27:23" + } + ], + "name": "repay", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3026, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3021, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3290, + "src": "13149:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3020, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13149:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3023, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 3290, + "src": "13175:15:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3022, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13175:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3025, + "name": "_onBehalfOf", + "nodeType": "VariableDeclaration", + "scope": 3290, + "src": "13200:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 3024, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13200:15:23", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13139:89:23" + }, + "returnParameters": { + "id": 3032, + "nodeType": "ParameterList", + "parameters": [], + "src": "13319:0:23" + }, + "scope": 4094, + "src": "13125:3976:23", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3493, + "nodeType": "Block", + "src": "17325:2987:23", + "statements": [ + { + "assignments": [ + 3303 + ], + "declarations": [ + { + "constant": false, + "id": 3303, + "name": "currentRateMode", + "nodeType": "VariableDeclaration", + "scope": 3493, + "src": "17336:44:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 3302, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "17336:28:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3310, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3306, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "17417:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3307, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "17427:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3308, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "17427:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3304, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "17383:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3305, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentBorrowRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5988, + "src": "17383:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view external returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3309, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17383:55:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17336:102:23" + }, + { + "assignments": [ + 3312, + 3314, + 3316 + ], + "declarations": [ + { + "constant": false, + "id": 3312, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 3493, + "src": "17449:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3311, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "17449:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3314, + "name": "compoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 3493, + "src": "17489:31:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3313, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "17489:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3316, + "name": "balanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 3493, + "src": "17530:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3315, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "17530:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3323, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3319, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "17584:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3320, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "17594:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3321, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "17594:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3317, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "17557:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3318, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "17557:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 3322, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17557:48:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17448:157:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3327, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3325, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3314, + "src": "17624:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3326, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "17650:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "17624:27:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220646f6573206e6f742068617665206120626f72726f7720696e2070726f6772657373206f6e20746869732072657365727665", + "id": 3328, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "17653:57:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_718668e522954015c4c3baf01c0871155fb82c8781867444b9071c1e053b8de3", + "typeString": "literal_string \"User does not have a borrow in progress on this reserve\"" + }, + "value": "User does not have a borrow in progress on this reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_718668e522954015c4c3baf01c0871155fb82c8781867444b9071c1e053b8de3", + "typeString": "literal_string \"User does not have a borrow in progress on this reserve\"" + } + ], + "id": 3324, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "17616:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3329, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17616:95:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3330, + "nodeType": "ExpressionStatement", + "src": "17616:95:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3334, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "17796:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3331, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "17760:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3333, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "17760:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3335, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17760:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3336, + "nodeType": "ExpressionStatement", + "src": "17760:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3340, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "17864:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3341, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "17874:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3342, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "17874:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3337, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "17815:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3339, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserLastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 5170, + "src": "17815:48:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3343, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17815:70:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3344, + "nodeType": "ExpressionStatement", + "src": "17815:70:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 3349, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3345, + "name": "currentRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3303, + "src": "17899:15:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3346, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "17918:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 3347, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "17918:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3348, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "17918:34:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "17899:53:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 3447, + "nodeType": "Block", + "src": "18455:1404:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3386, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "18957:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3384, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "18917:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3385, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveIsFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5870, + "src": "18917:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 3387, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "18917:49:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "466978656420626f72726f7773207261746520617265206e6f7420656e61626c6564206f6e20746869732072657365727665", + "id": 3388, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "18984:52:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_30ae1e787de81771fb5e541f596463a9e035feec07d62cf38eac51130f3d5751", + "typeString": "literal_string \"Fixed borrows rate are not enabled on this reserve\"" + }, + "value": "Fixed borrows rate are not enabled on this reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_30ae1e787de81771fb5e541f596463a9e035feec07d62cf38eac51130f3d5751", + "typeString": "literal_string \"Fixed borrows rate are not enabled on this reserve\"" + } + ], + "id": 3383, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "18892:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3389, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "18892:158:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3390, + "nodeType": "ExpressionStatement", + "src": "18892:158:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 3413, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 3404, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3398, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "19090:63:23", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3394, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19132:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3395, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "19142:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3396, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "19142:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3392, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19091:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3393, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "19091:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 3397, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19091:62:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "id": 3403, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "19173:49:23", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3401, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19213:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3399, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19174:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3400, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isReserveUsageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5851, + "src": "19174:38:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 3402, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19174:48:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "19090:132:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3412, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3405, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3314, + "src": "19242:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3408, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19311:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3409, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "19321:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3410, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "19321:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3406, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "19268:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3407, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserUnderlyingAssetBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7008, + "src": "19268:42:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3411, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19268:64:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "19242:90:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "19090:242:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220697320747279696e6720746f20626f72726f7720616e20616d6f756e74207468617420697320736d616c6c6572207468616e2077686174206865206465706f73697465642e", + "id": 3414, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "19350:76:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8e8988b95b250557994d0199f494f8a57e6ed9d03c97f897c930ab8fb8cdf6e8", + "typeString": "literal_string \"User is trying to borrow an amount that is smaller than what he deposited.\"" + }, + "value": "User is trying to borrow an amount that is smaller than what he deposited." + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_8e8988b95b250557994d0199f494f8a57e6ed9d03c97f897c930ab8fb8cdf6e8", + "typeString": "literal_string \"User is trying to borrow an amount that is smaller than what he deposited.\"" + } + ], + "id": 3391, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "19065:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3415, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19065:375:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3416, + "nodeType": "ExpressionStatement", + "src": "19065:375:23" + }, + { + "assignments": [ + 3418 + ], + "declarations": [ + { + "constant": false, + "id": 3418, + "name": "currentFixedRate", + "nodeType": "VariableDeclaration", + "scope": 3447, + "src": "19497:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3417, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "19497:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3423, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3421, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19562:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3419, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19524:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3420, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5681, + "src": "19524:37:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3422, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19524:47:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "19497:74:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3427, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19626:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3428, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3312, + "src": "19636:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3424, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19585:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3426, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 4991, + "src": "19585:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3429, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19585:74:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3430, + "nodeType": "ExpressionStatement", + "src": "19585:74:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3434, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19731:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3435, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3314, + "src": "19741:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3436, + "name": "currentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3418, + "src": "19766:16:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3431, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19673:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3433, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 4934, + "src": "19673:57:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 3437, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19673:110:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3438, + "nodeType": "ExpressionStatement", + "src": "19673:110:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3442, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19828:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3443, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "19837:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3444, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "19837:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3439, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19797:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3441, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5394, + "src": "19797:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3445, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19797:51:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3446, + "nodeType": "ExpressionStatement", + "src": "19797:51:23" + } + ] + }, + "id": 3448, + "nodeType": "IfStatement", + "src": "17896:1963:23", + "trueBody": { + "id": 3382, + "nodeType": "Block", + "src": "17953:488:23", + "statements": [ + { + "assignments": [ + 3351 + ], + "declarations": [ + { + "constant": false, + "id": 3351, + "name": "userFixedRate", + "nodeType": "VariableDeclaration", + "scope": 3382, + "src": "17968:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3350, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "17968:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3358, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3354, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "18027:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3355, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "18037:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3356, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "18037:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3352, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "17992:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3353, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6011, + "src": "17992:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3357, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "17992:56:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17968:80:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3362, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "18154:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3363, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3312, + "src": "18164:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3364, + "name": "userFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3351, + "src": "18188:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3359, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "18096:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3361, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 4954, + "src": "18096:57:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 3365, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "18096:106:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3366, + "nodeType": "ExpressionStatement", + "src": "18096:106:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3370, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "18303:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3371, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3314, + "src": "18313:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3367, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "18262:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3369, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 4974, + "src": "18262:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3372, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "18262:75:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3373, + "nodeType": "ExpressionStatement", + "src": "18262:75:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3377, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "18409:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3378, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "18419:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3379, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "18419:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3374, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "18379:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3376, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "resetUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5420, + "src": "18379:29:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3380, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "18379:51:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3381, + "nodeType": "ExpressionStatement", + "src": "18379:51:23" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3452, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19904:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3453, + "name": "balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3316, + "src": "19914:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3449, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19869:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3451, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "19869:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3454, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19869:61:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3455, + "nodeType": "ExpressionStatement", + "src": "19869:61:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3459, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "19972:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3456, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "19940:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3458, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "19940:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3460, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19940:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3461, + "nodeType": "ExpressionStatement", + "src": "19940:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3465, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "20074:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3466, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "20084:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3467, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "20084:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3468, + "name": "balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3316, + "src": "20096:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3462, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "20034:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3464, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseUserPrincipalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 5269, + "src": "20034:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 3469, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20034:78:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3470, + "nodeType": "ExpressionStatement", + "src": "20034:78:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3474, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "20148:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3471, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "20122:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3473, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "20122:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3475, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20122:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3476, + "nodeType": "ExpressionStatement", + "src": "20122:35:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3480, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "20190:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3481, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "20200:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3482, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "20200:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3477, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "20167:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3479, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5366, + "src": "20167:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3483, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20167:44:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3484, + "nodeType": "ExpressionStatement", + "src": "20167:44:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3486, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "20267:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3487, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "20277:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3488, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "20277:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3489, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "20289:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 3490, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "20289:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 3485, + "name": "Swap", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2333, + "src": "20262:4:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256)" + } + }, + "id": 3491, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20262:43:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3492, + "nodeType": "EmitStatement", + "src": "20257:48:23" + } + ] + }, + "documentation": "@notice allows the user to swap the current borrow rate mode, from fixed to variable and viceversa.", + "id": 3494, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3295, + "modifierName": { + "argumentTypes": null, + "id": 3294, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "17284:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "17284:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 3297, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3292, + "src": "17315:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 3298, + "modifierName": { + "argumentTypes": null, + "id": 3296, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "17297:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "17297:27:23" + } + ], + "name": "swapBorrowRateMode", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3293, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3292, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3494, + "src": "17257:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3291, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "17257:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17256:18:23" + }, + "returnParameters": { + "id": 3299, + "nodeType": "ParameterList", + "parameters": [], + "src": "17325:0:23" + }, + "scope": 4094, + "src": "17229:3083:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3634, + "nodeType": "Block", + "src": "20690:2313:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 3512, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3506, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "20756:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3507, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3498, + "src": "20765:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3504, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "20722:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3505, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentBorrowRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5988, + "src": "20722:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view external returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3508, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20722:49:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3509, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "20775:11:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 3510, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "20775:28:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 3511, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "20775:34:23", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "20722:87:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "546865207573657220626f72726f77206973207661726961626c6520616e642063616e6e6f7420626520726562616c616e636564", + "id": 3513, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "20823:54:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5a98527d2c56c096e76351ae749fedf53c91d460e35716d4ed657129cb941c65", + "typeString": "literal_string \"The user borrow is variable and cannot be rebalanced\"" + }, + "value": "The user borrow is variable and cannot be rebalanced" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_5a98527d2c56c096e76351ae749fedf53c91d460e35716d4ed657129cb941c65", + "typeString": "literal_string \"The user borrow is variable and cannot be rebalanced\"" + } + ], + "id": 3503, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "20701:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3514, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20701:190:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3515, + "nodeType": "ExpressionStatement", + "src": "20701:190:23" + }, + { + "assignments": [ + null, + 3517, + 3519 + ], + "declarations": [ + null, + { + "constant": false, + "id": 3517, + "name": "compoundedBalance", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "20913:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3516, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "20913:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3519, + "name": "balanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "20948:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3518, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "20948:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3526, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3522, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21002:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3523, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "21012:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3524, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "21012:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3520, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "20975:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3521, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "20975:26:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 3525, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20975:48:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "20902:121:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3530, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3528, + "name": "compoundedBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3517, + "src": "21124:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3529, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "21144:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "21124:21:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220646f6573206e6f74206861766520616e7920626f72726f7720666f7220746869732072657365727665", + "id": 3531, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "21159:48:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_1915b15b36ed5f5832a0d8c5f32f46d29e23c7345a8bcbc53a2390a08be12a0a", + "typeString": "literal_string \"User does not have any borrow for this reserve\"" + }, + "value": "User does not have any borrow for this reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_1915b15b36ed5f5832a0d8c5f32f46d29e23c7345a8bcbc53a2390a08be12a0a", + "typeString": "literal_string \"User does not have any borrow for this reserve\"" + } + ], + "id": 3527, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "21103:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3532, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21103:105:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3533, + "nodeType": "ExpressionStatement", + "src": "21103:105:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3537, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21313:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3534, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21277:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3536, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "21277:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3538, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21277:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3539, + "nodeType": "ExpressionStatement", + "src": "21277:45:23" + }, + { + "assignments": [ + 3541 + ], + "declarations": [ + { + "constant": false, + "id": 3541, + "name": "userCurrentFixedRate", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "21333:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3540, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "21333:4:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3547, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3544, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21396:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3545, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3498, + "src": "21405:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3542, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21361:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3543, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6011, + "src": "21361:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3546, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21361:50:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "21333:78:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3551, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21479:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3552, + "name": "balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3519, + "src": "21489:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3553, + "name": "userCurrentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3541, + "src": "21506:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3548, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21421:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3550, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 4934, + "src": "21421:57:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 3554, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21421:106:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3555, + "nodeType": "ExpressionStatement", + "src": "21421:106:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3559, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21577:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3560, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3498, + "src": "21587:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3561, + "name": "balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3519, + "src": "21594:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3556, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21537:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3558, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseUserPrincipalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 5269, + "src": "21537:39:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 3562, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21537:73:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3563, + "nodeType": "ExpressionStatement", + "src": "21537:73:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3567, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21655:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3568, + "name": "balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3519, + "src": "21665:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3564, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21620:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3566, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "21620:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3569, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21620:61:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3570, + "nodeType": "ExpressionStatement", + "src": "21620:61:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3574, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21717:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3571, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21691:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3573, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "21691:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3575, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21691:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3576, + "nodeType": "ExpressionStatement", + "src": "21691:35:23" + }, + { + "assignments": [ + 3578 + ], + "declarations": [ + { + "constant": false, + "id": 3578, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "21737:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3577, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "21737:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3583, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3581, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21797:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3579, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21761:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3580, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5719, + "src": "21761:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3582, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21761:45:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "21737:69:23" + }, + { + "assignments": [ + 3585 + ], + "declarations": [ + { + "constant": false, + "id": 3585, + "name": "reserveCurrentFixedRate", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "21816:31:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3584, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "21816:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3590, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3588, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "21888:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3586, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "21850:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3587, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5681, + "src": "21850:37:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3589, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21850:47:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "21816:81:23" + }, + { + "assignments": [ + 3592 + ], + "declarations": [ + { + "constant": false, + "id": 3592, + "name": "rebalanceDownRateThreshold", + "nodeType": "VariableDeclaration", + "scope": 3634, + "src": "21907:34:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3591, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "21907:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3604, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3599, + "name": "parametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2269, + "src": "22052:18:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "id": 3600, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getRebalanceDownRateDelta", + "nodeType": "MemberAccess", + "referencedDeclaration": 1404, + "src": "22052:44:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$", + "typeString": "function () view external returns (uint256)" + } + }, + "id": 3601, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22052:46:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3595, + "name": "WadRayMath", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9174, + "src": "21988:10:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_WadRayMath_$9174_$", + "typeString": "type(library WadRayMath)" + } + }, + "id": 3596, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "ray", + "nodeType": "MemberAccess", + "referencedDeclaration": 9027, + "src": "21988:27:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$__$returns$_t_uint256_$", + "typeString": "function () pure returns (uint256)" + } + }, + "id": 3597, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21988:29:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3598, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "21988:46:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3602, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21988:124:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3593, + "name": "reserveCurrentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3585, + "src": "21944:23:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3594, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "rayMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9120, + "src": "21944:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3603, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21944:169:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "21907:206:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 3611, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3607, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3605, + "name": "userCurrentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3541, + "src": "22636:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "id": 3606, + "name": "liquidityRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3578, + "src": "22659:13:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "22636:36:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3610, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3608, + "name": "userCurrentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3541, + "src": "22684:20:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 3609, + "name": "rebalanceDownRateThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3592, + "src": "22707:26:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "22684:49:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "22636:97:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 3629, + "nodeType": "IfStatement", + "src": "22633:295:23", + "trueBody": { + "id": 3628, + "nodeType": "Block", + "src": "22744:184:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3615, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "22824:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3616, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "22833:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3617, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "22833:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3612, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "22793:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3614, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateUserFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5394, + "src": "22793:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3618, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22793:51:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3619, + "nodeType": "ExpressionStatement", + "src": "22793:51:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3623, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3496, + "src": "22881:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3624, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3498, + "src": "22891:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3620, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "22858:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3622, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5366, + "src": "22858:22:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 3625, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22858:39:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3626, + "nodeType": "ExpressionStatement", + "src": "22858:39:23" + }, + { + "expression": null, + "functionReturnParameters": 3502, + "id": 3627, + "nodeType": "Return", + "src": "22911:7:23" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "496e746572657374207261746520726562616c616e636520636f6e646974696f6e73207768657265206e6f74206d6574", + "id": 3631, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "22945:50:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_6b84664b8ca5227a94caf7c150601896d3e2ce55785142f35c5271266a66d288", + "typeString": "literal_string \"Interest rate rebalance conditions where not met\"" + }, + "value": "Interest rate rebalance conditions where not met" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_6b84664b8ca5227a94caf7c150601896d3e2ce55785142f35c5271266a66d288", + "typeString": "literal_string \"Interest rate rebalance conditions where not met\"" + } + ], + "id": 3630, + "name": "revert", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12133, + 12134 + ], + "referencedDeclaration": 12134, + "src": "22938:6:23", + "typeDescriptions": { + "typeIdentifier": "t_function_revert_pure$_t_string_memory_ptr_$returns$__$", + "typeString": "function (string memory) pure" + } + }, + "id": 3632, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22938:58:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3633, + "nodeType": "ExpressionStatement", + "src": "22938:58:23" + } + ] + }, + "documentation": "@notice rebalances the fixed interest rate of a user if current liquidity rate > user fixed rate.\n@dev this is regulated by Aave to ensure that the protocol is not abused, and the user is paying a fair\nrate. Anyone can call this function though.", + "id": 3635, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3501, + "modifierName": { + "argumentTypes": null, + "id": 3500, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "20677:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "20677:12:23" + } + ], + "name": "rebalanceFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3499, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3496, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3635, + "src": "20635:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3495, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20635:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3498, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 3635, + "src": "20653:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3497, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20653:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20634:33:23" + }, + "returnParameters": { + "id": 3502, + "nodeType": "ParameterList", + "parameters": [], + "src": "20690:0:23" + }, + "scope": 4094, + "src": "20601:2402:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3696, + "nodeType": "Block", + "src": "23208:671:23", + "statements": [ + { + "assignments": [ + 3645 + ], + "declarations": [ + { + "constant": false, + "id": 3645, + "name": "underlyingBalance", + "nodeType": "VariableDeclaration", + "scope": 3696, + "src": "23219:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3644, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "23219:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3652, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3648, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3637, + "src": "23290:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3649, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "23299:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3650, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "23299:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "expression": { + "argumentTypes": null, + "id": 3646, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "23247:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3647, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserUnderlyingAssetBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7008, + "src": "23247:42:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 3651, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23247:63:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "23219:91:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3656, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3654, + "name": "underlyingBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3645, + "src": "23329:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3655, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23349:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "23329:21:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220646f6573206e6f74206861766520616e79206c6971756964697479206465706f7369746564", + "id": 3657, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23352:44:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a33f09dca6de47688a656ef882b2d46916d7bc325f5e2fda81e0afcea3ff2528", + "typeString": "literal_string \"User does not have any liquidity deposited\"" + }, + "value": "User does not have any liquidity deposited" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_a33f09dca6de47688a656ef882b2d46916d7bc325f5e2fda81e0afcea3ff2528", + "typeString": "literal_string \"User does not have any liquidity deposited\"" + } + ], + "id": 3653, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "23321:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3658, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23321:76:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3659, + "nodeType": "ExpressionStatement", + "src": "23321:76:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3663, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3637, + "src": "23465:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3664, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "23475:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3665, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "23475:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3666, + "name": "underlyingBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3645, + "src": "23487:17:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3661, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "23429:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3662, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceDecreaseAllowed", + "nodeType": "MemberAccess", + "referencedDeclaration": 7168, + "src": "23429:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,address,uint256) view external returns (bool)" + } + }, + "id": 3667, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23429:76:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "55736572206465706f73697420697320616c7265616479206265696e67207573656420617320636f6c6c61746572616c", + "id": 3668, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23519:50:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_1dc41e041ef7eb197e3fc50f36480baac7e4721c211d7b6652e582c6eb00756a", + "typeString": "literal_string \"User deposit is already being used as collateral\"" + }, + "value": "User deposit is already being used as collateral" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_1dc41e041ef7eb197e3fc50f36480baac7e4721c211d7b6652e582c6eb00756a", + "typeString": "literal_string \"User deposit is already being used as collateral\"" + } + ], + "id": 3660, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "23408:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3669, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23408:171:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3670, + "nodeType": "ExpressionStatement", + "src": "23408:171:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3674, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3637, + "src": "23625:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3675, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "23635:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3676, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "23635:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3677, + "name": "_useAsCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3639, + "src": "23647:16:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "expression": { + "argumentTypes": null, + "id": 3671, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "23590:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3673, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserUseReserveAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 5337, + "src": "23590:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_bool_$returns$__$", + "typeString": "function (address,address,bool) external" + } + }, + "id": 3678, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23590:74:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3679, + "nodeType": "ExpressionStatement", + "src": "23590:74:23" + }, + { + "condition": { + "argumentTypes": null, + "id": 3680, + "name": "_useAsCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3639, + "src": "23678:16:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 3694, + "nodeType": "Block", + "src": "23790:83:23", + "statements": [ + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3689, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3637, + "src": "23841:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3690, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "23851:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3691, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "23851:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 3688, + "name": "ReserveUsedAsCollateralDisabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2357, + "src": "23809:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address)" + } + }, + "id": 3692, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23809:53:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3693, + "nodeType": "EmitStatement", + "src": "23804:58:23" + } + ] + }, + "id": 3695, + "nodeType": "IfStatement", + "src": "23675:198:23", + "trueBody": { + "id": 3687, + "nodeType": "Block", + "src": "23695:82:23", + "statements": [ + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3682, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3637, + "src": "23745:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3683, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "23755:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 3684, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "23755:10:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 3681, + "name": "ReserveUsedAsCollateralEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2351, + "src": "23714:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address)" + } + }, + "id": 3685, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23714:52:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3686, + "nodeType": "EmitStatement", + "src": "23709:57:23" + } + ] + } + } + ] + }, + "documentation": "@notice allows user to enable or disable a specific deposit as collateral", + "id": 3697, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3642, + "modifierName": { + "argumentTypes": null, + "id": 3641, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "23195:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "23195:12:23" + } + ], + "name": "setUserUseReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3640, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3637, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3697, + "src": "23145:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3636, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "23145:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3639, + "name": "_useAsCollateral", + "nodeType": "VariableDeclaration", + "scope": 3697, + "src": "23163:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3638, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "23163:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "23144:41:23" + }, + "returnParameters": { + "id": 3643, + "nodeType": "ParameterList", + "parameters": [], + "src": "23208:0:23" + }, + "scope": 4094, + "src": "23106:773:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3779, + "nodeType": "Block", + "src": "24265:903:23", + "statements": [ + { + "assignments": [ + 3716 + ], + "declarations": [ + { + "constant": false, + "id": 3716, + "name": "liquidationManager", + "nodeType": "VariableDeclaration", + "scope": 3779, + "src": "24275:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3715, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24275:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3720, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3717, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2263, + "src": "24304:17:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 3718, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolLiquidationManager", + "nodeType": "MemberAccess", + "referencedDeclaration": 1341, + "src": "24304:50:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 3719, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24304:52:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "24275:81:23" + }, + { + "assignments": [ + 3722, + 3724 + ], + "declarations": [ + { + "constant": false, + "id": 3722, + "name": "success", + "nodeType": "VariableDeclaration", + "scope": 3779, + "src": "24403:12:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3721, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "24403:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3724, + "name": "result", + "nodeType": "VariableDeclaration", + "scope": 3779, + "src": "24417:19:23", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 3723, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "24417:5:23", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3737, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "6c69717569646174696f6e43616c6c28616464726573732c616464726573732c616464726573732c75696e743235362c626f6f6c29", + "id": 3729, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "24514:55:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_00a718a9d9ad23be6d712c3f743c97c344c043a2f5b8915b20cad9ae11f3f067", + "typeString": "literal_string \"liquidationCall(address,address,address,uint256,bool)\"" + }, + "value": "liquidationCall(address,address,address,uint256,bool)" + }, + { + "argumentTypes": null, + "id": 3730, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3699, + "src": "24588:11:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3731, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3701, + "src": "24618:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3732, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3703, + "src": "24645:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3733, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3705, + "src": "24669:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3734, + "name": "_receiveAToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3707, + "src": "24703:14:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_00a718a9d9ad23be6d712c3f743c97c344c043a2f5b8915b20cad9ae11f3f067", + "typeString": "literal_string \"liquidationCall(address,address,address,uint256,bool)\"" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "expression": { + "argumentTypes": null, + "id": 3727, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "24490:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 3728, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSignature", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "24490:23:23", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithsignature_pure$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (string memory) pure returns (bytes memory)" + } + }, + "id": 3735, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24490:241:23", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "expression": { + "argumentTypes": null, + "id": 3725, + "name": "liquidationManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3716, + "src": "24440:18:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 3726, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "delegatecall", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "24440:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_baredelegatecall_nonpayable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "function (bytes memory) returns (bool,bytes memory)" + } + }, + "id": 3736, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24440:292:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "tuple(bool,bytes memory)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "24402:330:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3739, + "name": "success", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3722, + "src": "24750:7:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "4c69717569646174696f6e2063616c6c206661696c6564", + "id": 3740, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "24759:25:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_b356d22163a9c42322b8eafa62927566857100ccc3ad6afcdfad7d317ea12a53", + "typeString": "literal_string \"Liquidation call failed\"" + }, + "value": "Liquidation call failed" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_b356d22163a9c42322b8eafa62927566857100ccc3ad6afcdfad7d317ea12a53", + "typeString": "literal_string \"Liquidation call failed\"" + } + ], + "id": 3738, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "24742:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3741, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24742:43:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3742, + "nodeType": "ExpressionStatement", + "src": "24742:43:23" + }, + { + "assignments": [ + 3744, + 3746 + ], + "declarations": [ + { + "constant": false, + "id": 3744, + "name": "returnCode", + "nodeType": "VariableDeclaration", + "scope": 3779, + "src": "24797:18:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3743, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "24797:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3746, + "name": "returnMessage", + "nodeType": "VariableDeclaration", + "scope": 3779, + "src": "24817:27:23", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 3745, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "24817:6:23", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3754, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3749, + "name": "result", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3724, + "src": "24859:6:23", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + }, + { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 3750, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "24868:7:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + { + "argumentTypes": null, + "id": 3751, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "24877:6:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_string_storage_ptr_$", + "typeString": "type(string storage pointer)" + }, + "typeName": "string" + } + ], + "id": 3752, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "24867:17:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_type$_t_uint256_$_$_t_type$_t_string_storage_ptr_$_$", + "typeString": "tuple(type(uint256),type(string storage pointer))" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + }, + { + "typeIdentifier": "t_tuple$_t_type$_t_uint256_$_$_t_type$_t_string_storage_ptr_$_$", + "typeString": "tuple(type(uint256),type(string storage pointer))" + } + ], + "expression": { + "argumentTypes": null, + "id": 3747, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "24848:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 3748, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "decode", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "24848:10:23", + "typeDescriptions": { + "typeIdentifier": "t_function_abidecode_pure$__$returns$__$", + "typeString": "function () pure" + } + }, + "id": 3753, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24848:37:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_string_memory_$", + "typeString": "tuple(uint256,string memory)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "24796:89:23" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3757, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3755, + "name": "returnCode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3744, + "src": "24899:10:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3756, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "24913:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "24899:15:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 3769, + "nodeType": "IfStatement", + "src": "24896:130:23", + "trueBody": { + "id": 3768, + "nodeType": "Block", + "src": "24916:110:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "4c69717569646174696f6e206661696c65643a20", + "id": 3762, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "24975:22:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_adca2f3137c54d8ddf7be034c60a44503a67c3111ba840b9211405ef6fb06777", + "typeString": "literal_string \"Liquidation failed: \"" + }, + "value": "Liquidation failed: " + }, + { + "argumentTypes": null, + "id": 3763, + "name": "returnMessage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3746, + "src": "24999:13:23", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_adca2f3137c54d8ddf7be034c60a44503a67c3111ba840b9211405ef6fb06777", + "typeString": "literal_string \"Liquidation failed: \"" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + ], + "expression": { + "argumentTypes": null, + "id": 3760, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "24958:3:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 3761, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodePacked", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "24958:16:23", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodepacked_pure$__$returns$_t_bytes_memory_ptr_$", + "typeString": "function () pure returns (bytes memory)" + } + }, + "id": 3764, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24958:55:23", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 3759, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "24951:6:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_string_storage_ptr_$", + "typeString": "type(string storage pointer)" + }, + "typeName": "string" + }, + "id": 3765, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24951:63:23", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + ], + "id": 3758, + "name": "revert", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12133, + 12134 + ], + "referencedDeclaration": 12134, + "src": "24944:6:23", + "typeDescriptions": { + "typeIdentifier": "t_function_revert_pure$_t_string_memory_ptr_$returns$__$", + "typeString": "function (string memory) pure" + } + }, + "id": 3766, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24944:71:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3767, + "nodeType": "ExpressionStatement", + "src": "24944:71:23" + } + ] + } + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3771, + "name": "liquidationManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3716, + "src": "25091:18:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3772, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3703, + "src": "25111:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3773, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3705, + "src": "25118:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3774, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3701, + "src": "25135:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3775, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "25145:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 3776, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "25145:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 3770, + "name": "LiquidationCall", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2325, + "src": "25075:15:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,address,uint256)" + } + }, + "id": 3777, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25075:86:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3778, + "nodeType": "EmitStatement", + "src": "25070:91:23" + } + ] + }, + "documentation": "@notice implements loan liquidation\n@dev _receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset.", + "id": 3780, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3710, + "modifierName": { + "argumentTypes": null, + "id": 3709, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "24212:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "24212:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 3712, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3701, + "src": "24251:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 3713, + "modifierName": { + "argumentTypes": null, + "id": 3711, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "24233:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "24233:27:23" + } + ], + "name": "liquidationCall", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3708, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3699, + "name": "_collateral", + "nodeType": "VariableDeclaration", + "scope": 3780, + "src": "24072:19:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3698, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24072:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3701, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3780, + "src": "24093:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3700, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24093:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3703, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 3780, + "src": "24111:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3702, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24111:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3705, + "name": "_purchaseAmount", + "nodeType": "VariableDeclaration", + "scope": 3780, + "src": "24126:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3704, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "24126:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3707, + "name": "_receiveAToken", + "nodeType": "VariableDeclaration", + "scope": 3780, + "src": "24151:19:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3706, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "24151:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "24071:100:23" + }, + "returnParameters": { + "id": 3714, + "nodeType": "ParameterList", + "parameters": [], + "src": "24265:0:23" + }, + "scope": 4094, + "src": "24047:1121:23", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3942, + "nodeType": "Block", + "src": "25343:2554:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 3795, + "name": "_receiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3782, + "src": "25409:9:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 3796, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isContract", + "nodeType": "MemberAccess", + "referencedDeclaration": 12033, + "src": "25409:20:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$bound_to$_t_address_$", + "typeString": "function (address) view returns (bool)" + } + }, + "id": 3797, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25409:22:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206f6620746869732066756e6374696f6e206d757374206265206120636f6e7472616374", + "id": 3798, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "25433:48:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c8d8b88b818c84a1935af7a142e1fb9bc75b2783890eabbb56c5c096178bad7d", + "typeString": "literal_string \"The caller of this function must be a contract\"" + }, + "value": "The caller of this function must be a contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_c8d8b88b818c84a1935af7a142e1fb9bc75b2783890eabbb56c5c096178bad7d", + "typeString": "literal_string \"The caller of this function must be a contract\"" + } + ], + "id": 3794, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "25401:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3799, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25401:81:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3800, + "nodeType": "ExpressionStatement", + "src": "25401:81:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3804, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "25590:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3802, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "25559:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3803, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isReserveBorrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5832, + "src": "25559:30:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 3805, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25559:40:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "52657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e67", + "id": 3806, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "25600:38:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + }, + "value": "Reserve is not enabled for borrowing" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + } + ], + "id": 3801, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "25551:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3807, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25551:88:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3808, + "nodeType": "ExpressionStatement", + "src": "25551:88:23" + }, + { + "assignments": [ + 3810 + ], + "declarations": [ + { + "constant": false, + "id": 3810, + "name": "availableLiquidity", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "25714:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3809, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "25714:4:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3815, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3813, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "25774:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3811, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "25740:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3812, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveAvailableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5482, + "src": "25740:33:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3814, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25740:43:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "25714:69:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3819, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3817, + "name": "availableLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3810, + "src": "25801:18:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 3818, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "25822:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "25801:28:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468657265206973206e6f7420656e6f756768206c697175696469747920617661696c61626c6520746f20626f72726f77", + "id": 3820, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "25831:51:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_12f1ea40393a7e170dfca23cc7ab5cb81fe067367db50831941a05793fe5fe30", + "typeString": "literal_string \"There is not enough liquidity available to borrow\"" + }, + "value": "There is not enough liquidity available to borrow" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_12f1ea40393a7e170dfca23cc7ab5cb81fe067367db50831941a05793fe5fe30", + "typeString": "literal_string \"There is not enough liquidity available to borrow\"" + } + ], + "id": 3816, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "25793:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3821, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25793:90:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3822, + "nodeType": "ExpressionStatement", + "src": "25793:90:23" + }, + { + "assignments": [ + 3824 + ], + "declarations": [ + { + "constant": false, + "id": 3824, + "name": "actualBalanceBefore", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "25894:24:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3823, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "25894:4:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3829, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3827, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "25962:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3825, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "25921:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3826, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getCoreActualReserveBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7659, + "src": "25921:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3828, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25921:50:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "25894:77:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3833, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3831, + "name": "availableLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3810, + "src": "26114:18:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 3832, + "name": "actualBalanceBefore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3824, + "src": "26136:19:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "26114:41:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c6964206c697175696469747920617661696c61626c65", + "id": 3834, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26157:29:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_fb154cd6ec907608200ef716d76ea73f441de4aed8415de07b317869251935a3", + "typeString": "literal_string \"Invalid liquidity available\"" + }, + "value": "Invalid liquidity available" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_fb154cd6ec907608200ef716d76ea73f441de4aed8415de07b317869251935a3", + "typeString": "literal_string \"Invalid liquidity available\"" + } + ], + "id": 3830, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "26106:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3835, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26106:81:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3836, + "nodeType": "ExpressionStatement", + "src": "26106:81:23" + }, + { + "assignments": [ + 3838 + ], + "declarations": [ + { + "constant": false, + "id": 3838, + "name": "amountFee", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "26279:14:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3837, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "26279:4:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3843, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 3841, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26308:3:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "id": 3839, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "26296:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3840, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "26296:11:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3842, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26296:16:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "26279:33:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3847, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3845, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "26331:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 3846, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26343:1:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "26331:13:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520616d6f756e7420697320746f6f20736d616c6c20746875732069742063616e6e6f7420626520626f72726f776564", + "id": 3848, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26346:52:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c313f75adce18cb0a1646d87d7e4e84d9d8728feec6c4c3ee8a3083ac038de6e", + "typeString": "literal_string \"The amount is too small thus it cannot be borrowed\"" + }, + "value": "The amount is too small thus it cannot be borrowed" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_c313f75adce18cb0a1646d87d7e4e84d9d8728feec6c4c3ee8a3083ac038de6e", + "typeString": "literal_string \"The amount is too small thus it cannot be borrowed\"" + } + ], + "id": 3844, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "26323:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3849, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26323:76:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3850, + "nodeType": "ExpressionStatement", + "src": "26323:76:23" + }, + { + "assignments": [ + 3852 + ], + "declarations": [ + { + "constant": false, + "id": 3852, + "name": "receiver", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "26455:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFlashLoanReceiver_$1733", + "typeString": "contract IFlashLoanReceiver" + }, + "typeName": { + "contractScope": null, + "id": 3851, + "name": "IFlashLoanReceiver", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1733, + "src": "26455:18:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFlashLoanReceiver_$1733", + "typeString": "contract IFlashLoanReceiver" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3856, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3854, + "name": "_receiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3782, + "src": "26504:9:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 3853, + "name": "IFlashLoanReceiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1733, + "src": "26485:18:23", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IFlashLoanReceiver_$1733_$", + "typeString": "type(contract IFlashLoanReceiver)" + } + }, + "id": 3855, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26485:29:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFlashLoanReceiver_$1733", + "typeString": "contract IFlashLoanReceiver" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "26455:59:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3860, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "26586:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3861, + "name": "_receiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3782, + "src": "26596:9:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3862, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "26607:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3857, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "26566:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3859, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToUser", + "nodeType": "MemberAccess", + "referencedDeclaration": 6486, + "src": "26566:19:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) external" + } + }, + "id": 3863, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26566:49:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3864, + "nodeType": "ExpressionStatement", + "src": "26566:49:23" + }, + { + "assignments": [ + 3866 + ], + "declarations": [ + { + "constant": false, + "id": 3866, + "name": "returnedAmount", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "26667:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3865, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "26667:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3873, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3869, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "26718:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3870, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "26728:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3871, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "26737:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3867, + "name": "receiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3852, + "src": "26692:8:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFlashLoanReceiver_$1733", + "typeString": "contract IFlashLoanReceiver" + } + }, + "id": 3868, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "executeOperation", + "nodeType": "MemberAccess", + "referencedDeclaration": 1732, + "src": "26692:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (address,uint256,uint256) external returns (uint256)" + } + }, + "id": 3872, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26692:55:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "26667:80:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3880, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3875, + "name": "returnedAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3866, + "src": "26866:14:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3878, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "26896:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3876, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "26884:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3877, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "26884:11:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3879, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26884:22:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "26866:40:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "546865206e6f6d696e616c2072657475726e656420616d6f756e7420697320696e76616c6964", + "id": 3881, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26908:40:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_d3a984b42b567cdd6d54324436557ccb15b01cde8713f46fbff00a4c5ceff514", + "typeString": "literal_string \"The nominal returned amount is invalid\"" + }, + "value": "The nominal returned amount is invalid" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_d3a984b42b567cdd6d54324436557ccb15b01cde8713f46fbff00a4c5ceff514", + "typeString": "literal_string \"The nominal returned amount is invalid\"" + } + ], + "id": 3874, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "26858:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3882, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26858:91:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3883, + "nodeType": "ExpressionStatement", + "src": "26858:91:23" + }, + { + "assignments": [ + 3885 + ], + "declarations": [ + { + "constant": false, + "id": 3885, + "name": "actualBalanceAfter", + "nodeType": "VariableDeclaration", + "scope": 3942, + "src": "27050:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3884, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "27050:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 3890, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3888, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27120:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3886, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "27079:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3887, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getCoreActualReserveBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7659, + "src": "27079:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 3889, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27079:50:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "27050:79:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 3897, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 3892, + "name": "actualBalanceAfter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3885, + "src": "27148:18:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3895, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "27194:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3893, + "name": "actualBalanceBefore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3824, + "src": "27170:19:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 3894, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "27170:23:23", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 3896, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27170:34:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "27148:56:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652061637475616c2062616c616e6365206f66207468652070726f746f636f6c20696e20696e636f6e73697374656e74", + "id": 3898, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "27206:52:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_6e665e32db13fc7cc07aaf3f821dbc3c5b2e2c9ee35188b5a0fa1aee3d1261b1", + "typeString": "literal_string \"The actual balance of the protocol in inconsistent\"" + }, + "value": "The actual balance of the protocol in inconsistent" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_6e665e32db13fc7cc07aaf3f821dbc3c5b2e2c9ee35188b5a0fa1aee3d1261b1", + "typeString": "literal_string \"The actual balance of the protocol in inconsistent\"" + } + ], + "id": 3891, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "27140:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 3899, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27140:119:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3900, + "nodeType": "ExpressionStatement", + "src": "27140:119:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3904, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27380:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3901, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "27344:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3903, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "27344:35:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3905, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27344:45:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3906, + "nodeType": "ExpressionStatement", + "src": "27344:45:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3910, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27502:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3911, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "27512:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3907, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "27456:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3909, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "cumulateLiquidityToReserveLiquidityIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 4810, + "src": "27456:45:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3912, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27456:66:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3913, + "nodeType": "ExpressionStatement", + "src": "27456:66:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3917, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27623:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3918, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "27632:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 3914, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "27588:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3916, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "27588:34:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 3919, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27588:54:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3920, + "nodeType": "ExpressionStatement", + "src": "27588:54:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3924, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27717:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3921, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "27685:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3923, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "27685:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3925, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27685:41:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3926, + "nodeType": "ExpressionStatement", + "src": "27685:41:23" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3930, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27762:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3927, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "27736:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 3929, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "27736:25:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 3931, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27736:35:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3932, + "nodeType": "ExpressionStatement", + "src": "27736:35:23" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3934, + "name": "_receiver", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3782, + "src": "27832:9:23", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 3935, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "27843:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 3936, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3786, + "src": "27853:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 3937, + "name": "amountFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3838, + "src": "27862:9:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 3938, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "27873:5:23", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 3939, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "27873:15:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 3933, + "name": "FlashLoan", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2345, + "src": "27822:9:23", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256,uint256,uint256)" + } + }, + "id": 3940, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27822:67:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 3941, + "nodeType": "EmitStatement", + "src": "27817:72:23" + } + ] + }, + "documentation": null, + "id": 3943, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 3789, + "modifierName": { + "argumentTypes": null, + "id": 3788, + "name": "nonReentrant", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12112, + "src": "25302:12:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "25302:12:23" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 3791, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3784, + "src": "25333:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 3792, + "modifierName": { + "argumentTypes": null, + "id": 3790, + "name": "onlyActiveReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2384, + "src": "25315:17:23", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "25315:27:23" + } + ], + "name": "flashLoan", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3787, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3782, + "name": "_receiver", + "nodeType": "VariableDeclaration", + "scope": 3943, + "src": "25202:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 3781, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25202:15:23", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3784, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3943, + "src": "25237:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3783, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25237:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3786, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 3943, + "src": "25263:12:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3785, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "25263:4:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "25192:84:23" + }, + "returnParameters": { + "id": 3793, + "nodeType": "ParameterList", + "parameters": [], + "src": "25343:0:23" + }, + "scope": 4094, + "src": "25174:2723:23", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 3969, + "nodeType": "Block", + "src": "28407:74:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 3966, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3945, + "src": "28465:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 3964, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "28424:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 3965, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveConfigurationData", + "nodeType": "MemberAccess", + "referencedDeclaration": 7318, + "src": "28424:40:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_$_t_bool_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,address,bool,bool,bool,bool)" + } + }, + "id": 3967, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "28424:50:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_$_t_bool_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "tuple(uint256,uint256,uint256,address,bool,bool,bool,bool)" + } + }, + "functionReturnParameters": 3963, + "id": 3968, + "nodeType": "Return", + "src": "28417:57:23" + } + ] + }, + "documentation": "*************\n@dev accessory methods to fetch data from the core contract", + "id": 3970, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveConfigurationData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3946, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3945, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28034:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3944, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "28034:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "28033:18:23" + }, + "returnParameters": { + "id": 3963, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3948, + "name": "ltv", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28112:11:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3947, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28112:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3950, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28137:28:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3949, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28137:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3952, + "name": "liquidationDiscount", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28179:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3951, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28179:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3954, + "name": "interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28220:35:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3953, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "28220:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3956, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28269:29:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3955, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "28269:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3958, + "name": "borrowingEnabled", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28312:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3957, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "28312:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3960, + "name": "fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28347:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3959, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "28347:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3962, + "name": "isActive", + "nodeType": "VariableDeclaration", + "scope": 3970, + "src": "28388:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 3961, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "28388:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "28098:304:23" + }, + "scope": 4094, + "src": "27997:484:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4006, + "nodeType": "Block", + "src": "29093:61:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4003, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 3972, + "src": "29138:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4001, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "29110:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 4002, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveData", + "nodeType": "MemberAccess", + "referencedDeclaration": 7441, + "src": "29110:27:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_$_t_uint40_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address,uint40)" + } + }, + "id": 4004, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "29110:37:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_$_t_uint40_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,address,uint40)" + } + }, + "functionReturnParameters": 4000, + "id": 4005, + "nodeType": "Return", + "src": "29103:44:23" + } + ] + }, + "documentation": null, + "id": 4007, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 3973, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3972, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28512:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3971, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "28512:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "28511:18:23" + }, + "returnParameters": { + "id": 4000, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 3975, + "name": "totalLiquidity", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28590:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3974, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28590:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3977, + "name": "availableLiquidity", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28626:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3976, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28626:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3979, + "name": "totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28666:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3978, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28666:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3981, + "name": "totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28705:28:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3980, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28705:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3983, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28747:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3982, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28747:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3985, + "name": "variableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28782:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3984, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28782:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3987, + "name": "fixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28822:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3986, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28822:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3989, + "name": "averageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28859:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3988, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28859:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3991, + "name": "utilizationRate", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28903:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3990, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28903:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3993, + "name": "liquidityIndex", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28940:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3992, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28940:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3995, + "name": "variableBorrowIndex", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "28976:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 3994, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "28976:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3997, + "name": "aTokenAddress", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "29017:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 3996, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "29017:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 3999, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 4007, + "src": "29052:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 3998, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "29052:6:23", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "28576:512:23" + }, + "scope": 4094, + "src": "28488:666:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4031, + "nodeType": "Block", + "src": "29529:62:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4028, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4009, + "src": "29578:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4026, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "29546:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 4027, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserAccountData", + "nodeType": "MemberAccess", + "referencedDeclaration": 7481, + "src": "29546:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "id": 4029, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "29546:38:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "functionReturnParameters": 4025, + "id": 4030, + "nodeType": "Return", + "src": "29539:45:23" + } + ] + }, + "documentation": null, + "id": 4032, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserAccountData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4010, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4009, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29188:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4008, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "29188:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "29187:15:23" + }, + "returnParameters": { + "id": 4025, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4012, + "name": "totalLiquidityETH", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29263:25:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4011, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29263:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4014, + "name": "totalCollateralETH", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29302:26:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4013, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29302:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4016, + "name": "totalBorrowsETH", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29342:23:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4015, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29342:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4018, + "name": "availableBorrowsETH", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29379:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4017, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29379:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4020, + "name": "currentLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29420:35:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4019, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29420:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4022, + "name": "ltv", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29469:11:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4021, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29469:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4024, + "name": "healthFactor", + "nodeType": "VariableDeclaration", + "scope": 4032, + "src": "29494:20:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4023, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29494:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "29249:275:23" + }, + "scope": 4094, + "src": "29160:431:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4067, + "nodeType": "Block", + "src": "30157:72:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4063, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4034, + "src": "30206:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4064, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4036, + "src": "30216:5:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4061, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2267, + "src": "30174:12:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 4062, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserReserveData", + "nodeType": "MemberAccess", + "referencedDeclaration": 7618, + "src": "30174:31:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,bool)" + } + }, + "id": 4065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "30174:48:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,uint256,bool)" + } + }, + "functionReturnParameters": 4060, + "id": 4066, + "nodeType": "Return", + "src": "30167:55:23" + } + ] + }, + "documentation": null, + "id": 4068, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserReserveData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4037, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4034, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29625:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4033, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "29625:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4036, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29643:13:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4035, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "29643:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "29624:33:23" + }, + "returnParameters": { + "id": 4060, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4039, + "name": "currentATokenBalance", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29718:28:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4038, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29718:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4041, + "name": "currentUnderlyingBalance", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29760:32:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4040, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29760:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4043, + "name": "currentBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29806:28:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4042, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29806:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4045, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29848:30:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4044, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29848:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4047, + "name": "borrowRateMode", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29892:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4046, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29892:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4049, + "name": "borrowRate", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29928:18:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4048, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29928:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4051, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29960:21:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4050, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29960:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4053, + "name": "originationFee", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "29995:22:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4052, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "29995:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4055, + "name": "variableBorrowIndex", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "30031:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4054, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "30031:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4057, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "30072:27:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4056, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "30072:7:23", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4059, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 4068, + "src": "30113:29:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 4058, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "30113:4:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "29704:448:23" + }, + "scope": 4094, + "src": "29597:632:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4078, + "nodeType": "Block", + "src": "30297:42:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4074, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "30314:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4075, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserves", + "nodeType": "MemberAccess", + "referencedDeclaration": 6134, + "src": "30314:16:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_array$_t_address_$dyn_memory_ptr_$", + "typeString": "function () view external returns (address[] memory)" + } + }, + "id": 4076, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "30314:18:23", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "functionReturnParameters": 4073, + "id": 4077, + "nodeType": "Return", + "src": "30307:25:23" + } + ] + }, + "documentation": null, + "id": 4079, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserves", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4069, + "nodeType": "ParameterList", + "parameters": [], + "src": "30255:2:23" + }, + "returnParameters": { + "id": 4073, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4072, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 4079, + "src": "30280:16:23", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 4070, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "30280:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 4071, + "length": null, + "nodeType": "ArrayTypeName", + "src": "30280:9:23", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "30279:18:23" + }, + "scope": 4094, + "src": "30235:104:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4092, + "nodeType": "Block", + "src": "30514:130:23", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4087, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4081, + "src": "30569:8:23", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4085, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 2265, + "src": "30545:4:23", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4086, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveIsActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 5889, + "src": "30545:23:23", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 4088, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "30545:33:23", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "416374696f6e20726571756972657320616e206163746976652072657365727665", + "id": 4089, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "30592:35:23", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_62ff4a583af39c5d4305dbf606abbf9562a2bd0263ebbe34037113a6623c8e7f", + "typeString": "literal_string \"Action requires an active reserve\"" + }, + "value": "Action requires an active reserve" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_62ff4a583af39c5d4305dbf606abbf9562a2bd0263ebbe34037113a6623c8e7f", + "typeString": "literal_string \"Action requires an active reserve\"" + } + ], + "id": 4084, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "30524:7:23", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4090, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "30524:113:23", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4091, + "nodeType": "ExpressionStatement", + "src": "30524:113:23" + } + ] + }, + "documentation": "@dev internal function to save on code size for the onlyActiveReserve modifier", + "id": 4093, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "requireReserveActiveInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4082, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4081, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4093, + "src": "30482:16:23", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4080, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "30482:7:23", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "30481:18:23" + }, + "returnParameters": { + "id": 4083, + "nodeType": "ParameterList", + "parameters": [], + "src": "30514:0:23" + }, + "scope": 4094, + "src": "30444:200:23", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 4095, + "src": "1118:29528:23" + } + ], + "src": "0:30647:23" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.637Z", + "devdoc": { + "author": "Aave", + "methods": { + "getReserveConfigurationData(address)": { + "details": "accessory methods to fetch data from the core contract" + }, + "liquidationCall(address,address,address,uint256,bool)": { + "details": "_receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset." + }, + "rebalanceFixedBorrowRate(address,address)": { + "details": "this is regulated by Aave to ensure that the protocol is not abused, and the user is paying a fair rate. Anyone can call this function though." + }, + "redeemUnderlying(address,address,uint256)": { + "details": "only aToken contracts can call this function" + }, + "repay(address,uint256,address)": { + "details": "the target user is defined by _onBehalfOf. If there is no repayment on behalf of another account, _onBehalfOf must be equal to msg.sender." + } + }, + "title": "LendingPool contract" + }, + "userdoc": { + "methods": { + "borrow(address,uint256,uint256,uint16)": { + "notice": "executes a borrow on the reserve of the specific amount with the interestRateMode specified." + }, + "deposit(address,uint256,uint16)": { + "notice": "deposits The underlying asset into the reserve. A corresponding amount of the overlying asset (aTokens) is minted." + }, + "getReserveConfigurationData(address)": { + "notice": "*************" + }, + "liquidationCall(address,address,address,uint256,bool)": { + "notice": "implements loan liquidation" + }, + "rebalanceFixedBorrowRate(address,address)": { + "notice": "rebalances the fixed interest rate of a user if current liquidity rate > user fixed rate." + }, + "redeemUnderlying(address,address,uint256)": { + "notice": "Allows to redeem a specific amount of underlying asset." + }, + "repay(address,uint256,address)": { + "notice": "repays a borrow on the specific reserve, for the specified amount." + }, + "setUserUseReserveAsCollateral(address,bool)": { + "notice": "allows user to enable or disable a specific deposit as collateral" + }, + "swapBorrowRateMode(address)": { + "notice": "allows the user to swap the current borrow rate mode, from fixed to variable and viceversa." + } + }, + "notice": "***********************************************************************************Implements the actions of the LendingPool, and exposes accessory methods to access the core information************************************************************************************" + } +} \ No newline at end of file diff --git a/client/src/contracts/LendingPoolAddressesProvider.json b/client/src/contracts/LendingPoolAddressesProvider.json new file mode 100644 index 0000000..06b1b56 --- /dev/null +++ b/client/src/contracts/LendingPoolAddressesProvider.json @@ -0,0 +1,10384 @@ +{ + "contractName": "LendingPoolAddressesProvider", + "abi": [ + { + "constant": true, + "inputs": [ + { + "name": "_key", + "type": "bytes32" + } + ], + "name": "getAddress", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "LendingPoolUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "LendingPoolCoreUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "LendingPoolParametersProviderUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "LendingPoolManagerUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "LendingPoolConfiguratorUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "LendingPoolLiquidationManagerUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "LendingPoolDataProviderUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "LendingPoolNetworkMetadataProviderUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "PriceOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "LendingRateOracleUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "FeeProviderUpdated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "newAddress", + "type": "address" + } + ], + "name": "InterestRrateStrategyUpdated", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPool", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_pool", + "type": "address" + } + ], + "name": "setLendingPool", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getInterestRateStrategy", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_strategy", + "type": "address" + } + ], + "name": "setInterestRateStrategy", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolCore", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_lendingPoolCore", + "type": "address" + } + ], + "name": "setLendingPoolCore", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolConfigurator", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_configurator", + "type": "address" + } + ], + "name": "setLendingPoolConfigurator", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolManager", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_lendingPoolManager", + "type": "address" + } + ], + "name": "setLendingPoolManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolDataProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_provider", + "type": "address" + } + ], + "name": "setLendingPoolDataProvider", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getNetworkMetadataProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_networkMetadataProvider", + "type": "address" + } + ], + "name": "setNetworkMetadataProvider", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolParametersProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_parametersProvider", + "type": "address" + } + ], + "name": "setLendingPoolParametersProvider", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getPriceOracle", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_priceOracle", + "type": "address" + } + ], + "name": "setPriceOracle", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingRateOracle", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_lendingRateOracle", + "type": "address" + } + ], + "name": "setLendingRateOracle", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getFeeProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_feeProvider", + "type": "address" + } + ], + "name": "setFeeProvider", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getLendingPoolLiquidationManager", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_manager", + "type": "address" + } + ], + "name": "setLendingPoolLiquidationManager", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPool\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_parametersProvider\",\"type\":\"address\"}],\"name\":\"setLendingPoolParametersProvider\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolParametersProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_pool\",\"type\":\"address\"}],\"name\":\"setLendingPool\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_key\",\"type\":\"bytes32\"}],\"name\":\"getAddress\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_strategy\",\"type\":\"address\"}],\"name\":\"setInterestRateStrategy\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolDataProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolManager\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingRateOracle\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_lendingPoolManager\",\"type\":\"address\"}],\"name\":\"setLendingPoolManager\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_manager\",\"type\":\"address\"}],\"name\":\"setLendingPoolLiquidationManager\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_priceOracle\",\"type\":\"address\"}],\"name\":\"setPriceOracle\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolLiquidationManager\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_networkMetadataProvider\",\"type\":\"address\"}],\"name\":\"setNetworkMetadataProvider\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_lendingRateOracle\",\"type\":\"address\"}],\"name\":\"setLendingRateOracle\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolConfigurator\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_lendingPoolCore\",\"type\":\"address\"}],\"name\":\"setLendingPoolCore\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_configurator\",\"type\":\"address\"}],\"name\":\"setLendingPoolConfigurator\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getNetworkMetadataProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_feeProvider\",\"type\":\"address\"}],\"name\":\"setFeeProvider\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_provider\",\"type\":\"address\"}],\"name\":\"setLendingPoolDataProvider\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getLendingPoolCore\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getInterestRateStrategy\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getFeeProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getPriceOracle\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"LendingPoolUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"LendingPoolCoreUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"LendingPoolParametersProviderUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"LendingPoolManagerUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"LendingPoolConfiguratorUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"LendingPoolLiquidationManagerUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"LendingPoolDataProviderUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"LendingPoolNetworkMetadataProviderUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"PriceOracleUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"LendingRateOracleUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"FeeProviderUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"newAddress\",\"type\":\"address\"}],\"name\":\"InterestRrateStrategyUpdated\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":\"LendingPoolAddressesProvider\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x0ae6004410cd58a1c5151e67959167cf58cd5e77e8b625677826e295905fb318\",\"urls\":[\"bzzr://d223bea23f0e9bd70844e9852f490be93d30fc1c31bf114c807d0e4fe07d929b\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]}},\"version\":1}", + "bytecode": "0x608060405234801561001057600080fd5b506110d0806100206000396000f3fe608060405234801561001057600080fd5b50600436106101735760003560e01c80635834eb9a116100de578063b5722bb511610097578063ed6ff76011610071578063ed6ff76014610766578063f529a5d0146107b0578063fbeefc3c146107fa578063fca513a81461084457610173565b8063b5722bb514610694578063c64bdf5a146106de578063ed1ce3251461072257610173565b80635834eb9a146104f05780637f65c2ff1461053a578063820d12741461057e57806385c858b1146105c257806387707c221461060c578063acaf79ac1461065057610173565b80632f58b80d116101305780632f58b80d1461034657806333128d59146103905780633618abba146103da57806340fdcadc1461042457806344ce375b14610468578063530e784f146104ac57610173565b80630261bf8b14610178578063026e76da146101c257806304061d8e14610206578063113aa8b11461025057806321f8a721146102945780632a5ad15914610302575b600080fd5b61018061088e565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610204600480360360208110156101d857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506108be565b005b61020e61092e565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6102926004803603602081101561026657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061095e565b005b6102c0600480360360208110156102aa57600080fd5b81019080803590602001909291905050506109ce565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6103446004803603602081101561031857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610a0a565b005b61034e610a7a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610398610aaa565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6103e2610ada565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6104666004803603602081101561043a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b0a565b005b6104aa6004803603602081101561047e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b7a565b005b6104ee600480360360208110156104c257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610bea565b005b6104f8610c5a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61057c6004803603602081101561055057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610c8a565b005b6105c06004803603602081101561059457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610cfa565b005b6105ca610d6a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61064e6004803603602081101561062257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610d9a565b005b6106926004803603602081101561066657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610e0a565b005b61069c610e7a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610720600480360360208110156106f457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610eaa565b005b6107646004803603602081101561073857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f1a565b005b61076e610f8a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6107b8610fbf565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610802610fef565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61084c61101f565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b60006108b97f4c454e44494e475f504f4f4c00000000000000000000000000000000000000006109ce565b905090565b6108e87f504152414d45544552535f50524f5649444552000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fce16ea9b2fd7cadddd0f7359971028f50b5ddba33dfae1a9bdea956fabb1e28060405160405180910390a250565b60006109597f504152414d45544552535f50524f5649444552000000000000000000000000006109ce565b905090565b6109887f4c454e44494e475f504f4f4c00000000000000000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fc4e6c6cdf28d0edbd8bcf071d724d33cc2e7a30be7d06443925656e9cb492aa460405160405180910390a250565b600080600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b610a347f494e5445524553545f524154455f5354524154454759000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fd25a3cb0b081c9728496d44769e25abdeec68adff4cef1b5e7748b8918c8e23960405160405180910390a250565b6000610aa57f444154415f50524f5649444552000000000000000000000000000000000000006109ce565b905090565b6000610ad57f4c454e44494e475f504f4f4c5f4d414e414745520000000000000000000000006109ce565b905090565b6000610b057f4c454e44494e475f524154455f4f5241434c45000000000000000000000000006109ce565b905090565b610b347f4c454e44494e475f504f4f4c5f4d414e414745520000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fd5280c51185a38d36f7a0f5e56cac6248312bb70d0974782fa5a595127e0e08e60405160405180910390a250565b610ba47f4c49515549444154494f4e5f4d414e41474552000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167f1a76cb769b814bc038223da86932b099b20aae03473683e6d98f5c3554e2606460405160405180910390a250565b610c147f50524943455f4f5241434c4500000000000000000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fefe8ab924ca486283a79dc604baa67add51afb82af1db8ac386ebbba643cdffd60405160405180910390a250565b6000610c857f4c49515549444154494f4e5f4d414e41474552000000000000000000000000006109ce565b905090565b610cb47f4e4554574f524b5f4d455441444154415f50524f5649444552000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fad2e24f28868b4296c2b1dac9efe6e376dd3395af5e7ecf00715b5bcdb3db51260405160405180910390a250565b610d247f4c454e44494e475f524154455f4f5241434c45000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167f5c29179aba6942020a8a2d38f65de02fb6b7f784e7f049ed3a3cab97621859b560405160405180910390a250565b6000610d957f4c454e44494e475f504f4f4c5f434f4e464947555241544f52000000000000006109ce565b905090565b610dc47f4c454e44494e475f504f4f4c5f434f52450000000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167f71c226bb2879778ca1298196bf7cc1256baee9d05b496c31ee627d35a471b5b760405160405180910390a250565b610e347f4c454e44494e475f504f4f4c5f434f4e464947555241544f52000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fdfabe479bad36782fb1e77fbfddd4e382671713527e4786cfc93a022ae76372960405160405180910390a250565b6000610ea57f4e4554574f524b5f4d455441444154415f50524f5649444552000000000000006109ce565b905090565b610ed47f4645455f50524f564944455200000000000000000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167f18e1a55b8eff9c93921eecfa1462d6a8cbb80b3988db3eb14c039e43fdb2266160405160405180910390a250565b610f447f444154415f50524f5649444552000000000000000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167f07890d7d10db37434d76ee4f2928fb2dc66227c3b3391206aced4f7bcb59cdb060405160405180910390a250565b600080610fb67f4c454e44494e475f504f4f4c5f434f52450000000000000000000000000000006109ce565b90508091505090565b6000610fea7f494e5445524553545f524154455f5354524154454759000000000000000000006109ce565b905090565b600061101a7f4645455f50524f564944455200000000000000000000000000000000000000006109ce565b905090565b600061104a7f50524943455f4f5241434c4500000000000000000000000000000000000000006109ce565b905090565b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505056fea165627a7a723058209e8049541c77c5ebe54f2b8fc1daa0ffb4312e0cb14738a3765a32258c32d8a20029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106101735760003560e01c80635834eb9a116100de578063b5722bb511610097578063ed6ff76011610071578063ed6ff76014610766578063f529a5d0146107b0578063fbeefc3c146107fa578063fca513a81461084457610173565b8063b5722bb514610694578063c64bdf5a146106de578063ed1ce3251461072257610173565b80635834eb9a146104f05780637f65c2ff1461053a578063820d12741461057e57806385c858b1146105c257806387707c221461060c578063acaf79ac1461065057610173565b80632f58b80d116101305780632f58b80d1461034657806333128d59146103905780633618abba146103da57806340fdcadc1461042457806344ce375b14610468578063530e784f146104ac57610173565b80630261bf8b14610178578063026e76da146101c257806304061d8e14610206578063113aa8b11461025057806321f8a721146102945780632a5ad15914610302575b600080fd5b61018061088e565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610204600480360360208110156101d857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506108be565b005b61020e61092e565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6102926004803603602081101561026657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061095e565b005b6102c0600480360360208110156102aa57600080fd5b81019080803590602001909291905050506109ce565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6103446004803603602081101561031857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610a0a565b005b61034e610a7a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610398610aaa565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6103e2610ada565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6104666004803603602081101561043a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b0a565b005b6104aa6004803603602081101561047e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b7a565b005b6104ee600480360360208110156104c257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610bea565b005b6104f8610c5a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61057c6004803603602081101561055057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610c8a565b005b6105c06004803603602081101561059457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610cfa565b005b6105ca610d6a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61064e6004803603602081101561062257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610d9a565b005b6106926004803603602081101561066657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610e0a565b005b61069c610e7a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610720600480360360208110156106f457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610eaa565b005b6107646004803603602081101561073857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f1a565b005b61076e610f8a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6107b8610fbf565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b610802610fef565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61084c61101f565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b60006108b97f4c454e44494e475f504f4f4c00000000000000000000000000000000000000006109ce565b905090565b6108e87f504152414d45544552535f50524f5649444552000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fce16ea9b2fd7cadddd0f7359971028f50b5ddba33dfae1a9bdea956fabb1e28060405160405180910390a250565b60006109597f504152414d45544552535f50524f5649444552000000000000000000000000006109ce565b905090565b6109887f4c454e44494e475f504f4f4c00000000000000000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fc4e6c6cdf28d0edbd8bcf071d724d33cc2e7a30be7d06443925656e9cb492aa460405160405180910390a250565b600080600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b610a347f494e5445524553545f524154455f5354524154454759000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fd25a3cb0b081c9728496d44769e25abdeec68adff4cef1b5e7748b8918c8e23960405160405180910390a250565b6000610aa57f444154415f50524f5649444552000000000000000000000000000000000000006109ce565b905090565b6000610ad57f4c454e44494e475f504f4f4c5f4d414e414745520000000000000000000000006109ce565b905090565b6000610b057f4c454e44494e475f524154455f4f5241434c45000000000000000000000000006109ce565b905090565b610b347f4c454e44494e475f504f4f4c5f4d414e414745520000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fd5280c51185a38d36f7a0f5e56cac6248312bb70d0974782fa5a595127e0e08e60405160405180910390a250565b610ba47f4c49515549444154494f4e5f4d414e41474552000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167f1a76cb769b814bc038223da86932b099b20aae03473683e6d98f5c3554e2606460405160405180910390a250565b610c147f50524943455f4f5241434c4500000000000000000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fefe8ab924ca486283a79dc604baa67add51afb82af1db8ac386ebbba643cdffd60405160405180910390a250565b6000610c857f4c49515549444154494f4e5f4d414e41474552000000000000000000000000006109ce565b905090565b610cb47f4e4554574f524b5f4d455441444154415f50524f5649444552000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fad2e24f28868b4296c2b1dac9efe6e376dd3395af5e7ecf00715b5bcdb3db51260405160405180910390a250565b610d247f4c454e44494e475f524154455f4f5241434c45000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167f5c29179aba6942020a8a2d38f65de02fb6b7f784e7f049ed3a3cab97621859b560405160405180910390a250565b6000610d957f4c454e44494e475f504f4f4c5f434f4e464947555241544f52000000000000006109ce565b905090565b610dc47f4c454e44494e475f504f4f4c5f434f52450000000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167f71c226bb2879778ca1298196bf7cc1256baee9d05b496c31ee627d35a471b5b760405160405180910390a250565b610e347f4c454e44494e475f504f4f4c5f434f4e464947555241544f52000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167fdfabe479bad36782fb1e77fbfddd4e382671713527e4786cfc93a022ae76372960405160405180910390a250565b6000610ea57f4e4554574f524b5f4d455441444154415f50524f5649444552000000000000006109ce565b905090565b610ed47f4645455f50524f564944455200000000000000000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167f18e1a55b8eff9c93921eecfa1462d6a8cbb80b3988db3eb14c039e43fdb2266160405160405180910390a250565b610f447f444154415f50524f5649444552000000000000000000000000000000000000008261104f565b8073ffffffffffffffffffffffffffffffffffffffff167f07890d7d10db37434d76ee4f2928fb2dc66227c3b3391206aced4f7bcb59cdb060405160405180910390a250565b600080610fb67f4c454e44494e475f504f4f4c5f434f52450000000000000000000000000000006109ce565b90508091505090565b6000610fea7f494e5445524553545f524154455f5354524154454759000000000000000000006109ce565b905090565b600061101a7f4645455f50524f564944455200000000000000000000000000000000000000006109ce565b905090565b600061104a7f50524943455f4f5241434c4500000000000000000000000000000000000000006109ce565b905090565b8060008084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505056fea165627a7a723058209e8049541c77c5ebe54f2b8fc1daa0ffb4312e0cb14738a3765a32258c32d8a20029", + "sourceMap": "115:6346:9:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;115:6346:9;;;;;;;", + "deployedSourceMap": "115:6346:9:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;115:6346:9;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2001:104;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4813:233;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4813:233:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;4617:142;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2159:135;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2159:135:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;107:103:8;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;107:103:8;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2477:176:9;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2477:176:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;3839:117;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;3461:119;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;5373:117;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;3634:199;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3634:199:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;6259:200;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6259:200:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;5211:156;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5211:156:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;6063:142;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4371:240;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4371:240:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;5544:193;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5544:193:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;3076:129;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2889:181;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2889:181:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;3259:196;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3259:196:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;4188:129;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;5901:156;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5901:156:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;4010:172;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4010:172:9;;;;;;;;;;;;;;;;;;;:::i;:::-;;2659:176;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2300:123;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;5743:104;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;5053;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2001;2048:7;2074:24;2085:12;2074:10;:24::i;:::-;2067:31;;2001:104;:::o;4813:233::-;4901:66;4913:32;4947:19;4901:11;:66::i;:::-;5019:19;4982:57;;;;;;;;;;;;4813:233;:::o;4617:142::-;4682:7;4708:44;4719:32;4708:10;:44::i;:::-;4701:51;;4617:142;:::o;2159:135::-;2215:32;2227:12;2241:5;2215:11;:32::i;:::-;2281:5;2262:25;;;;;;;;;;;;2159:135;:::o;107:103:8:-;162:7;188:9;:15;198:4;188:15;;;;;;;;;;;;;;;;;;;;;181:22;;107:103;;;:::o;2477:176:9:-;2546:46;2558:22;2582:9;2546:11;:46::i;:::-;2636:9;2607:39;;;;;;;;;;;;2477:176;:::o;3839:117::-;3898:7;3924:25;3935:13;3924:10;:25::i;:::-;3917:32;;3839:117;:::o;3461:119::-;3515:7;3541:32;3552:20;3541:10;:32::i;:::-;3534:39;;3461:119;:::o;5373:117::-;5426:7;5452:31;5463:19;5452:10;:31::i;:::-;5445:38;;5373:117;:::o;3634:199::-;3711:54;3723:20;3745:19;3711:11;:54::i;:::-;3806:19;3780:46;;;;;;;;;;;;3634:199;:::o;6259:200::-;6336:55;6348:32;6382:8;6336:11;:55::i;:::-;6443:8;6406:46;;;;;;;;;;;;6259:200;:::o;5211:156::-;5274:39;5286:12;5300;5274:11;:39::i;:::-;5347:12;5328:32;;;;;;;;;;;;5211:156;:::o;6063:142::-;6128:7;6154:44;6165:32;6154:10;:44::i;:::-;6147:51;;6063:142;:::o;4371:240::-;4458:64;4470:25;4497:24;4458:11;:64::i;:::-;4579:24;4537:67;;;;;;;;;;;;4371:240;:::o;5544:193::-;5619:52;5631:19;5652:18;5619:11;:52::i;:::-;5711:18;5686:44;;;;;;;;;;;;5544:193;:::o;3076:129::-;3135:7;3161:37;3172:25;3161:10;:37::i;:::-;3154:44;;3076:129;:::o;2889:181::-;2960:48;2972:17;2991:16;2960:11;:48::i;:::-;3046:16;3023:40;;;;;;;;;;;;2889:181;:::o;3259:196::-;3335:53;3347:25;3374:13;3335:11;:53::i;:::-;3434:13;3403:45;;;;;;;;;;;;3259:196;:::o;4188:129::-;4247:7;4273:37;4284:25;4273:10;:37::i;:::-;4266:44;;4188:129;:::o;5901:156::-;5964:39;5976:12;5990;5964:11;:39::i;:::-;6037:12;6018:32;;;;;;;;;;;;5901:156;:::o;4010:172::-;4082:37;4094:13;4109:9;4082:11;:37::i;:::-;4165:9;4134:41;;;;;;;;;;;;4010:172;:::o;2659:176::-;2710:15;2737:20;2776:29;2787:17;2776:10;:29::i;:::-;2737:70;;2824:4;2817:11;;;2659:176;:::o;2300:123::-;2356:7;2382:34;2393:22;2382:10;:34::i;:::-;2375:41;;2300:123;:::o;5743:104::-;5790:7;5816:24;5827:12;5816:10;:24::i;:::-;5809:31;;5743:104;:::o;5053:::-;5100:7;5126:24;5137:12;5126:10;:24::i;:::-;5119:31;;5053:104;:::o;216:101:8:-;304:6;286:9;:15;296:4;286:15;;;;;;;;;;;;:24;;;;;;;;;;;;;;;;;;216:101;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"./AddressStorage.sol\";\nimport \"../interfaces/ILendingPoolAddressesProvider.sol\";\n\ncontract LendingPoolAddressesProvider is ILendingPoolAddressesProvider, AddressStorage {\n\n //events\n event LendingPoolUpdated(address indexed newAddress);\n event LendingPoolCoreUpdated(address indexed newAddress);\n event LendingPoolParametersProviderUpdated(address indexed newAddress);\n event LendingPoolManagerUpdated(address indexed newAddress);\n event LendingPoolConfiguratorUpdated(address indexed newAddress);\n event LendingPoolLiquidationManagerUpdated(address indexed newAddress);\n event LendingPoolDataProviderUpdated(address indexed newAddress);\n event LendingPoolNetworkMetadataProviderUpdated(address indexed newAddress);\n event PriceOracleUpdated(address indexed newAddress);\n event LendingRateOracleUpdated(address indexed newAddress);\n event FeeProviderUpdated(address indexed newAddress);\n event InterestRrateStrategyUpdated(address indexed newAddress);\n\n\n bytes32 private constant LENDING_POOL = \"LENDING_POOL\";\n bytes32 private constant LENDING_POOL_CORE = \"LENDING_POOL_CORE\";\n bytes32 private constant LENDING_POOL_CONFIGURATOR = \"LENDING_POOL_CONFIGURATOR\";\n bytes32 private constant LENDING_POOL_PARAMETERS_PROVIDER = \"PARAMETERS_PROVIDER\";\n bytes32 private constant LENDING_POOL_MANAGER = \"LENDING_POOL_MANAGER\";\n bytes32 private constant LENDING_POOL_LIQUIDATION_MANAGER = \"LIQUIDATION_MANAGER\";\n bytes32 private constant DATA_PROVIDER = \"DATA_PROVIDER\";\n bytes32 private constant NETWORK_METADATA_PROVIDER = \"NETWORK_METADATA_PROVIDER\";\n bytes32 private constant PRICE_ORACLE = \"PRICE_ORACLE\";\n bytes32 private constant LENDING_RATE_ORACLE = \"LENDING_RATE_ORACLE\";\n bytes32 private constant FEE_PROVIDER = \"FEE_PROVIDER\";\n bytes32 private constant INTEREST_RATE_STRATEGY = \"INTEREST_RATE_STRATEGY\";\n bytes32 private constant WALLET_BALANCE_PROVIDER = \"WALLET_BALANCE_PROVIDER\";\n\n function getLendingPool() public view returns (address) {\n return getAddress(LENDING_POOL);\n }\n\n // TODO: add access control rules under DAO\n function setLendingPool(address _pool) public {\n _setAddress(LENDING_POOL, _pool);\n emit LendingPoolUpdated(_pool);\n }\n\n function getInterestRateStrategy() public view returns (address) {\n return getAddress(INTEREST_RATE_STRATEGY);\n }\n\n // TODO: add access control rules under DAO\n function setInterestRateStrategy(address _strategy) public {\n _setAddress(INTEREST_RATE_STRATEGY, _strategy);\n emit InterestRrateStrategyUpdated(_strategy);\n }\n\n function getLendingPoolCore() public view returns (address payable) {\n address payable core = address(uint160(getAddress(LENDING_POOL_CORE)));\n return core;\n }\n\n // TODO: add access control rules under DAO\n function setLendingPoolCore(address _lendingPoolCore) public {\n _setAddress(LENDING_POOL_CORE, _lendingPoolCore);\n emit LendingPoolCoreUpdated(_lendingPoolCore);\n }\n\n function getLendingPoolConfigurator() public view returns (address) {\n return getAddress(LENDING_POOL_CONFIGURATOR);\n }\n\n // TODO: add access control rules under DAO\n function setLendingPoolConfigurator(address _configurator) public {\n _setAddress(LENDING_POOL_CONFIGURATOR, _configurator);\n emit LendingPoolConfiguratorUpdated(_configurator);\n }\n\n function getLendingPoolManager() public view returns (address) {\n return getAddress(LENDING_POOL_MANAGER);\n }\n\n // TODO: add access control rules under DAO\n function setLendingPoolManager(address _lendingPoolManager) public {\n _setAddress(LENDING_POOL_MANAGER, _lendingPoolManager);\n emit LendingPoolManagerUpdated(_lendingPoolManager);\n }\n\n function getLendingPoolDataProvider() public view returns (address) {\n return getAddress(DATA_PROVIDER);\n }\n\n // TODO: add access control rules under DAO\n function setLendingPoolDataProvider(address _provider) public {\n _setAddress(DATA_PROVIDER, _provider);\n emit LendingPoolDataProviderUpdated(_provider);\n }\n\n function getNetworkMetadataProvider() public view returns (address) {\n return getAddress(NETWORK_METADATA_PROVIDER);\n }\n\n // TODO: add access control rules under DAO\n function setNetworkMetadataProvider(address _networkMetadataProvider) public {\n _setAddress(NETWORK_METADATA_PROVIDER, _networkMetadataProvider);\n emit LendingPoolNetworkMetadataProviderUpdated(_networkMetadataProvider);\n }\n\n function getLendingPoolParametersProvider() public view returns (address) {\n return getAddress(LENDING_POOL_PARAMETERS_PROVIDER);\n }\n\n // TODO: add access control rules under DAO\n function setLendingPoolParametersProvider(address _parametersProvider) public {\n _setAddress(LENDING_POOL_PARAMETERS_PROVIDER, _parametersProvider);\n emit LendingPoolParametersProviderUpdated(_parametersProvider);\n }\n\n\n function getPriceOracle() public view returns (address) {\n return getAddress(PRICE_ORACLE);\n }\n\n // TODO: add access control rules under DAO\n function setPriceOracle(address _priceOracle) public {\n _setAddress(PRICE_ORACLE, _priceOracle);\n emit PriceOracleUpdated(_priceOracle);\n }\n\n function getLendingRateOracle() public view returns (address) {\n return getAddress(LENDING_RATE_ORACLE);\n }\n\n // TODO: add access control rules under DAO\n function setLendingRateOracle(address _lendingRateOracle) public {\n _setAddress(LENDING_RATE_ORACLE, _lendingRateOracle);\n emit LendingRateOracleUpdated(_lendingRateOracle);\n }\n\n function getFeeProvider() public view returns (address) {\n return getAddress(FEE_PROVIDER);\n }\n\n // TODO: add access control rules under DAO\n function setFeeProvider(address _feeProvider) public {\n _setAddress(FEE_PROVIDER, _feeProvider);\n emit FeeProviderUpdated(_feeProvider);\n }\n\n function getLendingPoolLiquidationManager() public view returns (address) {\n return getAddress(LENDING_POOL_LIQUIDATION_MANAGER);\n }\n\n // TODO: add access control rules under DAO\n function setLendingPoolLiquidationManager(address _manager) public {\n _setAddress(LENDING_POOL_LIQUIDATION_MANAGER, _manager);\n emit LendingPoolLiquidationManagerUpdated(_manager);\n }\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "exportedSymbols": { + "LendingPoolAddressesProvider": [ + 1357 + ] + }, + "id": 1358, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 955, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:9" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol", + "file": "./AddressStorage.sol", + "id": 956, + "nodeType": "ImportDirective", + "scope": 1358, + "sourceUnit": 954, + "src": "25:30:9", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol", + "file": "../interfaces/ILendingPoolAddressesProvider.sol", + "id": 957, + "nodeType": "ImportDirective", + "scope": 1358, + "sourceUnit": 1879, + "src": "56:57:9", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 958, + "name": "ILendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1878, + "src": "156:29:9", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 959, + "nodeType": "InheritanceSpecifier", + "src": "156:29:9" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 960, + "name": "AddressStorage", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 953, + "src": "187:14:9", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AddressStorage_$953", + "typeString": "contract AddressStorage" + } + }, + "id": 961, + "nodeType": "InheritanceSpecifier", + "src": "187:14:9" + } + ], + "contractDependencies": [ + 953, + 1878 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 1357, + "linearizedBaseContracts": [ + 1357, + 953, + 1878 + ], + "name": "LendingPoolAddressesProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "anonymous": false, + "documentation": null, + "id": 965, + "name": "LendingPoolUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 964, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 963, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 965, + "src": "247:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 962, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "247:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "246:28:9" + }, + "src": "222:53:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 969, + "name": "LendingPoolCoreUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 968, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 967, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 969, + "src": "309:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 966, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "309:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "308:28:9" + }, + "src": "280:57:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 973, + "name": "LendingPoolParametersProviderUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 972, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 971, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 973, + "src": "385:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 970, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "385:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "384:28:9" + }, + "src": "342:71:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 977, + "name": "LendingPoolManagerUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 976, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 975, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 977, + "src": "450:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 974, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "450:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "449:28:9" + }, + "src": "418:60:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 981, + "name": "LendingPoolConfiguratorUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 980, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 979, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 981, + "src": "520:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 978, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "520:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "519:28:9" + }, + "src": "483:65:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 985, + "name": "LendingPoolLiquidationManagerUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 984, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 983, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 985, + "src": "596:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 982, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "596:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "595:28:9" + }, + "src": "553:71:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 989, + "name": "LendingPoolDataProviderUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 988, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 987, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 989, + "src": "666:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 986, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "666:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "665:28:9" + }, + "src": "629:65:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 993, + "name": "LendingPoolNetworkMetadataProviderUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 992, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 991, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 993, + "src": "747:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 990, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "747:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "746:28:9" + }, + "src": "699:76:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 997, + "name": "PriceOracleUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 996, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 995, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 997, + "src": "805:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 994, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "805:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "804:28:9" + }, + "src": "780:53:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 1001, + "name": "LendingRateOracleUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 1000, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 999, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 1001, + "src": "869:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 998, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "869:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "868:28:9" + }, + "src": "838:59:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 1005, + "name": "FeeProviderUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 1004, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1003, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 1005, + "src": "927:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1002, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "927:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "926:28:9" + }, + "src": "902:53:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 1009, + "name": "InterestRrateStrategyUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 1008, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1007, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 1009, + "src": "995:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1006, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "995:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "994:28:9" + }, + "src": "960:63:9" + }, + { + "constant": true, + "id": 1012, + "name": "LENDING_POOL", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1030:54:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1010, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1030:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44494e475f504f4f4c", + "id": 1011, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1070:14:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_b0a02d474211257da1bdb72ce7e91b05cbdc99ae0876cb0a61bbc7ad100c58a7", + "typeString": "literal_string \"LENDING_POOL\"" + }, + "value": "LENDING_POOL" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1015, + "name": "LENDING_POOL_CORE", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1090:64:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1013, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1090:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44494e475f504f4f4c5f434f5245", + "id": 1014, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1135:19:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_debd030f8671102224659f980e877487c7d3baa1e1b6c27b36811355a8cf480e", + "typeString": "literal_string \"LENDING_POOL_CORE\"" + }, + "value": "LENDING_POOL_CORE" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1018, + "name": "LENDING_POOL_CONFIGURATOR", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1160:80:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1016, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1160:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44494e475f504f4f4c5f434f4e464947555241544f52", + "id": 1017, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1213:27:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_daa78d61aa52695c850c795958745aa3b3dd53fcf767ab7e0a1b2527fbeac8ed", + "typeString": "literal_string \"LENDING_POOL_CONFIGURATOR\"" + }, + "value": "LENDING_POOL_CONFIGURATOR" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1021, + "name": "LENDING_POOL_PARAMETERS_PROVIDER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1246:81:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1019, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1246:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "504152414d45544552535f50524f5649444552", + "id": 1020, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1306:21:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_0ace7b0a9050f5e6e3fec6c7d67442523a810986ede2bd15a68f03d8a731ea58", + "typeString": "literal_string \"PARAMETERS_PROVIDER\"" + }, + "value": "PARAMETERS_PROVIDER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1024, + "name": "LENDING_POOL_MANAGER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1333:70:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1022, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1333:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44494e475f504f4f4c5f4d414e41474552", + "id": 1023, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1381:22:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_4b2b80371dc74900b689cf87b6606fd932b4a6c652fe9bbab580a2a9a9a590f0", + "typeString": "literal_string \"LENDING_POOL_MANAGER\"" + }, + "value": "LENDING_POOL_MANAGER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1027, + "name": "LENDING_POOL_LIQUIDATION_MANAGER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1409:81:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1025, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1409:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c49515549444154494f4e5f4d414e41474552", + "id": 1026, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1469:21:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_0b8b100501322269eb8293378cdaf941a0d883fad7878cbc00f3c143fa0c6c96", + "typeString": "literal_string \"LIQUIDATION_MANAGER\"" + }, + "value": "LIQUIDATION_MANAGER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1030, + "name": "DATA_PROVIDER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1496:56:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1028, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1496:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "444154415f50524f5649444552", + "id": 1029, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1537:15:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5164d5c7193030abda56ab2da6b1ecfb83373a1a97075675ab8548ca2be633d9", + "typeString": "literal_string \"DATA_PROVIDER\"" + }, + "value": "DATA_PROVIDER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1033, + "name": "NETWORK_METADATA_PROVIDER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1558:80:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1031, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1558:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4e4554574f524b5f4d455441444154415f50524f5649444552", + "id": 1032, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1611:27:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8220486d7dc5a09b47752faad5a32d9c1bb07ebc861afa7011c931235c655a47", + "typeString": "literal_string \"NETWORK_METADATA_PROVIDER\"" + }, + "value": "NETWORK_METADATA_PROVIDER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1036, + "name": "PRICE_ORACLE", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1644:54:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1034, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1644:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "50524943455f4f5241434c45", + "id": 1035, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1684:14:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_dd24a0f121e5ab7c3e97c63eaaf859e0b46792c3e0edfd86e2b3ad50f63011d8", + "typeString": "literal_string \"PRICE_ORACLE\"" + }, + "value": "PRICE_ORACLE" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1039, + "name": "LENDING_RATE_ORACLE", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1704:68:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1037, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1704:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44494e475f524154455f4f5241434c45", + "id": 1038, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1751:21:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_15e5978bd784d37462e6f1149d489232b2958f579b9f19e8da878a8ed491e4bd", + "typeString": "literal_string \"LENDING_RATE_ORACLE\"" + }, + "value": "LENDING_RATE_ORACLE" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1042, + "name": "FEE_PROVIDER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1778:54:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1040, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1778:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4645455f50524f5649444552", + "id": 1041, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1818:14:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ad24306cb85c40212eb431a99a37482b9ec077a212d8c1a7a04a61fb45d27c3b", + "typeString": "literal_string \"FEE_PROVIDER\"" + }, + "value": "FEE_PROVIDER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1045, + "name": "INTEREST_RATE_STRATEGY", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1838:74:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1043, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1838:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "494e5445524553545f524154455f5354524154454759", + "id": 1044, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1888:24:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_2a0f0074ef138a45546c636beef8a612108f7d50fdd8fab359e0ef6b5afbed3d", + "typeString": "literal_string \"INTEREST_RATE_STRATEGY\"" + }, + "value": "INTEREST_RATE_STRATEGY" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1048, + "name": "WALLET_BALANCE_PROVIDER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1918:76:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1046, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1918:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "57414c4c45545f42414c414e43455f50524f5649444552", + "id": 1047, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1969:25:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_9b5f64efb249e3e2d53d898488a2435420d078cd1b14b91f486803b836d5b3ef", + "typeString": "literal_string \"WALLET_BALANCE_PROVIDER\"" + }, + "value": "WALLET_BALANCE_PROVIDER" + }, + "visibility": "private" + }, + { + "body": { + "id": 1057, + "nodeType": "Block", + "src": "2057:48:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1054, + "name": "LENDING_POOL", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1012, + "src": "2085:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1053, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "2074:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1055, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2074:24:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1052, + "id": 1056, + "nodeType": "Return", + "src": "2067:31:9" + } + ] + }, + "documentation": null, + "id": 1058, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPool", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1049, + "nodeType": "ParameterList", + "parameters": [], + "src": "2024:2:9" + }, + "returnParameters": { + "id": 1052, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1051, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1058, + "src": "2048:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1050, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2048:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2047:9:9" + }, + "scope": 1357, + "src": "2001:104:9", + "stateMutability": "view", + "superFunction": 1772, + "visibility": "public" + }, + { + "body": { + "id": 1072, + "nodeType": "Block", + "src": "2205:89:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1064, + "name": "LENDING_POOL", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1012, + "src": "2227:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1065, + "name": "_pool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1060, + "src": "2241:5:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1063, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "2215:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1066, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2215:32:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1067, + "nodeType": "ExpressionStatement", + "src": "2215:32:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1069, + "name": "_pool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1060, + "src": "2281:5:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1068, + "name": "LendingPoolUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 965, + "src": "2262:18:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1070, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2262:25:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1071, + "nodeType": "EmitStatement", + "src": "2257:30:9" + } + ] + }, + "documentation": null, + "id": 1073, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPool", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1061, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1060, + "name": "_pool", + "nodeType": "VariableDeclaration", + "scope": 1073, + "src": "2183:13:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1059, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2183:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2182:15:9" + }, + "returnParameters": { + "id": 1062, + "nodeType": "ParameterList", + "parameters": [], + "src": "2205:0:9" + }, + "scope": 1357, + "src": "2159:135:9", + "stateMutability": "nonpayable", + "superFunction": 1777, + "visibility": "public" + }, + { + "body": { + "id": 1082, + "nodeType": "Block", + "src": "2365:58:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1079, + "name": "INTEREST_RATE_STRATEGY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1045, + "src": "2393:22:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1078, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "2382:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1080, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2382:34:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1077, + "id": 1081, + "nodeType": "Return", + "src": "2375:41:9" + } + ] + }, + "documentation": null, + "id": 1083, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getInterestRateStrategy", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1074, + "nodeType": "ParameterList", + "parameters": [], + "src": "2332:2:9" + }, + "returnParameters": { + "id": 1077, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1076, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1083, + "src": "2356:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1075, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2356:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2355:9:9" + }, + "scope": 1357, + "src": "2300:123:9", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 1097, + "nodeType": "Block", + "src": "2536:117:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1089, + "name": "INTEREST_RATE_STRATEGY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1045, + "src": "2558:22:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1090, + "name": "_strategy", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1085, + "src": "2582:9:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1088, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "2546:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1091, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2546:46:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1092, + "nodeType": "ExpressionStatement", + "src": "2546:46:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1094, + "name": "_strategy", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1085, + "src": "2636:9:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1093, + "name": "InterestRrateStrategyUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1009, + "src": "2607:28:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1095, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2607:39:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1096, + "nodeType": "EmitStatement", + "src": "2602:44:9" + } + ] + }, + "documentation": null, + "id": 1098, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setInterestRateStrategy", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1086, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1085, + "name": "_strategy", + "nodeType": "VariableDeclaration", + "scope": 1098, + "src": "2510:17:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1084, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2510:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2509:19:9" + }, + "returnParameters": { + "id": 1087, + "nodeType": "ParameterList", + "parameters": [], + "src": "2536:0:9" + }, + "scope": 1357, + "src": "2477:176:9", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 1115, + "nodeType": "Block", + "src": "2727:108:9", + "statements": [ + { + "assignments": [ + 1104 + ], + "declarations": [ + { + "constant": false, + "id": 1104, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 1115, + "src": "2737:20:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 1103, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2737:15:9", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 1112, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1108, + "name": "LENDING_POOL_CORE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1015, + "src": "2787:17:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1107, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "2776:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1109, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2776:29:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1106, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2768:7:9", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint160_$", + "typeString": "type(uint160)" + }, + "typeName": "uint160" + }, + "id": 1110, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2768:38:9", + "typeDescriptions": { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + ], + "id": 1105, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2760:7:9", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 1111, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2760:47:9", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2737:70:9" + }, + { + "expression": { + "argumentTypes": null, + "id": 1113, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1104, + "src": "2824:4:9", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "functionReturnParameters": 1102, + "id": 1114, + "nodeType": "Return", + "src": "2817:11:9" + } + ] + }, + "documentation": null, + "id": 1116, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolCore", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1099, + "nodeType": "ParameterList", + "parameters": [], + "src": "2686:2:9" + }, + "returnParameters": { + "id": 1102, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1101, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1116, + "src": "2710:15:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 1100, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2710:15:9", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2709:17:9" + }, + "scope": 1357, + "src": "2659:176:9", + "stateMutability": "view", + "superFunction": 1782, + "visibility": "public" + }, + { + "body": { + "id": 1130, + "nodeType": "Block", + "src": "2950:120:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1122, + "name": "LENDING_POOL_CORE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1015, + "src": "2972:17:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1123, + "name": "_lendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1118, + "src": "2991:16:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1121, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "2960:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1124, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2960:48:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1125, + "nodeType": "ExpressionStatement", + "src": "2960:48:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1127, + "name": "_lendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1118, + "src": "3046:16:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1126, + "name": "LendingPoolCoreUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 969, + "src": "3023:22:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1128, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3023:40:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1129, + "nodeType": "EmitStatement", + "src": "3018:45:9" + } + ] + }, + "documentation": null, + "id": 1131, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolCore", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1119, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1118, + "name": "_lendingPoolCore", + "nodeType": "VariableDeclaration", + "scope": 1131, + "src": "2917:24:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1117, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2917:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2916:26:9" + }, + "returnParameters": { + "id": 1120, + "nodeType": "ParameterList", + "parameters": [], + "src": "2950:0:9" + }, + "scope": 1357, + "src": "2889:181:9", + "stateMutability": "nonpayable", + "superFunction": 1787, + "visibility": "public" + }, + { + "body": { + "id": 1140, + "nodeType": "Block", + "src": "3144:61:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1137, + "name": "LENDING_POOL_CONFIGURATOR", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1018, + "src": "3172:25:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1136, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "3161:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1138, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3161:37:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1135, + "id": 1139, + "nodeType": "Return", + "src": "3154:44:9" + } + ] + }, + "documentation": null, + "id": 1141, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolConfigurator", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1132, + "nodeType": "ParameterList", + "parameters": [], + "src": "3111:2:9" + }, + "returnParameters": { + "id": 1135, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1134, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1141, + "src": "3135:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1133, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3135:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3134:9:9" + }, + "scope": 1357, + "src": "3076:129:9", + "stateMutability": "view", + "superFunction": 1792, + "visibility": "public" + }, + { + "body": { + "id": 1155, + "nodeType": "Block", + "src": "3325:130:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1147, + "name": "LENDING_POOL_CONFIGURATOR", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1018, + "src": "3347:25:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1148, + "name": "_configurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1143, + "src": "3374:13:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1146, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "3335:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1149, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3335:53:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1150, + "nodeType": "ExpressionStatement", + "src": "3335:53:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1152, + "name": "_configurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1143, + "src": "3434:13:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1151, + "name": "LendingPoolConfiguratorUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 981, + "src": "3403:30:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1153, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3403:45:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1154, + "nodeType": "EmitStatement", + "src": "3398:50:9" + } + ] + }, + "documentation": null, + "id": 1156, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolConfigurator", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1144, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1143, + "name": "_configurator", + "nodeType": "VariableDeclaration", + "scope": 1156, + "src": "3295:21:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1142, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3295:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3294:23:9" + }, + "returnParameters": { + "id": 1145, + "nodeType": "ParameterList", + "parameters": [], + "src": "3325:0:9" + }, + "scope": 1357, + "src": "3259:196:9", + "stateMutability": "nonpayable", + "superFunction": 1797, + "visibility": "public" + }, + { + "body": { + "id": 1165, + "nodeType": "Block", + "src": "3524:56:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1162, + "name": "LENDING_POOL_MANAGER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1024, + "src": "3552:20:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1161, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "3541:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1163, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3541:32:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1160, + "id": 1164, + "nodeType": "Return", + "src": "3534:39:9" + } + ] + }, + "documentation": null, + "id": 1166, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1157, + "nodeType": "ParameterList", + "parameters": [], + "src": "3491:2:9" + }, + "returnParameters": { + "id": 1160, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1159, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1166, + "src": "3515:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1158, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3515:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3514:9:9" + }, + "scope": 1357, + "src": "3461:119:9", + "stateMutability": "view", + "superFunction": 1802, + "visibility": "public" + }, + { + "body": { + "id": 1180, + "nodeType": "Block", + "src": "3701:132:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1172, + "name": "LENDING_POOL_MANAGER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1024, + "src": "3723:20:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1173, + "name": "_lendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1168, + "src": "3745:19:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1171, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "3711:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1174, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3711:54:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1175, + "nodeType": "ExpressionStatement", + "src": "3711:54:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1177, + "name": "_lendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1168, + "src": "3806:19:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1176, + "name": "LendingPoolManagerUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 977, + "src": "3780:25:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1178, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3780:46:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1179, + "nodeType": "EmitStatement", + "src": "3775:51:9" + } + ] + }, + "documentation": null, + "id": 1181, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1169, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1168, + "name": "_lendingPoolManager", + "nodeType": "VariableDeclaration", + "scope": 1181, + "src": "3665:27:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1167, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3665:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3664:29:9" + }, + "returnParameters": { + "id": 1170, + "nodeType": "ParameterList", + "parameters": [], + "src": "3701:0:9" + }, + "scope": 1357, + "src": "3634:199:9", + "stateMutability": "nonpayable", + "superFunction": 1807, + "visibility": "public" + }, + { + "body": { + "id": 1190, + "nodeType": "Block", + "src": "3907:49:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1187, + "name": "DATA_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1030, + "src": "3935:13:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1186, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "3924:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1188, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3924:25:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1185, + "id": 1189, + "nodeType": "Return", + "src": "3917:32:9" + } + ] + }, + "documentation": null, + "id": 1191, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolDataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1182, + "nodeType": "ParameterList", + "parameters": [], + "src": "3874:2:9" + }, + "returnParameters": { + "id": 1185, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1184, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1191, + "src": "3898:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1183, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3898:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3897:9:9" + }, + "scope": 1357, + "src": "3839:117:9", + "stateMutability": "view", + "superFunction": 1812, + "visibility": "public" + }, + { + "body": { + "id": 1205, + "nodeType": "Block", + "src": "4072:110:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1197, + "name": "DATA_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1030, + "src": "4094:13:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1198, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1193, + "src": "4109:9:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1196, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "4082:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1199, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4082:37:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1200, + "nodeType": "ExpressionStatement", + "src": "4082:37:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1202, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1193, + "src": "4165:9:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1201, + "name": "LendingPoolDataProviderUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 989, + "src": "4134:30:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1203, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4134:41:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1204, + "nodeType": "EmitStatement", + "src": "4129:46:9" + } + ] + }, + "documentation": null, + "id": 1206, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolDataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1194, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1193, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 1206, + "src": "4046:17:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1192, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4046:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4045:19:9" + }, + "returnParameters": { + "id": 1195, + "nodeType": "ParameterList", + "parameters": [], + "src": "4072:0:9" + }, + "scope": 1357, + "src": "4010:172:9", + "stateMutability": "nonpayable", + "superFunction": 1817, + "visibility": "public" + }, + { + "body": { + "id": 1215, + "nodeType": "Block", + "src": "4256:61:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1212, + "name": "NETWORK_METADATA_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1033, + "src": "4284:25:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1211, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "4273:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1213, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4273:37:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1210, + "id": 1214, + "nodeType": "Return", + "src": "4266:44:9" + } + ] + }, + "documentation": null, + "id": 1216, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getNetworkMetadataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1207, + "nodeType": "ParameterList", + "parameters": [], + "src": "4223:2:9" + }, + "returnParameters": { + "id": 1210, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1209, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1216, + "src": "4247:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1208, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4247:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4246:9:9" + }, + "scope": 1357, + "src": "4188:129:9", + "stateMutability": "view", + "superFunction": 1822, + "visibility": "public" + }, + { + "body": { + "id": 1230, + "nodeType": "Block", + "src": "4448:163:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1222, + "name": "NETWORK_METADATA_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1033, + "src": "4470:25:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1223, + "name": "_networkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1218, + "src": "4497:24:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1221, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "4458:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1224, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4458:64:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1225, + "nodeType": "ExpressionStatement", + "src": "4458:64:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1227, + "name": "_networkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1218, + "src": "4579:24:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1226, + "name": "LendingPoolNetworkMetadataProviderUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 993, + "src": "4537:41:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1228, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4537:67:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1229, + "nodeType": "EmitStatement", + "src": "4532:72:9" + } + ] + }, + "documentation": null, + "id": 1231, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setNetworkMetadataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1219, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1218, + "name": "_networkMetadataProvider", + "nodeType": "VariableDeclaration", + "scope": 1231, + "src": "4407:32:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1217, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4407:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4406:34:9" + }, + "returnParameters": { + "id": 1220, + "nodeType": "ParameterList", + "parameters": [], + "src": "4448:0:9" + }, + "scope": 1357, + "src": "4371:240:9", + "stateMutability": "nonpayable", + "superFunction": 1827, + "visibility": "public" + }, + { + "body": { + "id": 1240, + "nodeType": "Block", + "src": "4691:68:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1237, + "name": "LENDING_POOL_PARAMETERS_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1021, + "src": "4719:32:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1236, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "4708:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1238, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4708:44:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1235, + "id": 1239, + "nodeType": "Return", + "src": "4701:51:9" + } + ] + }, + "documentation": null, + "id": 1241, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolParametersProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1232, + "nodeType": "ParameterList", + "parameters": [], + "src": "4658:2:9" + }, + "returnParameters": { + "id": 1235, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1234, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1241, + "src": "4682:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1233, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4682:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4681:9:9" + }, + "scope": 1357, + "src": "4617:142:9", + "stateMutability": "view", + "superFunction": 1832, + "visibility": "public" + }, + { + "body": { + "id": 1255, + "nodeType": "Block", + "src": "4891:155:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1247, + "name": "LENDING_POOL_PARAMETERS_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1021, + "src": "4913:32:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1248, + "name": "_parametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1243, + "src": "4947:19:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1246, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "4901:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1249, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4901:66:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1250, + "nodeType": "ExpressionStatement", + "src": "4901:66:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1252, + "name": "_parametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1243, + "src": "5019:19:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1251, + "name": "LendingPoolParametersProviderUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 973, + "src": "4982:36:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1253, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4982:57:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1254, + "nodeType": "EmitStatement", + "src": "4977:62:9" + } + ] + }, + "documentation": null, + "id": 1256, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolParametersProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1244, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1243, + "name": "_parametersProvider", + "nodeType": "VariableDeclaration", + "scope": 1256, + "src": "4855:27:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1242, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4855:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4854:29:9" + }, + "returnParameters": { + "id": 1245, + "nodeType": "ParameterList", + "parameters": [], + "src": "4891:0:9" + }, + "scope": 1357, + "src": "4813:233:9", + "stateMutability": "nonpayable", + "superFunction": 1837, + "visibility": "public" + }, + { + "body": { + "id": 1265, + "nodeType": "Block", + "src": "5109:48:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1262, + "name": "PRICE_ORACLE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1036, + "src": "5137:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1261, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "5126:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1263, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5126:24:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1260, + "id": 1264, + "nodeType": "Return", + "src": "5119:31:9" + } + ] + }, + "documentation": null, + "id": 1266, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getPriceOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1257, + "nodeType": "ParameterList", + "parameters": [], + "src": "5076:2:9" + }, + "returnParameters": { + "id": 1260, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1259, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1266, + "src": "5100:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1258, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5100:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5099:9:9" + }, + "scope": 1357, + "src": "5053:104:9", + "stateMutability": "view", + "superFunction": 1842, + "visibility": "public" + }, + { + "body": { + "id": 1280, + "nodeType": "Block", + "src": "5264:103:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1272, + "name": "PRICE_ORACLE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1036, + "src": "5286:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1273, + "name": "_priceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1268, + "src": "5300:12:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1271, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "5274:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1274, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5274:39:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1275, + "nodeType": "ExpressionStatement", + "src": "5274:39:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1277, + "name": "_priceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1268, + "src": "5347:12:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1276, + "name": "PriceOracleUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 997, + "src": "5328:18:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1278, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5328:32:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1279, + "nodeType": "EmitStatement", + "src": "5323:37:9" + } + ] + }, + "documentation": null, + "id": 1281, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setPriceOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1269, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1268, + "name": "_priceOracle", + "nodeType": "VariableDeclaration", + "scope": 1281, + "src": "5235:20:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1267, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5235:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5234:22:9" + }, + "returnParameters": { + "id": 1270, + "nodeType": "ParameterList", + "parameters": [], + "src": "5264:0:9" + }, + "scope": 1357, + "src": "5211:156:9", + "stateMutability": "nonpayable", + "superFunction": 1847, + "visibility": "public" + }, + { + "body": { + "id": 1290, + "nodeType": "Block", + "src": "5435:55:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1287, + "name": "LENDING_RATE_ORACLE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1039, + "src": "5463:19:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1286, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "5452:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1288, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5452:31:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1285, + "id": 1289, + "nodeType": "Return", + "src": "5445:38:9" + } + ] + }, + "documentation": null, + "id": 1291, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingRateOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1282, + "nodeType": "ParameterList", + "parameters": [], + "src": "5402:2:9" + }, + "returnParameters": { + "id": 1285, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1284, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1291, + "src": "5426:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1283, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5426:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5425:9:9" + }, + "scope": 1357, + "src": "5373:117:9", + "stateMutability": "view", + "superFunction": 1852, + "visibility": "public" + }, + { + "body": { + "id": 1305, + "nodeType": "Block", + "src": "5609:128:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1297, + "name": "LENDING_RATE_ORACLE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1039, + "src": "5631:19:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1298, + "name": "_lendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1293, + "src": "5652:18:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1296, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "5619:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1299, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5619:52:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1300, + "nodeType": "ExpressionStatement", + "src": "5619:52:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1302, + "name": "_lendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1293, + "src": "5711:18:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1301, + "name": "LendingRateOracleUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1001, + "src": "5686:24:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1303, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5686:44:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1304, + "nodeType": "EmitStatement", + "src": "5681:49:9" + } + ] + }, + "documentation": null, + "id": 1306, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingRateOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1294, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1293, + "name": "_lendingRateOracle", + "nodeType": "VariableDeclaration", + "scope": 1306, + "src": "5574:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1292, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5574:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5573:28:9" + }, + "returnParameters": { + "id": 1295, + "nodeType": "ParameterList", + "parameters": [], + "src": "5609:0:9" + }, + "scope": 1357, + "src": "5544:193:9", + "stateMutability": "nonpayable", + "superFunction": 1857, + "visibility": "public" + }, + { + "body": { + "id": 1315, + "nodeType": "Block", + "src": "5799:48:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1312, + "name": "FEE_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1042, + "src": "5827:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1311, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "5816:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1313, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5816:24:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1310, + "id": 1314, + "nodeType": "Return", + "src": "5809:31:9" + } + ] + }, + "documentation": null, + "id": 1316, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getFeeProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1307, + "nodeType": "ParameterList", + "parameters": [], + "src": "5766:2:9" + }, + "returnParameters": { + "id": 1310, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1309, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1316, + "src": "5790:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1308, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5790:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5789:9:9" + }, + "scope": 1357, + "src": "5743:104:9", + "stateMutability": "view", + "superFunction": 1862, + "visibility": "public" + }, + { + "body": { + "id": 1330, + "nodeType": "Block", + "src": "5954:103:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1322, + "name": "FEE_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1042, + "src": "5976:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1323, + "name": "_feeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1318, + "src": "5990:12:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1321, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "5964:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1324, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5964:39:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1325, + "nodeType": "ExpressionStatement", + "src": "5964:39:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1327, + "name": "_feeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1318, + "src": "6037:12:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1326, + "name": "FeeProviderUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1005, + "src": "6018:18:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1328, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6018:32:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1329, + "nodeType": "EmitStatement", + "src": "6013:37:9" + } + ] + }, + "documentation": null, + "id": 1331, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setFeeProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1319, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1318, + "name": "_feeProvider", + "nodeType": "VariableDeclaration", + "scope": 1331, + "src": "5925:20:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1317, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5925:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5924:22:9" + }, + "returnParameters": { + "id": 1320, + "nodeType": "ParameterList", + "parameters": [], + "src": "5954:0:9" + }, + "scope": 1357, + "src": "5901:156:9", + "stateMutability": "nonpayable", + "superFunction": 1867, + "visibility": "public" + }, + { + "body": { + "id": 1340, + "nodeType": "Block", + "src": "6137:68:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1337, + "name": "LENDING_POOL_LIQUIDATION_MANAGER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1027, + "src": "6165:32:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1336, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "6154:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1338, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6154:44:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1335, + "id": 1339, + "nodeType": "Return", + "src": "6147:51:9" + } + ] + }, + "documentation": null, + "id": 1341, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolLiquidationManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1332, + "nodeType": "ParameterList", + "parameters": [], + "src": "6104:2:9" + }, + "returnParameters": { + "id": 1335, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1334, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1341, + "src": "6128:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1333, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6128:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6127:9:9" + }, + "scope": 1357, + "src": "6063:142:9", + "stateMutability": "view", + "superFunction": 1872, + "visibility": "public" + }, + { + "body": { + "id": 1355, + "nodeType": "Block", + "src": "6326:133:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1347, + "name": "LENDING_POOL_LIQUIDATION_MANAGER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1027, + "src": "6348:32:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1348, + "name": "_manager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1343, + "src": "6382:8:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1346, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "6336:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1349, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6336:55:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1350, + "nodeType": "ExpressionStatement", + "src": "6336:55:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1352, + "name": "_manager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1343, + "src": "6443:8:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1351, + "name": "LendingPoolLiquidationManagerUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 985, + "src": "6406:36:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1353, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6406:46:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1354, + "nodeType": "EmitStatement", + "src": "6401:51:9" + } + ] + }, + "documentation": null, + "id": 1356, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolLiquidationManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1344, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1343, + "name": "_manager", + "nodeType": "VariableDeclaration", + "scope": 1356, + "src": "6301:16:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1342, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6301:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6300:18:9" + }, + "returnParameters": { + "id": 1345, + "nodeType": "ParameterList", + "parameters": [], + "src": "6326:0:9" + }, + "scope": 1357, + "src": "6259:200:9", + "stateMutability": "nonpayable", + "superFunction": 1877, + "visibility": "public" + } + ], + "scope": 1358, + "src": "115:6346:9" + } + ], + "src": "0:6462:9" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "exportedSymbols": { + "LendingPoolAddressesProvider": [ + 1357 + ] + }, + "id": 1358, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 955, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:9" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol", + "file": "./AddressStorage.sol", + "id": 956, + "nodeType": "ImportDirective", + "scope": 1358, + "sourceUnit": 954, + "src": "25:30:9", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol", + "file": "../interfaces/ILendingPoolAddressesProvider.sol", + "id": 957, + "nodeType": "ImportDirective", + "scope": 1358, + "sourceUnit": 1879, + "src": "56:57:9", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 958, + "name": "ILendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1878, + "src": "156:29:9", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 959, + "nodeType": "InheritanceSpecifier", + "src": "156:29:9" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 960, + "name": "AddressStorage", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 953, + "src": "187:14:9", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AddressStorage_$953", + "typeString": "contract AddressStorage" + } + }, + "id": 961, + "nodeType": "InheritanceSpecifier", + "src": "187:14:9" + } + ], + "contractDependencies": [ + 953, + 1878 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 1357, + "linearizedBaseContracts": [ + 1357, + 953, + 1878 + ], + "name": "LendingPoolAddressesProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "anonymous": false, + "documentation": null, + "id": 965, + "name": "LendingPoolUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 964, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 963, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 965, + "src": "247:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 962, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "247:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "246:28:9" + }, + "src": "222:53:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 969, + "name": "LendingPoolCoreUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 968, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 967, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 969, + "src": "309:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 966, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "309:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "308:28:9" + }, + "src": "280:57:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 973, + "name": "LendingPoolParametersProviderUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 972, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 971, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 973, + "src": "385:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 970, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "385:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "384:28:9" + }, + "src": "342:71:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 977, + "name": "LendingPoolManagerUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 976, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 975, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 977, + "src": "450:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 974, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "450:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "449:28:9" + }, + "src": "418:60:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 981, + "name": "LendingPoolConfiguratorUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 980, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 979, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 981, + "src": "520:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 978, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "520:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "519:28:9" + }, + "src": "483:65:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 985, + "name": "LendingPoolLiquidationManagerUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 984, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 983, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 985, + "src": "596:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 982, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "596:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "595:28:9" + }, + "src": "553:71:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 989, + "name": "LendingPoolDataProviderUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 988, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 987, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 989, + "src": "666:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 986, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "666:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "665:28:9" + }, + "src": "629:65:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 993, + "name": "LendingPoolNetworkMetadataProviderUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 992, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 991, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 993, + "src": "747:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 990, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "747:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "746:28:9" + }, + "src": "699:76:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 997, + "name": "PriceOracleUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 996, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 995, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 997, + "src": "805:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 994, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "805:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "804:28:9" + }, + "src": "780:53:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 1001, + "name": "LendingRateOracleUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 1000, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 999, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 1001, + "src": "869:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 998, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "869:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "868:28:9" + }, + "src": "838:59:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 1005, + "name": "FeeProviderUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 1004, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1003, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 1005, + "src": "927:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1002, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "927:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "926:28:9" + }, + "src": "902:53:9" + }, + { + "anonymous": false, + "documentation": null, + "id": 1009, + "name": "InterestRrateStrategyUpdated", + "nodeType": "EventDefinition", + "parameters": { + "id": 1008, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1007, + "indexed": true, + "name": "newAddress", + "nodeType": "VariableDeclaration", + "scope": 1009, + "src": "995:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1006, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "995:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "994:28:9" + }, + "src": "960:63:9" + }, + { + "constant": true, + "id": 1012, + "name": "LENDING_POOL", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1030:54:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1010, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1030:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44494e475f504f4f4c", + "id": 1011, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1070:14:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_b0a02d474211257da1bdb72ce7e91b05cbdc99ae0876cb0a61bbc7ad100c58a7", + "typeString": "literal_string \"LENDING_POOL\"" + }, + "value": "LENDING_POOL" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1015, + "name": "LENDING_POOL_CORE", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1090:64:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1013, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1090:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44494e475f504f4f4c5f434f5245", + "id": 1014, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1135:19:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_debd030f8671102224659f980e877487c7d3baa1e1b6c27b36811355a8cf480e", + "typeString": "literal_string \"LENDING_POOL_CORE\"" + }, + "value": "LENDING_POOL_CORE" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1018, + "name": "LENDING_POOL_CONFIGURATOR", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1160:80:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1016, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1160:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44494e475f504f4f4c5f434f4e464947555241544f52", + "id": 1017, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1213:27:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_daa78d61aa52695c850c795958745aa3b3dd53fcf767ab7e0a1b2527fbeac8ed", + "typeString": "literal_string \"LENDING_POOL_CONFIGURATOR\"" + }, + "value": "LENDING_POOL_CONFIGURATOR" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1021, + "name": "LENDING_POOL_PARAMETERS_PROVIDER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1246:81:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1019, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1246:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "504152414d45544552535f50524f5649444552", + "id": 1020, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1306:21:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_0ace7b0a9050f5e6e3fec6c7d67442523a810986ede2bd15a68f03d8a731ea58", + "typeString": "literal_string \"PARAMETERS_PROVIDER\"" + }, + "value": "PARAMETERS_PROVIDER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1024, + "name": "LENDING_POOL_MANAGER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1333:70:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1022, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1333:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44494e475f504f4f4c5f4d414e41474552", + "id": 1023, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1381:22:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_4b2b80371dc74900b689cf87b6606fd932b4a6c652fe9bbab580a2a9a9a590f0", + "typeString": "literal_string \"LENDING_POOL_MANAGER\"" + }, + "value": "LENDING_POOL_MANAGER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1027, + "name": "LENDING_POOL_LIQUIDATION_MANAGER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1409:81:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1025, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1409:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c49515549444154494f4e5f4d414e41474552", + "id": 1026, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1469:21:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_0b8b100501322269eb8293378cdaf941a0d883fad7878cbc00f3c143fa0c6c96", + "typeString": "literal_string \"LIQUIDATION_MANAGER\"" + }, + "value": "LIQUIDATION_MANAGER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1030, + "name": "DATA_PROVIDER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1496:56:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1028, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1496:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "444154415f50524f5649444552", + "id": 1029, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1537:15:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5164d5c7193030abda56ab2da6b1ecfb83373a1a97075675ab8548ca2be633d9", + "typeString": "literal_string \"DATA_PROVIDER\"" + }, + "value": "DATA_PROVIDER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1033, + "name": "NETWORK_METADATA_PROVIDER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1558:80:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1031, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1558:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4e4554574f524b5f4d455441444154415f50524f5649444552", + "id": 1032, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1611:27:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8220486d7dc5a09b47752faad5a32d9c1bb07ebc861afa7011c931235c655a47", + "typeString": "literal_string \"NETWORK_METADATA_PROVIDER\"" + }, + "value": "NETWORK_METADATA_PROVIDER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1036, + "name": "PRICE_ORACLE", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1644:54:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1034, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1644:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "50524943455f4f5241434c45", + "id": 1035, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1684:14:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_dd24a0f121e5ab7c3e97c63eaaf859e0b46792c3e0edfd86e2b3ad50f63011d8", + "typeString": "literal_string \"PRICE_ORACLE\"" + }, + "value": "PRICE_ORACLE" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1039, + "name": "LENDING_RATE_ORACLE", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1704:68:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1037, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1704:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44494e475f524154455f4f5241434c45", + "id": 1038, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1751:21:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_15e5978bd784d37462e6f1149d489232b2958f579b9f19e8da878a8ed491e4bd", + "typeString": "literal_string \"LENDING_RATE_ORACLE\"" + }, + "value": "LENDING_RATE_ORACLE" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1042, + "name": "FEE_PROVIDER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1778:54:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1040, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1778:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4645455f50524f5649444552", + "id": 1041, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1818:14:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ad24306cb85c40212eb431a99a37482b9ec077a212d8c1a7a04a61fb45d27c3b", + "typeString": "literal_string \"FEE_PROVIDER\"" + }, + "value": "FEE_PROVIDER" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1045, + "name": "INTEREST_RATE_STRATEGY", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1838:74:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1043, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1838:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "494e5445524553545f524154455f5354524154454759", + "id": 1044, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1888:24:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_2a0f0074ef138a45546c636beef8a612108f7d50fdd8fab359e0ef6b5afbed3d", + "typeString": "literal_string \"INTEREST_RATE_STRATEGY\"" + }, + "value": "INTEREST_RATE_STRATEGY" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1048, + "name": "WALLET_BALANCE_PROVIDER", + "nodeType": "VariableDeclaration", + "scope": 1357, + "src": "1918:76:9", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1046, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "1918:7:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "57414c4c45545f42414c414e43455f50524f5649444552", + "id": 1047, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1969:25:9", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_9b5f64efb249e3e2d53d898488a2435420d078cd1b14b91f486803b836d5b3ef", + "typeString": "literal_string \"WALLET_BALANCE_PROVIDER\"" + }, + "value": "WALLET_BALANCE_PROVIDER" + }, + "visibility": "private" + }, + { + "body": { + "id": 1057, + "nodeType": "Block", + "src": "2057:48:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1054, + "name": "LENDING_POOL", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1012, + "src": "2085:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1053, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "2074:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1055, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2074:24:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1052, + "id": 1056, + "nodeType": "Return", + "src": "2067:31:9" + } + ] + }, + "documentation": null, + "id": 1058, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPool", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1049, + "nodeType": "ParameterList", + "parameters": [], + "src": "2024:2:9" + }, + "returnParameters": { + "id": 1052, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1051, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1058, + "src": "2048:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1050, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2048:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2047:9:9" + }, + "scope": 1357, + "src": "2001:104:9", + "stateMutability": "view", + "superFunction": 1772, + "visibility": "public" + }, + { + "body": { + "id": 1072, + "nodeType": "Block", + "src": "2205:89:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1064, + "name": "LENDING_POOL", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1012, + "src": "2227:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1065, + "name": "_pool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1060, + "src": "2241:5:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1063, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "2215:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1066, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2215:32:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1067, + "nodeType": "ExpressionStatement", + "src": "2215:32:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1069, + "name": "_pool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1060, + "src": "2281:5:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1068, + "name": "LendingPoolUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 965, + "src": "2262:18:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1070, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2262:25:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1071, + "nodeType": "EmitStatement", + "src": "2257:30:9" + } + ] + }, + "documentation": null, + "id": 1073, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPool", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1061, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1060, + "name": "_pool", + "nodeType": "VariableDeclaration", + "scope": 1073, + "src": "2183:13:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1059, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2183:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2182:15:9" + }, + "returnParameters": { + "id": 1062, + "nodeType": "ParameterList", + "parameters": [], + "src": "2205:0:9" + }, + "scope": 1357, + "src": "2159:135:9", + "stateMutability": "nonpayable", + "superFunction": 1777, + "visibility": "public" + }, + { + "body": { + "id": 1082, + "nodeType": "Block", + "src": "2365:58:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1079, + "name": "INTEREST_RATE_STRATEGY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1045, + "src": "2393:22:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1078, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "2382:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1080, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2382:34:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1077, + "id": 1081, + "nodeType": "Return", + "src": "2375:41:9" + } + ] + }, + "documentation": null, + "id": 1083, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getInterestRateStrategy", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1074, + "nodeType": "ParameterList", + "parameters": [], + "src": "2332:2:9" + }, + "returnParameters": { + "id": 1077, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1076, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1083, + "src": "2356:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1075, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2356:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2355:9:9" + }, + "scope": 1357, + "src": "2300:123:9", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 1097, + "nodeType": "Block", + "src": "2536:117:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1089, + "name": "INTEREST_RATE_STRATEGY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1045, + "src": "2558:22:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1090, + "name": "_strategy", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1085, + "src": "2582:9:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1088, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "2546:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1091, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2546:46:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1092, + "nodeType": "ExpressionStatement", + "src": "2546:46:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1094, + "name": "_strategy", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1085, + "src": "2636:9:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1093, + "name": "InterestRrateStrategyUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1009, + "src": "2607:28:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1095, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2607:39:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1096, + "nodeType": "EmitStatement", + "src": "2602:44:9" + } + ] + }, + "documentation": null, + "id": 1098, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setInterestRateStrategy", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1086, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1085, + "name": "_strategy", + "nodeType": "VariableDeclaration", + "scope": 1098, + "src": "2510:17:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1084, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2510:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2509:19:9" + }, + "returnParameters": { + "id": 1087, + "nodeType": "ParameterList", + "parameters": [], + "src": "2536:0:9" + }, + "scope": 1357, + "src": "2477:176:9", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 1115, + "nodeType": "Block", + "src": "2727:108:9", + "statements": [ + { + "assignments": [ + 1104 + ], + "declarations": [ + { + "constant": false, + "id": 1104, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 1115, + "src": "2737:20:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 1103, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2737:15:9", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 1112, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1108, + "name": "LENDING_POOL_CORE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1015, + "src": "2787:17:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1107, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "2776:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1109, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2776:29:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1106, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2768:7:9", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint160_$", + "typeString": "type(uint160)" + }, + "typeName": "uint160" + }, + "id": 1110, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2768:38:9", + "typeDescriptions": { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + ], + "id": 1105, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2760:7:9", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 1111, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2760:47:9", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2737:70:9" + }, + { + "expression": { + "argumentTypes": null, + "id": 1113, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1104, + "src": "2824:4:9", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "functionReturnParameters": 1102, + "id": 1114, + "nodeType": "Return", + "src": "2817:11:9" + } + ] + }, + "documentation": null, + "id": 1116, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolCore", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1099, + "nodeType": "ParameterList", + "parameters": [], + "src": "2686:2:9" + }, + "returnParameters": { + "id": 1102, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1101, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1116, + "src": "2710:15:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 1100, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2710:15:9", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2709:17:9" + }, + "scope": 1357, + "src": "2659:176:9", + "stateMutability": "view", + "superFunction": 1782, + "visibility": "public" + }, + { + "body": { + "id": 1130, + "nodeType": "Block", + "src": "2950:120:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1122, + "name": "LENDING_POOL_CORE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1015, + "src": "2972:17:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1123, + "name": "_lendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1118, + "src": "2991:16:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1121, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "2960:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1124, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2960:48:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1125, + "nodeType": "ExpressionStatement", + "src": "2960:48:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1127, + "name": "_lendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1118, + "src": "3046:16:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1126, + "name": "LendingPoolCoreUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 969, + "src": "3023:22:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1128, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3023:40:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1129, + "nodeType": "EmitStatement", + "src": "3018:45:9" + } + ] + }, + "documentation": null, + "id": 1131, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolCore", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1119, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1118, + "name": "_lendingPoolCore", + "nodeType": "VariableDeclaration", + "scope": 1131, + "src": "2917:24:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1117, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2917:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2916:26:9" + }, + "returnParameters": { + "id": 1120, + "nodeType": "ParameterList", + "parameters": [], + "src": "2950:0:9" + }, + "scope": 1357, + "src": "2889:181:9", + "stateMutability": "nonpayable", + "superFunction": 1787, + "visibility": "public" + }, + { + "body": { + "id": 1140, + "nodeType": "Block", + "src": "3144:61:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1137, + "name": "LENDING_POOL_CONFIGURATOR", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1018, + "src": "3172:25:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1136, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "3161:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1138, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3161:37:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1135, + "id": 1139, + "nodeType": "Return", + "src": "3154:44:9" + } + ] + }, + "documentation": null, + "id": 1141, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolConfigurator", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1132, + "nodeType": "ParameterList", + "parameters": [], + "src": "3111:2:9" + }, + "returnParameters": { + "id": 1135, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1134, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1141, + "src": "3135:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1133, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3135:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3134:9:9" + }, + "scope": 1357, + "src": "3076:129:9", + "stateMutability": "view", + "superFunction": 1792, + "visibility": "public" + }, + { + "body": { + "id": 1155, + "nodeType": "Block", + "src": "3325:130:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1147, + "name": "LENDING_POOL_CONFIGURATOR", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1018, + "src": "3347:25:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1148, + "name": "_configurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1143, + "src": "3374:13:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1146, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "3335:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1149, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3335:53:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1150, + "nodeType": "ExpressionStatement", + "src": "3335:53:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1152, + "name": "_configurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1143, + "src": "3434:13:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1151, + "name": "LendingPoolConfiguratorUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 981, + "src": "3403:30:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1153, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3403:45:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1154, + "nodeType": "EmitStatement", + "src": "3398:50:9" + } + ] + }, + "documentation": null, + "id": 1156, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolConfigurator", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1144, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1143, + "name": "_configurator", + "nodeType": "VariableDeclaration", + "scope": 1156, + "src": "3295:21:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1142, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3295:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3294:23:9" + }, + "returnParameters": { + "id": 1145, + "nodeType": "ParameterList", + "parameters": [], + "src": "3325:0:9" + }, + "scope": 1357, + "src": "3259:196:9", + "stateMutability": "nonpayable", + "superFunction": 1797, + "visibility": "public" + }, + { + "body": { + "id": 1165, + "nodeType": "Block", + "src": "3524:56:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1162, + "name": "LENDING_POOL_MANAGER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1024, + "src": "3552:20:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1161, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "3541:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1163, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3541:32:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1160, + "id": 1164, + "nodeType": "Return", + "src": "3534:39:9" + } + ] + }, + "documentation": null, + "id": 1166, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1157, + "nodeType": "ParameterList", + "parameters": [], + "src": "3491:2:9" + }, + "returnParameters": { + "id": 1160, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1159, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1166, + "src": "3515:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1158, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3515:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3514:9:9" + }, + "scope": 1357, + "src": "3461:119:9", + "stateMutability": "view", + "superFunction": 1802, + "visibility": "public" + }, + { + "body": { + "id": 1180, + "nodeType": "Block", + "src": "3701:132:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1172, + "name": "LENDING_POOL_MANAGER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1024, + "src": "3723:20:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1173, + "name": "_lendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1168, + "src": "3745:19:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1171, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "3711:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1174, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3711:54:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1175, + "nodeType": "ExpressionStatement", + "src": "3711:54:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1177, + "name": "_lendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1168, + "src": "3806:19:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1176, + "name": "LendingPoolManagerUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 977, + "src": "3780:25:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1178, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3780:46:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1179, + "nodeType": "EmitStatement", + "src": "3775:51:9" + } + ] + }, + "documentation": null, + "id": 1181, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1169, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1168, + "name": "_lendingPoolManager", + "nodeType": "VariableDeclaration", + "scope": 1181, + "src": "3665:27:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1167, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3665:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3664:29:9" + }, + "returnParameters": { + "id": 1170, + "nodeType": "ParameterList", + "parameters": [], + "src": "3701:0:9" + }, + "scope": 1357, + "src": "3634:199:9", + "stateMutability": "nonpayable", + "superFunction": 1807, + "visibility": "public" + }, + { + "body": { + "id": 1190, + "nodeType": "Block", + "src": "3907:49:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1187, + "name": "DATA_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1030, + "src": "3935:13:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1186, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "3924:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1188, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3924:25:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1185, + "id": 1189, + "nodeType": "Return", + "src": "3917:32:9" + } + ] + }, + "documentation": null, + "id": 1191, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolDataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1182, + "nodeType": "ParameterList", + "parameters": [], + "src": "3874:2:9" + }, + "returnParameters": { + "id": 1185, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1184, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1191, + "src": "3898:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1183, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3898:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3897:9:9" + }, + "scope": 1357, + "src": "3839:117:9", + "stateMutability": "view", + "superFunction": 1812, + "visibility": "public" + }, + { + "body": { + "id": 1205, + "nodeType": "Block", + "src": "4072:110:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1197, + "name": "DATA_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1030, + "src": "4094:13:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1198, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1193, + "src": "4109:9:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1196, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "4082:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1199, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4082:37:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1200, + "nodeType": "ExpressionStatement", + "src": "4082:37:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1202, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1193, + "src": "4165:9:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1201, + "name": "LendingPoolDataProviderUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 989, + "src": "4134:30:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1203, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4134:41:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1204, + "nodeType": "EmitStatement", + "src": "4129:46:9" + } + ] + }, + "documentation": null, + "id": 1206, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolDataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1194, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1193, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 1206, + "src": "4046:17:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1192, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4046:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4045:19:9" + }, + "returnParameters": { + "id": 1195, + "nodeType": "ParameterList", + "parameters": [], + "src": "4072:0:9" + }, + "scope": 1357, + "src": "4010:172:9", + "stateMutability": "nonpayable", + "superFunction": 1817, + "visibility": "public" + }, + { + "body": { + "id": 1215, + "nodeType": "Block", + "src": "4256:61:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1212, + "name": "NETWORK_METADATA_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1033, + "src": "4284:25:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1211, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "4273:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1213, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4273:37:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1210, + "id": 1214, + "nodeType": "Return", + "src": "4266:44:9" + } + ] + }, + "documentation": null, + "id": 1216, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getNetworkMetadataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1207, + "nodeType": "ParameterList", + "parameters": [], + "src": "4223:2:9" + }, + "returnParameters": { + "id": 1210, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1209, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1216, + "src": "4247:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1208, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4247:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4246:9:9" + }, + "scope": 1357, + "src": "4188:129:9", + "stateMutability": "view", + "superFunction": 1822, + "visibility": "public" + }, + { + "body": { + "id": 1230, + "nodeType": "Block", + "src": "4448:163:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1222, + "name": "NETWORK_METADATA_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1033, + "src": "4470:25:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1223, + "name": "_networkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1218, + "src": "4497:24:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1221, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "4458:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1224, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4458:64:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1225, + "nodeType": "ExpressionStatement", + "src": "4458:64:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1227, + "name": "_networkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1218, + "src": "4579:24:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1226, + "name": "LendingPoolNetworkMetadataProviderUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 993, + "src": "4537:41:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1228, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4537:67:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1229, + "nodeType": "EmitStatement", + "src": "4532:72:9" + } + ] + }, + "documentation": null, + "id": 1231, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setNetworkMetadataProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1219, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1218, + "name": "_networkMetadataProvider", + "nodeType": "VariableDeclaration", + "scope": 1231, + "src": "4407:32:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1217, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4407:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4406:34:9" + }, + "returnParameters": { + "id": 1220, + "nodeType": "ParameterList", + "parameters": [], + "src": "4448:0:9" + }, + "scope": 1357, + "src": "4371:240:9", + "stateMutability": "nonpayable", + "superFunction": 1827, + "visibility": "public" + }, + { + "body": { + "id": 1240, + "nodeType": "Block", + "src": "4691:68:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1237, + "name": "LENDING_POOL_PARAMETERS_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1021, + "src": "4719:32:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1236, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "4708:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1238, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4708:44:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1235, + "id": 1239, + "nodeType": "Return", + "src": "4701:51:9" + } + ] + }, + "documentation": null, + "id": 1241, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolParametersProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1232, + "nodeType": "ParameterList", + "parameters": [], + "src": "4658:2:9" + }, + "returnParameters": { + "id": 1235, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1234, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1241, + "src": "4682:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1233, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4682:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4681:9:9" + }, + "scope": 1357, + "src": "4617:142:9", + "stateMutability": "view", + "superFunction": 1832, + "visibility": "public" + }, + { + "body": { + "id": 1255, + "nodeType": "Block", + "src": "4891:155:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1247, + "name": "LENDING_POOL_PARAMETERS_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1021, + "src": "4913:32:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1248, + "name": "_parametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1243, + "src": "4947:19:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1246, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "4901:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1249, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4901:66:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1250, + "nodeType": "ExpressionStatement", + "src": "4901:66:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1252, + "name": "_parametersProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1243, + "src": "5019:19:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1251, + "name": "LendingPoolParametersProviderUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 973, + "src": "4982:36:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1253, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4982:57:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1254, + "nodeType": "EmitStatement", + "src": "4977:62:9" + } + ] + }, + "documentation": null, + "id": 1256, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolParametersProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1244, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1243, + "name": "_parametersProvider", + "nodeType": "VariableDeclaration", + "scope": 1256, + "src": "4855:27:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1242, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4855:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4854:29:9" + }, + "returnParameters": { + "id": 1245, + "nodeType": "ParameterList", + "parameters": [], + "src": "4891:0:9" + }, + "scope": 1357, + "src": "4813:233:9", + "stateMutability": "nonpayable", + "superFunction": 1837, + "visibility": "public" + }, + { + "body": { + "id": 1265, + "nodeType": "Block", + "src": "5109:48:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1262, + "name": "PRICE_ORACLE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1036, + "src": "5137:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1261, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "5126:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1263, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5126:24:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1260, + "id": 1264, + "nodeType": "Return", + "src": "5119:31:9" + } + ] + }, + "documentation": null, + "id": 1266, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getPriceOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1257, + "nodeType": "ParameterList", + "parameters": [], + "src": "5076:2:9" + }, + "returnParameters": { + "id": 1260, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1259, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1266, + "src": "5100:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1258, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5100:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5099:9:9" + }, + "scope": 1357, + "src": "5053:104:9", + "stateMutability": "view", + "superFunction": 1842, + "visibility": "public" + }, + { + "body": { + "id": 1280, + "nodeType": "Block", + "src": "5264:103:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1272, + "name": "PRICE_ORACLE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1036, + "src": "5286:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1273, + "name": "_priceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1268, + "src": "5300:12:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1271, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "5274:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1274, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5274:39:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1275, + "nodeType": "ExpressionStatement", + "src": "5274:39:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1277, + "name": "_priceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1268, + "src": "5347:12:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1276, + "name": "PriceOracleUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 997, + "src": "5328:18:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1278, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5328:32:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1279, + "nodeType": "EmitStatement", + "src": "5323:37:9" + } + ] + }, + "documentation": null, + "id": 1281, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setPriceOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1269, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1268, + "name": "_priceOracle", + "nodeType": "VariableDeclaration", + "scope": 1281, + "src": "5235:20:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1267, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5235:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5234:22:9" + }, + "returnParameters": { + "id": 1270, + "nodeType": "ParameterList", + "parameters": [], + "src": "5264:0:9" + }, + "scope": 1357, + "src": "5211:156:9", + "stateMutability": "nonpayable", + "superFunction": 1847, + "visibility": "public" + }, + { + "body": { + "id": 1290, + "nodeType": "Block", + "src": "5435:55:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1287, + "name": "LENDING_RATE_ORACLE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1039, + "src": "5463:19:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1286, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "5452:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1288, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5452:31:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1285, + "id": 1289, + "nodeType": "Return", + "src": "5445:38:9" + } + ] + }, + "documentation": null, + "id": 1291, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingRateOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1282, + "nodeType": "ParameterList", + "parameters": [], + "src": "5402:2:9" + }, + "returnParameters": { + "id": 1285, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1284, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1291, + "src": "5426:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1283, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5426:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5425:9:9" + }, + "scope": 1357, + "src": "5373:117:9", + "stateMutability": "view", + "superFunction": 1852, + "visibility": "public" + }, + { + "body": { + "id": 1305, + "nodeType": "Block", + "src": "5609:128:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1297, + "name": "LENDING_RATE_ORACLE", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1039, + "src": "5631:19:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1298, + "name": "_lendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1293, + "src": "5652:18:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1296, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "5619:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1299, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5619:52:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1300, + "nodeType": "ExpressionStatement", + "src": "5619:52:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1302, + "name": "_lendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1293, + "src": "5711:18:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1301, + "name": "LendingRateOracleUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1001, + "src": "5686:24:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1303, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5686:44:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1304, + "nodeType": "EmitStatement", + "src": "5681:49:9" + } + ] + }, + "documentation": null, + "id": 1306, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingRateOracle", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1294, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1293, + "name": "_lendingRateOracle", + "nodeType": "VariableDeclaration", + "scope": 1306, + "src": "5574:26:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1292, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5574:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5573:28:9" + }, + "returnParameters": { + "id": 1295, + "nodeType": "ParameterList", + "parameters": [], + "src": "5609:0:9" + }, + "scope": 1357, + "src": "5544:193:9", + "stateMutability": "nonpayable", + "superFunction": 1857, + "visibility": "public" + }, + { + "body": { + "id": 1315, + "nodeType": "Block", + "src": "5799:48:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1312, + "name": "FEE_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1042, + "src": "5827:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1311, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "5816:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1313, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5816:24:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1310, + "id": 1314, + "nodeType": "Return", + "src": "5809:31:9" + } + ] + }, + "documentation": null, + "id": 1316, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getFeeProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1307, + "nodeType": "ParameterList", + "parameters": [], + "src": "5766:2:9" + }, + "returnParameters": { + "id": 1310, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1309, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1316, + "src": "5790:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1308, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5790:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5789:9:9" + }, + "scope": 1357, + "src": "5743:104:9", + "stateMutability": "view", + "superFunction": 1862, + "visibility": "public" + }, + { + "body": { + "id": 1330, + "nodeType": "Block", + "src": "5954:103:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1322, + "name": "FEE_PROVIDER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1042, + "src": "5976:12:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1323, + "name": "_feeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1318, + "src": "5990:12:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1321, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "5964:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1324, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5964:39:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1325, + "nodeType": "ExpressionStatement", + "src": "5964:39:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1327, + "name": "_feeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1318, + "src": "6037:12:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1326, + "name": "FeeProviderUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1005, + "src": "6018:18:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1328, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6018:32:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1329, + "nodeType": "EmitStatement", + "src": "6013:37:9" + } + ] + }, + "documentation": null, + "id": 1331, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setFeeProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1319, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1318, + "name": "_feeProvider", + "nodeType": "VariableDeclaration", + "scope": 1331, + "src": "5925:20:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1317, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5925:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5924:22:9" + }, + "returnParameters": { + "id": 1320, + "nodeType": "ParameterList", + "parameters": [], + "src": "5954:0:9" + }, + "scope": 1357, + "src": "5901:156:9", + "stateMutability": "nonpayable", + "superFunction": 1867, + "visibility": "public" + }, + { + "body": { + "id": 1340, + "nodeType": "Block", + "src": "6137:68:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1337, + "name": "LENDING_POOL_LIQUIDATION_MANAGER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1027, + "src": "6165:32:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1336, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "6154:10:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1338, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6154:44:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1335, + "id": 1339, + "nodeType": "Return", + "src": "6147:51:9" + } + ] + }, + "documentation": null, + "id": 1341, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getLendingPoolLiquidationManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1332, + "nodeType": "ParameterList", + "parameters": [], + "src": "6104:2:9" + }, + "returnParameters": { + "id": 1335, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1334, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1341, + "src": "6128:7:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1333, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6128:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6127:9:9" + }, + "scope": 1357, + "src": "6063:142:9", + "stateMutability": "view", + "superFunction": 1872, + "visibility": "public" + }, + { + "body": { + "id": 1355, + "nodeType": "Block", + "src": "6326:133:9", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1347, + "name": "LENDING_POOL_LIQUIDATION_MANAGER", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1027, + "src": "6348:32:9", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1348, + "name": "_manager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1343, + "src": "6382:8:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1346, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "6336:11:9", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1349, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6336:55:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1350, + "nodeType": "ExpressionStatement", + "src": "6336:55:9" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1352, + "name": "_manager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1343, + "src": "6443:8:9", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1351, + "name": "LendingPoolLiquidationManagerUpdated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 985, + "src": "6406:36:9", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 1353, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6406:46:9", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 1354, + "nodeType": "EmitStatement", + "src": "6401:51:9" + } + ] + }, + "documentation": null, + "id": 1356, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setLendingPoolLiquidationManager", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1344, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1343, + "name": "_manager", + "nodeType": "VariableDeclaration", + "scope": 1356, + "src": "6301:16:9", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1342, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6301:7:9", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6300:18:9" + }, + "returnParameters": { + "id": 1345, + "nodeType": "ParameterList", + "parameters": [], + "src": "6326:0:9" + }, + "scope": 1357, + "src": "6259:200:9", + "stateMutability": "nonpayable", + "superFunction": 1877, + "visibility": "public" + } + ], + "scope": 1358, + "src": "115:6346:9" + } + ], + "src": "0:6462:9" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.577Z", + "devdoc": { + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/LendingPoolConfigurator.json b/client/src/contracts/LendingPoolConfigurator.json new file mode 100644 index 0000000..5f858fb --- /dev/null +++ b/client/src/contracts/LendingPoolConfigurator.json @@ -0,0 +1,14978 @@ +{ + "contractName": "LendingPoolConfigurator", + "abi": [ + { + "constant": false, + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "poolAddressesProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isOwner", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "name": "_poolAddressesProvider", + "type": "address" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": true, + "name": "_aToken", + "type": "address" + }, + { + "indexed": false, + "name": "_initialExchangeRate", + "type": "uint256" + }, + { + "indexed": false, + "name": "_interestRateStrategyAddress", + "type": "address" + } + ], + "name": "ReserveInitialized", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "name": "_reserve", + "type": "address" + }, + { + "indexed": false, + "name": "_fixedRateEnabled", + "type": "bool" + } + ], + "name": "BorrowingEnabledOnReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + } + ], + "name": "BorrowingDisabledOnReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + }, + { + "indexed": false, + "name": "_ltv", + "type": "uint256" + }, + { + "indexed": false, + "name": "_liquidationThreshold", + "type": "uint256" + } + ], + "name": "ReserveEnabledAsCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + } + ], + "name": "ReserveDisabledAsCollateral", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + } + ], + "name": "FixedRateEnabledOnReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + } + ], + "name": "FixedRateDisabledOnReserve", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + } + ], + "name": "ReserveActivated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "_reserve", + "type": "address" + } + ], + "name": "ReserveDeactivated", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_aTokenInitialExchangeRate", + "type": "uint256" + }, + { + "name": "_underlyingAssetDecimals", + "type": "uint256" + }, + { + "name": "_interestRateStrategyAddress", + "type": "address" + } + ], + "name": "initReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "aTokenName", + "type": "string" + }, + { + "name": "aTokenSymbol", + "type": "string" + }, + { + "name": "_aTokenInitialExchangeRate", + "type": "uint256" + }, + { + "name": "_underlyingAssetDecimals", + "type": "uint256" + }, + { + "name": "_interestRateStrategyAddress", + "type": "address" + } + ], + "name": "initReserveWithData", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_fixedBorrowRateEnabled", + "type": "bool" + } + ], + "name": "enableBorrowingOnReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "disableBorrowingOnReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_baseLTVasCollateral", + "type": "uint256" + }, + { + "name": "_liquidationThreshold", + "type": "uint256" + } + ], + "name": "enableReserveAsCollateral", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "disableReserveAsCollateral", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "enableReserveFixedBorrowRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "disableReserveFixedBorrowRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "activateReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "deactivateReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_ltv", + "type": "uint256" + } + ], + "name": "setReserveBaseLTVasCollateral", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_threshold", + "type": "uint256" + } + ], + "name": "setReserveLiquidationThreshold", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_threshold", + "type": "uint256" + } + ], + "name": "setReserveLiquidationDiscount", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_rateStrategyAddress", + "type": "address" + } + ], + "name": "setReserveInterestRateStrategyAddress", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_provider", + "type": "address" + } + ], + "name": "setLendingPoolCoreAddressesProvider", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "refreshLendingPoolCoreConfiguration", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_rateStrategyAddress\",\"type\":\"address\"}],\"name\":\"setReserveInterestRateStrategyAddress\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_baseLTVasCollateral\",\"type\":\"uint256\"},{\"name\":\"_liquidationThreshold\",\"type\":\"uint256\"}],\"name\":\"enableReserveAsCollateral\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_threshold\",\"type\":\"uint256\"}],\"name\":\"setReserveLiquidationThreshold\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"deactivateReserve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_aTokenInitialExchangeRate\",\"type\":\"uint256\"},{\"name\":\"_underlyingAssetDecimals\",\"type\":\"uint256\"},{\"name\":\"_interestRateStrategyAddress\",\"type\":\"address\"}],\"name\":\"initReserve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"poolAddressesProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isOwner\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"enableReserveFixedBorrowRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"aTokenName\",\"type\":\"string\"},{\"name\":\"aTokenSymbol\",\"type\":\"string\"},{\"name\":\"_aTokenInitialExchangeRate\",\"type\":\"uint256\"},{\"name\":\"_underlyingAssetDecimals\",\"type\":\"uint256\"},{\"name\":\"_interestRateStrategyAddress\",\"type\":\"address\"}],\"name\":\"initReserveWithData\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"disableBorrowingOnReserve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_provider\",\"type\":\"address\"}],\"name\":\"setLendingPoolCoreAddressesProvider\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_threshold\",\"type\":\"uint256\"}],\"name\":\"setReserveLiquidationDiscount\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"activateReserve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_ltv\",\"type\":\"uint256\"}],\"name\":\"setReserveBaseLTVasCollateral\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"disableReserveFixedBorrowRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"refreshLendingPoolCoreConfiguration\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"disableReserveAsCollateral\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_fixedBorrowRateEnabled\",\"type\":\"bool\"}],\"name\":\"enableBorrowingOnReserve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_poolAddressesProvider\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"_aToken\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_initialExchangeRate\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_interestRateStrategyAddress\",\"type\":\"address\"}],\"name\":\"ReserveInitialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_fixedRateEnabled\",\"type\":\"bool\"}],\"name\":\"BorrowingEnabledOnReserve\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"BorrowingDisabledOnReserve\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_ltv\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_liquidationThreshold\",\"type\":\"uint256\"}],\"name\":\"ReserveEnabledAsCollateral\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"ReserveDisabledAsCollateral\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"FixedRateEnabledOnReserve\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"FixedRateDisabledOnReserve\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"ReserveActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"ReserveDeactivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"}],\"devdoc\":{\"author\":\"Aave\",\"methods\":{\"initReserve(address,uint256,uint256,address)\":{\"details\":\"pool core managment functions*****************************************\"},\"isOwner()\":{\"details\":\"Returns true if the caller is the current owner.\"},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"},\"setReserveBaseLTVasCollateral(address,uint256)\":{\"details\":\"functions to update available collateralsthe interest rate and the ltv are expressed in percentage**************\"},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}},\"title\":\"LendingPoolConfigurator contract\"},\"userdoc\":{\"methods\":{\"enableBorrowingOnReserve(address,bool)\":{\"notice\":\"functions to enable/disable borrowing on reserve.\"},\"enableReserveAsCollateral(address,uint256,uint256)\":{\"notice\":\"functions to enable/disable usage of the reserve as collateral.\"},\"enableReserveFixedBorrowRate(address)\":{\"notice\":\"functions to enable/disable fixed borrow rate mode on a reserve.\"},\"initReserve(address,uint256,uint256,address)\":{\"notice\":\"****************************************\"},\"initReserveWithData(address,string,string,uint256,uint256,address)\":{\"notice\":\"initialises the reserve and instantiates the specific aToken with the specified initial exchange rate.\"},\"setReserveBaseLTVasCollateral(address,uint256)\":{\"notice\":\"*************\"}},\"notice\":\"***********************************************************************************Executes configuration methods on the LendingPoolCore contract. Allows to enable/disable reserves, and set different protocol parameters.************************************************************************************\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolConfigurator.sol\":\"LendingPoolConfigurator\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x0ae6004410cd58a1c5151e67959167cf58cd5e77e8b625677826e295905fb318\",\"urls\":[\"bzzr://d223bea23f0e9bd70844e9852f490be93d30fc1c31bf114c807d0e4fe07d929b\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol\":{\"keccak256\":\"0xcd8c22e8b9f5c5c4bdb5b5262beafa93486c3b15262283c053afd423eca6e16b\",\"urls\":[\"bzzr://a9a5076a121f51ea42d9ebddc2684f299a0b57c0321837b5776c3a9eb26be97e\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol\":{\"keccak256\":\"0x479a8627304b58f37a4adbe06a72c7a056ad7ce6793a4ea66deeba04c6e443c8\",\"urls\":[\"bzzr://92bb0ae9b38ab361638c71c81f650ff8115da42cb4f50a0ee7a6fb5e03e5e640\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol\":{\"keccak256\":\"0x3f74e899243a66d556c0fa81875ab95ed1e3af1909b0281d03fe89590b95121f\",\"urls\":[\"bzzr://ef6ed6edeb1ec124bf1749991346f0708214f7e12c353175d36b491bce45d7a4\"]},\"/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol\":{\"keccak256\":\"0x3b825dc98b6a7aa21e9c9b05e1951bec7b5d7c84b7a0e8de0750069ccb31ebac\",\"urls\":[\"bzzr://8a616caca158d63de8db6037a2162c1effaaa71f6d7095a11516e03f7ea391d0\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol\":{\"keccak256\":\"0xdf72f6345d96ca2731656811b508db7f8e4975776d6de39ab24dbe4a13794fd8\",\"urls\":[\"bzzr://687ac9b4f396f264af2645041f5532b6881ec8c92dad3e505ca96477957c784d\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":{\"keccak256\":\"0xeeae2b67fa36103fe1c3a4e346b9c04171f9065949953abd00104c357834b0e3\",\"urls\":[\"bzzr://4e3bd29abfa796726532c3e42dd8039ab0f93388d7bbf358428dbc9b0399664a\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x0adf744884b9262f507aba565d1c96c82397f58d399a2dc2c60a452953197574\",\"urls\":[\"bzzr://03099f88c041565b5ac13ea7e645a8f9bff0c29bfa584c7969372ce12c5473f5\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol\":{\"keccak256\":\"0x35a7f1a34259948cdcb03084718f765215fe69559f557b395d9d6e18c63ac823\",\"urls\":[\"bzzr://f529e265dd06192a1d552f1f41c245790419562dfb52e7be9d443c758ccb72d0\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol\":{\"keccak256\":\"0x3f4ef00886795fb781b76e1fab7ce2f0422de9d0941bc8d5d9c377ad100e9a33\",\"urls\":[\"bzzr://8aff91a48f36ed3d3da74fc48d65cbc20e56e45172790ae38f18e234883ece70\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolConfigurator.sol\":{\"keccak256\":\"0xad657f63f944e71d67e4954699de9942f51854fc4bb335626b4b543d3cd3d3ee\",\"urls\":[\"bzzr://eac91279a1def9ed2e4338d9db977c814d52cc1cef59d01214455c64b8d23a0a\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol\":{\"keccak256\":\"0xca757f989e0e7519d03d4e3086028e3022306ec4bb7f610fa78bff866f04c998\",\"urls\":[\"bzzr://f381f642ecce43d76d9e0011ea3c7c6218d1eaa2e0d3a7d5aecd55552cc0fb27\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol\":{\"keccak256\":\"0xe9e88d47e58f59345bb70a48960878e8b6d7525e3fe4f03c63f575599123957a\",\"urls\":[\"bzzr://ab72dddd7f00500a59b72b7f2f938ca25ae859517d524e446dc92a37f5f4a4e3\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol\":{\"keccak256\":\"0x8cd409571214e2d2f9196b8a31ce04bb44919ce7b12e66301c216c3de70a3f5f\",\"urls\":[\"bzzr://87f2c373a1f51ca84ac1132e72e3ef5a43e7a4f4f10341a63993c2cbdb769b64\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol\":{\"keccak256\":\"0xb8b4844881a9ea5c3f0f2584061efcbfb6c96863ca3a07b960d2f9d323293cac\",\"urls\":[\"bzzr://8cb1c5dcce198c0f60c21bd9807b361fc214a60d4b3aa3442153b045b51a4325\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol\":{\"keccak256\":\"0x547550bb7c7e61190fddae1b4dbe71932c9acdaf1d196524ee99c3340a5bec2d\",\"urls\":[\"bzzr://4a9ee0d136529517d7586cb3842177dbd767d9c34fdb035b0a90e8f4cc4d1b35\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol\":{\"keccak256\":\"0x4a3a810b7ebe742e897e1fd428b3eeed2196d3acea58eaf9c566ed10d545d2ed\",\"urls\":[\"bzzr://729aefb3f89f616c954a0735f8b4dd8804bdd0351e96f8e904fdb3e78a109b6c\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]},\"openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol\":{\"keccak256\":\"0xe86fdc15fbc379ecf14d6aa4f51b87c0be8476e114e23c171b790a6717230655\",\"urls\":[\"bzzr://364c5847b4ee3ac37a6ad6e54a288889ac3d2a85757b7999c00c719db6cd871d\"]}},\"version\":1}", + "bytecode": "0x60806040523480156200001157600080fd5b506040516020806200684d833981018060405260208110156200003357600080fd5b8101908080519060200190929190505050620000546200015760201b60201c565b6000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550506200015f565b600033905090565b6166de806200016f6000396000f3fe60806040523480156200001157600080fd5b5060043610620001545760003560e01c8063a17166f111620000c9578063d466016f1162000087578063d466016f1462000712578063d7e075811462000763578063e12dcc6c14620007aa578063e8ae2f5b14620007b6578063eede87c114620007fd578063f2fde38b14620008505762000154565b8063a17166f1146200043d578063a8dc0f4514620005ec578063a9ef33e91462000633578063b46a4b34146200067a578063b75d6f3414620006cb5762000154565b8063715018a61162000117578063715018a6146200032e57806380e17d87146200033a5780638da5cb5b14620003865780638f32d59b14620003d25780639789b68a14620003f65762000154565b80631d2118f9146200015957806329a1786814620001c05780633443a14b146200021b5780633e72a454146200026c5780635f674c8714620002b3575b600080fd5b620001be600480360360408110156200017157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062000897565b005b6200021960048036036060811015620001d857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035906020019092919050505062000b3e565b005b6200026a600480360360408110156200023357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505062000e18565b005b620002b1600480360360208110156200028457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062001093565b005b6200032c60048036036080811015620002cb57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062001348565b005b620003386200177b565b005b62000344620018b7565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b62000390620018dd565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b620003dc62001906565b604051808215151515815260200191505060405180910390f35b6200043b600480360360208110156200040e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062001966565b005b620005ea600480360360c08110156200045557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001906401000000008111156200049357600080fd5b820183602082011115620004a657600080fd5b80359060200191846001830284011164010000000083111715620004c957600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f820116905080830192505050505050509192919290803590602001906401000000008111156200052d57600080fd5b8201836020820111156200054057600080fd5b803590602001918460018302840111640100000000831117156200056357600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f8201169050808301925050505050505091929192908035906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062001c1b565b005b62000631600480360360208110156200060457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062002155565b005b62000678600480360360208110156200064b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506200240a565b005b620006c9600480360360408110156200069257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506200267c565b005b6200071060048036036020811015620006e357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050620028f7565b005b62000761600480360360408110156200072a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505062002bac565b005b620007a8600480360360208110156200077b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062002e27565b005b620007b4620030dc565b005b620007fb60048036036020811015620007ce57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062003316565b005b6200084e600480360360408110156200081557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803515159060200190929190505050620035cb565b005b62000895600480360360208110156200086857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050620038b9565b005b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200091757600080fd5b505afa1580156200092c573d6000803e3d6000fd5b505050506040513d60208110156200094357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614620009c2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562000a2d57600080fd5b505afa15801562000a42573d6000803e3d6000fd5b505050506040513d602081101562000a5957600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16631d2118f984846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801562000b2057600080fd5b505af115801562000b35573d6000803e3d6000fd5b50505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b15801562000bbe57600080fd5b505afa15801562000bd3573d6000803e3d6000fd5b505050506040513d602081101562000bea57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462000c69576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562000cd457600080fd5b505afa15801562000ce9573d6000803e3d6000fd5b505050506040513d602081101562000d0057600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff166329a178688585856040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b15801562000da357600080fd5b505af115801562000db8573d6000803e3d6000fd5b505050508373ffffffffffffffffffffffffffffffffffffffff167f0b2f4ddd80e34a38c71a6c5f953a99dc8b45c79b8c563d301c2bb2267b9dbc348484604051808381526020018281526020019250505060405180910390a250505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b15801562000e9857600080fd5b505afa15801562000ead573d6000803e3d6000fd5b505050506040513d602081101562000ec457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462000f43576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562000fae57600080fd5b505afa15801562000fc3573d6000803e3d6000fd5b505050506040513d602081101562000fda57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16633443a14b84846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156200107557600080fd5b505af11580156200108a573d6000803e3d6000fd5b50505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200111357600080fd5b505afa15801562001128573d6000803e3d6000fd5b505050506040513d60208110156200113f57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614620011be576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200122957600080fd5b505afa1580156200123e573d6000803e3d6000fd5b505050506040513d60208110156200125557600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16633e72a454836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b158015620012e857600080fd5b505af1158015620012fd573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167f6f60cf8bd0f218cabe1ea3150bd07b0b758c35c4cfdf7138017a283e65564d5e60405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b158015620013c857600080fd5b505afa158015620013dd573d6000803e3d6000fd5b505050506040513d6020811015620013f457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462001473576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b600084905060608173ffffffffffffffffffffffffffffffffffffffff166306fdde036040518163ffffffff1660e01b815260040160006040518083038186803b158015620014c157600080fd5b505afa158015620014d6573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f8201168201806040525060208110156200150157600080fd5b8101908080516401000000008111156200151a57600080fd5b828101905060208101848111156200153157600080fd5b81518560018202830111640100000000821117156200154f57600080fd5b505092919050505060405160200180807f4161766520496e7465726573742062656172696e67200000000000000000000081525060160182805190602001908083835b60208310620015b7578051825260208201915060208101905060208303925062001592565b6001836020036101000a038019825116818451168082178552505050505050905001915050604051602081830303815290604052905060608273ffffffffffffffffffffffffffffffffffffffff166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b1580156200163657600080fd5b505afa1580156200164b573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f8201168201806040525060208110156200167657600080fd5b8101908080516401000000008111156200168f57600080fd5b82810190506020810184811115620016a657600080fd5b8151856001820283011164010000000082111715620016c457600080fd5b505092919050505060405160200180807f610000000000000000000000000000000000000000000000000000000000000081525060010182805190602001908083835b602083106200172c578051825260208201915060208101905060208303925062001707565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405160208183030381529060405290506200177287838389898962001c1b565b50505050505050565b6200178562001906565b620017f8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166200194a62003944565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b158015620019e657600080fd5b505afa158015620019fb573d6000803e3d6000fd5b505050506040513d602081101562001a1257600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462001a91576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562001afc57600080fd5b505afa15801562001b11573d6000803e3d6000fd5b505050506040513d602081101562001b2857600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16639789b68a836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801562001bbb57600080fd5b505af115801562001bd0573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167f3785f652b18f48a8a4c505037390f85f5b89bfe105384b964138f8a947ae89c660405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b15801562001c9b57600080fd5b505afa15801562001cb0573d6000803e3d6000fd5b505050506040513d602081101562001cc757600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462001d46576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562001db157600080fd5b505afa15801562001dc6573d6000803e3d6000fd5b505050506040513d602081101562001ddd57600080fd5b810190808051906020019092919050505090506000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff168885898960128a60405162001e2a9062003a92565b808873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200186815260200180602001806020018560ff168152602001848152602001838103835287818151815260200191508051906020019080838360005b8381101562001ee657808201518184015260208101905062001ec9565b50505050905090810190601f16801562001f145780820380516001836020036101000a031916815260200191505b50838103825286818151815260200191508051906020019080838360005b8381101562001f4f57808201518184015260208101905062001f32565b50505050905090810190601f16801562001f7d5780820380516001836020036101000a031916815260200191505b509950505050505050505050604051809103906000f08015801562001fa6573d6000803e3d6000fd5b5090508173ffffffffffffffffffffffffffffffffffffffff166345330a40898387876040518563ffffffff1660e01b8152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050600060405180830381600087803b1580156200209957600080fd5b505af1158015620020ae573d6000803e3d6000fd5b505050508073ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff167f9c6373c8d8364b6e1acd1bcb5895e6aee73dc8128782869914d27d7e54a938988786604051808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060405180910390a35050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b158015620021d557600080fd5b505afa158015620021ea573d6000803e3d6000fd5b505050506040513d60208110156200220157600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462002280576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b158015620022eb57600080fd5b505afa15801562002300573d6000803e3d6000fd5b505050506040513d60208110156200231757600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663a8dc0f45836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b158015620023aa57600080fd5b505af1158015620023bf573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167fe9a7e5fd4fc8ea18e602350324bf48e8f05d12434af0ce0be05743e6a5fdcb9e60405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200248a57600080fd5b505afa1580156200249f573d6000803e3d6000fd5b505050506040513d6020811015620024b657600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462002535576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b158015620025a057600080fd5b505afa158015620025b5573d6000803e3d6000fd5b505050506040513d6020811015620025cc57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16636722997a836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156200265f57600080fd5b505af115801562002674573d6000803e3d6000fd5b505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b158015620026fc57600080fd5b505afa15801562002711573d6000803e3d6000fd5b505050506040513d60208110156200272857600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614620027a7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200281257600080fd5b505afa15801562002827573d6000803e3d6000fd5b505050506040513d60208110156200283e57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663b46a4b3484846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015620028d957600080fd5b505af1158015620028ee573d6000803e3d6000fd5b50505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200297757600080fd5b505afa1580156200298c573d6000803e3d6000fd5b505050506040513d6020811015620029a357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462002a22576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562002a8d57600080fd5b505afa15801562002aa2573d6000803e3d6000fd5b505050506040513d602081101562002ab957600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663b75d6f34836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801562002b4c57600080fd5b505af115801562002b61573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167f35b80cd8ea3440e9a8454f116fa658b858da1b64c86c48451f4559cefcdfb56c60405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b15801562002c2c57600080fd5b505afa15801562002c41573d6000803e3d6000fd5b505050506040513d602081101562002c5857600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462002cd7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562002d4257600080fd5b505afa15801562002d57573d6000803e3d6000fd5b505050506040513d602081101562002d6e57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663d466016f84846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801562002e0957600080fd5b505af115801562002e1e573d6000803e3d6000fd5b50505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b15801562002ea757600080fd5b505afa15801562002ebc573d6000803e3d6000fd5b505050506040513d602081101562002ed357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462002f52576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562002fbd57600080fd5b505afa15801562002fd2573d6000803e3d6000fd5b505050506040513d602081101562002fe957600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663d7e07581836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156200307c57600080fd5b505af115801562003091573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167fd4fb373808cfe3d293bd3d3826c216194001d776dff64c75ae047dfda7f564de60405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200315c57600080fd5b505afa15801562003171573d6000803e3d6000fd5b505050506040513d60208110156200318857600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462003207576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200327257600080fd5b505afa15801562003287573d6000803e3d6000fd5b505050506040513d60208110156200329e57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663646810836040518163ffffffff1660e01b8152600401600060405180830381600087803b158015620032fa57600080fd5b505af11580156200330f573d6000803e3d6000fd5b5050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200339657600080fd5b505afa158015620033ab573d6000803e3d6000fd5b505050506040513d6020811015620033c257600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462003441576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b158015620034ac57600080fd5b505afa158015620034c1573d6000803e3d6000fd5b505050506040513d6020811015620034d857600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663e8ae2f5b836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156200356b57600080fd5b505af115801562003580573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167f9cc75e4cafc9a556a369bc53468649075680eb554d225d5918f199453824796d60405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200364b57600080fd5b505afa15801562003660573d6000803e3d6000fd5b505050506040513d60208110156200367757600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614620036f6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200376157600080fd5b505afa15801562003776573d6000803e3d6000fd5b505050506040513d60208110156200378d57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663eede87c184846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018215151515815260200192505050600060405180830381600087803b1580156200382c57600080fd5b505af115801562003841573d6000803e3d6000fd5b505050507fab2f7f9e5ca2772fafa94f355c1842a80ae6b9e41f83083098d81f67d7a0b5088383604051808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001821515151581526020019250505060405180910390a1505050565b620038c362001906565b62003936576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b62003941816200394c565b50565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415620039d4576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180620066646026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b612bc38062003aa18339019056fe60806040523480156200001157600080fd5b5060405162002bc338038062002bc3833981018060405260e08110156200003757600080fd5b8101908080519060200190929190805190602001909291908051906020019092919080516401000000008111156200006e57600080fd5b828101905060208101848111156200008557600080fd5b8151856001820283011164010000000082111715620000a357600080fd5b50509291906020018051640100000000811115620000c057600080fd5b82810190506020810184811115620000d757600080fd5b8151856001820283011164010000000082111715620000f557600080fd5b5050929190602001805190602001909291908051906020019092919050505083838382600390805190602001906200012f929190620002ea565b50816004908051906020019062000148929190620002ea565b5080600560006101000a81548160ff021916908360ff16021790555050505086600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200021157600080fd5b505afa15801562000226573d6000803e3d6000fd5b505050506040513d60208110156200023d57600080fd5b8101908080519060200190929190505050600960006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508060078190555085600560016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550846006819055505050505050505062000399565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106200032d57805160ff19168380011785556200035e565b828001600101855582156200035e579182015b828111156200035d57825182559160200191906001019062000340565b5b5090506200036d919062000371565b5090565b6200039691905b808211156200039257600081600090555060010162000378565b5090565b90565b61281a80620003a96000396000f3fe608060405234801561001057600080fd5b506004361061014d5760003560e01c806370a08231116100c3578063a9059cbb1161007c578063a9059cbb146106cc578063b32d461014610732578063db006a7514610774578063dd62ed3e146107a2578063e6aa216c1461081a578063f866c319146108385761014d565b806370a08231146104d557806389d1a0fc1461052d57806394362e8b1461057757806395d89b41146105c55780639a32c20714610648578063a457c2d7146106665761014d565b8063313ce56711610115578063313ce5671461032157806339509351146103455780633af9e669146103ab5780633edb7cb8146104035780635eae177c146104515780636d019f35146104b75761014d565b806306fdde0314610152578063095ea7b3146101d55780630ece1a5f1461023b57806318160ddd1461027d57806323b872dd1461029b575b600080fd5b61015a6108a6565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561019a57808201518184015260208101905061017f565b50505050905090810190601f1680156101c75780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b610221600480360360408110156101eb57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610948565b604051808215151515815260200191505060405180910390f35b6102676004803603602081101561025157600080fd5b8101908080359060200190929190505050610966565b6040518082815260200191505060405180910390f35b6102856109e7565b6040518082815260200191505060405180910390f35b610307600480360360608110156102b157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506109f1565b604051808215151515815260200191505060405180910390f35b610329610aca565b604051808260ff1660ff16815260200191505060405180910390f35b6103916004803603604081101561035b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610ae1565b604051808215151515815260200191505060405180910390f35b6103ed600480360360208110156103c157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b94565b6040518082815260200191505060405180910390f35b61044f6004803603604081101561041957600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610bae565b005b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610d50565b604051808215151515815260200191505060405180910390f35b6104bf610f25565b6040518082815260200191505060405180910390f35b610517600480360360208110156104eb57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f2b565b6040518082815260200191505060405180910390f35b610535610f73565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6105c36004803603604081101561058d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610f99565b005b6105cd611141565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561060d5780820151818401526020810190506105f2565b50505050905090810190601f16801561063a5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6106506111e3565b6040518082815260200191505060405180910390f35b6106b26004803603604081101561067c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506111e9565b604051808215151515815260200191505060405180910390f35b610718600480360360408110156106e257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506112b6565b604051808215151515815260200191505060405180910390f35b61075e6004803603602081101561074857600080fd5b81019080803590602001909291905050506112d4565b6040518082815260200191505060405180910390f35b6107a06004803603602081101561078a57600080fd5b8101908080359060200190929190505050611328565b005b610804600480360360408110156107b857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506115c6565b6040518082815260200191505060405180910390f35b61082261164d565b6040518082815260200191505060405180910390f35b6108a46004803603606081101561084e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611769565b005b606060038054600181600116156101000203166002900480601f01602080910402602001604051908101604052809291908181526020018280546001816001161561010002031660029004801561093e5780601f106109135761010080835404028352916020019161093e565b820191906000526020600020905b81548152906001019060200180831161092157829003601f168201915b5050505050905090565b600061095c610955611934565b848461193c565b6001905092915050565b60008082141561097957600090506109e2565b6000610983610aca565b60ff16600a0a90506109de6109d9826109cb600654600a0a6109bd6109a661164d565b6109af8a611b33565b611b5390919063ffffffff16565b611baf90919063ffffffff16565b611c3590919063ffffffff16565b611c7f565b9150505b919050565b6000600254905090565b60006109fe848484611c9f565b610abf84610a0a611934565b610aba8560405180606001604052806028815260200161273860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000610a70611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b61193c565b600190509392505050565b6000600560009054906101000a900460ff16905090565b6000610b8a610aee611934565b84610b858560016000610aff611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b61193c565b6001905092915050565b6000610ba7610ba283610f2b565b610966565b9050919050565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b158015610c1657600080fd5b505afa158015610c2a573d6000803e3d6000fd5b505050506040513d6020811015610c4057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610cd4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b610cde8282611f0c565b8173ffffffffffffffffffffffffffffffffffffffff167f90e5d3d68ec162d9c7de393037a3ede04dd44f68e051bf2ace4a73c299dbc4db82610d2084610966565b610d2986610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a25050565b600080600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f58b80d6040518163ffffffff1660e01b815260040160206040518083038186803b158015610dbb57600080fd5b505afa158015610dcf573d6000803e3d6000fd5b505050506040513d6020811015610de557600080fd5b810190808051906020019092919050505090506000610e0384610966565b90508173ffffffffffffffffffffffffffffffffffffffff166376e9d615600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1687846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001935050505060206040518083038186803b158015610ee057600080fd5b505afa158015610ef4573d6000803e3d6000fd5b505050506040513d6020811015610f0a57600080fd5b81019080805190602001909291905050509250505092915050565b60075481565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561100157600080fd5b505afa158015611015573d6000803e3d6000fd5b505050506040513d602081101561102b57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146110bf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b60006110ca826112d4565b90506110d683826120c4565b8273ffffffffffffffffffffffffffffffffffffffff167fbe7799898ca2d813ff902b487c1b434ab45b47edd8f38b77ad5e99aae8341b7a828461111987610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a2505050565b606060048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156111d95780601f106111ae576101008083540402835291602001916111d9565b820191906000526020600020905b8154815290600101906020018083116111bc57829003601f168201915b5050505050905090565b60065481565b60006112ac6111f6611934565b846112a7856040518060600160405280602581526020016127ca6025913960016000611220611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b61193c565b6001905092915050565b60006112ca6112c3611934565b8484611c9f565b6001905092915050565b6000808214156112e75760009050611323565b61132061131b600654600a0a61130d6112fe61164d565b86611baf90919063ffffffff16565b611c3590919063ffffffff16565b611c7f565b90505b919050565b33816113348282610d50565b6113a6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f5472616e736665722063616e6e6f7420626520616c6c6f7765642e000000000081525060200191505060405180910390fd5b60006113b184610966565b90506113bd338561227f565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561142757600080fd5b505afa15801561143b573d6000803e3d6000fd5b505050506040513d602081101561145157600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663935642cf600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633856040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561154157600080fd5b505af1158015611555573d6000803e3d6000fd5b505050503373ffffffffffffffffffffffffffffffffffffffff167fbd5034ffbd47e4e72a94baa2cdb74c6fad73cb3bcdc13036b72ec8306f5a7646868461159c33610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a25050505050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600080600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d15e0053600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff166040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561171157600080fd5b505afa158015611725573d6000803e3d6000fd5b505050506040513d602081101561173b57600080fd5b8101908080519060200190929190505050905061176381600754611b5390919063ffffffff16565b91505090565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156117d157600080fd5b505afa1580156117e5573d6000803e3d6000fd5b505050506040513d60208110156117fb57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461188f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b61189a83838361228d565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f2c335084544f8f7476a1c2e460962cd7e50d03d52a940d3d09e6f25894c75df3836118f385610966565b6118fc88610f2b565b61190588610f2b565b6040518085815260200184815260200183815260200182815260200194505050505060405180910390a3505050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156119c2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806127a66024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611a48576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806126996022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b6000611b4c633b9aca0083611baf90919063ffffffff16565b9050919050565b60008060028381611b6057fe5b049050611ba683611b98611b896b033b2e3c9fd0803ce800000088611baf90919063ffffffff16565b84611e8490919063ffffffff16565b611c3590919063ffffffff16565b91505092915050565b600080831415611bc25760009050611c2f565b6000828402905082848281611bd357fe5b0414611c2a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806126e16021913960400191505060405180910390fd5b809150505b92915050565b6000611c7783836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612543565b905092915050565b6000611c98633b9aca0083611c3590919063ffffffff16565b9050919050565b8281611cab8282610d50565b611d1d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f5472616e736665722063616e6e6f7420626520616c6c6f7765642e000000000081525060200191505060405180910390fd5b611d2885858561228d565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fbf553f39591e51c9524a30865d4a5590424976ba75d2046a6c7ce15d6321b62485611d8187610966565b611d8a8a610f2b565b611d938a610f2b565b6040518085815260200184815260200183815260200182815260200194505050505060405180910390a35050505050565b6000838311158290611e71576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611e36578082015181840152602081019050611e1b565b50505050905090810190601f168015611e635780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015611f02576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611f92576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806127606021913960400191505060405180910390fd5b611ffd81604051806060016040528060228152602001612677602291396000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506120548160025461260990919063ffffffff16565b600281905550600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612167576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b61217c81600254611e8490919063ffffffff16565b6002819055506121d3816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b6122898282611f0c565b5050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415612313576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806127816025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612399576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806126546023913960400191505060405180910390fd5b612404816040518060600160405280602681526020016126bb602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550612497816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b600080831182906125ef576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156125b4578082015181840152602081019050612599565b50505050905090810190601f1680156125e15780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816125fb57fe5b049050809150509392505050565b600061264b83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611dc4565b90509291505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e6365536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f775468652063616c6c6572206f6620746869732066756e6374696f6e2063616e206f6e6c792062652061206c656e64696e6720706f6f6c45524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058204a0bed3ae55c5673e00e38acc740d939f148a1b9c8a8f608b3b3212a756b939800294f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573735468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c206d616e61676572a165627a7a72305820a202c6e9d935e8f08041e242ce25c0fedfbd7ec22255bef08bbd56a1b49ca1660029", + "deployedBytecode": "0x60806040523480156200001157600080fd5b5060043610620001545760003560e01c8063a17166f111620000c9578063d466016f1162000087578063d466016f1462000712578063d7e075811462000763578063e12dcc6c14620007aa578063e8ae2f5b14620007b6578063eede87c114620007fd578063f2fde38b14620008505762000154565b8063a17166f1146200043d578063a8dc0f4514620005ec578063a9ef33e91462000633578063b46a4b34146200067a578063b75d6f3414620006cb5762000154565b8063715018a61162000117578063715018a6146200032e57806380e17d87146200033a5780638da5cb5b14620003865780638f32d59b14620003d25780639789b68a14620003f65762000154565b80631d2118f9146200015957806329a1786814620001c05780633443a14b146200021b5780633e72a454146200026c5780635f674c8714620002b3575b600080fd5b620001be600480360360408110156200017157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062000897565b005b6200021960048036036060811015620001d857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291908035906020019092919050505062000b3e565b005b6200026a600480360360408110156200023357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505062000e18565b005b620002b1600480360360208110156200028457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062001093565b005b6200032c60048036036080811015620002cb57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062001348565b005b620003386200177b565b005b62000344620018b7565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b62000390620018dd565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b620003dc62001906565b604051808215151515815260200191505060405180910390f35b6200043b600480360360208110156200040e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062001966565b005b620005ea600480360360c08110156200045557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001906401000000008111156200049357600080fd5b820183602082011115620004a657600080fd5b80359060200191846001830284011164010000000083111715620004c957600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f820116905080830192505050505050509192919290803590602001906401000000008111156200052d57600080fd5b8201836020820111156200054057600080fd5b803590602001918460018302840111640100000000831117156200056357600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600081840152601f19601f8201169050808301925050505050505091929192908035906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062001c1b565b005b62000631600480360360208110156200060457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062002155565b005b62000678600480360360208110156200064b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506200240a565b005b620006c9600480360360408110156200069257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506200267c565b005b6200071060048036036020811015620006e357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050620028f7565b005b62000761600480360360408110156200072a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505062002bac565b005b620007a8600480360360208110156200077b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062002e27565b005b620007b4620030dc565b005b620007fb60048036036020811015620007ce57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505062003316565b005b6200084e600480360360408110156200081557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803515159060200190929190505050620035cb565b005b62000895600480360360208110156200086857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050620038b9565b005b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200091757600080fd5b505afa1580156200092c573d6000803e3d6000fd5b505050506040513d60208110156200094357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614620009c2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562000a2d57600080fd5b505afa15801562000a42573d6000803e3d6000fd5b505050506040513d602081101562000a5957600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16631d2118f984846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801562000b2057600080fd5b505af115801562000b35573d6000803e3d6000fd5b50505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b15801562000bbe57600080fd5b505afa15801562000bd3573d6000803e3d6000fd5b505050506040513d602081101562000bea57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462000c69576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562000cd457600080fd5b505afa15801562000ce9573d6000803e3d6000fd5b505050506040513d602081101562000d0057600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff166329a178688585856040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b15801562000da357600080fd5b505af115801562000db8573d6000803e3d6000fd5b505050508373ffffffffffffffffffffffffffffffffffffffff167f0b2f4ddd80e34a38c71a6c5f953a99dc8b45c79b8c563d301c2bb2267b9dbc348484604051808381526020018281526020019250505060405180910390a250505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b15801562000e9857600080fd5b505afa15801562000ead573d6000803e3d6000fd5b505050506040513d602081101562000ec457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462000f43576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562000fae57600080fd5b505afa15801562000fc3573d6000803e3d6000fd5b505050506040513d602081101562000fda57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16633443a14b84846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156200107557600080fd5b505af11580156200108a573d6000803e3d6000fd5b50505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200111357600080fd5b505afa15801562001128573d6000803e3d6000fd5b505050506040513d60208110156200113f57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614620011be576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200122957600080fd5b505afa1580156200123e573d6000803e3d6000fd5b505050506040513d60208110156200125557600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16633e72a454836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b158015620012e857600080fd5b505af1158015620012fd573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167f6f60cf8bd0f218cabe1ea3150bd07b0b758c35c4cfdf7138017a283e65564d5e60405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b158015620013c857600080fd5b505afa158015620013dd573d6000803e3d6000fd5b505050506040513d6020811015620013f457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462001473576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b600084905060608173ffffffffffffffffffffffffffffffffffffffff166306fdde036040518163ffffffff1660e01b815260040160006040518083038186803b158015620014c157600080fd5b505afa158015620014d6573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f8201168201806040525060208110156200150157600080fd5b8101908080516401000000008111156200151a57600080fd5b828101905060208101848111156200153157600080fd5b81518560018202830111640100000000821117156200154f57600080fd5b505092919050505060405160200180807f4161766520496e7465726573742062656172696e67200000000000000000000081525060160182805190602001908083835b60208310620015b7578051825260208201915060208101905060208303925062001592565b6001836020036101000a038019825116818451168082178552505050505050905001915050604051602081830303815290604052905060608273ffffffffffffffffffffffffffffffffffffffff166395d89b416040518163ffffffff1660e01b815260040160006040518083038186803b1580156200163657600080fd5b505afa1580156200164b573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f8201168201806040525060208110156200167657600080fd5b8101908080516401000000008111156200168f57600080fd5b82810190506020810184811115620016a657600080fd5b8151856001820283011164010000000082111715620016c457600080fd5b505092919050505060405160200180807f610000000000000000000000000000000000000000000000000000000000000081525060010182805190602001908083835b602083106200172c578051825260208201915060208101905060208303925062001707565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405160208183030381529060405290506200177287838389898962001c1b565b50505050505050565b6200178562001906565b620017f8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166200194a62003944565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b158015620019e657600080fd5b505afa158015620019fb573d6000803e3d6000fd5b505050506040513d602081101562001a1257600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462001a91576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562001afc57600080fd5b505afa15801562001b11573d6000803e3d6000fd5b505050506040513d602081101562001b2857600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16639789b68a836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801562001bbb57600080fd5b505af115801562001bd0573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167f3785f652b18f48a8a4c505037390f85f5b89bfe105384b964138f8a947ae89c660405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b15801562001c9b57600080fd5b505afa15801562001cb0573d6000803e3d6000fd5b505050506040513d602081101562001cc757600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462001d46576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562001db157600080fd5b505afa15801562001dc6573d6000803e3d6000fd5b505050506040513d602081101562001ddd57600080fd5b810190808051906020019092919050505090506000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff168885898960128a60405162001e2a9062003a92565b808873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200186815260200180602001806020018560ff168152602001848152602001838103835287818151815260200191508051906020019080838360005b8381101562001ee657808201518184015260208101905062001ec9565b50505050905090810190601f16801562001f145780820380516001836020036101000a031916815260200191505b50838103825286818151815260200191508051906020019080838360005b8381101562001f4f57808201518184015260208101905062001f32565b50505050905090810190601f16801562001f7d5780820380516001836020036101000a031916815260200191505b509950505050505050505050604051809103906000f08015801562001fa6573d6000803e3d6000fd5b5090508173ffffffffffffffffffffffffffffffffffffffff166345330a40898387876040518563ffffffff1660e01b8152600401808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050600060405180830381600087803b1580156200209957600080fd5b505af1158015620020ae573d6000803e3d6000fd5b505050508073ffffffffffffffffffffffffffffffffffffffff168873ffffffffffffffffffffffffffffffffffffffff167f9c6373c8d8364b6e1acd1bcb5895e6aee73dc8128782869914d27d7e54a938988786604051808381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060405180910390a35050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b158015620021d557600080fd5b505afa158015620021ea573d6000803e3d6000fd5b505050506040513d60208110156200220157600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462002280576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b158015620022eb57600080fd5b505afa15801562002300573d6000803e3d6000fd5b505050506040513d60208110156200231757600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663a8dc0f45836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b158015620023aa57600080fd5b505af1158015620023bf573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167fe9a7e5fd4fc8ea18e602350324bf48e8f05d12434af0ce0be05743e6a5fdcb9e60405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200248a57600080fd5b505afa1580156200249f573d6000803e3d6000fd5b505050506040513d6020811015620024b657600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462002535576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b158015620025a057600080fd5b505afa158015620025b5573d6000803e3d6000fd5b505050506040513d6020811015620025cc57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16636722997a836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156200265f57600080fd5b505af115801562002674573d6000803e3d6000fd5b505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b158015620026fc57600080fd5b505afa15801562002711573d6000803e3d6000fd5b505050506040513d60208110156200272857600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614620027a7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200281257600080fd5b505afa15801562002827573d6000803e3d6000fd5b505050506040513d60208110156200283e57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663b46a4b3484846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015620028d957600080fd5b505af1158015620028ee573d6000803e3d6000fd5b50505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200297757600080fd5b505afa1580156200298c573d6000803e3d6000fd5b505050506040513d6020811015620029a357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462002a22576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562002a8d57600080fd5b505afa15801562002aa2573d6000803e3d6000fd5b505050506040513d602081101562002ab957600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663b75d6f34836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801562002b4c57600080fd5b505af115801562002b61573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167f35b80cd8ea3440e9a8454f116fa658b858da1b64c86c48451f4559cefcdfb56c60405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b15801562002c2c57600080fd5b505afa15801562002c41573d6000803e3d6000fd5b505050506040513d602081101562002c5857600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462002cd7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562002d4257600080fd5b505afa15801562002d57573d6000803e3d6000fd5b505050506040513d602081101562002d6e57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663d466016f84846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b15801562002e0957600080fd5b505af115801562002e1e573d6000803e3d6000fd5b50505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b15801562002ea757600080fd5b505afa15801562002ebc573d6000803e3d6000fd5b505050506040513d602081101562002ed357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462002f52576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801562002fbd57600080fd5b505afa15801562002fd2573d6000803e3d6000fd5b505050506040513d602081101562002fe957600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663d7e07581836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156200307c57600080fd5b505af115801562003091573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167fd4fb373808cfe3d293bd3d3826c216194001d776dff64c75ae047dfda7f564de60405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200315c57600080fd5b505afa15801562003171573d6000803e3d6000fd5b505050506040513d60208110156200318857600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462003207576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200327257600080fd5b505afa15801562003287573d6000803e3d6000fd5b505050506040513d60208110156200329e57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663646810836040518163ffffffff1660e01b8152600401600060405180830381600087803b158015620032fa57600080fd5b505af11580156200330f573d6000803e3d6000fd5b5050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200339657600080fd5b505afa158015620033ab573d6000803e3d6000fd5b505050506040513d6020811015620033c257600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161462003441576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b158015620034ac57600080fd5b505afa158015620034c1573d6000803e3d6000fd5b505050506040513d6020811015620034d857600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663e8ae2f5b836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b1580156200356b57600080fd5b505af115801562003580573d6000803e3d6000fd5b505050508173ffffffffffffffffffffffffffffffffffffffff167f9cc75e4cafc9a556a369bc53468649075680eb554d225d5918f199453824796d60405160405180910390a25050565b3373ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166333128d596040518163ffffffff1660e01b815260040160206040518083038186803b1580156200364b57600080fd5b505afa15801562003660573d6000803e3d6000fd5b505050506040513d60208110156200367757600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614620036f6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260298152602001806200668a6029913960400191505060405180910390fd5b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200376157600080fd5b505afa15801562003776573d6000803e3d6000fd5b505050506040513d60208110156200378d57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663eede87c184846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018215151515815260200192505050600060405180830381600087803b1580156200382c57600080fd5b505af115801562003841573d6000803e3d6000fd5b505050507fab2f7f9e5ca2772fafa94f355c1842a80ae6b9e41f83083098d81f67d7a0b5088383604051808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001821515151581526020019250505060405180910390a1505050565b620038c362001906565b62003936576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b62003941816200394c565b50565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415620039d4576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180620066646026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b612bc38062003aa18339019056fe60806040523480156200001157600080fd5b5060405162002bc338038062002bc3833981018060405260e08110156200003757600080fd5b8101908080519060200190929190805190602001909291908051906020019092919080516401000000008111156200006e57600080fd5b828101905060208101848111156200008557600080fd5b8151856001820283011164010000000082111715620000a357600080fd5b50509291906020018051640100000000811115620000c057600080fd5b82810190506020810184811115620000d757600080fd5b8151856001820283011164010000000082111715620000f557600080fd5b5050929190602001805190602001909291908051906020019092919050505083838382600390805190602001906200012f929190620002ea565b50816004908051906020019062000148929190620002ea565b5080600560006101000a81548160ff021916908360ff16021790555050505086600860006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200021157600080fd5b505afa15801562000226573d6000803e3d6000fd5b505050506040513d60208110156200023d57600080fd5b8101908080519060200190929190505050600960006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508060078190555085600560016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550846006819055505050505050505062000399565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f106200032d57805160ff19168380011785556200035e565b828001600101855582156200035e579182015b828111156200035d57825182559160200191906001019062000340565b5b5090506200036d919062000371565b5090565b6200039691905b808211156200039257600081600090555060010162000378565b5090565b90565b61281a80620003a96000396000f3fe608060405234801561001057600080fd5b506004361061014d5760003560e01c806370a08231116100c3578063a9059cbb1161007c578063a9059cbb146106cc578063b32d461014610732578063db006a7514610774578063dd62ed3e146107a2578063e6aa216c1461081a578063f866c319146108385761014d565b806370a08231146104d557806389d1a0fc1461052d57806394362e8b1461057757806395d89b41146105c55780639a32c20714610648578063a457c2d7146106665761014d565b8063313ce56711610115578063313ce5671461032157806339509351146103455780633af9e669146103ab5780633edb7cb8146104035780635eae177c146104515780636d019f35146104b75761014d565b806306fdde0314610152578063095ea7b3146101d55780630ece1a5f1461023b57806318160ddd1461027d57806323b872dd1461029b575b600080fd5b61015a6108a6565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561019a57808201518184015260208101905061017f565b50505050905090810190601f1680156101c75780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b610221600480360360408110156101eb57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610948565b604051808215151515815260200191505060405180910390f35b6102676004803603602081101561025157600080fd5b8101908080359060200190929190505050610966565b6040518082815260200191505060405180910390f35b6102856109e7565b6040518082815260200191505060405180910390f35b610307600480360360608110156102b157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506109f1565b604051808215151515815260200191505060405180910390f35b610329610aca565b604051808260ff1660ff16815260200191505060405180910390f35b6103916004803603604081101561035b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610ae1565b604051808215151515815260200191505060405180910390f35b6103ed600480360360208110156103c157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610b94565b6040518082815260200191505060405180910390f35b61044f6004803603604081101561041957600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610bae565b005b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610d50565b604051808215151515815260200191505060405180910390f35b6104bf610f25565b6040518082815260200191505060405180910390f35b610517600480360360208110156104eb57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610f2b565b6040518082815260200191505060405180910390f35b610535610f73565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6105c36004803603604081101561058d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610f99565b005b6105cd611141565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561060d5780820151818401526020810190506105f2565b50505050905090810190601f16801561063a5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6106506111e3565b6040518082815260200191505060405180910390f35b6106b26004803603604081101561067c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506111e9565b604051808215151515815260200191505060405180910390f35b610718600480360360408110156106e257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506112b6565b604051808215151515815260200191505060405180910390f35b61075e6004803603602081101561074857600080fd5b81019080803590602001909291905050506112d4565b6040518082815260200191505060405180910390f35b6107a06004803603602081101561078a57600080fd5b8101908080359060200190929190505050611328565b005b610804600480360360408110156107b857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506115c6565b6040518082815260200191505060405180910390f35b61082261164d565b6040518082815260200191505060405180910390f35b6108a46004803603606081101561084e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050611769565b005b606060038054600181600116156101000203166002900480601f01602080910402602001604051908101604052809291908181526020018280546001816001161561010002031660029004801561093e5780601f106109135761010080835404028352916020019161093e565b820191906000526020600020905b81548152906001019060200180831161092157829003601f168201915b5050505050905090565b600061095c610955611934565b848461193c565b6001905092915050565b60008082141561097957600090506109e2565b6000610983610aca565b60ff16600a0a90506109de6109d9826109cb600654600a0a6109bd6109a661164d565b6109af8a611b33565b611b5390919063ffffffff16565b611baf90919063ffffffff16565b611c3590919063ffffffff16565b611c7f565b9150505b919050565b6000600254905090565b60006109fe848484611c9f565b610abf84610a0a611934565b610aba8560405180606001604052806028815260200161273860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000610a70611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b61193c565b600190509392505050565b6000600560009054906101000a900460ff16905090565b6000610b8a610aee611934565b84610b858560016000610aff611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b61193c565b6001905092915050565b6000610ba7610ba283610f2b565b610966565b9050919050565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b158015610c1657600080fd5b505afa158015610c2a573d6000803e3d6000fd5b505050506040513d6020811015610c4057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610cd4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b610cde8282611f0c565b8173ffffffffffffffffffffffffffffffffffffffff167f90e5d3d68ec162d9c7de393037a3ede04dd44f68e051bf2ace4a73c299dbc4db82610d2084610966565b610d2986610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a25050565b600080600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632f58b80d6040518163ffffffff1660e01b815260040160206040518083038186803b158015610dbb57600080fd5b505afa158015610dcf573d6000803e3d6000fd5b505050506040513d6020811015610de557600080fd5b810190808051906020019092919050505090506000610e0384610966565b90508173ffffffffffffffffffffffffffffffffffffffff166376e9d615600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1687846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001828152602001935050505060206040518083038186803b158015610ee057600080fd5b505afa158015610ef4573d6000803e3d6000fd5b505050506040513d6020811015610f0a57600080fd5b81019080805190602001909291905050509250505092915050565b60075481565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561100157600080fd5b505afa158015611015573d6000803e3d6000fd5b505050506040513d602081101561102b57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146110bf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b60006110ca826112d4565b90506110d683826120c4565b8273ffffffffffffffffffffffffffffffffffffffff167fbe7799898ca2d813ff902b487c1b434ab45b47edd8f38b77ad5e99aae8341b7a828461111987610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a2505050565b606060048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156111d95780601f106111ae576101008083540402835291602001916111d9565b820191906000526020600020905b8154815290600101906020018083116111bc57829003601f168201915b5050505050905090565b60065481565b60006112ac6111f6611934565b846112a7856040518060600160405280602581526020016127ca6025913960016000611220611934565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b61193c565b6001905092915050565b60006112ca6112c3611934565b8484611c9f565b6001905092915050565b6000808214156112e75760009050611323565b61132061131b600654600a0a61130d6112fe61164d565b86611baf90919063ffffffff16565b611c3590919063ffffffff16565b611c7f565b90505b919050565b33816113348282610d50565b6113a6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f5472616e736665722063616e6e6f7420626520616c6c6f7765642e000000000081525060200191505060405180910390fd5b60006113b184610966565b90506113bd338561227f565b6000600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b15801561142757600080fd5b505afa15801561143b573d6000803e3d6000fd5b505050506040513d602081101561145157600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff1663935642cf600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633856040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561154157600080fd5b505af1158015611555573d6000803e3d6000fd5b505050503373ffffffffffffffffffffffffffffffffffffffff167fbd5034ffbd47e4e72a94baa2cdb74c6fad73cb3bcdc13036b72ec8306f5a7646868461159c33610f2b565b60405180848152602001838152602001828152602001935050505060405180910390a25050505050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600080600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663d15e0053600560019054906101000a900473ffffffffffffffffffffffffffffffffffffffff166040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561171157600080fd5b505afa158015611725573d6000803e3d6000fd5b505050506040513d602081101561173b57600080fd5b8101908080519060200190929190505050905061176381600754611b5390919063ffffffff16565b91505090565b600860009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156117d157600080fd5b505afa1580156117e5573d6000803e3d6000fd5b505050506040513d60208110156117fb57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461188f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806127026036913960400191505060405180910390fd5b61189a83838361228d565b8173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f2c335084544f8f7476a1c2e460962cd7e50d03d52a940d3d09e6f25894c75df3836118f385610966565b6118fc88610f2b565b61190588610f2b565b6040518085815260200184815260200183815260200182815260200194505050505060405180910390a3505050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156119c2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806127a66024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611a48576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806126996022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b6000611b4c633b9aca0083611baf90919063ffffffff16565b9050919050565b60008060028381611b6057fe5b049050611ba683611b98611b896b033b2e3c9fd0803ce800000088611baf90919063ffffffff16565b84611e8490919063ffffffff16565b611c3590919063ffffffff16565b91505092915050565b600080831415611bc25760009050611c2f565b6000828402905082848281611bd357fe5b0414611c2a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806126e16021913960400191505060405180910390fd5b809150505b92915050565b6000611c7783836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250612543565b905092915050565b6000611c98633b9aca0083611c3590919063ffffffff16565b9050919050565b8281611cab8282610d50565b611d1d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f5472616e736665722063616e6e6f7420626520616c6c6f7765642e000000000081525060200191505060405180910390fd5b611d2885858561228d565b8373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fbf553f39591e51c9524a30865d4a5590424976ba75d2046a6c7ce15d6321b62485611d8187610966565b611d8a8a610f2b565b611d938a610f2b565b6040518085815260200184815260200183815260200182815260200194505050505060405180910390a35050505050565b6000838311158290611e71576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611e36578082015181840152602081019050611e1b565b50505050905090810190601f168015611e635780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015611f02576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611f92576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806127606021913960400191505060405180910390fd5b611ffd81604051806060016040528060228152602001612677602291396000808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506120548160025461260990919063ffffffff16565b600281905550600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612167576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b61217c81600254611e8490919063ffffffff16565b6002819055506121d3816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a35050565b6122898282611f0c565b5050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415612313576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806127816025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415612399576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806126546023913960400191505060405180910390fd5b612404816040518060600160405280602681526020016126bb602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611dc49092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550612497816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054611e8490919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b600080831182906125ef576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156125b4578082015181840152602081019050612599565b50505050905090810190601f1680156125e15780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816125fb57fe5b049050809150509392505050565b600061264b83836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250611dc4565b90509291505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a206275726e20616d6f756e7420657863656564732062616c616e636545524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e6365536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f775468652063616c6c6572206f6620746869732066756e6374696f6e2063616e206f6e6c792062652061206c656e64696e6720706f6f6c45524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a206275726e2066726f6d20746865207a65726f206164647265737345524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058204a0bed3ae55c5673e00e38acc740d939f148a1b9c8a8f608b3b3212a756b939800294f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573735468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c206d616e61676572a165627a7a72305820a202c6e9d935e8f08041e242ce25c0fedfbd7ec22255bef08bbd56a1b49ca1660029", + "sourceMap": "808:7919:24:-;;;2033:147;8:9:-1;5:2;;;30:1;27;20:12;5:2;2033:147:24;;;;;;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2033:147:24;;;;;;;;;;;;;;;;707:12:57;:10;;;:12;;:::i;:::-;698:6;;:21;;;;;;;;;;;;;;;;;;767:6;;;;;;;;;;;734:40;;763:1;734:40;;;;;;;;;;;;2151:22:24;2127:21;;:46;;;;;;;;;;;;;;;;;;2033:147;808:7919;;788:96:55;833:15;867:10;860:17;;788:96;:::o;808:7919:24:-;;;;;;;", + "deployedSourceMap": "808:7919:24:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;808:7919:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7946:311;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;7946:311:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;4933:456;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4933:456:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;7343:296;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;7343:296:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;6644:262;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6644:262:24;;;;;;;;;;;;;;;;;;;:::i;:::-;;2323:704;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;2323:704:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;1642:137:57;;;:::i;:::-;;1669:57:24;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;857:77:57;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1208:92;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;5785:291:24;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5785:291:24;;;;;;;;;;;;;;;;;;;:::i;:::-;;3165:907;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;3165:907:24;;;;;;;;;;;;;;;;;;;;;21:11:-1;8;5:28;2:2;;;46:1;43;36:12;2:2;3165:907:24;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;3165:907:24;;;;;;100:9:-1;95:1;81:12;77:20;67:8;63:35;60:50;39:11;25:12;22:29;11:107;8:2;;;131:1;128;121:12;8:2;3165:907:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30:3:-1;22:6;14;1:33;99:1;93:3;85:6;81:16;74:27;137:4;133:9;126:4;121:3;117:14;113:30;106:37;;169:3;161:6;157:16;147:26;;3165:907:24;;;;;;;;;;;;;;;;;21:11:-1;8;5:28;2:2;;;46:1;43;36:12;2:2;3165:907:24;;35:9:-1;28:4;12:14;8:25;5:40;2:2;;;58:1;55;48:12;2:2;3165:907:24;;;;;;100:9:-1;95:1;81:12;77:20;67:8;63:35;60:50;39:11;25:12;22:29;11:107;8:2;;;131:1;128;121:12;8:2;3165:907:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30:3:-1;22:6;14;1:33;99:1;93:3;85:6;81:16;74:27;137:4;133:9;126:4;121:3;117:14;113:30;106:37;;169:3;161:6;157:16;147:26;;3165:907:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;4547:286;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4547:286:24;;;;;;;;;;;;;;;;;;;:::i;:::-;;8263:241;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8263:241:24;;;;;;;;;;;;;;;;;;;:::i;:::-;;7645:294;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;7645:294:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;6382:256;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6382:256:24;;;;;;;;;;;;;;;;;;;:::i;:::-;;7075:262;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;7075:262:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;6082:294;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6082:294:24;;;;;;;;;;;;;;;;;;;:::i;:::-;;8510:215;;;:::i;:::-;;5395:289;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5395:289:24;;;;;;;;;;;;;;;;;;;:::i;:::-;;4157:384;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4157:384:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;1928:107:57;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1928:107:57;;;;;;;;;;;;;;;;;;;:::i;:::-;;7946:311:24;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8084:20;8123:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8123:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8123:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8123:42:24;;;;;;;;;;;;;;;;8084:82;;8176:4;:42;;;8219:8;8229:20;8176:74;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8176:74:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8176:74:24;;;;2019:1;7946:311;;:::o;4933:456::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5109:20;5148:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5148:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5148:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5148:42:24;;;;;;;;;;;;;;;;5109:82;;5201:4;:30;;;5232:8;5242:20;5264:21;5201:85;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5201:85:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5201:85:24;;;;5328:8;5301:81;;;5338:20;5360:21;5301:81;;;;;;;;;;;;;;;;;;;;;;;;2019:1;4933:456;;;:::o;7343:296::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7483:20;7522:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7522:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7522:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;7522:42:24;;;;;;;;;;;;;;;;7483:82;;7575:4;:35;;;7611:8;7621:10;7575:57;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7575:57:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7575:57:24;;;;2019:1;7343:296;;:::o;6644:262::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6731:20;6770:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6770:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6770:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6770:42:24;;;;;;;;;;;;;;;;6731:82;;6823:4;:22;;;6846:8;6823:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6823:32:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6823:32:24;;;;6890:8;6871:28;;;;;;;;;;;;2019:1;6644:262;:::o;2323:704::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2565:19;2601:8;2565:45;;2621:24;2698:5;:10;;;:12;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2698:12:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2698:12:24;;;;;;39:16:-1;36:1;17:17;2:54;2698:12:24;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;13:2;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2698:12:24;;;;;;19:11:-1;14:3;11:20;8:2;;;44:1;41;34:12;8:2;71:11;66:3;62:21;55:28;;123:4;118:3;114:14;159:9;141:16;138:31;135:2;;;182:1;179;172:12;135:2;219:3;213:10;330:9;325:1;311:12;307:20;289:16;285:43;282:58;261:11;247:12;244:29;233:115;230:2;;;361:1;358;351:12;230:2;0:372;;2698:12:24;;;;;;2655:56;;;;;;;;;;;;;;;;;;;;;;36:153:-1;66:2;61:3;58:11;36:153;;182:3;176:10;171:3;164:23;98:2;93:3;89:12;82:19;;123:2;118:3;114:12;107:19;;148:2;143:3;139:12;132:19;;36:153;;;274:1;267:3;263:2;259:12;254:3;250:22;246:30;315:4;311:9;305:3;299:10;295:26;356:4;350:3;344:10;340:21;389:7;380;377:20;372:3;365:33;3:399;;;2655:56:24;;;;;;;;;;;49:4:-1;39:7;30;26:21;22:32;13:7;6:49;2655:56:24;;;2621:91;;2722:26;2780:5;:12;;;:14;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2780:14:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2780:14:24;;;;;;39:16:-1;36:1;17:17;2:54;2780:14:24;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;13:2;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2780:14:24;;;;;;19:11:-1;14:3;11:20;8:2;;;44:1;41;34:12;8:2;71:11;66:3;62:21;55:28;;123:4;118:3;114:14;159:9;141:16;138:31;135:2;;;182:1;179;172:12;135:2;219:3;213:10;330:9;325:1;311:12;307:20;289:16;285:43;282:58;261:11;247:12;244:29;233:115;230:2;;;361:1;358;351:12;230:2;0:372;;2780:14:24;;;;;;2758:37;;;;;;;;;;;;;;;;;;;;;;36:153:-1;66:2;61:3;58:11;36:153;;182:3;176:10;171:3;164:23;98:2;93:3;89:12;82:19;;123:2;118:3;114:12;107:19;;148:2;143:3;139:12;132:19;;36:153;;;274:1;267:3;263:2;259:12;254:3;250:22;246:30;315:4;311:9;305:3;299:10;295:26;356:4;350:3;344:10;340:21;389:7;380;377:20;372:3;365:33;3:399;;;2758:37:24;;;;;;;;;;;49:4:-1;39:7;30;26:21;22:32;13:7;6:49;2758:37:24;;;2722:74;;2807:212;2840:8;2862:10;2886:12;2912:26;2952:24;2990:28;2807:19;:212::i;:::-;2019:1;;;2323:704;;;;:::o;1642:137:57:-;1061:9;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1740:1;1703:40;;1724:6;;;;;;;;;;;1703:40;;;;;;;;;;;;1770:1;1753:6;;:19;;;;;;;;;;;;;;;;;;1642:137::o;1669:57:24:-;;;;;;;;;;;;;:::o;857:77:57:-;895:7;921:6;;;;;;;;;;;914:13;;857:77;:::o;1208:92::-;1248:4;1287:6;;;;;;;;;;;1271:22;;:12;:10;:12::i;:::-;:22;;;1264:29;;1208:92;:::o;5785:291:24:-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5883:20;5922:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5922:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5922:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5922:42:24;;;;;;;;;;;;;;;;5883:82;;5975:4;:33;;;6009:8;5975:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5975:43:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5975:43:24;;;;6060:8;6034:35;;;;;;;;;;;;2019:1;5785:291;:::o;3165:907::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3483:20;3522:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3522:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3522:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3522:42:24;;;;;;;;;;;;;;;;3483:82;;3576:21;3624;;;;;;;;;;;3659:8;3681:24;3719:10;3743:12;3769:2;3785:26;3600:221;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;3600:221:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;3600:221:24;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3600:221:24;3576:245;;3831:4;:16;;;3848:8;3866:14;3883:24;3909:28;3831:107;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3831:107:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3831:107:24;;;;3991:14;3954:111;;3973:8;3954:111;;;4008:26;4036:28;3954:111;;;;;;;;;;;;;;;;;;;;;;;;;;;;2019:1;;3165:907;;;;;;:::o;4547:286::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4642:20;4681:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4681:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4681:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4681:42:24;;;;;;;;;;;;;;;;4642:82;;4734:4;:30;;;4765:8;4734:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4734:40:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4734:40:24;;;;4817:8;4790:36;;;;;;;;;;;;2019:1;4547:286;:::o;8263:241::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8369:20;8408:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8408:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8408:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8408:42:24;;;;;;;;;;;;;;;;8369:82;;8461:4;:25;;;8487:9;8461:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8461:36:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8461:36:24;;;;2019:1;8263:241;:::o;7645:294::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7784:20;7823:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7823:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7823:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;7823:42:24;;;;;;;;;;;;;;;;7784:82;;7876:4;:34;;;7911:8;7921:10;7876:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7876:56:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7876:56:24;;;;2019:1;7645:294;;:::o;6382:256::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6467:20;6506:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6506:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6506:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6506:42:24;;;;;;;;;;;;;;;;6467:82;;6559:4;:20;;;6580:8;6559:30;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6559:30:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6559:30:24;;;;6622:8;6605:26;;;;;;;;;;;;2019:1;6382:256;:::o;7075:262::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7188:20;7227:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7227:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7227:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;7227:42:24;;;;;;;;;;;;;;;;7188:82;;7280:4;:34;;;7315:8;7325:4;7280:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7280:50:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7280:50:24;;;;2019:1;7075:262;;:::o;6082:294::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6181:20;6220:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6220:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6220:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6220:42:24;;;;;;;;;;;;;;;;6181:82;;6273:4;:34;;;6308:8;6273:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6273:44:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6273:44:24;;;;6360:8;6333:36;;;;;;;;;;;;2019:1;6082:294;:::o;8510:215::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8599:20;8638:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8638:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8638:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8638:42:24;;;;;;;;;;;;;;;;8599:82;;8691:4;:25;;;:27;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8691:27:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8691:27:24;;;;2019:1;8510:215::o;5395:289::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5491:20;5530:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5530:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5530:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5530:42:24;;;;;;;;;;;;;;;;5491:82;;5583:4;:31;;;5615:8;5583:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5583:41:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5583:41:24;;;;5668:8;5640:37;;;;;;;;;;;;2019:1;5395:289;:::o;4157:384::-;1932:10;1883:59;;:21;;;;;;;;;;;:43;;;:45;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1883:45:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1883:45:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1883:45:24;;;;;;;;;;;;;;;;:59;;;1862:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4303:20;4342:21;;;;;;;;;;;:40;;;:42;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4342:42:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4342:42:24;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4342:42:24;;;;;;;;;;;;;;;;4303:82;;4395:4;:29;;;4425:8;4435:23;4395:64;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4395:64:24;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4395:64:24;;;;4474:60;4500:8;4510:23;4474:60;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2019:1;4157:384;;:::o;1928:107:57:-;1061:9;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2000:28;2019:8;2000:18;:28::i;:::-;1928:107;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;2136:225:57:-;2229:1;2209:22;;:8;:22;;;;2201:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2318:8;2289:38;;2310:6;;;;;;;;;;;2289:38;;;;;;;;;;;;2346:8;2337:6;;:17;;;;;;;;;;;;;;;;;;2136:225;:::o;808:7919:24:-;;;;;;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/ownership/Ownable.sol\";\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol\";\nimport \"../libraries/CoreLibrary.sol\";\nimport \"../configuration/LendingPoolAddressesProvider.sol\";\nimport \"./LendingPoolCore.sol\";\nimport \"../interfaces/IFeeProvider.sol\";\nimport \"../tokenization/AToken.sol\";\n\n\n\n/*************************************************************************************\n@title LendingPoolConfigurator contract\n@author Aave\n@notice Executes configuration methods on the LendingPoolCore contract. Allows to enable/disable reserves,\nand set different protocol parameters.\n *************************************************************************************/\n\ncontract LendingPoolConfigurator is Ownable {\n\n using SafeMath for uint256;\n\n event ReserveInitialized(\n address indexed _reserve,\n address indexed _aToken,\n uint256 _initialExchangeRate,\n address _interestRateStrategyAddress);\n\n event BorrowingEnabledOnReserve(\n address _reserve,\n bool _fixedRateEnabled\n );\n\n /**\n @dev events\n */\n event BorrowingDisabledOnReserve(address indexed _reserve);\n event ReserveEnabledAsCollateral(address indexed _reserve, uint256 _ltv, uint256 _liquidationThreshold);\n event ReserveDisabledAsCollateral(address indexed _reserve);\n event FixedRateEnabledOnReserve(address indexed _reserve);\n event FixedRateDisabledOnReserve(address indexed _reserve);\n event ReserveActivated(address indexed _reserve);\n event ReserveDeactivated(address indexed _reserve);\n\n LendingPoolAddressesProvider public poolAddressesProvider;\n /**\n @dev only lending pools can use functions affected by this modifier\n */\n modifier onlyLendingPoolManager {\n require(\n poolAddressesProvider.getLendingPoolManager() == msg.sender,\n \"The caller must be a lending pool manager\"\n );\n _;\n }\n\n constructor(LendingPoolAddressesProvider _poolAddressesProvider)\n public\n {\n poolAddressesProvider = _poolAddressesProvider;\n }\n\n /******************************************\n @dev pool core managment functions\n ******************************************/\n\n function initReserve(\n address _reserve,\n uint256 _aTokenInitialExchangeRate,\n uint256 _underlyingAssetDecimals,\n address _interestRateStrategyAddress)\n external\n onlyLendingPoolManager\n {\n ERC20Detailed asset = ERC20Detailed(_reserve);\n\n string memory aTokenName = string(abi.encodePacked(\"Aave Interest bearing \", asset.name()));\n string memory aTokenSymbol = string(abi.encodePacked(\"a\", asset.symbol()));\n\n initReserveWithData(\n _reserve,\n aTokenName,\n aTokenSymbol,\n _aTokenInitialExchangeRate,\n _underlyingAssetDecimals,\n _interestRateStrategyAddress);\n\n }\n\n\n /**\n @notice initialises the reserve and instantiates the specific aToken with the specified initial exchange rate.\n */\n function initReserveWithData(\n address _reserve,\n string memory aTokenName,\n string memory aTokenSymbol,\n uint256 _aTokenInitialExchangeRate,\n uint256 _underlyingAssetDecimals,\n address _interestRateStrategyAddress)\n public\n onlyLendingPoolManager\n {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n\n AToken aTokenInstance = new AToken(\n poolAddressesProvider,\n _reserve,\n _underlyingAssetDecimals,\n aTokenName,\n aTokenSymbol,\n 18,\n _aTokenInitialExchangeRate\n );\n core.initReserve(_reserve, address(aTokenInstance), _underlyingAssetDecimals, _interestRateStrategyAddress);\n\n emit ReserveInitialized(_reserve, address(aTokenInstance), _aTokenInitialExchangeRate, _interestRateStrategyAddress);\n }\n\n\n /**\n @notice functions to enable/disable borrowing on reserve.\n */\n function enableBorrowingOnReserve(\n address _reserve,\n bool _fixedBorrowRateEnabled\n ) external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.enableBorrowingOnReserve(_reserve, _fixedBorrowRateEnabled);\n emit BorrowingEnabledOnReserve(_reserve, _fixedBorrowRateEnabled);\n }\n\n function disableBorrowingOnReserve(address _reserve) external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.disableBorrowingOnReserve(_reserve);\n\n emit BorrowingDisabledOnReserve(_reserve);\n }\n\n /**\n @notice functions to enable/disable usage of the reserve as collateral.\n */\n\n\n function enableReserveAsCollateral(address _reserve, uint256 _baseLTVasCollateral, uint256 _liquidationThreshold)\n external\n onlyLendingPoolManager\n {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.enableReserveAsCollateral(_reserve, _baseLTVasCollateral, _liquidationThreshold);\n emit ReserveEnabledAsCollateral(_reserve, _baseLTVasCollateral, _liquidationThreshold);\n }\n\n function disableReserveAsCollateral(address _reserve) external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.disableReserveAsCollateral(_reserve);\n\n emit ReserveDisabledAsCollateral(_reserve);\n }\n\n /**\n @notice functions to enable/disable fixed borrow rate mode on a reserve.\n */\n\n\n function enableReserveFixedBorrowRate(address _reserve) external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.enableReserveFixedBorrowRate(_reserve);\n\n emit FixedRateEnabledOnReserve(_reserve);\n }\n\n function disableReserveFixedBorrowRate(address _reserve) external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.disableReserveFixedBorrowRate(_reserve);\n\n emit FixedRateDisabledOnReserve(_reserve);\n }\n\n function activateReserve(address _reserve) external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.activateReserve(_reserve);\n\n emit ReserveActivated(_reserve);\n }\n\n function deactivateReserve(address _reserve) external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.deactivateReserve(_reserve);\n\n emit ReserveDeactivated(_reserve);\n }\n\n\n /***************\n @dev functions to update available collaterals\n @dev the interest rate and the ltv are expressed in percentage\n ***************/\n\n function setReserveBaseLTVasCollateral(address _reserve, uint256 _ltv) external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.setReserveBaseLTVasCollateral(_reserve, _ltv);\n }\n\n function setReserveLiquidationThreshold(address _reserve, uint256 _threshold)\n external\n onlyLendingPoolManager\n {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.setReserveLiquidationThreshold(_reserve, _threshold);\n }\n\n function setReserveLiquidationDiscount(address _reserve, uint256 _threshold)\n external\n onlyLendingPoolManager\n {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.setReserveLiquidationDiscount(_reserve, _threshold);\n }\n\n\n function setReserveInterestRateStrategyAddress( address _reserve, address _rateStrategyAddress) external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.setReserveInterestRateStrategyAddress(_reserve, _rateStrategyAddress);\n }\n\n function setLendingPoolCoreAddressesProvider(address _provider) external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.setAddressesProvider(_provider);\n }\n\n function refreshLendingPoolCoreConfiguration() external onlyLendingPoolManager {\n LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore());\n core.refreshConfiguration();\n }\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolConfigurator.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolConfigurator.sol", + "exportedSymbols": { + "LendingPoolConfigurator": [ + 4657 + ] + }, + "id": 4658, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 4096, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:24" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "id": 4097, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 11255, + "src": "25:63:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 4098, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 11141, + "src": "89:59:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "id": 4099, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 11718, + "src": "149:71:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "file": "../libraries/CoreLibrary.sol", + "id": 4100, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 8995, + "src": "221:38:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 4101, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 1358, + "src": "260:59:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "./LendingPoolCore.sol", + "id": 4102, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 6683, + "src": "320:31:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "file": "../interfaces/IFeeProvider.sol", + "id": 4103, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 1766, + "src": "352:40:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "file": "../tokenization/AToken.sol", + "id": 4104, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 10328, + "src": "393:36:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 4105, + "name": "Ownable", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11254, + "src": "844:7:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Ownable_$11254", + "typeString": "contract Ownable" + } + }, + "id": 4106, + "nodeType": "InheritanceSpecifier", + "src": "844:7:24" + } + ], + "contractDependencies": [ + 10327, + 10953, + 11254 + ], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title LendingPoolConfigurator contract\n@author Aave\n@notice Executes configuration methods on the LendingPoolCore contract. Allows to enable/disable reserves,\nand set different protocol parameters.************************************************************************************", + "fullyImplemented": true, + "id": 4657, + "linearizedBaseContracts": [ + 4657, + 11254, + 10953 + ], + "name": "LendingPoolConfigurator", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 4109, + "libraryName": { + "contractScope": null, + "id": 4107, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "865:8:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "859:27:24", + "typeName": { + "id": 4108, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "878:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "anonymous": false, + "documentation": null, + "id": 4119, + "name": "ReserveInitialized", + "nodeType": "EventDefinition", + "parameters": { + "id": 4118, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4111, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4119, + "src": "922:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4110, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "922:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4113, + "indexed": true, + "name": "_aToken", + "nodeType": "VariableDeclaration", + "scope": 4119, + "src": "952:23:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4112, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "952:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4115, + "indexed": false, + "name": "_initialExchangeRate", + "nodeType": "VariableDeclaration", + "scope": 4119, + "src": "981:28:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4114, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "981:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4117, + "indexed": false, + "name": "_interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 4119, + "src": "1015:36:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4116, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1015:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "916:136:24" + }, + "src": "892:161:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4125, + "name": "BorrowingEnabledOnReserve", + "nodeType": "EventDefinition", + "parameters": { + "id": 4124, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4121, + "indexed": false, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4125, + "src": "1100:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4120, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1100:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4123, + "indexed": false, + "name": "_fixedRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 4125, + "src": "1126:22:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 4122, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "1126:4:24", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1090:64:24" + }, + "src": "1059:96:24" + }, + { + "anonymous": false, + "documentation": "@dev events", + "id": 4129, + "name": "BorrowingDisabledOnReserve", + "nodeType": "EventDefinition", + "parameters": { + "id": 4128, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4127, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4129, + "src": "1226:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4126, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1226:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1225:26:24" + }, + "src": "1193:59:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4137, + "name": "ReserveEnabledAsCollateral", + "nodeType": "EventDefinition", + "parameters": { + "id": 4136, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4131, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4137, + "src": "1290:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4130, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1290:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4133, + "indexed": false, + "name": "_ltv", + "nodeType": "VariableDeclaration", + "scope": 4137, + "src": "1316:12:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4132, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1316:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4135, + "indexed": false, + "name": "_liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 4137, + "src": "1330:29:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4134, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1330:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1289:71:24" + }, + "src": "1257:104:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4141, + "name": "ReserveDisabledAsCollateral", + "nodeType": "EventDefinition", + "parameters": { + "id": 4140, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4139, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4141, + "src": "1400:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4138, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1400:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1399:26:24" + }, + "src": "1366:60:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4145, + "name": "FixedRateEnabledOnReserve", + "nodeType": "EventDefinition", + "parameters": { + "id": 4144, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4143, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4145, + "src": "1463:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4142, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1463:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1462:26:24" + }, + "src": "1431:58:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4149, + "name": "FixedRateDisabledOnReserve", + "nodeType": "EventDefinition", + "parameters": { + "id": 4148, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4147, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4149, + "src": "1527:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4146, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1527:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1526:26:24" + }, + "src": "1494:59:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4153, + "name": "ReserveActivated", + "nodeType": "EventDefinition", + "parameters": { + "id": 4152, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4151, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4153, + "src": "1581:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4150, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1581:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1580:26:24" + }, + "src": "1558:49:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4157, + "name": "ReserveDeactivated", + "nodeType": "EventDefinition", + "parameters": { + "id": 4156, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4155, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4157, + "src": "1637:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4154, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1637:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1636:26:24" + }, + "src": "1612:51:24" + }, + { + "constant": false, + "id": 4159, + "name": "poolAddressesProvider", + "nodeType": "VariableDeclaration", + "scope": 4657, + "src": "1669:57:24", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 4158, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1669:28:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "public" + }, + { + "body": { + "id": 4172, + "nodeType": "Block", + "src": "1852:175:24", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 4167, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4162, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "1883:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4163, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolManager", + "nodeType": "MemberAccess", + "referencedDeclaration": 1166, + "src": "1883:43:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 4164, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1883:45:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4165, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "1932:3:24", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 4166, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1932:10:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "1883:59:24", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c206d616e61676572", + "id": 4168, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1956:43:24", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5b05b6449ea50bfbadee2fb35b128dd51c0b0dbb68c28249090495b24b5390f6", + "typeString": "literal_string \"The caller must be a lending pool manager\"" + }, + "value": "The caller must be a lending pool manager" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_5b05b6449ea50bfbadee2fb35b128dd51c0b0dbb68c28249090495b24b5390f6", + "typeString": "literal_string \"The caller must be a lending pool manager\"" + } + ], + "id": 4161, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1862:7:24", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4169, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1862:147:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4170, + "nodeType": "ExpressionStatement", + "src": "1862:147:24" + }, + { + "id": 4171, + "nodeType": "PlaceholderStatement", + "src": "2019:1:24" + } + ] + }, + "documentation": "@dev only lending pools can use functions affected by this modifier", + "id": 4173, + "name": "onlyLendingPoolManager", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 4160, + "nodeType": "ParameterList", + "parameters": [], + "src": "1852:0:24" + }, + "src": "1820:207:24", + "visibility": "internal" + }, + { + "body": { + "id": 4182, + "nodeType": "Block", + "src": "2117:63:24", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 4180, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 4178, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "2127:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 4179, + "name": "_poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4175, + "src": "2151:22:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "2127:46:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4181, + "nodeType": "ExpressionStatement", + "src": "2127:46:24" + } + ] + }, + "documentation": null, + "id": 4183, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4176, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4175, + "name": "_poolAddressesProvider", + "nodeType": "VariableDeclaration", + "scope": 4183, + "src": "2045:51:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 4174, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "2045:28:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2044:53:24" + }, + "returnParameters": { + "id": 4177, + "nodeType": "ParameterList", + "parameters": [], + "src": "2117:0:24" + }, + "scope": 4657, + "src": "2033:147:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 4235, + "nodeType": "Block", + "src": "2555:472:24", + "statements": [ + { + "assignments": [ + 4197 + ], + "declarations": [ + { + "constant": false, + "id": 4197, + "name": "asset", + "nodeType": "VariableDeclaration", + "scope": 4235, + "src": "2565:19:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + }, + "typeName": { + "contractScope": null, + "id": 4196, + "name": "ERC20Detailed", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11717, + "src": "2565:13:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4201, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4199, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4185, + "src": "2601:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4198, + "name": "ERC20Detailed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11717, + "src": "2587:13:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ERC20Detailed_$11717_$", + "typeString": "type(contract ERC20Detailed)" + } + }, + "id": 4200, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2587:23:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2565:45:24" + }, + { + "assignments": [ + 4203 + ], + "declarations": [ + { + "constant": false, + "id": 4203, + "name": "aTokenName", + "nodeType": "VariableDeclaration", + "scope": 4235, + "src": "2621:24:24", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 4202, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "2621:6:24", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4213, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "4161766520496e7465726573742062656172696e6720", + "id": 4207, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2672:24:24", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_df9afa475fefbb32a1b38bb3c5a018a798a881718885d14615d414c2a39e63c4", + "typeString": "literal_string \"Aave Interest bearing \"" + }, + "value": "Aave Interest bearing " + }, + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4208, + "name": "asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4197, + "src": "2698:5:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + } + }, + "id": 4209, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "name", + "nodeType": "MemberAccess", + "referencedDeclaration": 11700, + "src": "2698:10:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_string_memory_ptr_$", + "typeString": "function () view external returns (string memory)" + } + }, + "id": 4210, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2698:12:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_df9afa475fefbb32a1b38bb3c5a018a798a881718885d14615d414c2a39e63c4", + "typeString": "literal_string \"Aave Interest bearing \"" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + ], + "expression": { + "argumentTypes": null, + "id": 4205, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "2655:3:24", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 4206, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodePacked", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2655:16:24", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodepacked_pure$__$returns$_t_bytes_memory_ptr_$", + "typeString": "function () pure returns (bytes memory)" + } + }, + "id": 4211, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2655:56:24", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 4204, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2648:6:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_string_storage_ptr_$", + "typeString": "type(string storage pointer)" + }, + "typeName": "string" + }, + "id": 4212, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2648:64:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2621:91:24" + }, + { + "assignments": [ + 4215 + ], + "declarations": [ + { + "constant": false, + "id": 4215, + "name": "aTokenSymbol", + "nodeType": "VariableDeclaration", + "scope": 4235, + "src": "2722:26:24", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 4214, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "2722:6:24", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4225, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "61", + "id": 4219, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2775:3:24", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3ac225168df54212a25c1c01fd35bebfea408fdac2e31ddd6f80a4bbf9a5f1cb", + "typeString": "literal_string \"a\"" + }, + "value": "a" + }, + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4220, + "name": "asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4197, + "src": "2780:5:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + } + }, + "id": 4221, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "symbol", + "nodeType": "MemberAccess", + "referencedDeclaration": 11708, + "src": "2780:12:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_string_memory_ptr_$", + "typeString": "function () view external returns (string memory)" + } + }, + "id": 4222, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2780:14:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_3ac225168df54212a25c1c01fd35bebfea408fdac2e31ddd6f80a4bbf9a5f1cb", + "typeString": "literal_string \"a\"" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + ], + "expression": { + "argumentTypes": null, + "id": 4217, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "2758:3:24", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 4218, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodePacked", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2758:16:24", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodepacked_pure$__$returns$_t_bytes_memory_ptr_$", + "typeString": "function () pure returns (bytes memory)" + } + }, + "id": 4223, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2758:37:24", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 4216, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2751:6:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_string_storage_ptr_$", + "typeString": "type(string storage pointer)" + }, + "typeName": "string" + }, + "id": 4224, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2751:45:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2722:74:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4227, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4185, + "src": "2840:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4228, + "name": "aTokenName", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4203, + "src": "2862:10:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "id": 4229, + "name": "aTokenSymbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4215, + "src": "2886:12:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "id": 4230, + "name": "_aTokenInitialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4187, + "src": "2912:26:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4231, + "name": "_underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4189, + "src": "2952:24:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4232, + "name": "_interestRateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4191, + "src": "2990:28:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4226, + "name": "initReserveWithData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4295, + "src": "2807:19:24", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_string_memory_ptr_$_t_string_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_$returns$__$", + "typeString": "function (address,string memory,string memory,uint256,uint256,address)" + } + }, + "id": 4233, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2807:212:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4234, + "nodeType": "ExpressionStatement", + "src": "2807:212:24" + } + ] + }, + "documentation": "****************************************\n@dev pool core managment functions*****************************************", + "id": 4236, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4194, + "modifierName": { + "argumentTypes": null, + "id": 4193, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "2528:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "2528:22:24" + } + ], + "name": "initReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4192, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4185, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4236, + "src": "2353:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4184, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2353:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4187, + "name": "_aTokenInitialExchangeRate", + "nodeType": "VariableDeclaration", + "scope": 4236, + "src": "2379:34:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4186, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2379:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4189, + "name": "_underlyingAssetDecimals", + "nodeType": "VariableDeclaration", + "scope": 4236, + "src": "2423:32:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4188, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2423:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4191, + "name": "_interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 4236, + "src": "2465:36:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4190, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2465:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2343:159:24" + }, + "returnParameters": { + "id": 4195, + "nodeType": "ParameterList", + "parameters": [], + "src": "2555:0:24" + }, + "scope": 4657, + "src": "2323:704:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4294, + "nodeType": "Block", + "src": "3473:599:24", + "statements": [ + { + "assignments": [ + 4254 + ], + "declarations": [ + { + "constant": false, + "id": 4254, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4294, + "src": "3483:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4253, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "3483:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4260, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4256, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "3522:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4257, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "3522:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4258, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3522:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4255, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "3506:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4259, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3506:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3483:82:24" + }, + { + "assignments": [ + 4262 + ], + "declarations": [ + { + "constant": false, + "id": 4262, + "name": "aTokenInstance", + "nodeType": "VariableDeclaration", + "scope": 4294, + "src": "3576:21:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + }, + "typeName": { + "contractScope": null, + "id": 4261, + "name": "AToken", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10327, + "src": "3576:6:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4273, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4265, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "3624:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + { + "argumentTypes": null, + "id": 4266, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4238, + "src": "3659:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4267, + "name": "_underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4246, + "src": "3681:24:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4268, + "name": "aTokenName", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4240, + "src": "3719:10:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "id": 4269, + "name": "aTokenSymbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4242, + "src": "3743:12:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "hexValue": "3138", + "id": 4270, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3769:2:24", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + { + "argumentTypes": null, + "id": 4271, + "name": "_aTokenInitialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4244, + "src": "3785:26:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + }, + { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 4264, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "NewExpression", + "src": "3600:10:24", + "typeDescriptions": { + "typeIdentifier": "t_function_creation_nonpayable$_t_contract$_LendingPoolAddressesProvider_$1357_$_t_address_$_t_uint256_$_t_string_memory_ptr_$_t_string_memory_ptr_$_t_uint8_$_t_uint256_$returns$_t_contract$_AToken_$10327_$", + "typeString": "function (contract LendingPoolAddressesProvider,address,uint256,string memory,string memory,uint8,uint256) returns (contract AToken)" + }, + "typeName": { + "contractScope": null, + "id": 4263, + "name": "AToken", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10327, + "src": "3604:6:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + } + }, + "id": 4272, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3600:221:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3576:245:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4277, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4238, + "src": "3848:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4279, + "name": "aTokenInstance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4262, + "src": "3866:14:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + ], + "id": 4278, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3858:7:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 4280, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3858:23:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4281, + "name": "_underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4246, + "src": "3883:24:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4282, + "name": "_interestRateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4248, + "src": "3909:28:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4274, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4254, + "src": "3831:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4276, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "initReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6187, + "src": "3831:16:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$", + "typeString": "function (address,address,uint256,address) external" + } + }, + "id": 4283, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3831:107:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4284, + "nodeType": "ExpressionStatement", + "src": "3831:107:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4286, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4238, + "src": "3973:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4288, + "name": "aTokenInstance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4262, + "src": "3991:14:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + ], + "id": 4287, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3983:7:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 4289, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3983:23:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4290, + "name": "_aTokenInitialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4244, + "src": "4008:26:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4291, + "name": "_interestRateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4248, + "src": "4036:28:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4285, + "name": "ReserveInitialized", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4119, + "src": "3954:18:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$", + "typeString": "function (address,address,uint256,address)" + } + }, + "id": 4292, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3954:111:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4293, + "nodeType": "EmitStatement", + "src": "3949:116:24" + } + ] + }, + "documentation": "@notice initialises the reserve and instantiates the specific aToken with the specified initial exchange rate.", + "id": 4295, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4251, + "modifierName": { + "argumentTypes": null, + "id": 4250, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "3446:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "3446:22:24" + } + ], + "name": "initReserveWithData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4249, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4238, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3203:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4237, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3203:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4240, + "name": "aTokenName", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3229:24:24", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 4239, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "3229:6:24", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4242, + "name": "aTokenSymbol", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3263:26:24", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 4241, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "3263:6:24", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4244, + "name": "_aTokenInitialExchangeRate", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3299:34:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4243, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3299:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4246, + "name": "_underlyingAssetDecimals", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3343:32:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4245, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3343:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4248, + "name": "_interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3385:36:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4247, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3385:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3193:229:24" + }, + "returnParameters": { + "id": 4252, + "nodeType": "ParameterList", + "parameters": [], + "src": "3473:0:24" + }, + "scope": 4657, + "src": "3165:907:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 4324, + "nodeType": "Block", + "src": "4293:248:24", + "statements": [ + { + "assignments": [ + 4305 + ], + "declarations": [ + { + "constant": false, + "id": 4305, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4324, + "src": "4303:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4304, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "4303:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4311, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4307, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "4342:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4308, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "4342:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4309, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4342:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4306, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "4326:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4310, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4326:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4303:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4315, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4297, + "src": "4425:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4316, + "name": "_fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4299, + "src": "4435:23:24", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "expression": { + "argumentTypes": null, + "id": 4312, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4305, + "src": "4395:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4314, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "enableBorrowingOnReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6221, + "src": "4395:29:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_bool_$returns$__$", + "typeString": "function (address,bool) external" + } + }, + "id": 4317, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4395:64:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4318, + "nodeType": "ExpressionStatement", + "src": "4395:64:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4320, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4297, + "src": "4500:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4321, + "name": "_fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4299, + "src": "4510:23:24", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "id": 4319, + "name": "BorrowingEnabledOnReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4125, + "src": "4474:25:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_bool_$returns$__$", + "typeString": "function (address,bool)" + } + }, + "id": 4322, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4474:60:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4323, + "nodeType": "EmitStatement", + "src": "4469:65:24" + } + ] + }, + "documentation": "@notice functions to enable/disable borrowing on reserve.", + "id": 4325, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4302, + "modifierName": { + "argumentTypes": null, + "id": 4301, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "4270:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4270:22:24" + } + ], + "name": "enableBorrowingOnReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4300, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4297, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4325, + "src": "4200:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4296, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4200:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4299, + "name": "_fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 4325, + "src": "4226:28:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 4298, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "4226:4:24", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4190:70:24" + }, + "returnParameters": { + "id": 4303, + "nodeType": "ParameterList", + "parameters": [], + "src": "4293:0:24" + }, + "scope": 4657, + "src": "4157:384:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4350, + "nodeType": "Block", + "src": "4632:201:24", + "statements": [ + { + "assignments": [ + 4333 + ], + "declarations": [ + { + "constant": false, + "id": 4333, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4350, + "src": "4642:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4332, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "4642:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4339, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4335, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "4681:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4336, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "4681:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4337, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4681:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4334, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "4665:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4338, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4665:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4642:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4343, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4327, + "src": "4765:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4340, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4333, + "src": "4734:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4342, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "disableBorrowingOnReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6235, + "src": "4734:30:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4344, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4734:40:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4345, + "nodeType": "ExpressionStatement", + "src": "4734:40:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4347, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4327, + "src": "4817:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4346, + "name": "BorrowingDisabledOnReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4129, + "src": "4790:26:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4348, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4790:36:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4349, + "nodeType": "EmitStatement", + "src": "4785:41:24" + } + ] + }, + "documentation": null, + "id": 4351, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4330, + "modifierName": { + "argumentTypes": null, + "id": 4329, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "4609:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4609:22:24" + } + ], + "name": "disableBorrowingOnReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4328, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4327, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4351, + "src": "4582:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4326, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4582:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4581:18:24" + }, + "returnParameters": { + "id": 4331, + "nodeType": "ParameterList", + "parameters": [], + "src": "4632:0:24" + }, + "scope": 4657, + "src": "4547:286:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4384, + "nodeType": "Block", + "src": "5099:290:24", + "statements": [ + { + "assignments": [ + 4363 + ], + "declarations": [ + { + "constant": false, + "id": 4363, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4384, + "src": "5109:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4362, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "5109:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4369, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4365, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "5148:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4366, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "5148:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4367, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5148:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4364, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "5132:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4368, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5132:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5109:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4373, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4353, + "src": "5232:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4374, + "name": "_baseLTVasCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4355, + "src": "5242:20:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4375, + "name": "_liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4357, + "src": "5264:21:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 4370, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4363, + "src": "5201:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4372, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "enableReserveAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 6255, + "src": "5201:30:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 4376, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5201:85:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4377, + "nodeType": "ExpressionStatement", + "src": "5201:85:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4379, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4353, + "src": "5328:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4380, + "name": "_baseLTVasCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4355, + "src": "5338:20:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4381, + "name": "_liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4357, + "src": "5360:21:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 4378, + "name": "ReserveEnabledAsCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4137, + "src": "5301:26:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256)" + } + }, + "id": 4382, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5301:81:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4383, + "nodeType": "EmitStatement", + "src": "5296:86:24" + } + ] + }, + "documentation": "@notice functions to enable/disable usage of the reserve as collateral.", + "id": 4385, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4360, + "modifierName": { + "argumentTypes": null, + "id": 4359, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "5072:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5072:22:24" + } + ], + "name": "enableReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4358, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4353, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4385, + "src": "4968:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4352, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4968:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4355, + "name": "_baseLTVasCollateral", + "nodeType": "VariableDeclaration", + "scope": 4385, + "src": "4986:28:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4354, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4986:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4357, + "name": "_liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 4385, + "src": "5016:29:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4356, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5016:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4967:79:24" + }, + "returnParameters": { + "id": 4361, + "nodeType": "ParameterList", + "parameters": [], + "src": "5099:0:24" + }, + "scope": 4657, + "src": "4933:456:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4410, + "nodeType": "Block", + "src": "5481:203:24", + "statements": [ + { + "assignments": [ + 4393 + ], + "declarations": [ + { + "constant": false, + "id": 4393, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4410, + "src": "5491:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4392, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "5491:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4399, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4395, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "5530:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4396, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "5530:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4397, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5530:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4394, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "5514:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4398, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5514:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5491:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4403, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4387, + "src": "5615:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4400, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4393, + "src": "5583:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4402, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "disableReserveAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 6269, + "src": "5583:31:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4404, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5583:41:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4405, + "nodeType": "ExpressionStatement", + "src": "5583:41:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4407, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4387, + "src": "5668:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4406, + "name": "ReserveDisabledAsCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4141, + "src": "5640:27:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4408, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5640:37:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4409, + "nodeType": "EmitStatement", + "src": "5635:42:24" + } + ] + }, + "documentation": null, + "id": 4411, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4390, + "modifierName": { + "argumentTypes": null, + "id": 4389, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "5458:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5458:22:24" + } + ], + "name": "disableReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4388, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4387, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4411, + "src": "5431:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4386, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5431:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5430:18:24" + }, + "returnParameters": { + "id": 4391, + "nodeType": "ParameterList", + "parameters": [], + "src": "5481:0:24" + }, + "scope": 4657, + "src": "5395:289:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4436, + "nodeType": "Block", + "src": "5873:203:24", + "statements": [ + { + "assignments": [ + 4419 + ], + "declarations": [ + { + "constant": false, + "id": 4419, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4436, + "src": "5883:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4418, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "5883:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4425, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4421, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "5922:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4422, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "5922:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4423, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5922:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4420, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "5906:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4424, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5906:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5883:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4429, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4413, + "src": "6009:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4426, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4419, + "src": "5975:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4428, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "enableReserveFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6291, + "src": "5975:33:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4430, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5975:43:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4431, + "nodeType": "ExpressionStatement", + "src": "5975:43:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4433, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4413, + "src": "6060:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4432, + "name": "FixedRateEnabledOnReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4145, + "src": "6034:25:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4434, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6034:35:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4435, + "nodeType": "EmitStatement", + "src": "6029:40:24" + } + ] + }, + "documentation": "@notice functions to enable/disable fixed borrow rate mode on a reserve.", + "id": 4437, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4416, + "modifierName": { + "argumentTypes": null, + "id": 4415, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "5850:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5850:22:24" + } + ], + "name": "enableReserveFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4414, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4413, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4437, + "src": "5823:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4412, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5823:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5822:18:24" + }, + "returnParameters": { + "id": 4417, + "nodeType": "ParameterList", + "parameters": [], + "src": "5873:0:24" + }, + "scope": 4657, + "src": "5785:291:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4462, + "nodeType": "Block", + "src": "6171:205:24", + "statements": [ + { + "assignments": [ + 4445 + ], + "declarations": [ + { + "constant": false, + "id": 4445, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4462, + "src": "6181:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4444, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "6181:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4451, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4447, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "6220:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4448, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "6220:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4449, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6220:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4446, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "6204:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4450, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6204:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6181:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4455, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4439, + "src": "6308:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4452, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4445, + "src": "6273:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4454, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "disableReserveFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6313, + "src": "6273:34:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4456, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6273:44:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4457, + "nodeType": "ExpressionStatement", + "src": "6273:44:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4459, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4439, + "src": "6360:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4458, + "name": "FixedRateDisabledOnReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4149, + "src": "6333:26:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4460, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6333:36:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4461, + "nodeType": "EmitStatement", + "src": "6328:41:24" + } + ] + }, + "documentation": null, + "id": 4463, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4442, + "modifierName": { + "argumentTypes": null, + "id": 4441, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "6148:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6148:22:24" + } + ], + "name": "disableReserveFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4440, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4439, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4463, + "src": "6121:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4438, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6121:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6120:18:24" + }, + "returnParameters": { + "id": 4443, + "nodeType": "ParameterList", + "parameters": [], + "src": "6171:0:24" + }, + "scope": 4657, + "src": "6082:294:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4488, + "nodeType": "Block", + "src": "6457:181:24", + "statements": [ + { + "assignments": [ + 4471 + ], + "declarations": [ + { + "constant": false, + "id": 4471, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4488, + "src": "6467:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4470, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "6467:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4477, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4473, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "6506:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4474, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "6506:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4475, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6506:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4472, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "6490:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4476, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6490:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6467:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4481, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4465, + "src": "6580:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4478, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4471, + "src": "6559:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4480, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "activateReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6348, + "src": "6559:20:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4482, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6559:30:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4483, + "nodeType": "ExpressionStatement", + "src": "6559:30:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4485, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4465, + "src": "6622:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4484, + "name": "ReserveActivated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4153, + "src": "6605:16:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4486, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6605:26:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4487, + "nodeType": "EmitStatement", + "src": "6600:31:24" + } + ] + }, + "documentation": null, + "id": 4489, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4468, + "modifierName": { + "argumentTypes": null, + "id": 4467, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "6434:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6434:22:24" + } + ], + "name": "activateReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4466, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4465, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4489, + "src": "6407:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4464, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6407:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6406:18:24" + }, + "returnParameters": { + "id": 4469, + "nodeType": "ParameterList", + "parameters": [], + "src": "6457:0:24" + }, + "scope": 4657, + "src": "6382:256:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4514, + "nodeType": "Block", + "src": "6721:185:24", + "statements": [ + { + "assignments": [ + 4497 + ], + "declarations": [ + { + "constant": false, + "id": 4497, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4514, + "src": "6731:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4496, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "6731:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4503, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4499, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "6770:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4500, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "6770:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4501, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6770:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4498, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "6754:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4502, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6754:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6731:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4507, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4491, + "src": "6846:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4504, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4497, + "src": "6823:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4506, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "deactivateReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6370, + "src": "6823:22:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4508, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6823:32:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4509, + "nodeType": "ExpressionStatement", + "src": "6823:32:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4511, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4491, + "src": "6890:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4510, + "name": "ReserveDeactivated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4157, + "src": "6871:18:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4512, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6871:28:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4513, + "nodeType": "EmitStatement", + "src": "6866:33:24" + } + ] + }, + "documentation": null, + "id": 4515, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4494, + "modifierName": { + "argumentTypes": null, + "id": 4493, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "6698:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6698:22:24" + } + ], + "name": "deactivateReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4492, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4491, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4515, + "src": "6671:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4490, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6671:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6670:18:24" + }, + "returnParameters": { + "id": 4495, + "nodeType": "ParameterList", + "parameters": [], + "src": "6721:0:24" + }, + "scope": 4657, + "src": "6644:262:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4539, + "nodeType": "Block", + "src": "7178:159:24", + "statements": [ + { + "assignments": [ + 4525 + ], + "declarations": [ + { + "constant": false, + "id": 4525, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4539, + "src": "7188:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4524, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "7188:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4531, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4527, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "7227:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4528, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "7227:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4529, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7227:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4526, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "7211:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4530, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7211:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7188:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4535, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4517, + "src": "7315:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4536, + "name": "_ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4519, + "src": "7325:4:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 4532, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4525, + "src": "7280:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4534, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveBaseLTVasCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 6394, + "src": "7280:34:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 4537, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7280:50:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4538, + "nodeType": "ExpressionStatement", + "src": "7280:50:24" + } + ] + }, + "documentation": "*************\n@dev functions to update available collaterals\n@dev the interest rate and the ltv are expressed in percentage**************", + "id": 4540, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4522, + "modifierName": { + "argumentTypes": null, + "id": 4521, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "7155:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "7155:22:24" + } + ], + "name": "setReserveBaseLTVasCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4520, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4517, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4540, + "src": "7114:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4516, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7114:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4519, + "name": "_ltv", + "nodeType": "VariableDeclaration", + "scope": 4540, + "src": "7132:12:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4518, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7132:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7113:32:24" + }, + "returnParameters": { + "id": 4523, + "nodeType": "ParameterList", + "parameters": [], + "src": "7178:0:24" + }, + "scope": 4657, + "src": "7075:262:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4564, + "nodeType": "Block", + "src": "7473:166:24", + "statements": [ + { + "assignments": [ + 4550 + ], + "declarations": [ + { + "constant": false, + "id": 4550, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4564, + "src": "7483:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4549, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "7483:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4556, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4552, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "7522:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4553, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "7522:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4554, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7522:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4551, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "7506:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4555, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7506:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7483:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4560, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4542, + "src": "7611:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4561, + "name": "_threshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4544, + "src": "7621:10:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 4557, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4550, + "src": "7575:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4559, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 6418, + "src": "7575:35:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 4562, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7575:57:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4563, + "nodeType": "ExpressionStatement", + "src": "7575:57:24" + } + ] + }, + "documentation": null, + "id": 4565, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4547, + "modifierName": { + "argumentTypes": null, + "id": 4546, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "7446:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "7446:22:24" + } + ], + "name": "setReserveLiquidationThreshold", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4545, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4542, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4565, + "src": "7383:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4541, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7383:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4544, + "name": "_threshold", + "nodeType": "VariableDeclaration", + "scope": 4565, + "src": "7401:18:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4543, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7401:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7382:38:24" + }, + "returnParameters": { + "id": 4548, + "nodeType": "ParameterList", + "parameters": [], + "src": "7473:0:24" + }, + "scope": 4657, + "src": "7343:296:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4589, + "nodeType": "Block", + "src": "7774:165:24", + "statements": [ + { + "assignments": [ + 4575 + ], + "declarations": [ + { + "constant": false, + "id": 4575, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4589, + "src": "7784:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4574, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "7784:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4581, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4577, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "7823:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4578, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "7823:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4579, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7823:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4576, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "7807:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4580, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7807:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7784:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4585, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4567, + "src": "7911:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4586, + "name": "_threshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4569, + "src": "7921:10:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 4582, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4575, + "src": "7876:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4584, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLiquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 6442, + "src": "7876:34:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 4587, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7876:56:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4588, + "nodeType": "ExpressionStatement", + "src": "7876:56:24" + } + ] + }, + "documentation": null, + "id": 4590, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4572, + "modifierName": { + "argumentTypes": null, + "id": 4571, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "7747:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "7747:22:24" + } + ], + "name": "setReserveLiquidationDiscount", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4570, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4567, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4590, + "src": "7684:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4566, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7684:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4569, + "name": "_threshold", + "nodeType": "VariableDeclaration", + "scope": 4590, + "src": "7702:18:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4568, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7702:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7683:38:24" + }, + "returnParameters": { + "id": 4573, + "nodeType": "ParameterList", + "parameters": [], + "src": "7774:0:24" + }, + "scope": 4657, + "src": "7645:294:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4614, + "nodeType": "Block", + "src": "8074:183:24", + "statements": [ + { + "assignments": [ + 4600 + ], + "declarations": [ + { + "constant": false, + "id": 4600, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4614, + "src": "8084:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4599, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "8084:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4606, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4602, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "8123:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4603, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "8123:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4604, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8123:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4601, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "8107:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4605, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8107:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8084:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4610, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4592, + "src": "8219:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4611, + "name": "_rateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4594, + "src": "8229:20:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4607, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4600, + "src": "8176:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4609, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveInterestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 6204, + "src": "8176:42:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 4612, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8176:74:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4613, + "nodeType": "ExpressionStatement", + "src": "8176:74:24" + } + ] + }, + "documentation": null, + "id": 4615, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4597, + "modifierName": { + "argumentTypes": null, + "id": 4596, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "8051:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "8051:22:24" + } + ], + "name": "setReserveInterestRateStrategyAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4595, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4592, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4615, + "src": "7994:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4591, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7994:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4594, + "name": "_rateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 4615, + "src": "8012:28:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4593, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "8012:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7992:49:24" + }, + "returnParameters": { + "id": 4598, + "nodeType": "ParameterList", + "parameters": [], + "src": "8074:0:24" + }, + "scope": 4657, + "src": "7946:311:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4636, + "nodeType": "Block", + "src": "8359:145:24", + "statements": [ + { + "assignments": [ + 4623 + ], + "declarations": [ + { + "constant": false, + "id": 4623, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4636, + "src": "8369:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4622, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "8369:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4629, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4625, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "8408:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4626, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "8408:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4627, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8408:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4624, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "8392:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4628, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8392:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8369:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4633, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4617, + "src": "8487:9:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4630, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4623, + "src": "8461:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4632, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setAddressesProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 6151, + "src": "8461:25:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4634, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8461:36:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4635, + "nodeType": "ExpressionStatement", + "src": "8461:36:24" + } + ] + }, + "documentation": null, + "id": 4637, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4620, + "modifierName": { + "argumentTypes": null, + "id": 4619, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "8336:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "8336:22:24" + } + ], + "name": "setLendingPoolCoreAddressesProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4618, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4617, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 4637, + "src": "8308:17:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4616, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "8308:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8307:19:24" + }, + "returnParameters": { + "id": 4621, + "nodeType": "ParameterList", + "parameters": [], + "src": "8359:0:24" + }, + "scope": 4657, + "src": "8263:241:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4655, + "nodeType": "Block", + "src": "8589:136:24", + "statements": [ + { + "assignments": [ + 4643 + ], + "declarations": [ + { + "constant": false, + "id": 4643, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4655, + "src": "8599:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4642, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "8599:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4649, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4645, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "8638:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4646, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "8638:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4647, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8638:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4644, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "8622:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4648, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8622:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8599:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4650, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4643, + "src": "8691:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4652, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "refreshConfiguration", + "nodeType": "MemberAccess", + "referencedDeclaration": 6160, + "src": "8691:25:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$__$returns$__$", + "typeString": "function () external" + } + }, + "id": 4653, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8691:27:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4654, + "nodeType": "ExpressionStatement", + "src": "8691:27:24" + } + ] + }, + "documentation": null, + "id": 4656, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4640, + "modifierName": { + "argumentTypes": null, + "id": 4639, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "8566:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "8566:22:24" + } + ], + "name": "refreshLendingPoolCoreConfiguration", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4638, + "nodeType": "ParameterList", + "parameters": [], + "src": "8554:2:24" + }, + "returnParameters": { + "id": 4641, + "nodeType": "ParameterList", + "parameters": [], + "src": "8589:0:24" + }, + "scope": 4657, + "src": "8510:215:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 4658, + "src": "808:7919:24" + } + ], + "src": "0:8728:24" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolConfigurator.sol", + "exportedSymbols": { + "LendingPoolConfigurator": [ + 4657 + ] + }, + "id": 4658, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 4096, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:24" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "id": 4097, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 11255, + "src": "25:63:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 4098, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 11141, + "src": "89:59:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol", + "id": 4099, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 11718, + "src": "149:71:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "file": "../libraries/CoreLibrary.sol", + "id": 4100, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 8995, + "src": "221:38:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 4101, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 1358, + "src": "260:59:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "./LendingPoolCore.sol", + "id": 4102, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 6683, + "src": "320:31:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "file": "../interfaces/IFeeProvider.sol", + "id": 4103, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 1766, + "src": "352:40:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "file": "../tokenization/AToken.sol", + "id": 4104, + "nodeType": "ImportDirective", + "scope": 4658, + "sourceUnit": 10328, + "src": "393:36:24", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 4105, + "name": "Ownable", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11254, + "src": "844:7:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Ownable_$11254", + "typeString": "contract Ownable" + } + }, + "id": 4106, + "nodeType": "InheritanceSpecifier", + "src": "844:7:24" + } + ], + "contractDependencies": [ + 10327, + 10953, + 11254 + ], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title LendingPoolConfigurator contract\n@author Aave\n@notice Executes configuration methods on the LendingPoolCore contract. Allows to enable/disable reserves,\nand set different protocol parameters.************************************************************************************", + "fullyImplemented": true, + "id": 4657, + "linearizedBaseContracts": [ + 4657, + 11254, + 10953 + ], + "name": "LendingPoolConfigurator", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 4109, + "libraryName": { + "contractScope": null, + "id": 4107, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "865:8:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "859:27:24", + "typeName": { + "id": 4108, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "878:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "anonymous": false, + "documentation": null, + "id": 4119, + "name": "ReserveInitialized", + "nodeType": "EventDefinition", + "parameters": { + "id": 4118, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4111, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4119, + "src": "922:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4110, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "922:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4113, + "indexed": true, + "name": "_aToken", + "nodeType": "VariableDeclaration", + "scope": 4119, + "src": "952:23:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4112, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "952:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4115, + "indexed": false, + "name": "_initialExchangeRate", + "nodeType": "VariableDeclaration", + "scope": 4119, + "src": "981:28:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4114, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "981:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4117, + "indexed": false, + "name": "_interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 4119, + "src": "1015:36:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4116, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1015:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "916:136:24" + }, + "src": "892:161:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4125, + "name": "BorrowingEnabledOnReserve", + "nodeType": "EventDefinition", + "parameters": { + "id": 4124, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4121, + "indexed": false, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4125, + "src": "1100:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4120, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1100:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4123, + "indexed": false, + "name": "_fixedRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 4125, + "src": "1126:22:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 4122, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "1126:4:24", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1090:64:24" + }, + "src": "1059:96:24" + }, + { + "anonymous": false, + "documentation": "@dev events", + "id": 4129, + "name": "BorrowingDisabledOnReserve", + "nodeType": "EventDefinition", + "parameters": { + "id": 4128, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4127, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4129, + "src": "1226:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4126, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1226:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1225:26:24" + }, + "src": "1193:59:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4137, + "name": "ReserveEnabledAsCollateral", + "nodeType": "EventDefinition", + "parameters": { + "id": 4136, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4131, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4137, + "src": "1290:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4130, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1290:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4133, + "indexed": false, + "name": "_ltv", + "nodeType": "VariableDeclaration", + "scope": 4137, + "src": "1316:12:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4132, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1316:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4135, + "indexed": false, + "name": "_liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 4137, + "src": "1330:29:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4134, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1330:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1289:71:24" + }, + "src": "1257:104:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4141, + "name": "ReserveDisabledAsCollateral", + "nodeType": "EventDefinition", + "parameters": { + "id": 4140, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4139, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4141, + "src": "1400:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4138, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1400:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1399:26:24" + }, + "src": "1366:60:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4145, + "name": "FixedRateEnabledOnReserve", + "nodeType": "EventDefinition", + "parameters": { + "id": 4144, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4143, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4145, + "src": "1463:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4142, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1463:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1462:26:24" + }, + "src": "1431:58:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4149, + "name": "FixedRateDisabledOnReserve", + "nodeType": "EventDefinition", + "parameters": { + "id": 4148, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4147, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4149, + "src": "1527:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4146, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1527:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1526:26:24" + }, + "src": "1494:59:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4153, + "name": "ReserveActivated", + "nodeType": "EventDefinition", + "parameters": { + "id": 4152, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4151, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4153, + "src": "1581:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4150, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1581:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1580:26:24" + }, + "src": "1558:49:24" + }, + { + "anonymous": false, + "documentation": null, + "id": 4157, + "name": "ReserveDeactivated", + "nodeType": "EventDefinition", + "parameters": { + "id": 4156, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4155, + "indexed": true, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4157, + "src": "1637:24:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4154, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1637:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1636:26:24" + }, + "src": "1612:51:24" + }, + { + "constant": false, + "id": 4159, + "name": "poolAddressesProvider", + "nodeType": "VariableDeclaration", + "scope": 4657, + "src": "1669:57:24", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 4158, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1669:28:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "public" + }, + { + "body": { + "id": 4172, + "nodeType": "Block", + "src": "1852:175:24", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 4167, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4162, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "1883:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4163, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolManager", + "nodeType": "MemberAccess", + "referencedDeclaration": 1166, + "src": "1883:43:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 4164, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1883:45:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4165, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "1932:3:24", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 4166, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1932:10:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "1883:59:24", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c206d616e61676572", + "id": 4168, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1956:43:24", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5b05b6449ea50bfbadee2fb35b128dd51c0b0dbb68c28249090495b24b5390f6", + "typeString": "literal_string \"The caller must be a lending pool manager\"" + }, + "value": "The caller must be a lending pool manager" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_5b05b6449ea50bfbadee2fb35b128dd51c0b0dbb68c28249090495b24b5390f6", + "typeString": "literal_string \"The caller must be a lending pool manager\"" + } + ], + "id": 4161, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1862:7:24", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4169, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1862:147:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4170, + "nodeType": "ExpressionStatement", + "src": "1862:147:24" + }, + { + "id": 4171, + "nodeType": "PlaceholderStatement", + "src": "2019:1:24" + } + ] + }, + "documentation": "@dev only lending pools can use functions affected by this modifier", + "id": 4173, + "name": "onlyLendingPoolManager", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 4160, + "nodeType": "ParameterList", + "parameters": [], + "src": "1852:0:24" + }, + "src": "1820:207:24", + "visibility": "internal" + }, + { + "body": { + "id": 4182, + "nodeType": "Block", + "src": "2117:63:24", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 4180, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 4178, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "2127:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 4179, + "name": "_poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4175, + "src": "2151:22:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "2127:46:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4181, + "nodeType": "ExpressionStatement", + "src": "2127:46:24" + } + ] + }, + "documentation": null, + "id": 4183, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4176, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4175, + "name": "_poolAddressesProvider", + "nodeType": "VariableDeclaration", + "scope": 4183, + "src": "2045:51:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 4174, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "2045:28:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2044:53:24" + }, + "returnParameters": { + "id": 4177, + "nodeType": "ParameterList", + "parameters": [], + "src": "2117:0:24" + }, + "scope": 4657, + "src": "2033:147:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 4235, + "nodeType": "Block", + "src": "2555:472:24", + "statements": [ + { + "assignments": [ + 4197 + ], + "declarations": [ + { + "constant": false, + "id": 4197, + "name": "asset", + "nodeType": "VariableDeclaration", + "scope": 4235, + "src": "2565:19:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + }, + "typeName": { + "contractScope": null, + "id": 4196, + "name": "ERC20Detailed", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11717, + "src": "2565:13:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4201, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4199, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4185, + "src": "2601:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4198, + "name": "ERC20Detailed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11717, + "src": "2587:13:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ERC20Detailed_$11717_$", + "typeString": "type(contract ERC20Detailed)" + } + }, + "id": 4200, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2587:23:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2565:45:24" + }, + { + "assignments": [ + 4203 + ], + "declarations": [ + { + "constant": false, + "id": 4203, + "name": "aTokenName", + "nodeType": "VariableDeclaration", + "scope": 4235, + "src": "2621:24:24", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 4202, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "2621:6:24", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4213, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "4161766520496e7465726573742062656172696e6720", + "id": 4207, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2672:24:24", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_df9afa475fefbb32a1b38bb3c5a018a798a881718885d14615d414c2a39e63c4", + "typeString": "literal_string \"Aave Interest bearing \"" + }, + "value": "Aave Interest bearing " + }, + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4208, + "name": "asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4197, + "src": "2698:5:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + } + }, + "id": 4209, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "name", + "nodeType": "MemberAccess", + "referencedDeclaration": 11700, + "src": "2698:10:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_string_memory_ptr_$", + "typeString": "function () view external returns (string memory)" + } + }, + "id": 4210, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2698:12:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_df9afa475fefbb32a1b38bb3c5a018a798a881718885d14615d414c2a39e63c4", + "typeString": "literal_string \"Aave Interest bearing \"" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + ], + "expression": { + "argumentTypes": null, + "id": 4205, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "2655:3:24", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 4206, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodePacked", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2655:16:24", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodepacked_pure$__$returns$_t_bytes_memory_ptr_$", + "typeString": "function () pure returns (bytes memory)" + } + }, + "id": 4211, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2655:56:24", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 4204, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2648:6:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_string_storage_ptr_$", + "typeString": "type(string storage pointer)" + }, + "typeName": "string" + }, + "id": 4212, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2648:64:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2621:91:24" + }, + { + "assignments": [ + 4215 + ], + "declarations": [ + { + "constant": false, + "id": 4215, + "name": "aTokenSymbol", + "nodeType": "VariableDeclaration", + "scope": 4235, + "src": "2722:26:24", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 4214, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "2722:6:24", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4225, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "61", + "id": 4219, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2775:3:24", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3ac225168df54212a25c1c01fd35bebfea408fdac2e31ddd6f80a4bbf9a5f1cb", + "typeString": "literal_string \"a\"" + }, + "value": "a" + }, + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4220, + "name": "asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4197, + "src": "2780:5:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20Detailed_$11717", + "typeString": "contract ERC20Detailed" + } + }, + "id": 4221, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "symbol", + "nodeType": "MemberAccess", + "referencedDeclaration": 11708, + "src": "2780:12:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_string_memory_ptr_$", + "typeString": "function () view external returns (string memory)" + } + }, + "id": 4222, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2780:14:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_3ac225168df54212a25c1c01fd35bebfea408fdac2e31ddd6f80a4bbf9a5f1cb", + "typeString": "literal_string \"a\"" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + ], + "expression": { + "argumentTypes": null, + "id": 4217, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "2758:3:24", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 4218, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodePacked", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2758:16:24", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodepacked_pure$__$returns$_t_bytes_memory_ptr_$", + "typeString": "function () pure returns (bytes memory)" + } + }, + "id": 4223, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2758:37:24", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 4216, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2751:6:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_string_storage_ptr_$", + "typeString": "type(string storage pointer)" + }, + "typeName": "string" + }, + "id": 4224, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2751:45:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2722:74:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4227, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4185, + "src": "2840:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4228, + "name": "aTokenName", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4203, + "src": "2862:10:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "id": 4229, + "name": "aTokenSymbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4215, + "src": "2886:12:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "id": 4230, + "name": "_aTokenInitialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4187, + "src": "2912:26:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4231, + "name": "_underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4189, + "src": "2952:24:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4232, + "name": "_interestRateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4191, + "src": "2990:28:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4226, + "name": "initReserveWithData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4295, + "src": "2807:19:24", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_string_memory_ptr_$_t_string_memory_ptr_$_t_uint256_$_t_uint256_$_t_address_$returns$__$", + "typeString": "function (address,string memory,string memory,uint256,uint256,address)" + } + }, + "id": 4233, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2807:212:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4234, + "nodeType": "ExpressionStatement", + "src": "2807:212:24" + } + ] + }, + "documentation": "****************************************\n@dev pool core managment functions*****************************************", + "id": 4236, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4194, + "modifierName": { + "argumentTypes": null, + "id": 4193, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "2528:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "2528:22:24" + } + ], + "name": "initReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4192, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4185, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4236, + "src": "2353:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4184, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2353:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4187, + "name": "_aTokenInitialExchangeRate", + "nodeType": "VariableDeclaration", + "scope": 4236, + "src": "2379:34:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4186, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2379:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4189, + "name": "_underlyingAssetDecimals", + "nodeType": "VariableDeclaration", + "scope": 4236, + "src": "2423:32:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4188, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2423:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4191, + "name": "_interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 4236, + "src": "2465:36:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4190, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2465:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2343:159:24" + }, + "returnParameters": { + "id": 4195, + "nodeType": "ParameterList", + "parameters": [], + "src": "2555:0:24" + }, + "scope": 4657, + "src": "2323:704:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4294, + "nodeType": "Block", + "src": "3473:599:24", + "statements": [ + { + "assignments": [ + 4254 + ], + "declarations": [ + { + "constant": false, + "id": 4254, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4294, + "src": "3483:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4253, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "3483:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4260, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4256, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "3522:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4257, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "3522:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4258, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3522:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4255, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "3506:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4259, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3506:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3483:82:24" + }, + { + "assignments": [ + 4262 + ], + "declarations": [ + { + "constant": false, + "id": 4262, + "name": "aTokenInstance", + "nodeType": "VariableDeclaration", + "scope": 4294, + "src": "3576:21:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + }, + "typeName": { + "contractScope": null, + "id": 4261, + "name": "AToken", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10327, + "src": "3576:6:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4273, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4265, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "3624:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + { + "argumentTypes": null, + "id": 4266, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4238, + "src": "3659:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4267, + "name": "_underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4246, + "src": "3681:24:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4268, + "name": "aTokenName", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4240, + "src": "3719:10:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "id": 4269, + "name": "aTokenSymbol", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4242, + "src": "3743:12:24", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + }, + { + "argumentTypes": null, + "hexValue": "3138", + "id": 4270, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3769:2:24", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + { + "argumentTypes": null, + "id": 4271, + "name": "_aTokenInitialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4244, + "src": "3785:26:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + }, + { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 4264, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "NewExpression", + "src": "3600:10:24", + "typeDescriptions": { + "typeIdentifier": "t_function_creation_nonpayable$_t_contract$_LendingPoolAddressesProvider_$1357_$_t_address_$_t_uint256_$_t_string_memory_ptr_$_t_string_memory_ptr_$_t_uint8_$_t_uint256_$returns$_t_contract$_AToken_$10327_$", + "typeString": "function (contract LendingPoolAddressesProvider,address,uint256,string memory,string memory,uint8,uint256) returns (contract AToken)" + }, + "typeName": { + "contractScope": null, + "id": 4263, + "name": "AToken", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10327, + "src": "3604:6:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + } + }, + "id": 4272, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3600:221:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3576:245:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4277, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4238, + "src": "3848:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4279, + "name": "aTokenInstance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4262, + "src": "3866:14:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + ], + "id": 4278, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3858:7:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 4280, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3858:23:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4281, + "name": "_underlyingAssetDecimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4246, + "src": "3883:24:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4282, + "name": "_interestRateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4248, + "src": "3909:28:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4274, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4254, + "src": "3831:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4276, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "initReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6187, + "src": "3831:16:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$", + "typeString": "function (address,address,uint256,address) external" + } + }, + "id": 4283, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3831:107:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4284, + "nodeType": "ExpressionStatement", + "src": "3831:107:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4286, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4238, + "src": "3973:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4288, + "name": "aTokenInstance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4262, + "src": "3991:14:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + ], + "id": 4287, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3983:7:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 4289, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3983:23:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4290, + "name": "_aTokenInitialExchangeRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4244, + "src": "4008:26:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4291, + "name": "_interestRateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4248, + "src": "4036:28:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4285, + "name": "ReserveInitialized", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4119, + "src": "3954:18:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$_t_uint256_$_t_address_$returns$__$", + "typeString": "function (address,address,uint256,address)" + } + }, + "id": 4292, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3954:111:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4293, + "nodeType": "EmitStatement", + "src": "3949:116:24" + } + ] + }, + "documentation": "@notice initialises the reserve and instantiates the specific aToken with the specified initial exchange rate.", + "id": 4295, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4251, + "modifierName": { + "argumentTypes": null, + "id": 4250, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "3446:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "3446:22:24" + } + ], + "name": "initReserveWithData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4249, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4238, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3203:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4237, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3203:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4240, + "name": "aTokenName", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3229:24:24", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 4239, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "3229:6:24", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4242, + "name": "aTokenSymbol", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3263:26:24", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 4241, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "3263:6:24", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4244, + "name": "_aTokenInitialExchangeRate", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3299:34:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4243, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3299:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4246, + "name": "_underlyingAssetDecimals", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3343:32:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4245, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3343:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4248, + "name": "_interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 4295, + "src": "3385:36:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4247, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3385:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3193:229:24" + }, + "returnParameters": { + "id": 4252, + "nodeType": "ParameterList", + "parameters": [], + "src": "3473:0:24" + }, + "scope": 4657, + "src": "3165:907:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 4324, + "nodeType": "Block", + "src": "4293:248:24", + "statements": [ + { + "assignments": [ + 4305 + ], + "declarations": [ + { + "constant": false, + "id": 4305, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4324, + "src": "4303:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4304, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "4303:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4311, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4307, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "4342:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4308, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "4342:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4309, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4342:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4306, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "4326:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4310, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4326:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4303:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4315, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4297, + "src": "4425:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4316, + "name": "_fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4299, + "src": "4435:23:24", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "expression": { + "argumentTypes": null, + "id": 4312, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4305, + "src": "4395:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4314, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "enableBorrowingOnReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6221, + "src": "4395:29:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_bool_$returns$__$", + "typeString": "function (address,bool) external" + } + }, + "id": 4317, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4395:64:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4318, + "nodeType": "ExpressionStatement", + "src": "4395:64:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4320, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4297, + "src": "4500:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4321, + "name": "_fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4299, + "src": "4510:23:24", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "id": 4319, + "name": "BorrowingEnabledOnReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4125, + "src": "4474:25:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_bool_$returns$__$", + "typeString": "function (address,bool)" + } + }, + "id": 4322, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4474:60:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4323, + "nodeType": "EmitStatement", + "src": "4469:65:24" + } + ] + }, + "documentation": "@notice functions to enable/disable borrowing on reserve.", + "id": 4325, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4302, + "modifierName": { + "argumentTypes": null, + "id": 4301, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "4270:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4270:22:24" + } + ], + "name": "enableBorrowingOnReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4300, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4297, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4325, + "src": "4200:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4296, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4200:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4299, + "name": "_fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 4325, + "src": "4226:28:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 4298, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "4226:4:24", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4190:70:24" + }, + "returnParameters": { + "id": 4303, + "nodeType": "ParameterList", + "parameters": [], + "src": "4293:0:24" + }, + "scope": 4657, + "src": "4157:384:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4350, + "nodeType": "Block", + "src": "4632:201:24", + "statements": [ + { + "assignments": [ + 4333 + ], + "declarations": [ + { + "constant": false, + "id": 4333, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4350, + "src": "4642:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4332, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "4642:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4339, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4335, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "4681:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4336, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "4681:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4337, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4681:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4334, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "4665:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4338, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4665:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4642:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4343, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4327, + "src": "4765:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4340, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4333, + "src": "4734:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4342, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "disableBorrowingOnReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6235, + "src": "4734:30:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4344, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4734:40:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4345, + "nodeType": "ExpressionStatement", + "src": "4734:40:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4347, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4327, + "src": "4817:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4346, + "name": "BorrowingDisabledOnReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4129, + "src": "4790:26:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4348, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4790:36:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4349, + "nodeType": "EmitStatement", + "src": "4785:41:24" + } + ] + }, + "documentation": null, + "id": 4351, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4330, + "modifierName": { + "argumentTypes": null, + "id": 4329, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "4609:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4609:22:24" + } + ], + "name": "disableBorrowingOnReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4328, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4327, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4351, + "src": "4582:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4326, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4582:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4581:18:24" + }, + "returnParameters": { + "id": 4331, + "nodeType": "ParameterList", + "parameters": [], + "src": "4632:0:24" + }, + "scope": 4657, + "src": "4547:286:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4384, + "nodeType": "Block", + "src": "5099:290:24", + "statements": [ + { + "assignments": [ + 4363 + ], + "declarations": [ + { + "constant": false, + "id": 4363, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4384, + "src": "5109:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4362, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "5109:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4369, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4365, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "5148:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4366, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "5148:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4367, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5148:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4364, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "5132:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4368, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5132:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5109:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4373, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4353, + "src": "5232:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4374, + "name": "_baseLTVasCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4355, + "src": "5242:20:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4375, + "name": "_liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4357, + "src": "5264:21:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 4370, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4363, + "src": "5201:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4372, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "enableReserveAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 6255, + "src": "5201:30:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 4376, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5201:85:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4377, + "nodeType": "ExpressionStatement", + "src": "5201:85:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4379, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4353, + "src": "5328:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4380, + "name": "_baseLTVasCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4355, + "src": "5338:20:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4381, + "name": "_liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4357, + "src": "5360:21:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 4378, + "name": "ReserveEnabledAsCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4137, + "src": "5301:26:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256)" + } + }, + "id": 4382, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5301:81:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4383, + "nodeType": "EmitStatement", + "src": "5296:86:24" + } + ] + }, + "documentation": "@notice functions to enable/disable usage of the reserve as collateral.", + "id": 4385, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4360, + "modifierName": { + "argumentTypes": null, + "id": 4359, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "5072:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5072:22:24" + } + ], + "name": "enableReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4358, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4353, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4385, + "src": "4968:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4352, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4968:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4355, + "name": "_baseLTVasCollateral", + "nodeType": "VariableDeclaration", + "scope": 4385, + "src": "4986:28:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4354, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4986:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4357, + "name": "_liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 4385, + "src": "5016:29:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4356, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5016:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4967:79:24" + }, + "returnParameters": { + "id": 4361, + "nodeType": "ParameterList", + "parameters": [], + "src": "5099:0:24" + }, + "scope": 4657, + "src": "4933:456:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4410, + "nodeType": "Block", + "src": "5481:203:24", + "statements": [ + { + "assignments": [ + 4393 + ], + "declarations": [ + { + "constant": false, + "id": 4393, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4410, + "src": "5491:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4392, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "5491:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4399, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4395, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "5530:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4396, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "5530:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4397, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5530:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4394, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "5514:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4398, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5514:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5491:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4403, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4387, + "src": "5615:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4400, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4393, + "src": "5583:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4402, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "disableReserveAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 6269, + "src": "5583:31:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4404, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5583:41:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4405, + "nodeType": "ExpressionStatement", + "src": "5583:41:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4407, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4387, + "src": "5668:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4406, + "name": "ReserveDisabledAsCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4141, + "src": "5640:27:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4408, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5640:37:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4409, + "nodeType": "EmitStatement", + "src": "5635:42:24" + } + ] + }, + "documentation": null, + "id": 4411, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4390, + "modifierName": { + "argumentTypes": null, + "id": 4389, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "5458:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5458:22:24" + } + ], + "name": "disableReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4388, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4387, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4411, + "src": "5431:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4386, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5431:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5430:18:24" + }, + "returnParameters": { + "id": 4391, + "nodeType": "ParameterList", + "parameters": [], + "src": "5481:0:24" + }, + "scope": 4657, + "src": "5395:289:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4436, + "nodeType": "Block", + "src": "5873:203:24", + "statements": [ + { + "assignments": [ + 4419 + ], + "declarations": [ + { + "constant": false, + "id": 4419, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4436, + "src": "5883:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4418, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "5883:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4425, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4421, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "5922:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4422, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "5922:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4423, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5922:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4420, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "5906:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4424, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5906:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5883:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4429, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4413, + "src": "6009:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4426, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4419, + "src": "5975:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4428, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "enableReserveFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6291, + "src": "5975:33:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4430, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5975:43:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4431, + "nodeType": "ExpressionStatement", + "src": "5975:43:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4433, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4413, + "src": "6060:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4432, + "name": "FixedRateEnabledOnReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4145, + "src": "6034:25:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4434, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6034:35:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4435, + "nodeType": "EmitStatement", + "src": "6029:40:24" + } + ] + }, + "documentation": "@notice functions to enable/disable fixed borrow rate mode on a reserve.", + "id": 4437, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4416, + "modifierName": { + "argumentTypes": null, + "id": 4415, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "5850:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5850:22:24" + } + ], + "name": "enableReserveFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4414, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4413, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4437, + "src": "5823:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4412, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5823:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5822:18:24" + }, + "returnParameters": { + "id": 4417, + "nodeType": "ParameterList", + "parameters": [], + "src": "5873:0:24" + }, + "scope": 4657, + "src": "5785:291:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4462, + "nodeType": "Block", + "src": "6171:205:24", + "statements": [ + { + "assignments": [ + 4445 + ], + "declarations": [ + { + "constant": false, + "id": 4445, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4462, + "src": "6181:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4444, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "6181:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4451, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4447, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "6220:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4448, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "6220:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4449, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6220:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4446, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "6204:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4450, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6204:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6181:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4455, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4439, + "src": "6308:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4452, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4445, + "src": "6273:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4454, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "disableReserveFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6313, + "src": "6273:34:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4456, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6273:44:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4457, + "nodeType": "ExpressionStatement", + "src": "6273:44:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4459, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4439, + "src": "6360:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4458, + "name": "FixedRateDisabledOnReserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4149, + "src": "6333:26:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4460, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6333:36:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4461, + "nodeType": "EmitStatement", + "src": "6328:41:24" + } + ] + }, + "documentation": null, + "id": 4463, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4442, + "modifierName": { + "argumentTypes": null, + "id": 4441, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "6148:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6148:22:24" + } + ], + "name": "disableReserveFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4440, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4439, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4463, + "src": "6121:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4438, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6121:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6120:18:24" + }, + "returnParameters": { + "id": 4443, + "nodeType": "ParameterList", + "parameters": [], + "src": "6171:0:24" + }, + "scope": 4657, + "src": "6082:294:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4488, + "nodeType": "Block", + "src": "6457:181:24", + "statements": [ + { + "assignments": [ + 4471 + ], + "declarations": [ + { + "constant": false, + "id": 4471, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4488, + "src": "6467:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4470, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "6467:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4477, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4473, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "6506:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4474, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "6506:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4475, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6506:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4472, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "6490:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4476, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6490:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6467:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4481, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4465, + "src": "6580:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4478, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4471, + "src": "6559:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4480, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "activateReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6348, + "src": "6559:20:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4482, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6559:30:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4483, + "nodeType": "ExpressionStatement", + "src": "6559:30:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4485, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4465, + "src": "6622:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4484, + "name": "ReserveActivated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4153, + "src": "6605:16:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4486, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6605:26:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4487, + "nodeType": "EmitStatement", + "src": "6600:31:24" + } + ] + }, + "documentation": null, + "id": 4489, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4468, + "modifierName": { + "argumentTypes": null, + "id": 4467, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "6434:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6434:22:24" + } + ], + "name": "activateReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4466, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4465, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4489, + "src": "6407:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4464, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6407:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6406:18:24" + }, + "returnParameters": { + "id": 4469, + "nodeType": "ParameterList", + "parameters": [], + "src": "6457:0:24" + }, + "scope": 4657, + "src": "6382:256:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4514, + "nodeType": "Block", + "src": "6721:185:24", + "statements": [ + { + "assignments": [ + 4497 + ], + "declarations": [ + { + "constant": false, + "id": 4497, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4514, + "src": "6731:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4496, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "6731:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4503, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4499, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "6770:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4500, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "6770:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4501, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6770:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4498, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "6754:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4502, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6754:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6731:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4507, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4491, + "src": "6846:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4504, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4497, + "src": "6823:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4506, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "deactivateReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6370, + "src": "6823:22:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4508, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6823:32:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4509, + "nodeType": "ExpressionStatement", + "src": "6823:32:24" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4511, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4491, + "src": "6890:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4510, + "name": "ReserveDeactivated", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4157, + "src": "6871:18:24", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 4512, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6871:28:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4513, + "nodeType": "EmitStatement", + "src": "6866:33:24" + } + ] + }, + "documentation": null, + "id": 4515, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4494, + "modifierName": { + "argumentTypes": null, + "id": 4493, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "6698:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6698:22:24" + } + ], + "name": "deactivateReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4492, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4491, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4515, + "src": "6671:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4490, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6671:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6670:18:24" + }, + "returnParameters": { + "id": 4495, + "nodeType": "ParameterList", + "parameters": [], + "src": "6721:0:24" + }, + "scope": 4657, + "src": "6644:262:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4539, + "nodeType": "Block", + "src": "7178:159:24", + "statements": [ + { + "assignments": [ + 4525 + ], + "declarations": [ + { + "constant": false, + "id": 4525, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4539, + "src": "7188:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4524, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "7188:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4531, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4527, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "7227:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4528, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "7227:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4529, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7227:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4526, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "7211:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4530, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7211:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7188:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4535, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4517, + "src": "7315:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4536, + "name": "_ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4519, + "src": "7325:4:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 4532, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4525, + "src": "7280:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4534, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveBaseLTVasCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 6394, + "src": "7280:34:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 4537, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7280:50:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4538, + "nodeType": "ExpressionStatement", + "src": "7280:50:24" + } + ] + }, + "documentation": "*************\n@dev functions to update available collaterals\n@dev the interest rate and the ltv are expressed in percentage**************", + "id": 4540, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4522, + "modifierName": { + "argumentTypes": null, + "id": 4521, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "7155:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "7155:22:24" + } + ], + "name": "setReserveBaseLTVasCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4520, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4517, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4540, + "src": "7114:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4516, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7114:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4519, + "name": "_ltv", + "nodeType": "VariableDeclaration", + "scope": 4540, + "src": "7132:12:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4518, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7132:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7113:32:24" + }, + "returnParameters": { + "id": 4523, + "nodeType": "ParameterList", + "parameters": [], + "src": "7178:0:24" + }, + "scope": 4657, + "src": "7075:262:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4564, + "nodeType": "Block", + "src": "7473:166:24", + "statements": [ + { + "assignments": [ + 4550 + ], + "declarations": [ + { + "constant": false, + "id": 4550, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4564, + "src": "7483:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4549, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "7483:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4556, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4552, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "7522:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4553, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "7522:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4554, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7522:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4551, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "7506:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4555, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7506:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7483:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4560, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4542, + "src": "7611:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4561, + "name": "_threshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4544, + "src": "7621:10:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 4557, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4550, + "src": "7575:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4559, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 6418, + "src": "7575:35:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 4562, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7575:57:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4563, + "nodeType": "ExpressionStatement", + "src": "7575:57:24" + } + ] + }, + "documentation": null, + "id": 4565, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4547, + "modifierName": { + "argumentTypes": null, + "id": 4546, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "7446:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "7446:22:24" + } + ], + "name": "setReserveLiquidationThreshold", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4545, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4542, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4565, + "src": "7383:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4541, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7383:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4544, + "name": "_threshold", + "nodeType": "VariableDeclaration", + "scope": 4565, + "src": "7401:18:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4543, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7401:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7382:38:24" + }, + "returnParameters": { + "id": 4548, + "nodeType": "ParameterList", + "parameters": [], + "src": "7473:0:24" + }, + "scope": 4657, + "src": "7343:296:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4589, + "nodeType": "Block", + "src": "7774:165:24", + "statements": [ + { + "assignments": [ + 4575 + ], + "declarations": [ + { + "constant": false, + "id": 4575, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4589, + "src": "7784:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4574, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "7784:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4581, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4577, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "7823:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4578, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "7823:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4579, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7823:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4576, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "7807:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4580, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7807:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7784:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4585, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4567, + "src": "7911:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4586, + "name": "_threshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4569, + "src": "7921:10:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 4582, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4575, + "src": "7876:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4584, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLiquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 6442, + "src": "7876:34:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 4587, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7876:56:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4588, + "nodeType": "ExpressionStatement", + "src": "7876:56:24" + } + ] + }, + "documentation": null, + "id": 4590, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4572, + "modifierName": { + "argumentTypes": null, + "id": 4571, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "7747:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "7747:22:24" + } + ], + "name": "setReserveLiquidationDiscount", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4570, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4567, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4590, + "src": "7684:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4566, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7684:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4569, + "name": "_threshold", + "nodeType": "VariableDeclaration", + "scope": 4590, + "src": "7702:18:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4568, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7702:7:24", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7683:38:24" + }, + "returnParameters": { + "id": 4573, + "nodeType": "ParameterList", + "parameters": [], + "src": "7774:0:24" + }, + "scope": 4657, + "src": "7645:294:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4614, + "nodeType": "Block", + "src": "8074:183:24", + "statements": [ + { + "assignments": [ + 4600 + ], + "declarations": [ + { + "constant": false, + "id": 4600, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4614, + "src": "8084:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4599, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "8084:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4606, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4602, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "8123:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4603, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "8123:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4604, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8123:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4601, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "8107:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4605, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8107:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8084:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4610, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4592, + "src": "8219:8:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 4611, + "name": "_rateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4594, + "src": "8229:20:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4607, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4600, + "src": "8176:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4609, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveInterestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 6204, + "src": "8176:42:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 4612, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8176:74:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4613, + "nodeType": "ExpressionStatement", + "src": "8176:74:24" + } + ] + }, + "documentation": null, + "id": 4615, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4597, + "modifierName": { + "argumentTypes": null, + "id": 4596, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "8051:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "8051:22:24" + } + ], + "name": "setReserveInterestRateStrategyAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4595, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4592, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4615, + "src": "7994:16:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4591, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7994:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4594, + "name": "_rateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 4615, + "src": "8012:28:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4593, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "8012:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7992:49:24" + }, + "returnParameters": { + "id": 4598, + "nodeType": "ParameterList", + "parameters": [], + "src": "8074:0:24" + }, + "scope": 4657, + "src": "7946:311:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4636, + "nodeType": "Block", + "src": "8359:145:24", + "statements": [ + { + "assignments": [ + 4623 + ], + "declarations": [ + { + "constant": false, + "id": 4623, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4636, + "src": "8369:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4622, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "8369:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4629, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4625, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "8408:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4626, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "8408:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4627, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8408:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4624, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "8392:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4628, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8392:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8369:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4633, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4617, + "src": "8487:9:24", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 4630, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4623, + "src": "8461:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4632, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setAddressesProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 6151, + "src": "8461:25:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 4634, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8461:36:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4635, + "nodeType": "ExpressionStatement", + "src": "8461:36:24" + } + ] + }, + "documentation": null, + "id": 4637, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4620, + "modifierName": { + "argumentTypes": null, + "id": 4619, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "8336:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "8336:22:24" + } + ], + "name": "setLendingPoolCoreAddressesProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4618, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4617, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 4637, + "src": "8308:17:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4616, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "8308:7:24", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8307:19:24" + }, + "returnParameters": { + "id": 4621, + "nodeType": "ParameterList", + "parameters": [], + "src": "8359:0:24" + }, + "scope": 4657, + "src": "8263:241:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4655, + "nodeType": "Block", + "src": "8589:136:24", + "statements": [ + { + "assignments": [ + 4643 + ], + "declarations": [ + { + "constant": false, + "id": 4643, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 4655, + "src": "8599:20:24", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 4642, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "8599:15:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4649, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4645, + "name": "poolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4159, + "src": "8638:21:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4646, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "8638:40:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 4647, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8638:42:24", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 4644, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "8622:15:24", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 4648, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8622:59:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8599:82:24" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4650, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4643, + "src": "8691:4:24", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 4652, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "refreshConfiguration", + "nodeType": "MemberAccess", + "referencedDeclaration": 6160, + "src": "8691:25:24", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$__$returns$__$", + "typeString": "function () external" + } + }, + "id": 4653, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8691:27:24", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4654, + "nodeType": "ExpressionStatement", + "src": "8691:27:24" + } + ] + }, + "documentation": null, + "id": 4656, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4640, + "modifierName": { + "argumentTypes": null, + "id": 4639, + "name": "onlyLendingPoolManager", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4173, + "src": "8566:22:24", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "8566:22:24" + } + ], + "name": "refreshLendingPoolCoreConfiguration", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4638, + "nodeType": "ParameterList", + "parameters": [], + "src": "8554:2:24" + }, + "returnParameters": { + "id": 4641, + "nodeType": "ParameterList", + "parameters": [], + "src": "8589:0:24" + }, + "scope": 4657, + "src": "8510:215:24", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 4658, + "src": "808:7919:24" + } + ], + "src": "0:8728:24" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.673Z", + "devdoc": { + "author": "Aave", + "methods": { + "initReserve(address,uint256,uint256,address)": { + "details": "pool core managment functions*****************************************" + }, + "isOwner()": { + "details": "Returns true if the caller is the current owner." + }, + "owner()": { + "details": "Returns the address of the current owner." + }, + "renounceOwnership()": { + "details": "Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner." + }, + "setReserveBaseLTVasCollateral(address,uint256)": { + "details": "functions to update available collateralsthe interest rate and the ltv are expressed in percentage**************" + }, + "transferOwnership(address)": { + "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner." + } + }, + "title": "LendingPoolConfigurator contract" + }, + "userdoc": { + "methods": { + "enableBorrowingOnReserve(address,bool)": { + "notice": "functions to enable/disable borrowing on reserve." + }, + "enableReserveAsCollateral(address,uint256,uint256)": { + "notice": "functions to enable/disable usage of the reserve as collateral." + }, + "enableReserveFixedBorrowRate(address)": { + "notice": "functions to enable/disable fixed borrow rate mode on a reserve." + }, + "initReserve(address,uint256,uint256,address)": { + "notice": "****************************************" + }, + "initReserveWithData(address,string,string,uint256,uint256,address)": { + "notice": "initialises the reserve and instantiates the specific aToken with the specified initial exchange rate." + }, + "setReserveBaseLTVasCollateral(address,uint256)": { + "notice": "*************" + } + }, + "notice": "***********************************************************************************Executes configuration methods on the LendingPoolCore contract. Allows to enable/disable reserves, and set different protocol parameters.************************************************************************************" + } +} \ No newline at end of file diff --git a/client/src/contracts/LendingPoolCore.json b/client/src/contracts/LendingPoolCore.json new file mode 100644 index 0000000..e992233 --- /dev/null +++ b/client/src/contracts/LendingPoolCore.json @@ -0,0 +1,48811 @@ +{ + "contractName": "LendingPoolCore", + "abi": [ + { + "constant": true, + "inputs": [ + { + "name": "", + "type": "uint256" + } + ], + "name": "reservesList", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isOwner", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "addressesProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "name": "_addressesProvider", + "type": "address" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "updateReserveCumulativeIndexes", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "cumulateLiquidityToReserveLiquidityIndex", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "updateReserveInterestRates", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "increaseReserveTotalLiquidity", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "decreaseReserveTotalLiquidity", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + }, + { + "name": "_rate", + "type": "uint256" + } + ], + "name": "increaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + }, + { + "name": "_rate", + "type": "uint256" + } + ], + "name": "decreaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "increaseReserveTotalBorrowsVariable", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "decreaseReserveTotalBorrowsVariable", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_principalBalance", + "type": "uint256" + }, + { + "name": "_balanceIncrease", + "type": "uint256" + }, + { + "name": "_newBorrowRateMode", + "type": "uint8" + }, + { + "name": "_fixedRate", + "type": "uint256" + } + ], + "name": "updateReserveTotalBorrowsByRateMode", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "setReserveLastUpdate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "updateUserLastVariableBorrowCumulativeIndex", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "increaseUserOriginationFee", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "decreaseUserOriginationFee", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "increaseUserPrincipalBorrowBalance", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "decreaseUserPrincipalBorrowBalance", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_useAsCollateral", + "type": "bool" + } + ], + "name": "setUserUseReserveAsCollateral", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "setUserLastUpdate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "updateUserFixedBorrowRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "resetUserFixedBorrowRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveInterestRateStrategyAddress", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveATokenAddress", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveAvailableLiquidity", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveTotalLiquidity", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveNormalizedIncome", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveTotalBorrows", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveTotalBorrowsFixed", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveTotalBorrowsVariable", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveLiquidationThreshold", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveLiquidationDiscount", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveCurrentVariableBorrowRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveCurrentFixedBorrowRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveCurrentAverageFixedBorrowRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveCurrentLiquidityRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveLiquidityCumulativeIndex", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveVariableBorrowsCumulativeIndex", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveConfiguration", + "outputs": [ + { + "name": "decimals", + "type": "uint256" + }, + { + "name": "baseLTVasCollateral", + "type": "uint256" + }, + { + "name": "liquidationThreshold", + "type": "uint256" + }, + { + "name": "usageAsCollateralEnabled", + "type": "bool" + }, + { + "name": "fixedBorrowRateEnabled", + "type": "bool" + }, + { + "name": "borrowingEnabled", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "isReserveBorrowingEnabled", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "isReserveUsageAsCollateralEnabled", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveIsFixedBorrowRateEnabled", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveIsActive", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveLastUpdate", + "outputs": [ + { + "name": "timestamp", + "type": "uint40" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "isUserUseReserveAsCollateralEnabled", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserOriginationFee", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserCurrentBorrowRateMode", + "outputs": [ + { + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserCurrentFixedBorrowRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserBorrowBalances", + "outputs": [ + { + "name": "principalBorrowBalance", + "type": "uint256" + }, + { + "name": "compoundedBorrowBalance", + "type": "uint256" + }, + { + "name": "compoundedAmount", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserVariableBorrowCumulativeIndex", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserLastUpdate", + "outputs": [ + { + "name": "timestamp", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveUtilizationRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getReserves", + "outputs": [ + { + "name": "", + "type": "address[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_addressesProvider", + "type": "address" + } + ], + "name": "setAddressesProvider", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "refreshConfiguration", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_aTokenAddress", + "type": "address" + }, + { + "name": "_decimals", + "type": "uint256" + }, + { + "name": "_interestRateStrategyAddress", + "type": "address" + } + ], + "name": "initReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_rateStrategyAddress", + "type": "address" + } + ], + "name": "setReserveInterestRateStrategyAddress", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_fixedBorrowRateEnabled", + "type": "bool" + } + ], + "name": "enableBorrowingOnReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "disableBorrowingOnReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_baseLTVasCollateral", + "type": "uint256" + }, + { + "name": "_liquidationThreshold", + "type": "uint256" + } + ], + "name": "enableReserveAsCollateral", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "disableReserveAsCollateral", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "enableReserveFixedBorrowRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "disableReserveFixedBorrowRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "activateReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "deactivateReserve", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_ltv", + "type": "uint256" + } + ], + "name": "setReserveBaseLTVasCollateral", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_threshold", + "type": "uint256" + } + ], + "name": "setReserveLiquidationThreshold", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_discount", + "type": "uint256" + } + ], + "name": "setReserveLiquidationDiscount", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "transferToUser", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_token", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + }, + { + "name": "destination", + "type": "address" + } + ], + "name": "transferToFeeCollectionAddress", + "outputs": [], + "payable": true, + "stateMutability": "payable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "transferToReserve", + "outputs": [], + "payable": true, + "stateMutability": "payable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveIsActive\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getReserves\",\"outputs\":[{\"name\":\"\",\"type\":\"address[]\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"isReserveUsageAsCollateralEnabled\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"cumulateLiquidityToReserveLiquidityIndex\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"updateUserLastVariableBorrowCumulativeIndex\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserCurrentBorrowRateMode\",\"outputs\":[{\"name\":\"\",\"type\":\"uint8\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_rateStrategyAddress\",\"type\":\"address\"}],\"name\":\"setReserveInterestRateStrategyAddress\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"increaseUserPrincipalBorrowBalance\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"setReserveLastUpdate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"transferToReserve\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_baseLTVasCollateral\",\"type\":\"uint256\"},{\"name\":\"_liquidationThreshold\",\"type\":\"uint256\"}],\"name\":\"enableReserveAsCollateral\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveTotalBorrowsFixed\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_threshold\",\"type\":\"uint256\"}],\"name\":\"setReserveLiquidationThreshold\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveATokenAddress\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"decreaseReserveTotalLiquidity\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"updateUserFixedBorrowRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"deactivateReserve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_principalBalance\",\"type\":\"uint256\"},{\"name\":\"_balanceIncrease\",\"type\":\"uint256\"},{\"name\":\"_newBorrowRateMode\",\"type\":\"uint8\"},{\"name\":\"_fixedRate\",\"type\":\"uint256\"}],\"name\":\"updateReserveTotalBorrowsByRateMode\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"setUserLastUpdate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"updateReserveInterestRates\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserCurrentFixedBorrowRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_aTokenAddress\",\"type\":\"address\"},{\"name\":\"_decimals\",\"type\":\"uint256\"},{\"name\":\"_interestRateStrategyAddress\",\"type\":\"address\"}],\"name\":\"initReserve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"updateReserveCumulativeIndexes\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_rate\",\"type\":\"uint256\"}],\"name\":\"increaseReserveTotalBorrowsFixedAndUpdateAverageRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"increaseReserveTotalBorrowsVariable\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveLastUpdate\",\"outputs\":[{\"name\":\"timestamp\",\"type\":\"uint40\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"reservesList\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveIsFixedBorrowRateEnabled\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"isReserveBorrowingEnabled\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveConfiguration\",\"outputs\":[{\"name\":\"decimals\",\"type\":\"uint256\"},{\"name\":\"baseLTVasCollateral\",\"type\":\"uint256\"},{\"name\":\"liquidationThreshold\",\"type\":\"uint256\"},{\"name\":\"usageAsCollateralEnabled\",\"type\":\"bool\"},{\"name\":\"fixedBorrowRateEnabled\",\"type\":\"bool\"},{\"name\":\"borrowingEnabled\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"refreshConfiguration\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserLastUpdate\",\"outputs\":[{\"name\":\"timestamp\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_addressesProvider\",\"type\":\"address\"}],\"name\":\"setAddressesProvider\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveInterestRateStrategyAddress\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveCurrentAverageFixedBorrowRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"increaseReserveTotalLiquidity\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isOwner\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveCurrentVariableBorrowRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"enableReserveFixedBorrowRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveTotalBorrowsVariable\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"isUserUseReserveAsCollateralEnabled\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveCurrentFixedBorrowRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserBorrowBalances\",\"outputs\":[{\"name\":\"principalBorrowBalance\",\"type\":\"uint256\"},{\"name\":\"compoundedBorrowBalance\",\"type\":\"uint256\"},{\"name\":\"compoundedAmount\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"decreaseUserOriginationFee\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"decreaseUserPrincipalBorrowBalance\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"disableBorrowingOnReserve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_discount\",\"type\":\"uint256\"}],\"name\":\"setReserveLiquidationDiscount\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_rate\",\"type\":\"uint256\"}],\"name\":\"decreaseReserveTotalBorrowsFixedAndUpdateAverageRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveVariableBorrowsCumulativeIndex\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"activateReserve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveLiquidationDiscount\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveLiquidityCumulativeIndex\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveUtilizationRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveTotalLiquidity\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveCurrentLiquidityRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"addressesProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_token\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"transferToFeeCollectionAddress\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"decreaseReserveTotalBorrowsVariable\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveNormalizedIncome\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_ltv\",\"type\":\"uint256\"}],\"name\":\"setReserveBaseLTVasCollateral\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"disableReserveFixedBorrowRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"increaseUserOriginationFee\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveAvailableLiquidity\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveTotalBorrows\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"disableReserveAsCollateral\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_fixedBorrowRateEnabled\",\"type\":\"bool\"}],\"name\":\"enableBorrowingOnReserve\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"resetUserFixedBorrowRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveLiquidationThreshold\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserVariableBorrowCumulativeIndex\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_useAsCollateral\",\"type\":\"bool\"}],\"name\":\"setUserUseReserveAsCollateral\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"transferToUser\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserOriginationFee\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_addressesProvider\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"fallback\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"}],\"devdoc\":{\"author\":\"Aave\",\"methods\":{\"getReserveConfiguration(address)\":{\"details\":\"this function aggregates the configuration parameters of the reserve. It's used in the LendingPoolDataProvider specifically to save gas, and avoid multiple external contract calls to fetch the same data.\"},\"getReserveInterestRateStrategyAddress(address)\":{\"details\":\"reserve accessors********************\"},\"getReserveUtilizationRate(address)\":{\"details\":\"utility functions\"},\"isOwner()\":{\"details\":\"Returns true if the caller is the current owner.\"},\"isUserUseReserveAsCollateralEnabled(address,address)\":{\"details\":\"user accessors*****************\"},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"},\"setAddressesProvider(address)\":{\"details\":\"Core configuration functions\"},\"setReserveBaseLTVasCollateral(address,uint256)\":{\"details\":\"functions to update available collateralsthe interest rate and the ltv are expressed in percentage\"},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"},\"updateReserveTotalBorrowsByRateMode(address,address,uint256,uint256,uint8,uint256)\":{\"details\":\"increases the proper total borrows on a reserve depending on the type of interest rate chosen by the user**************\"},\"updateUserFixedBorrowRate(address,address)\":{\"details\":\"updates the fixed borrow rate for the user******************\"},\"updateUserLastVariableBorrowCumulativeIndex(address,address)\":{\"details\":\"functions to update users reserve data\"}},\"title\":\"LendingPoolCore contract\"},\"userdoc\":{\"methods\":{\"cumulateLiquidityToReserveLiquidityIndex(address,uint256)\":{\"notice\":\"cumulates a fixed amount of liquidity to the reserve, considered as a specific interest accrued in one block. Please refer to the whitepaper for further information.\"},\"decreaseReserveTotalBorrowsFixedAndUpdateAverageRate(address,uint256,uint256)\":{\"notice\":\"decreases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper for further information.\"},\"decreaseReserveTotalBorrowsVariable(address,uint256)\":{\"notice\":\"decreases the the total borrow variable of a reserve Bv.\"},\"decreaseReserveTotalLiquidity(address,uint256)\":{\"notice\":\"decreases the total liquidity Lt of a reserve\"},\"getReserveInterestRateStrategyAddress(address)\":{\"notice\":\"*******************\"},\"increaseReserveTotalBorrowsFixedAndUpdateAverageRate(address,uint256,uint256)\":{\"notice\":\"increases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper for further information.\"},\"increaseReserveTotalBorrowsVariable(address,uint256)\":{\"notice\":\"increases the the total borrow variable of a reserve Bv.\"},\"increaseReserveTotalLiquidity(address,uint256)\":{\"notice\":\"increases the total liquidity Lt of a reserve\"},\"isUserUseReserveAsCollateralEnabled(address,address)\":{\"notice\":\"****************\"},\"setReserveBaseLTVasCollateral(address,uint256)\":{\"notice\":\"*************\"},\"setReserveLastUpdate(address)\":{\"notice\":\"refreshes reserve last updated block number Bl\"},\"updateReserveCumulativeIndexes(address)\":{\"notice\":\"Updates the reserve Liquidity cumulative interest Ci and the Variable borrows cumulative index Bvc. Please refer to the whitepaper for further information.\"},\"updateReserveInterestRates(address)\":{\"notice\":\"Updates the reserve current fixed borrow rate Rf, the current variable borrow rate Rv and the current liquidity rate Rl. Please refer to the whitepaper for further information.\"},\"updateReserveTotalBorrowsByRateMode(address,address,uint256,uint256,uint8,uint256)\":{\"notice\":\"*************\"},\"updateUserFixedBorrowRate(address,address)\":{\"notice\":\"****************\"},\"updateUserLastVariableBorrowCumulativeIndex(address,address)\":{\"notice\":\"*************\"}},\"notice\":\"***********************************************************************************Contains all the data and the funds deposited into a lending pool************************************************************************************\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol\":\"LendingPoolCore\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x0ae6004410cd58a1c5151e67959167cf58cd5e77e8b625677826e295905fb318\",\"urls\":[\"bzzr://d223bea23f0e9bd70844e9852f490be93d30fc1c31bf114c807d0e4fe07d929b\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":{\"keccak256\":\"0xeeae2b67fa36103fe1c3a4e346b9c04171f9065949953abd00104c357834b0e3\",\"urls\":[\"bzzr://4e3bd29abfa796726532c3e42dd8039ab0f93388d7bbf358428dbc9b0399664a\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x0adf744884b9262f507aba565d1c96c82397f58d399a2dc2c60a452953197574\",\"urls\":[\"bzzr://03099f88c041565b5ac13ea7e645a8f9bff0c29bfa584c7969372ce12c5473f5\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol\":{\"keccak256\":\"0x35a7f1a34259948cdcb03084718f765215fe69559f557b395d9d6e18c63ac823\",\"urls\":[\"bzzr://f529e265dd06192a1d552f1f41c245790419562dfb52e7be9d443c758ccb72d0\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol\":{\"keccak256\":\"0xca757f989e0e7519d03d4e3086028e3022306ec4bb7f610fa78bff866f04c998\",\"urls\":[\"bzzr://f381f642ecce43d76d9e0011ea3c7c6218d1eaa2e0d3a7d5aecd55552cc0fb27\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol\":{\"keccak256\":\"0xb8b4844881a9ea5c3f0f2584061efcbfb6c96863ca3a07b960d2f9d323293cac\",\"urls\":[\"bzzr://8cb1c5dcce198c0f60c21bd9807b361fc214a60d4b3aa3442153b045b51a4325\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]}},\"version\":1}", + "bytecode": "0x60806040523480156200001157600080fd5b5060405160208062008d26833981018060405260208110156200003357600080fd5b8101908080519060200190929190505050620000546200016760201b60201c565b6000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550620001606200016f60201b60201c565b50620003c0565b600033905090565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b158015620001d857600080fd5b505afa158015620001ed573d6000803e3d6000fd5b505050506040513d60208110156200020457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b1580156200025b57600080fd5b505afa15801562000270573d6000803e3d6000fd5b505050506040513d60208110156200028757600080fd5b8101908080519060200190929190505050600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156200034157600080fd5b505afa15801562000356573d6000803e3d6000fd5b505050506040513d60208110156200036d57600080fd5b8101908080519060200190929190505050600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b61895680620003d06000396000f3fe60806040526004361061043c5760003560e01c80638e65a6b011610234578063c540148e1161012e578063e6d18190116100b6578063f2fde38b1161007a578063f2fde38b146120f7578063f6ea8d7614612148578063fa51854c146121cd578063fa93b2a51461224a578063feab31ac146122c55761043c565b8063e6d1819014611f0e578063e8ae2f5b14611f73578063eede87c114611fc4578063f03e79ff14612021578063f054ab46146120925761043c565b8063d15e0053116100fd578063d15e005314611d1d578063d466016f14611d82578063d7e0758114611ddd578063da2f787914611e2e578063e240301914611ea95761043c565b8063c540148e14611b78578063c72c4d1014611bdd578063c7d1423714611c34578063cc6ae76314611cc25761043c565b8063a37b1957116101bc578063b75d6f3411610180578063b75d6f3414611993578063b77b1958146119e4578063bd7fd79a14611a49578063bfacad8414611aae578063c33cfd9014611b135761043c565b8063a37b1957146117a2578063a8dc0f451461181d578063b46a4b341461186e578063b6e1f702146118c9578063b701d0931461192e5761043c565b806398bd47371161020357806398bd4737146115415780639e3c4f3b146115a65780639e7d3b961461162f5780639fb8afcd14611694578063a0fca839146117275761043c565b80638e65a6b0146114015780638f32d59b1461145c578063906c0a411461148b5780639789b68a146114f05761043c565b8063405300df1161034557806353cf36e8116102cd5780636722997a116102915780636722997a1461124c5780636ae144161461129d578063715018a61461132e5780637269e853146113455780638da5cb5b146113aa5761043c565b806353cf36e81461104a5780635cf2e656146110b35780635fc526ff1461111c57806364681083146111b057806366d103f3146111c75761043c565b806348dfc16e1161031457806348dfc16e14610e4b5780634aaa347a14610e9c5780634d79c1c214610f015780634f14460914610f5c5780634fe7a6e514610fcf5761043c565b8063405300df14610c6957806342bbd65314610cda57806344e636b714610d2b57806345330a4014610db05761043c565b806328fcf4d3116103c857806334b3beee1161039757806334b3beee14610a1f578063352ed9d414610ab0578063385c91b014610b0b5780633e72a45414610b7c5780633ef563ad14610bcd5761043c565b806328fcf4d31461088c57806329a17868146108fa578063308f9d551461095f5780633443a14b146109c45761043c565b80631b70fba11161040f5780631b70fba11461064b5780631ca19f19146106bc5780631d2118f91461074f57806320840f6b146107c05780632717cbfb1461083b5761043c565b806305075d6e146104b25780630902f1ac1461051b57806318f9bbae146105875780631a95129f146105f0575b61045b3373ffffffffffffffffffffffffffffffffffffffff1661234a565b6104b0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806186d56036913960400191505060405180910390fd5b005b3480156104be57600080fd5b50610501600480360360208110156104d557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612395565b604051808215151515815260200191505060405180910390f35b34801561052757600080fd5b506105306123f3565b6040518080602001828103825283818151815260200191508051906020019060200280838360005b83811015610573578082015181840152602081019050610558565b505050509050019250505060405180910390f35b34801561059357600080fd5b506105d6600480360360208110156105aa57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612481565b604051808215151515815260200191505060405180910390f35b3480156105fc57600080fd5b506106496004803603604081101561061357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506124df565b005b34801561065757600080fd5b506106ba6004803603604081101561066e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506125da565b005b3480156106c857600080fd5b5061072b600480360360408110156106df57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612756565b6040518082600181111561073b57fe5b60ff16815260200191505060405180910390f35b34801561075b57600080fd5b506107be6004803603604081101561077257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506127f6565b005b3480156107cc57600080fd5b50610839600480360360608110156107e357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506129a1565b005b34801561084757600080fd5b5061088a6004803603602081101561085e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612b93565b005b6108f8600480360360608110156108a257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050612c83565b005b34801561090657600080fd5b5061095d6004803603606081101561091d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190505050612f94565b005b34801561096b57600080fd5b506109ae6004803603602081101561098257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613176565b6040518082815260200191505060405180910390f35b3480156109d057600080fd5b50610a1d600480360360408110156109e757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506131c7565b005b348015610a2b57600080fd5b50610a6e60048036036020811015610a4257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061333e565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b348015610abc57600080fd5b50610b0960048036036040811015610ad357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506133af565b005b348015610b1757600080fd5b50610b7a60048036036040811015610b2e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506134bc565b005b348015610b8857600080fd5b50610bcb60048036036020811015610b9f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506135f8565b005b348015610bd957600080fd5b50610c67600480360360c0811015610bf057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190803560ff16906020019092919080359060200190929190505050613782565b005b348015610c7557600080fd5b50610cd860048036036040811015610c8c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613a63565b005b348015610ce657600080fd5b50610d2960048036036020811015610cfd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613bb3565b005b348015610d3757600080fd5b50610d9a60048036036040811015610d4e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613de8565b6040518082815260200191505060405180910390f35b348015610dbc57600080fd5b50610e4960048036036080811015610dd357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613e77565b005b348015610e5757600080fd5b50610e9a60048036036020811015610e6e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506140c3565b005b348015610ea857600080fd5b50610eff60048036036060811015610ebf57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291905050506141b3565b005b348015610f0d57600080fd5b50610f5a60048036036040811015610f2457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506143af565b005b348015610f6857600080fd5b50610fab60048036036020811015610f7f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506145a8565b604051808264ffffffffff1664ffffffffff16815260200191505060405180910390f35b348015610fdb57600080fd5b5061100860048036036020811015610ff257600080fd5b810190808035906020019092919050505061460a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561105657600080fd5b506110996004803603602081101561106d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614646565b604051808215151515815260200191505060405180910390f35b3480156110bf57600080fd5b50611102600480360360208110156110d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506146a4565b604051808215151515815260200191505060405180910390f35b34801561112857600080fd5b5061116b6004803603602081101561113f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614702565b60405180878152602001868152602001858152602001841515151581526020018315151515815260200182151515158152602001965050505050505060405180910390f35b3480156111bc57600080fd5b506111c56147a9565b005b3480156111d357600080fd5b50611236600480360360408110156111ea57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506148d9565b6040518082815260200191505060405180910390f35b34801561125857600080fd5b5061129b6004803603602081101561126f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614980565b005b3480156112a957600080fd5b506112ec600480360360208110156112c057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614af2565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561133a57600080fd5b50611343614b63565b005b34801561135157600080fd5b506113946004803603602081101561136857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614c9c565b6040518082815260200191505060405180910390f35b3480156113b657600080fd5b506113bf614ced565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561140d57600080fd5b5061145a6004803603604081101561142457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050614d16565b005b34801561146857600080fd5b50611471614f21565b604051808215151515815260200191505060405180910390f35b34801561149757600080fd5b506114da600480360360208110156114ae57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614f7f565b6040518082815260200191505060405180910390f35b3480156114fc57600080fd5b5061153f6004803603602081101561151357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061508b565b005b34801561154d57600080fd5b506115906004803603602081101561156457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615215565b6040518082815260200191505060405180910390f35b3480156115b257600080fd5b50611615600480360360408110156115c957600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615266565b604051808215151515815260200191505060405180910390f35b34801561163b57600080fd5b5061167e6004803603602081101561165257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615302565b6040518082815260200191505060405180910390f35b3480156116a057600080fd5b50611703600480360360408110156116b757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506154ca565b60405180848152602001838152602001828152602001935050505060405180910390f35b34801561173357600080fd5b506117a06004803603606081101561174a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506155c2565b005b3480156117ae57600080fd5b5061181b600480360360608110156117c557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061570d565b005b34801561182957600080fd5b5061186c6004803603602081101561184057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506158d2565b005b34801561187a57600080fd5b506118c76004803603604081101561189157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050615aa2565b005b3480156118d557600080fd5b5061192c600480360360608110156118ec57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190505050615c19565b005b34801561193a57600080fd5b5061197d6004803603602081101561195157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615d17565b6040518082815260200191505060405180910390f35b34801561199f57600080fd5b506119e2600480360360208110156119b657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615d68565b005b3480156119f057600080fd5b50611a3360048036036020811015611a0757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615f5f565b6040518082815260200191505060405180910390f35b348015611a5557600080fd5b50611a9860048036036020811015611a6c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615fb0565b6040518082815260200191505060405180910390f35b348015611aba57600080fd5b50611afd60048036036020811015611ad157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616001565b6040518082815260200191505060405180910390f35b348015611b1f57600080fd5b50611b6260048036036020811015611b3657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616051565b6040518082815260200191505060405180910390f35b348015611b8457600080fd5b50611bc760048036036020811015611b9b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506160a2565b6040518082815260200191505060405180910390f35b348015611be957600080fd5b50611bf26160f3565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b611cc060048036036080811015611c4a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616119565b005b348015611cce57600080fd5b50611d1b60048036036040811015611ce557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506162f3565b005b348015611d2957600080fd5b50611d6c60048036036020811015611d4057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506163ee565b6040518082815260200191505060405180910390f35b348015611d8e57600080fd5b50611ddb60048036036040811015611da557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050616443565b005b348015611de957600080fd5b50611e2c60048036036020811015611e0057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506165ba565b005b348015611e3a57600080fd5b50611ea760048036036060811015611e5157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050616744565b005b348015611eb557600080fd5b50611ef860048036036020811015611ecc57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061688f565b6040518082815260200191505060405180910390f35b348015611f1a57600080fd5b50611f5d60048036036020811015611f3157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506168fa565b6040518082815260200191505060405180910390f35b348015611f7f57600080fd5b50611fc260048036036020811015611f9657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061694a565b005b348015611fd057600080fd5b5061201f60048036036040811015611fe757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803515159060200190929190505050616b1a565b005b34801561202d57600080fd5b506120906004803603604081101561204457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616cf7565b005b34801561209e57600080fd5b506120e1600480360360208110156120b557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616e2c565b6040518082815260200191505060405180910390f35b34801561210357600080fd5b506121466004803603602081101561211a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616e7d565b005b34801561215457600080fd5b506121b76004803603604081101561216b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616f03565b6040518082815260200191505060405180910390f35b3480156121d957600080fd5b50612248600480360360608110156121f057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803515159060200190929190505050616f92565b005b34801561225657600080fd5b506122c36004803603606081101561226d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506170da565b005b3480156122d157600080fd5b50612334600480360360408110156122e857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050617252565b6040518082815260200191505060405180910390f35b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f91506000801b821415801561238c5750808214155b92505050919050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e01601c9054906101000a900460ff16915050919050565b6060600680548060200260200160405190810160405280929190818152602001828054801561247757602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001906001019080831161242d575b5050505050905090565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e01601a9054906101000a900460ff16915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612585576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6125d681600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206172e190919063ffffffff16565b5050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612680576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506000600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060080154826001018190555050505050565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008160030154116127ea5760016127ed565b60005b91505092915050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561287557600080fd5b505afa158015612889573d6000803e3d6000fd5b505050506040513d602081101561289f57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161461291c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b80600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e0160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612a47576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b82600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e0160199054906101000a900460ff16612aed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602481526020018061867c6024913960400191505060405180910390fd5b6000600560008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050612b8483826000015461734f90919063ffffffff16565b81600001819055505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612c39576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b612c80600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206173d7565b50565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612d29576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e01601a9054906101000a900460ff1680612d97575080600e0160199054906101000a900460ff165b612dec576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260388152602001806188f36038913960400191505060405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614612ecc5760003414612e9a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252605f81526020018061870b605f913960600191505060405180910390fd5b612ec78330848773ffffffffffffffffffffffffffffffffffffffff166173ff909392919063ffffffff16565b612f8e565b81341015612f25576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260358152602001806186a06035913960400191505060405180910390fd5b81341115612f8d576000612f42833461750590919063ffffffff16565b90508373ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f19350505050158015612f8a573d6000803e3d6000fd5b50505b5b50505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561301357600080fd5b505afa158015613027573d6000803e3d6000fd5b505050506040513d602081101561303d57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146130ba576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002073__CoreLibrary___________________________632eb0d006909184846040518463ffffffff1660e01b815260040180848152602001838152602001828152602001935050505060006040518083038186803b15801561315957600080fd5b505af415801561316d573d6000803e3d6000fd5b50505050505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060030154915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561324657600080fd5b505afa15801561325a573d6000803e3d6000fd5b505050506040513d602081101561327057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146132ed576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508181600a0181905550505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600d0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614613455576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506134af82826000015461750590919063ffffffff16565b8160000181905550505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614613562576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506135eb83615302565b8160030181905550505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561367757600080fd5b505afa15801561368b573d6000803e3d6000fd5b505050506040513d60208110156136a157600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161461371e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050600081600e01601c6101000a81548160ff0219169083151502179055505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614613828576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b60006138348787612756565b90506000600460008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506000600181111561388657fe5b82600181111561389257fe5b14156139c7576000600560008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506139318782600301548461754f9092919063ffffffff16565b6000600181111561393e57fe5b85600181111561394a57fe5b141561397c57613977613966878961734f90919063ffffffff16565b85846176eb9092919063ffffffff16565b6139c1565b60018081111561398857fe5b85600181111561399457fe5b14156139c0576139bf6139b0878961734f90919063ffffffff16565b8361779690919063ffffffff16565b5b5b50613a59565b600060018111156139d457fe5b8460018111156139e057fe5b1415613a25576139f986826177b990919063ffffffff16565b613a20613a0f868861734f90919063ffffffff16565b84836176eb9092919063ffffffff16565b613a58565b600180811115613a3157fe5b846001811115613a3d57fe5b1415613a5757613a56858261779690919063ffffffff16565b5b5b5b5050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614613b09576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050428160040160006101000a81548164ffffffffff021916908364ffffffffff160217905550505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614613c59576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166357e37af083613ce684617839565b8460030154856004015486600701546040518663ffffffff1660e01b8152600401808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018581526020018481526020018381526020018281526020019550505050505060606040518083038186803b158015613d7157600080fd5b505afa158015613d85573d6000803e3d6000fd5b505050506040513d6060811015613d9b57600080fd5b810190808051906020019092919080519060200190929190805190602001909291905050508360020160008560060160008760050160008691905055859190505584919050555050505050565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050806003015491505092915050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b158015613ef657600080fd5b505afa158015613f0a573d6000803e3d6000fd5b505050506040513d6020811015613f2057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614613f9d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002073__CoreLibrary___________________________6313769cd490918585856040518563ffffffff1660e01b8152600401808581526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200194505050505060006040518083038186803b15801561409c57600080fd5b505af41580156140b0573d6000803e3d6000fd5b505050506140bd8461788f565b50505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614614169576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6141b0600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020617995565b50565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614614259576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b82600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e0160199054906101000a900460ff16806143015750600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e01601a9054906101000a900460ff165b614356576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604481526020018061885b6044913960600191505060405180910390fd5b6143a98383600460008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206176eb9092919063ffffffff16565b50505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614614455576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b81600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e0160199054906101000a900460ff16806144fd5750600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e01601a9054906101000a900460ff165b614552576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604481526020018061885b6044913960600191505060405180910390fd5b6145a382600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002061779690919063ffffffff16565b505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e0160149054906101000a900464ffffffffff16915050919050565b6006818154811061461757fe5b906000526020600020016000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e01601b9054906101000a900460ff16915050919050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e0160199054906101000a900460ff16915050919050565b6000806000806000806000600460008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600c015496508060090154955080600a0154945080600e01601a9054906101000a900460ff16935080600e01601b9054906101000a900460ff16925080600e0160199054906101000a900460ff1691505091939550919395565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561482857600080fd5b505afa15801561483c573d6000803e3d6000fd5b505050506040513d602081101561485257600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146148cf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6148d7617a3e565b565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060040160009054906101000a900464ffffffffff1664ffffffffff1691505092915050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b1580156149ff57600080fd5b505afa158015614a13573d6000803e3d6000fd5b505050506040513d6020811015614a2957600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614614aa6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b80600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550614aef617a3e565b50565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16915050919050565b614b6b614f21565b614bdd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060070154915050919050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614614dbc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b81600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e0160199054906101000a900460ff1680614e645750600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e01601a9054906101000a900460ff165b614eb9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604481526020018061885b6044913960600191505060405180910390fd5b6000600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050614f1383826000015461734f90919063ffffffff16565b816000018190555050505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16614f63617c86565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008160050154141561507d5780600e0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334762ca56040518163ffffffff1660e01b815260040160206040518083038186803b15801561503a57600080fd5b505afa15801561504e573d6000803e3d6000fd5b505050506040513d602081101561506457600080fd5b8101908080519060200190929190505050915050615086565b80600501549150505b919050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561510a57600080fd5b505afa15801561511e573d6000803e3d6000fd5b505050506040513d602081101561513457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146151b1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050600181600e01601b6101000a81548160ff0219169083151502179055505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060040154915050919050565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060040160059054906101000a900460ff1691505092915050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633618abba6040518163ffffffff1660e01b815260040160206040518083038186803b1580156153b057600080fd5b505afa1580156153c4573d6000803e3d6000fd5b505050506040513d60208110156153da57600080fd5b810190808051906020019092919050505090506000826006015414156154bb578073ffffffffffffffffffffffffffffffffffffffff1663bb85c0bb856040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561547757600080fd5b505afa15801561548b573d6000803e3d6000fd5b505050506040513d60208110156154a157600080fd5b8101908080519060200190929190505050925050506154c5565b8160060154925050505b919050565b600080600080600560008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506000600460008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050816000015494506155a28282617c8e565b93506155b7858561750590919063ffffffff16565b925050509250925092565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614615668576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506156ff82826002015461750590919063ffffffff16565b816002018190555050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146157b3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905081816000015410156158ad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f54686520626f72726f772062616c616e636520697320746f6f206c6f7700000081525060200191505060405180910390fd5b6158c482826000015461750590919063ffffffff16565b816000018190555050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561595157600080fd5b505afa158015615965573d6000803e3d6000fd5b505050506040513d602081101561597b57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146159f8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002073__CoreLibrary___________________________63e5df56a690916040518263ffffffff1660e01b81526004018082815260200191505060006040518083038186803b158015615a8757600080fd5b505af4158015615a9b573d6000803e3d6000fd5b5050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b158015615b2157600080fd5b505afa158015615b35573d6000803e3d6000fd5b505050506040513d6020811015615b4b57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614615bc8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508181600b0181905550505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614615cbf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b615d128282600460008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002061754f9092919063ffffffff16565b505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060080154915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b158015615de757600080fd5b505afa158015615dfb573d6000803e3d6000fd5b505050506040513d6020811015615e1157600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614615e8e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008160010154118015615ee9575060008160080154115b615f3e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806187f26024913960400191505060405180910390fd5b600181600e01601c6101000a81548160ff0219169083151502179055505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600b0154915050919050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060010154915050919050565b600061604a600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020617839565b9050919050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060000154915050919050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060020154915050919050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146161bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000819050600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161461624b576162468482858873ffffffffffffffffffffffffffffffffffffffff166173ff909392919063ffffffff16565b6162ec565b823410156162a4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260358152602001806186a06035913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166108fc849081150290604051600060405180830381858888f193505050501580156162ea573d6000803e3d6000fd5b505b5050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614616399576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6163ea81600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206177b990919063ffffffff16565b5050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905061643b81617da1565b915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b1580156164c257600080fd5b505afa1580156164d6573d6000803e3d6000fd5b505050506040513d60208110156164ec57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614616569576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050818160090181905550505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561663957600080fd5b505afa15801561664d573d6000803e3d6000fd5b505050506040513d602081101561666357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146166e0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050600081600e01601b6101000a81548160ff0219169083151502179055505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146167ea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905061688182826002015461734f90919063ffffffff16565b816002018190555050505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506168f26168df846168fa565b826000015461750590919063ffffffff16565b915050919050565b6000616943600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020617de8565b9050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b1580156169c957600080fd5b505afa1580156169dd573d6000803e3d6000fd5b505050506040513d60208110156169f357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614616a70576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002073__CoreLibrary___________________________6383c165a090916040518263ffffffff1660e01b81526004018082815260200191505060006040518083038186803b158015616aff57600080fd5b505af4158015616b13573d6000803e3d6000fd5b5050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b158015616b9957600080fd5b505afa158015616bad573d6000803e3d6000fd5b505050506040513d6020811015616bc357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614616c40576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002073__CoreLibrary___________________________63f63babbe9091836040518363ffffffff1660e01b815260040180838152602001821515151581526020019250505060006040518083038186803b158015616cdb57600080fd5b505af4158015616cef573d6000803e3d6000fd5b505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614616d9d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008160030181905550505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600a0154915050919050565b616e85614f21565b616ef7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b616f0081617e0c565b50565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050806001015491505092915050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614617038576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050818160040160056101000a81548160ff02191690831515021790555050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614617180576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16146172055761720082828573ffffffffffffffffffffffffffffffffffffffff16617f509092919063ffffffff16565b61724d565b8173ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f1935050505015801561724b573d6000803e3d6000fd5b505b505050565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050806002015491505092915050565b600061730a6172f38460000154618021565b6172fc84618021565b61804190919063ffffffff16565b9050600061732861731961809d565b8361734f90919063ffffffff16565b90506173418460010154826180b190919063ffffffff16565b846001018190555050505050565b6000808284019050838110156173cd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b4281600e0160146101000a81548164ffffffffff021916908364ffffffffff16021790555050565b6174ff848573ffffffffffffffffffffffffffffffffffffffff166323b872dd905060e01b858585604051602401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050618114565b50505050565b600061754783836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525061835f565b905092915050565b81836003015410156175c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f496e76616c696420616d6f756e7420746f20646563726561736500000000000081525060200191505060405180910390fd5b6000836003015490506175e983856003015461750590919063ffffffff16565b846003018190555060008460030154141561760e5760008460070181905550506176e6565b600061762b8361761d86618021565b6180b190919063ffffffff16565b9050600061764e866007015461764085618021565b6180b190919063ffffffff16565b9050818110156176a9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806188166024913960400191505060405180910390fd5b6176da6176b98760030154618021565b6176cc848461750590919063ffffffff16565b61804190919063ffffffff16565b86600701819055505050505b505050565b60008360030154905061770b83856003015461734f90919063ffffffff16565b846003018190555060006177308361772286618021565b6180b190919063ffffffff16565b90506000617753866007015461774585618021565b6180b190919063ffffffff16565b90506177866177658760030154618021565b617778838561734f90919063ffffffff16565b61804190919063ffffffff16565b8660070181905550505050505050565b6177ad81836004015461734f90919063ffffffff16565b82600401819055505050565b8082600401541015617816576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252605181526020018061876a6051913960600191505060405180910390fd5b61782d81836004015461750590919063ffffffff16565b82600401819055505050565b60008082600001541415617850576000905061788a565b600061786d8360040154846003015461734f90919063ffffffff16565b905061788683600001548261804190919063ffffffff16565b9150505b919050565b600080905060008090505b600680549050811015617924578273ffffffffffffffffffffffffffffffffffffffff16600682815481106178cb57fe5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16141561791757600191505b808060010191505061789a565b50806179915760068290806001815401808255809150509060018203906000526020600020016000909192909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505b5050565b60006179a082617839565b90506000811115617a3a5760006179d0836002015484600e0160149054906101000a900464ffffffffff1661841f565b90506179e98360010154826180b190919063ffffffff16565b83600101819055506000617a16846005015485600e0160149054906101000a900464ffffffffff1661841f565b9050617a2f8460080154826180b190919063ffffffff16565b846008018190555050505b5050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b158015617aa657600080fd5b505afa158015617aba573d6000803e3d6000fd5b505050506040513d6020811015617ad057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b158015617b2657600080fd5b505afa158015617b3a573d6000803e3d6000fd5b505050506040513d6020811015617b5057600080fd5b8101908080519060200190929190505050600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b158015617c0957600080fd5b505afa158015617c1d573d6000803e3d6000fd5b505050506040513d6020811015617c3357600080fd5b8101908080519060200190929190505050600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b600033905090565b60008083600001541415617ca55760009050617d9b565b6000617cb48460000154618021565b905060008090506000809050600086600301541115617cf757617cf086600301548760040160009054906101000a900464ffffffffff1661841f565b9050617d49565b617d468660010154617d388760080154617d2a89600501548a600e0160149054906101000a900464ffffffffff1661841f565b6180b190919063ffffffff16565b61804190919063ffffffff16565b90505b617d64617d5f82856180b190919063ffffffff16565b61849f565b91508560000154821415617d9457617d8a6001876000015461734f90919063ffffffff16565b9350505050617d9b565b8193505050505b92915050565b600080617ddd8360010154617dcf856002015486600e0160149054906101000a900464ffffffffff1661841f565b6180b190919063ffffffff16565b905080915050919050565b6000617e058260040154836003015461734f90919063ffffffff16565b9050919050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415617e92576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806186566026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b61801c838473ffffffffffffffffffffffffffffffffffffffff1663a9059cbb905060e01b8484604051602401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050618114565b505050565b600061803a633b9aca00836184bf90919063ffffffff16565b9050919050565b6000806002838161804e57fe5b049050618094836180866180776b033b2e3c9fd0803ce8000000886184bf90919063ffffffff16565b8461734f90919063ffffffff16565b61854590919063ffffffff16565b91505092915050565b60006b033b2e3c9fd0803ce8000000905090565b600061810c6b033b2e3c9fd0803ce80000006180fe6180d985876184bf90919063ffffffff16565b60026b033b2e3c9fd0803ce8000000816180ef57fe5b0461734f90919063ffffffff16565b61854590919063ffffffff16565b905092915050565b6181338273ffffffffffffffffffffffffffffffffffffffff1661234a565b6181a5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e74726163740081525060200191505060405180910390fd5b600060608373ffffffffffffffffffffffffffffffffffffffff16836040518082805190602001908083835b602083106181f457805182526020820191506020810190506020830392506181d1565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114618256576040519150601f19603f3d011682016040523d82523d6000602084013e61825b565b606091505b5091509150816182d3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656481525060200191505060405180910390fd5b600081511115618359578080602001905160208110156182f257600080fd5b8101908080519060200190929190505050618358576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a8152602001806188c9602a913960400191505060405180910390fd5b5b50505050565b600083831115829061840c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156183d15780820151818401526020810190506183b6565b50505050905090810190601f1680156183fe5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b60008061843c8364ffffffffff164261750590919063ffffffff16565b905060006184676184506301e13380618021565b61845984618021565b61804190919063ffffffff16565b905061849561847461809d565b61848783886180b190919063ffffffff16565b61734f90919063ffffffff16565b9250505092915050565b60006184b8633b9aca008361854590919063ffffffff16565b9050919050565b6000808314156184d2576000905061853f565b60008284029050828482816184e357fe5b041461853a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602181526020018061883a6021913960400191505060405180910390fd5b809150505b92915050565b600061858783836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061858f565b905092915050565b6000808311829061863b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156186005780820151818401526020810190506185e5565b50505050905090810190601f16801561862d5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50600083858161864757fe5b04905080915050939250505056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f206164647265737352657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e6754686520616d6f756e7420616e64207468652076616c75652073656e7420746f206465706f73697420646f206e6f74206d617463684f6e6c7920636f6e7472616374732063616e2073656e6420657468657220746f20746865204c656e64696e6720706f6f6c20636f7265557365722069732073656e64696e672045544820616c6f6e67207769746820746865204552433230207472616e736665722e20436865636b207468652076616c756520617474726962757465206f6620746865207472616e73616374696f6e54686520616d6f756e742074686174206973206265696e672073756273747261637465642066726f6d20746865207661726961626c6520746f74616c20626f72726f777320697320696e636f72726563745468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c20636f6e666967757261746f7220636f6e74726163745265736572766520686173206e6f74206265656e20696e697469616c697a65642079657454686520616d6f756e747320746f2073756273747261637420646f6e2774206d61746368536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7752657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e67206f7220666f72206265696e67207573656420617320636f6c6c61746572616c5468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c20636f6e74726163745361666545524332303a204552433230206f7065726174696f6e20646964206e6f74207375636365656454686520726573657276652069736e277420656e61626c656420666f7220626f72726f77696e67206f7220617320636f6c6c61746572616ca165627a7a723058205a01ee47bede87331f5605293ad6bf3266377c99197ce551361bb321e7c18f170029", + "deployedBytecode": "0x60806040526004361061043c5760003560e01c80638e65a6b011610234578063c540148e1161012e578063e6d18190116100b6578063f2fde38b1161007a578063f2fde38b146120f7578063f6ea8d7614612148578063fa51854c146121cd578063fa93b2a51461224a578063feab31ac146122c55761043c565b8063e6d1819014611f0e578063e8ae2f5b14611f73578063eede87c114611fc4578063f03e79ff14612021578063f054ab46146120925761043c565b8063d15e0053116100fd578063d15e005314611d1d578063d466016f14611d82578063d7e0758114611ddd578063da2f787914611e2e578063e240301914611ea95761043c565b8063c540148e14611b78578063c72c4d1014611bdd578063c7d1423714611c34578063cc6ae76314611cc25761043c565b8063a37b1957116101bc578063b75d6f3411610180578063b75d6f3414611993578063b77b1958146119e4578063bd7fd79a14611a49578063bfacad8414611aae578063c33cfd9014611b135761043c565b8063a37b1957146117a2578063a8dc0f451461181d578063b46a4b341461186e578063b6e1f702146118c9578063b701d0931461192e5761043c565b806398bd47371161020357806398bd4737146115415780639e3c4f3b146115a65780639e7d3b961461162f5780639fb8afcd14611694578063a0fca839146117275761043c565b80638e65a6b0146114015780638f32d59b1461145c578063906c0a411461148b5780639789b68a146114f05761043c565b8063405300df1161034557806353cf36e8116102cd5780636722997a116102915780636722997a1461124c5780636ae144161461129d578063715018a61461132e5780637269e853146113455780638da5cb5b146113aa5761043c565b806353cf36e81461104a5780635cf2e656146110b35780635fc526ff1461111c57806364681083146111b057806366d103f3146111c75761043c565b806348dfc16e1161031457806348dfc16e14610e4b5780634aaa347a14610e9c5780634d79c1c214610f015780634f14460914610f5c5780634fe7a6e514610fcf5761043c565b8063405300df14610c6957806342bbd65314610cda57806344e636b714610d2b57806345330a4014610db05761043c565b806328fcf4d3116103c857806334b3beee1161039757806334b3beee14610a1f578063352ed9d414610ab0578063385c91b014610b0b5780633e72a45414610b7c5780633ef563ad14610bcd5761043c565b806328fcf4d31461088c57806329a17868146108fa578063308f9d551461095f5780633443a14b146109c45761043c565b80631b70fba11161040f5780631b70fba11461064b5780631ca19f19146106bc5780631d2118f91461074f57806320840f6b146107c05780632717cbfb1461083b5761043c565b806305075d6e146104b25780630902f1ac1461051b57806318f9bbae146105875780631a95129f146105f0575b61045b3373ffffffffffffffffffffffffffffffffffffffff1661234a565b6104b0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260368152602001806186d56036913960400191505060405180910390fd5b005b3480156104be57600080fd5b50610501600480360360208110156104d557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612395565b604051808215151515815260200191505060405180910390f35b34801561052757600080fd5b506105306123f3565b6040518080602001828103825283818151815260200191508051906020019060200280838360005b83811015610573578082015181840152602081019050610558565b505050509050019250505060405180910390f35b34801561059357600080fd5b506105d6600480360360208110156105aa57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612481565b604051808215151515815260200191505060405180910390f35b3480156105fc57600080fd5b506106496004803603604081101561061357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506124df565b005b34801561065757600080fd5b506106ba6004803603604081101561066e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506125da565b005b3480156106c857600080fd5b5061072b600480360360408110156106df57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612756565b6040518082600181111561073b57fe5b60ff16815260200191505060405180910390f35b34801561075b57600080fd5b506107be6004803603604081101561077257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506127f6565b005b3480156107cc57600080fd5b50610839600480360360608110156107e357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506129a1565b005b34801561084757600080fd5b5061088a6004803603602081101561085e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050612b93565b005b6108f8600480360360608110156108a257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050612c83565b005b34801561090657600080fd5b5061095d6004803603606081101561091d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190505050612f94565b005b34801561096b57600080fd5b506109ae6004803603602081101561098257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613176565b6040518082815260200191505060405180910390f35b3480156109d057600080fd5b50610a1d600480360360408110156109e757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506131c7565b005b348015610a2b57600080fd5b50610a6e60048036036020811015610a4257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061333e565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b348015610abc57600080fd5b50610b0960048036036040811015610ad357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506133af565b005b348015610b1757600080fd5b50610b7a60048036036040811015610b2e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506134bc565b005b348015610b8857600080fd5b50610bcb60048036036020811015610b9f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506135f8565b005b348015610bd957600080fd5b50610c67600480360360c0811015610bf057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190803560ff16906020019092919080359060200190929190505050613782565b005b348015610c7557600080fd5b50610cd860048036036040811015610c8c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613a63565b005b348015610ce657600080fd5b50610d2960048036036020811015610cfd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613bb3565b005b348015610d3757600080fd5b50610d9a60048036036040811015610d4e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613de8565b6040518082815260200191505060405180910390f35b348015610dbc57600080fd5b50610e4960048036036080811015610dd357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613e77565b005b348015610e5757600080fd5b50610e9a60048036036020811015610e6e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506140c3565b005b348015610ea857600080fd5b50610eff60048036036060811015610ebf57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291905050506141b3565b005b348015610f0d57600080fd5b50610f5a60048036036040811015610f2457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506143af565b005b348015610f6857600080fd5b50610fab60048036036020811015610f7f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506145a8565b604051808264ffffffffff1664ffffffffff16815260200191505060405180910390f35b348015610fdb57600080fd5b5061100860048036036020811015610ff257600080fd5b810190808035906020019092919050505061460a565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561105657600080fd5b506110996004803603602081101561106d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614646565b604051808215151515815260200191505060405180910390f35b3480156110bf57600080fd5b50611102600480360360208110156110d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506146a4565b604051808215151515815260200191505060405180910390f35b34801561112857600080fd5b5061116b6004803603602081101561113f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614702565b60405180878152602001868152602001858152602001841515151581526020018315151515815260200182151515158152602001965050505050505060405180910390f35b3480156111bc57600080fd5b506111c56147a9565b005b3480156111d357600080fd5b50611236600480360360408110156111ea57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506148d9565b6040518082815260200191505060405180910390f35b34801561125857600080fd5b5061129b6004803603602081101561126f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614980565b005b3480156112a957600080fd5b506112ec600480360360208110156112c057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614af2565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561133a57600080fd5b50611343614b63565b005b34801561135157600080fd5b506113946004803603602081101561136857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614c9c565b6040518082815260200191505060405180910390f35b3480156113b657600080fd5b506113bf614ced565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561140d57600080fd5b5061145a6004803603604081101561142457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050614d16565b005b34801561146857600080fd5b50611471614f21565b604051808215151515815260200191505060405180910390f35b34801561149757600080fd5b506114da600480360360208110156114ae57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050614f7f565b6040518082815260200191505060405180910390f35b3480156114fc57600080fd5b5061153f6004803603602081101561151357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061508b565b005b34801561154d57600080fd5b506115906004803603602081101561156457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615215565b6040518082815260200191505060405180910390f35b3480156115b257600080fd5b50611615600480360360408110156115c957600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615266565b604051808215151515815260200191505060405180910390f35b34801561163b57600080fd5b5061167e6004803603602081101561165257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615302565b6040518082815260200191505060405180910390f35b3480156116a057600080fd5b50611703600480360360408110156116b757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506154ca565b60405180848152602001838152602001828152602001935050505060405180910390f35b34801561173357600080fd5b506117a06004803603606081101561174a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506155c2565b005b3480156117ae57600080fd5b5061181b600480360360608110156117c557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061570d565b005b34801561182957600080fd5b5061186c6004803603602081101561184057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506158d2565b005b34801561187a57600080fd5b506118c76004803603604081101561189157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050615aa2565b005b3480156118d557600080fd5b5061192c600480360360608110156118ec57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190505050615c19565b005b34801561193a57600080fd5b5061197d6004803603602081101561195157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615d17565b6040518082815260200191505060405180910390f35b34801561199f57600080fd5b506119e2600480360360208110156119b657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615d68565b005b3480156119f057600080fd5b50611a3360048036036020811015611a0757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615f5f565b6040518082815260200191505060405180910390f35b348015611a5557600080fd5b50611a9860048036036020811015611a6c57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050615fb0565b6040518082815260200191505060405180910390f35b348015611aba57600080fd5b50611afd60048036036020811015611ad157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616001565b6040518082815260200191505060405180910390f35b348015611b1f57600080fd5b50611b6260048036036020811015611b3657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616051565b6040518082815260200191505060405180910390f35b348015611b8457600080fd5b50611bc760048036036020811015611b9b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506160a2565b6040518082815260200191505060405180910390f35b348015611be957600080fd5b50611bf26160f3565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b611cc060048036036080811015611c4a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616119565b005b348015611cce57600080fd5b50611d1b60048036036040811015611ce557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506162f3565b005b348015611d2957600080fd5b50611d6c60048036036020811015611d4057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506163ee565b6040518082815260200191505060405180910390f35b348015611d8e57600080fd5b50611ddb60048036036040811015611da557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050616443565b005b348015611de957600080fd5b50611e2c60048036036020811015611e0057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506165ba565b005b348015611e3a57600080fd5b50611ea760048036036060811015611e5157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050616744565b005b348015611eb557600080fd5b50611ef860048036036020811015611ecc57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061688f565b6040518082815260200191505060405180910390f35b348015611f1a57600080fd5b50611f5d60048036036020811015611f3157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506168fa565b6040518082815260200191505060405180910390f35b348015611f7f57600080fd5b50611fc260048036036020811015611f9657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061694a565b005b348015611fd057600080fd5b5061201f60048036036040811015611fe757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803515159060200190929190505050616b1a565b005b34801561202d57600080fd5b506120906004803603604081101561204457600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616cf7565b005b34801561209e57600080fd5b506120e1600480360360208110156120b557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616e2c565b6040518082815260200191505060405180910390f35b34801561210357600080fd5b506121466004803603602081101561211a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616e7d565b005b34801561215457600080fd5b506121b76004803603604081101561216b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050616f03565b6040518082815260200191505060405180910390f35b3480156121d957600080fd5b50612248600480360360608110156121f057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803515159060200190929190505050616f92565b005b34801561225657600080fd5b506122c36004803603606081101561226d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506170da565b005b3480156122d157600080fd5b50612334600480360360408110156122e857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050617252565b6040518082815260200191505060405180910390f35b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f91506000801b821415801561238c5750808214155b92505050919050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e01601c9054906101000a900460ff16915050919050565b6060600680548060200260200160405190810160405280929190818152602001828054801561247757602002820191906000526020600020905b8160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001906001019080831161242d575b5050505050905090565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e01601a9054906101000a900460ff16915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612585576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6125d681600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206172e190919063ffffffff16565b5050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612680576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506000600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060080154826001018190555050505050565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008160030154116127ea5760016127ed565b60005b91505092915050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561287557600080fd5b505afa158015612889573d6000803e3d6000fd5b505050506040513d602081101561289f57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161461291c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b80600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e0160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612a47576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b82600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e0160199054906101000a900460ff16612aed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602481526020018061867c6024913960400191505060405180910390fd5b6000600560008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050612b8483826000015461734f90919063ffffffff16565b81600001819055505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612c39576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b612c80600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206173d7565b50565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614612d29576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e01601a9054906101000a900460ff1680612d97575080600e0160199054906101000a900460ff165b612dec576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260388152602001806188f36038913960400191505060405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614612ecc5760003414612e9a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252605f81526020018061870b605f913960600191505060405180910390fd5b612ec78330848773ffffffffffffffffffffffffffffffffffffffff166173ff909392919063ffffffff16565b612f8e565b81341015612f25576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260358152602001806186a06035913960400191505060405180910390fd5b81341115612f8d576000612f42833461750590919063ffffffff16565b90508373ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f19350505050158015612f8a573d6000803e3d6000fd5b50505b5b50505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561301357600080fd5b505afa158015613027573d6000803e3d6000fd5b505050506040513d602081101561303d57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146130ba576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002073__CoreLibrary___________________________632eb0d006909184846040518463ffffffff1660e01b815260040180848152602001838152602001828152602001935050505060006040518083038186803b15801561315957600080fd5b505af415801561316d573d6000803e3d6000fd5b50505050505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060030154915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561324657600080fd5b505afa15801561325a573d6000803e3d6000fd5b505050506040513d602081101561327057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146132ed576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508181600a0181905550505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600d0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614613455576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506134af82826000015461750590919063ffffffff16565b8160000181905550505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614613562576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506135eb83615302565b8160030181905550505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561367757600080fd5b505afa15801561368b573d6000803e3d6000fd5b505050506040513d60208110156136a157600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff161461371e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050600081600e01601c6101000a81548160ff0219169083151502179055505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614613828576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b60006138348787612756565b90506000600460008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506000600181111561388657fe5b82600181111561389257fe5b14156139c7576000600560008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506139318782600301548461754f9092919063ffffffff16565b6000600181111561393e57fe5b85600181111561394a57fe5b141561397c57613977613966878961734f90919063ffffffff16565b85846176eb9092919063ffffffff16565b6139c1565b60018081111561398857fe5b85600181111561399457fe5b14156139c0576139bf6139b0878961734f90919063ffffffff16565b8361779690919063ffffffff16565b5b5b50613a59565b600060018111156139d457fe5b8460018111156139e057fe5b1415613a25576139f986826177b990919063ffffffff16565b613a20613a0f868861734f90919063ffffffff16565b84836176eb9092919063ffffffff16565b613a58565b600180811115613a3157fe5b846001811115613a3d57fe5b1415613a5757613a56858261779690919063ffffffff16565b5b5b5b5050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614613b09576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050428160040160006101000a81548164ffffffffff021916908364ffffffffff160217905550505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614613c59576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166357e37af083613ce684617839565b8460030154856004015486600701546040518663ffffffff1660e01b8152600401808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018581526020018481526020018381526020018281526020019550505050505060606040518083038186803b158015613d7157600080fd5b505afa158015613d85573d6000803e3d6000fd5b505050506040513d6060811015613d9b57600080fd5b810190808051906020019092919080519060200190929190805190602001909291905050508360020160008560060160008760050160008691905055859190505584919050555050505050565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050806003015491505092915050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b158015613ef657600080fd5b505afa158015613f0a573d6000803e3d6000fd5b505050506040513d6020811015613f2057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614613f9d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002073__CoreLibrary___________________________6313769cd490918585856040518563ffffffff1660e01b8152600401808581526020018473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200194505050505060006040518083038186803b15801561409c57600080fd5b505af41580156140b0573d6000803e3d6000fd5b505050506140bd8461788f565b50505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614614169576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6141b0600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020617995565b50565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614614259576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b82600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e0160199054906101000a900460ff16806143015750600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e01601a9054906101000a900460ff165b614356576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604481526020018061885b6044913960600191505060405180910390fd5b6143a98383600460008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206176eb9092919063ffffffff16565b50505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614614455576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b81600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e0160199054906101000a900460ff16806144fd5750600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e01601a9054906101000a900460ff165b614552576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604481526020018061885b6044913960600191505060405180910390fd5b6145a382600460008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002061779690919063ffffffff16565b505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e0160149054906101000a900464ffffffffff16915050919050565b6006818154811061461757fe5b906000526020600020016000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e01601b9054906101000a900460ff16915050919050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e0160199054906101000a900460ff16915050919050565b6000806000806000806000600460008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600c015496508060090154955080600a0154945080600e01601a9054906101000a900460ff16935080600e01601b9054906101000a900460ff16925080600e0160199054906101000a900460ff1691505091939550919395565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561482857600080fd5b505afa15801561483c573d6000803e3d6000fd5b505050506040513d602081101561485257600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146148cf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6148d7617a3e565b565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060040160009054906101000a900464ffffffffff1664ffffffffff1691505092915050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b1580156149ff57600080fd5b505afa158015614a13573d6000803e3d6000fd5b505050506040513d6020811015614a2957600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614614aa6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b80600360006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550614aef617a3e565b50565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600e0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16915050919050565b614b6b614f21565b614bdd576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060070154915050919050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614614dbc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b81600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e0160199054906101000a900460ff1680614e645750600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600e01601a9054906101000a900460ff165b614eb9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252604481526020018061885b6044913960600191505060405180910390fd5b6000600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050614f1383826000015461734f90919063ffffffff16565b816000018190555050505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16614f63617c86565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008160050154141561507d5780600e0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334762ca56040518163ffffffff1660e01b815260040160206040518083038186803b15801561503a57600080fd5b505afa15801561504e573d6000803e3d6000fd5b505050506040513d602081101561506457600080fd5b8101908080519060200190929190505050915050615086565b80600501549150505b919050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561510a57600080fd5b505afa15801561511e573d6000803e3d6000fd5b505050506040513d602081101561513457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146151b1576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050600181600e01601b6101000a81548160ff0219169083151502179055505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060040154915050919050565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060040160059054906101000a900460ff1691505092915050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506000600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633618abba6040518163ffffffff1660e01b815260040160206040518083038186803b1580156153b057600080fd5b505afa1580156153c4573d6000803e3d6000fd5b505050506040513d60208110156153da57600080fd5b810190808051906020019092919050505090506000826006015414156154bb578073ffffffffffffffffffffffffffffffffffffffff1663bb85c0bb856040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561547757600080fd5b505afa15801561548b573d6000803e3d6000fd5b505050506040513d60208110156154a157600080fd5b8101908080519060200190929190505050925050506154c5565b8160060154925050505b919050565b600080600080600560008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506000600460008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050816000015494506155a28282617c8e565b93506155b7858561750590919063ffffffff16565b925050509250925092565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614615668576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506156ff82826002015461750590919063ffffffff16565b816002018190555050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146157b3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905081816000015410156158ad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601d8152602001807f54686520626f72726f772062616c616e636520697320746f6f206c6f7700000081525060200191505060405180910390fd5b6158c482826000015461750590919063ffffffff16565b816000018190555050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561595157600080fd5b505afa158015615965573d6000803e3d6000fd5b505050506040513d602081101561597b57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146159f8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002073__CoreLibrary___________________________63e5df56a690916040518263ffffffff1660e01b81526004018082815260200191505060006040518083038186803b158015615a8757600080fd5b505af4158015615a9b573d6000803e3d6000fd5b5050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b158015615b2157600080fd5b505afa158015615b35573d6000803e3d6000fd5b505050506040513d6020811015615b4b57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614615bc8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508181600b0181905550505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614615cbf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b615d128282600460008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002061754f9092919063ffffffff16565b505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060080154915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b158015615de757600080fd5b505afa158015615dfb573d6000803e3d6000fd5b505050506040513d6020811015615e1157600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614615e8e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008160010154118015615ee9575060008160080154115b615f3e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806187f26024913960400191505060405180910390fd5b600181600e01601c6101000a81548160ff0219169083151502179055505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600b0154915050919050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060010154915050919050565b600061604a600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020617839565b9050919050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060000154915050919050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090508060020154915050919050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146161bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000819050600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff161461624b576162468482858873ffffffffffffffffffffffffffffffffffffffff166173ff909392919063ffffffff16565b6162ec565b823410156162a4576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260358152602001806186a06035913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166108fc849081150290604051600060405180830381858888f193505050501580156162ea573d6000803e3d6000fd5b505b5050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614616399576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6163ea81600460008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206177b990919063ffffffff16565b5050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905061643b81617da1565b915050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b1580156164c257600080fd5b505afa1580156164d6573d6000803e3d6000fd5b505050506040513d60208110156164ec57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614616569576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050818160090181905550505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b15801561663957600080fd5b505afa15801561664d573d6000803e3d6000fd5b505050506040513d602081101561666357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16146166e0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b6000600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050600081600e01601b6101000a81548160ff0219169083151502179055505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16146167ea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905061688182826002015461734f90919063ffffffff16565b816002018190555050505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002090506168f26168df846168fa565b826000015461750590919063ffffffff16565b915050919050565b6000616943600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020617de8565b9050919050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b1580156169c957600080fd5b505afa1580156169dd573d6000803e3d6000fd5b505050506040513d60208110156169f357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614616a70576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b600460008273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002073__CoreLibrary___________________________6383c165a090916040518263ffffffff1660e01b81526004018082815260200191505060006040518083038186803b158015616aff57600080fd5b505af4158015616b13573d6000803e3d6000fd5b5050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166385c858b16040518163ffffffff1660e01b815260040160206040518083038186803b158015616b9957600080fd5b505afa158015616bad573d6000803e3d6000fd5b505050506040513d6020811015616bc357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1614616c40576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260378152602001806187bb6037913960400191505060405180910390fd5b600460008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002073__CoreLibrary___________________________63f63babbe9091836040518363ffffffff1660e01b815260040180838152602001821515151581526020019250505060006040518083038186803b158015616cdb57600080fd5b505af4158015616cef573d6000803e3d6000fd5b505050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614616d9d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905060008160030181905550505050565b600080600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020905080600a0154915050919050565b616e85614f21565b616ef7576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b616f0081617e0c565b50565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050806001015491505092915050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614617038576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b6000600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050818160040160056101000a81548160ff02191690831515021790555050505050565b3373ffffffffffffffffffffffffffffffffffffffff16600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614617180576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a81526020018061889f602a913960400191505060405180910390fd5b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff16146172055761720082828573ffffffffffffffffffffffffffffffffffffffff16617f509092919063ffffffff16565b61724d565b8173ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f1935050505015801561724b573d6000803e3d6000fd5b505b505050565b600080600560008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000209050806002015491505092915050565b600061730a6172f38460000154618021565b6172fc84618021565b61804190919063ffffffff16565b9050600061732861731961809d565b8361734f90919063ffffffff16565b90506173418460010154826180b190919063ffffffff16565b846001018190555050505050565b6000808284019050838110156173cd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b4281600e0160146101000a81548164ffffffffff021916908364ffffffffff16021790555050565b6174ff848573ffffffffffffffffffffffffffffffffffffffff166323b872dd905060e01b858585604051602401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050618114565b50505050565b600061754783836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f77000081525061835f565b905092915050565b81836003015410156175c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601a8152602001807f496e76616c696420616d6f756e7420746f20646563726561736500000000000081525060200191505060405180910390fd5b6000836003015490506175e983856003015461750590919063ffffffff16565b846003018190555060008460030154141561760e5760008460070181905550506176e6565b600061762b8361761d86618021565b6180b190919063ffffffff16565b9050600061764e866007015461764085618021565b6180b190919063ffffffff16565b9050818110156176a9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806188166024913960400191505060405180910390fd5b6176da6176b98760030154618021565b6176cc848461750590919063ffffffff16565b61804190919063ffffffff16565b86600701819055505050505b505050565b60008360030154905061770b83856003015461734f90919063ffffffff16565b846003018190555060006177308361772286618021565b6180b190919063ffffffff16565b90506000617753866007015461774585618021565b6180b190919063ffffffff16565b90506177866177658760030154618021565b617778838561734f90919063ffffffff16565b61804190919063ffffffff16565b8660070181905550505050505050565b6177ad81836004015461734f90919063ffffffff16565b82600401819055505050565b8082600401541015617816576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252605181526020018061876a6051913960600191505060405180910390fd5b61782d81836004015461750590919063ffffffff16565b82600401819055505050565b60008082600001541415617850576000905061788a565b600061786d8360040154846003015461734f90919063ffffffff16565b905061788683600001548261804190919063ffffffff16565b9150505b919050565b600080905060008090505b600680549050811015617924578273ffffffffffffffffffffffffffffffffffffffff16600682815481106178cb57fe5b9060005260206000200160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16141561791757600191505b808060010191505061789a565b50806179915760068290806001815401808255809150509060018203906000526020600020016000909192909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505b5050565b60006179a082617839565b90506000811115617a3a5760006179d0836002015484600e0160149054906101000a900464ffffffffff1661841f565b90506179e98360010154826180b190919063ffffffff16565b83600101819055506000617a16846005015485600e0160149054906101000a900464ffffffffff1661841f565b9050617a2f8460080154826180b190919063ffffffff16565b846008018190555050505b5050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b158015617aa657600080fd5b505afa158015617aba573d6000803e3d6000fd5b505050506040513d6020811015617ad057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b158015617b2657600080fd5b505afa158015617b3a573d6000803e3d6000fd5b505050506040513d6020811015617b5057600080fd5b8101908080519060200190929190505050600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630261bf8b6040518163ffffffff1660e01b815260040160206040518083038186803b158015617c0957600080fd5b505afa158015617c1d573d6000803e3d6000fd5b505050506040513d6020811015617c3357600080fd5b8101908080519060200190929190505050600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b600033905090565b60008083600001541415617ca55760009050617d9b565b6000617cb48460000154618021565b905060008090506000809050600086600301541115617cf757617cf086600301548760040160009054906101000a900464ffffffffff1661841f565b9050617d49565b617d468660010154617d388760080154617d2a89600501548a600e0160149054906101000a900464ffffffffff1661841f565b6180b190919063ffffffff16565b61804190919063ffffffff16565b90505b617d64617d5f82856180b190919063ffffffff16565b61849f565b91508560000154821415617d9457617d8a6001876000015461734f90919063ffffffff16565b9350505050617d9b565b8193505050505b92915050565b600080617ddd8360010154617dcf856002015486600e0160149054906101000a900464ffffffffff1661841f565b6180b190919063ffffffff16565b905080915050919050565b6000617e058260040154836003015461734f90919063ffffffff16565b9050919050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415617e92576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806186566026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b61801c838473ffffffffffffffffffffffffffffffffffffffff1663a9059cbb905060e01b8484604051602401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050618114565b505050565b600061803a633b9aca00836184bf90919063ffffffff16565b9050919050565b6000806002838161804e57fe5b049050618094836180866180776b033b2e3c9fd0803ce8000000886184bf90919063ffffffff16565b8461734f90919063ffffffff16565b61854590919063ffffffff16565b91505092915050565b60006b033b2e3c9fd0803ce8000000905090565b600061810c6b033b2e3c9fd0803ce80000006180fe6180d985876184bf90919063ffffffff16565b60026b033b2e3c9fd0803ce8000000816180ef57fe5b0461734f90919063ffffffff16565b61854590919063ffffffff16565b905092915050565b6181338273ffffffffffffffffffffffffffffffffffffffff1661234a565b6181a5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e74726163740081525060200191505060405180910390fd5b600060608373ffffffffffffffffffffffffffffffffffffffff16836040518082805190602001908083835b602083106181f457805182526020820191506020810190506020830392506181d1565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114618256576040519150601f19603f3d011682016040523d82523d6000602084013e61825b565b606091505b5091509150816182d3576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656481525060200191505060405180910390fd5b600081511115618359578080602001905160208110156182f257600080fd5b8101908080519060200190929190505050618358576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a8152602001806188c9602a913960400191505060405180910390fd5b5b50505050565b600083831115829061840c576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156183d15780820151818401526020810190506183b6565b50505050905090810190601f1680156183fe5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b60008061843c8364ffffffffff164261750590919063ffffffff16565b905060006184676184506301e13380618021565b61845984618021565b61804190919063ffffffff16565b905061849561847461809d565b61848783886180b190919063ffffffff16565b61734f90919063ffffffff16565b9250505092915050565b60006184b8633b9aca008361854590919063ffffffff16565b9050919050565b6000808314156184d2576000905061853f565b60008284029050828482816184e357fe5b041461853a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602181526020018061883a6021913960400191505060405180910390fd5b809150505b92915050565b600061858783836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061858f565b905092915050565b6000808311829061863b576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156186005780820151818401526020810190506185e5565b50505050905090810190601f16801561862d5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50600083858161864757fe5b04905080915050939250505056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f206164647265737352657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e6754686520616d6f756e7420616e64207468652076616c75652073656e7420746f206465706f73697420646f206e6f74206d617463684f6e6c7920636f6e7472616374732063616e2073656e6420657468657220746f20746865204c656e64696e6720706f6f6c20636f7265557365722069732073656e64696e672045544820616c6f6e67207769746820746865204552433230207472616e736665722e20436865636b207468652076616c756520617474726962757465206f6620746865207472616e73616374696f6e54686520616d6f756e742074686174206973206265696e672073756273747261637465642066726f6d20746865207661726961626c6520746f74616c20626f72726f777320697320696e636f72726563745468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c20636f6e666967757261746f7220636f6e74726163745265736572766520686173206e6f74206265656e20696e697469616c697a65642079657454686520616d6f756e747320746f2073756273747261637420646f6e2774206d61746368536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7752657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e67206f7220666f72206265696e67207573656420617320636f6c6c61746572616c5468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c20636f6e74726163745361666545524332303a204552433230206f7065726174696f6e20646964206e6f74207375636365656454686520726573657276652069736e277420656e61626c656420666f7220626f72726f77696e67206f7220617320636f6c6c61746572616ca165627a7a723058205a01ee47bede87331f5605293ad6bf3266377c99197ce551361bb321e7c18f170029", + "sourceMap": "973:26330:25:-;;;2930:156;8:9:-1;5:2;;;30:1;27;20:12;5:2;2930:156:25;;;;;;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2930:156:25;;;;;;;;;;;;;;;;707:12:57;:10;;;:12;;:::i;:::-;698:6;;:21;;;;;;;;;;;;;;;;;;767:6;;;;;;;;;;;734:40;;763:1;734:40;;;;;;;;;;;;3028:18:25;3008:17;;:38;;;;;;;;;;;;;;;;;;3056:23;:21;;;:23;;:::i;:::-;2930:156;973:26330;;788:96:55;833:15;867:10;860:17;;788:96;:::o;26722:236:25:-;26818:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;26818:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;26818:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;26818:46:25;;;;;;;;;;;;;;;;26793:91;;;:93;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;26793:93:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;26793:93:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;26793:93:25;;;;;;;;;;;;;;;;26775:15;;:111;;;;;;;;;;;;;;;;;;26917:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;26917:34:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;26917:34:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;26917:34:25;;;;;;;;;;;;;;;;26896:18;;:55;;;;;;;;;;;;;;;;;;26722:236::o;973:26330::-;;;;;;;", + "deployedSourceMap": "973:26330:25:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;24769:23;:10;:21;;;:23::i;:::-;24761:90;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;973:26330;17791:184;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17791:184:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;17791:184:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;20791:100;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20791:100:25;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;20791:100:25;;;;;;;;;;;;;;;;;17346:216;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17346:216:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;17346:216:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;3688:179;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3688:179:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3688:179:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;9302:367;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9302:367:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9302:367:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;18750:361;;8:9:-1;5:2;;;30:1;27;20:12;5:2;18750:361:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;18750:361:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21613:218;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21613:218:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;21613:218:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;10223:362;;8:9:-1;5:2;;;30:1;27;20:12;5:2;10223:362:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;10223:362:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;9093:124;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9093:124:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9093:124:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;25721:946;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;25721:946:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;22210:270;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22210:270:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;22210:270:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;13469:206;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13469:206:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13469:206:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;24082:263;;8:9:-1;5:2;;;30:1;27;20:12;5:2;24082:263:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;24082:263:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;12454:196;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12454:196:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;12454:196:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;5175:246;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5175:246:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5175:246:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;11648:262;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11648:262:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11648:262:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;23483:193;;8:9:-1;5:2;;;30:1;27;20:12;5:2;23483:193:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;23483:193:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;7167:1845;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7167:1845:25;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;7167:1845:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;11267:274;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11267:274:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11267:274:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;4083:601;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4083:601:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4083:601:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;19117:234;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19117:234:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;19117:234:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;21288:319;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21288:319:25;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;21288:319:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;3340:144;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3340:144:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3340:144:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;5612:316;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5612:316:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5612:316:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;6467:260;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6467:260:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6467:260:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;17982:215;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17982:215:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;17982:215:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2894:29;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2894:29:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2894:29:25;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;17568:217;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17568:217:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;17568:217:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;17140:200;;8:9:-1;5:2;;;30:1;27;20:12;5:2;17140:200:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;17140:200:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;16413:721;;8:9:-1;5:2;;;30:1;27;20:12;5:2;16413:721:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;16413:721:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21173:109;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21173:109:25;;;:::i;:::-;;20311:269;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20311:269:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;20311:269:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;20952:215;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20952:215:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;20952:215:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;12224:224;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12224:224:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;12224:224:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1642:137:57;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1642:137:57;;;:::i;:::-;;15234:230:25;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15234:230:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;15234:230:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;857:77:57;;8:9:-1;5:2;;;30:1;27;20:12;5:2;857:77:57;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4765:329:25;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4765:329:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4765:329:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;1208:92:57;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1208:92:57;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;14333:417:25;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14333:417:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14333:417:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;22640:219;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22640:219:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;22640:219:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;13681:212;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13681:212:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13681:212:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;18277:237;;8:9:-1;5:2;;;30:1;27;20:12;5:2;18277:237:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;18277:237:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;14756:472;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14756:472:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14756:472:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;19357:683;;8:9:-1;5:2;;;30:1;27;20:12;5:2;19357:683:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;19357:683:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9949:268;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9949:268:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9949:268:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;10591:402;;8:9:-1;5:2;;;30:1;27;20:12;5:2;10591:402:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;10591:402:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;22060:144;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22060:144:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;22060:144:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;24351:259;;8:9:-1;5:2;;;30:1;27;20:12;5:2;24351:259:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;24351:259:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;6121:255;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6121:255:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6121:255:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;15918:235;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15918:235:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;15918:235:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;23092:385;;8:9:-1;5:2;;;30:1;27;20:12;5:2;23092:385:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;23092:385:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;14117:210;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14117:210:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14117:210:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;15688:224;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15688:224:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;15688:224:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;20630:155;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20630:155:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;20630:155:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;12902:200;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12902:200:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;12902:200:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;15470:212;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15470:212:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;15470:212:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1377:53;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1377:53:25;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;25157:558;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;25157:558:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;6824:178;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6824:178:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6824:178:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;13108:209;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13108:209:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13108:209:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;23831:245;;8:9:-1;5:2;;;30:1;27;20:12;5:2;23831:245:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;23831:245:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;22865:221;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22865:221:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;22865:221:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;9675:268;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9675:268:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9675:268:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;12656:240;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12656:240:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;12656:240:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;13323:140;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13323:140:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13323:140:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;22486:148;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22486:148:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;22486:148:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;21837:217;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21837:217:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;21837:217:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;11916:219;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11916:219:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11916:219:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;13899:212;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13899:212:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13899:212:25;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1928:107:57;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1928:107:57;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1928:107:57;;;;;;;;;;;;;;;;;;;:::i;:::-;;20046:259:25;;8:9:-1;5:2;;;30:1;27;20:12;5:2;20046:259:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;20046:259:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;10999:262;;8:9:-1;5:2;;;30:1;27;20:12;5:2;10999:262:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;10999:262:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;24865:286;;8:9:-1;5:2;;;30:1;27;20:12;5:2;24865:286:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;24865:286:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;18519:225;;8:9:-1;5:2;;;30:1;27;20:12;5:2;18519:225:25;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;18519:225:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;557:797:62;617:4;1062:16;1088:19;1110:66;1088:88;;;;1277:7;1265:20;1253:32;;1316:3;1304:15;;:8;:15;;:42;;;;;1335:11;1323:8;:23;;1304:42;1296:51;;;;557:797;;;:::o;17791:184:25:-;17859:4;17875:39;17917:8;:18;17926:8;17917:18;;;;;;;;;;;;;;;17875:60;;17952:7;:16;;;;;;;;;;;;17945:23;;;17791:184;;;:::o;20791:100::-;20837:16;20872:12;20865:19;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;20791:100;:::o;17346:216::-;17430:4;17446:39;17488:8;:18;17497:8;17488:18;;;;;;;;;;;;;;;17446:60;;17523:7;:32;;;;;;;;;;;;17516:39;;;17346:216;;;:::o;3688:179::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3808:52;3852:7;3808:8;:18;3817:8;3808:18;;;;;;;;;;;;;;;:43;;:52;;;;:::i;:::-;3688:179;;:::o;9302:367::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9423:40;9466:16;:23;9483:5;9466:23;;;;;;;;;;;;;;;:33;9490:8;9466:33;;;;;;;;;;;;;;;9423:76;;9509:39;9551:8;:18;9560:8;9551:18;;;;;;;;;;;;;;;9509:60;;9621:7;:41;;;9580:4;:38;;:82;;;;1657:1;;9302:367;;:::o;18750:361::-;18866:28;18910:40;18953:16;:23;18970:5;18953:23;;;;;;;;;;;;;;;:33;18977:8;18953:33;;;;;;;;;;;;;;;18910:76;;19026:1;19003:4;:20;;;:24;:101;;19067:37;19003:101;;;19030:34;19003:101;18996:108;;;18750:361;;;;:::o;21613:218::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21804:20;21755:8;:18;21764:8;21755:18;;;;;;;;;;;;;;;:46;;;:69;;;;;;;;;;;;;;;;;;21613:218;;:::o;10223:362::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10398:8;2641;:18;2650:8;2641:18;;;;;;;;;;;;;;;:35;;;;;;;;;;;;2633:84;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10422:40;10465:16;:23;10482:5;10465:23;;;;;;;;;;;;;;;:33;10489:8;10465:33;;;;;;;;;;;;;;;10422:76;;10538:40;10570:7;10538:4;:27;;;:31;;:40;;;;:::i;:::-;10508:4;:27;;:70;;;;2727:1;1657;10223:362;;;:::o;9093:124::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9176:34;:8;:18;9185:8;9176:18;;;;;;;;;;;;;;;:32;:34::i;:::-;9093:124;:::o;25721:946::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;25849:39;25891:8;:18;25900:8;25891:18;;;;;;;;;;;;;;;25849:60;;25941:7;:32;;;;;;;;;;;;:60;;;;25977:7;:24;;;;;;;;;;;;25941:60;25920:163;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;26110:15;;;;;;;;;;;26098:27;;:8;:27;;;26094:567;;26161:1;26148:9;:14;26140:122;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;26276:63;26309:5;26324:4;26331:7;26282:8;26276:32;;;;:63;;;;;;:::i;:::-;26094:567;;;26400:7;26387:9;:20;;26379:86;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;26495:7;26483:9;:19;26480:171;;;26545:20;26568:22;26582:7;26568:9;:13;;:22;;;;:::i;:::-;26545:45;;26608:5;:14;;:28;26623:12;26608:28;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;26608:28:25;26480:171;;26094:567;1657:1;25721:946;;;:::o;22210:270::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;22391:8;:18;22400:8;22391:18;;;;;;;;;;;;;;;:37;;;;22429:20;22451:21;22391:82;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22391:82:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22391:82:25;;;;22210:270;;;:::o;13469:206::-;13547:7;13566:39;13608:8;:18;13617:8;13608:18;;;;;;;;;;;;;;;13566:60;;13643:7;:25;;;13636:32;;;13469:206;;;:::o;24082:263::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;24227:39;24269:8;:18;24278:8;24269:18;;;;;;;;;;;;;;;24227:60;;24328:10;24297:7;:28;;:41;;;;1991:1;24082:263;;:::o;12454:196::-;12526:7;12545:39;12587:8;:18;12596:8;12587:18;;;;;;;;;;;;;;;12545:60;;12622:7;:21;;;;;;;;;;;;12615:28;;;12454:196;;;:::o;5175:246::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5284:39;5326:8;:18;5335:8;5326:18;;;;;;;;;;;;;;;5284:60;;5379:35;5406:7;5379;:22;;;:26;;:35;;;;:::i;:::-;5354:7;:22;;:60;;;;1657:1;5175:246;;:::o;11648:262::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11751:40;11794:16;:23;11811:5;11794:23;;;;;;;;;;;;;;;:33;11818:8;11794:33;;;;;;;;;;;;;;;11751:76;;11861:42;11894:8;11861:32;:42::i;:::-;11838:4;:20;;:65;;;;1657:1;11648:262;;:::o;23483:193::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23575:39;23617:8;:18;23626:8;23617:18;;;;;;;;;;;;;;;23575:60;;23664:5;23645:7;:16;;;:24;;;;;;;;;;;;;;;;;;1991:1;23483:193;:::o;7167:1845::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7456:44;7503:45;7532:8;7542:5;7503:28;:45::i;:::-;7456:92;;7558:39;7600:8;:18;7609:8;7600:18;;;;;;;;;;;;;;;7558:60;;7653:34;7634:53;;;;;;;;:15;:53;;;;;;;;;7630:1376;;;7776:40;7819:16;:23;7836:5;7819:23;;;;;;;;;;;;;;;:33;7843:8;7819:33;;;;;;;;;;;;;;;7776:76;;7866:94;7920:17;7939:4;:20;;;7866:7;:53;;:94;;;;;:::i;:::-;8001:34;7979:56;;;;;;;;:18;:56;;;;;;;;;7975:449;;;8055:106;8109:39;8131:16;8109:17;:21;;:39;;;;:::i;:::-;8150:10;8055:7;:53;;:106;;;;;:::i;:::-;7975:449;;;8209:37;8187:59;;;;;;;;:18;:59;;;;;;;;;8183:241;;;8332:77;8369:39;8391:16;8369:17;:21;;:39;;;;:::i;:::-;8332:7;:36;;:77;;;;:::i;:::-;8183:241;7975:449;7630:1376;;;;8524:34;8502:56;;;;;;;;:18;:56;;;;;;;;;8498:498;;;8578:55;8615:17;8578:7;:36;;:55;;;;:::i;:::-;8651:106;8705:39;8727:16;8705:17;:21;;:39;;;;:::i;:::-;8746:10;8651:7;:53;;:106;;;;;:::i;:::-;8498:498;;;8804:37;8782:59;;;;;;;;:18;:59;;;;;;;;;8778:218;;;8927:54;8964:16;8927:7;:36;;:54;;;;:::i;:::-;8778:218;8498:498;7630:1376;1657:1;;7167:1845;;;;;;:::o;11267:274::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11362:40;11405:16;:23;11422:5;11405:23;;;;;;;;;;;;;;;:33;11429:8;11405:33;;;;;;;;;;;;;;;11362:76;;11518:15;11484:4;:24;;;:50;;;;;;;;;;;;;;;;;;1657:1;11267:274;;:::o;4083:601::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4173:39;4215:8;:18;4224:8;4215:18;;;;;;;;;;;;;;;4173:60;;4388:7;:35;;;;;;;;;;;;4359:101;;;4474:8;4496:35;:7;:33;:35::i;:::-;4545:7;:25;;;4584:7;:28;;;4626:7;:37;;;4359:318;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;4359:318:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;4359:318:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4359:318:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4244:7;:28;;;4282:7;:30;;;4322:7;:33;;;4243:434;;;;;;;;;;;;;;;;;;1657:1;4083:601;:::o;19117:234::-;19212:7;19231:40;19274:16;:23;19291:5;19274:23;;;;;;;;;;;;;;;:33;19298:8;19274:33;;;;;;;;;;;;;;;19231:76;;19324:4;:20;;;19317:27;;;19117:234;;;;:::o;21288:319::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21475:8;:18;21484:8;21475:18;;;;;;;;;;;;;;;:23;;;;21499:14;21515:9;21526:28;21475:80;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21475:80:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;21475:80:25;;;;21565:34;21590:8;21565:24;:34::i;:::-;21288:319;;;;:::o;3340:144::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3433:44;:8;:18;3442:8;3433:18;;;;;;;;;;;;;;;:42;:44::i;:::-;3340:144;:::o;5612:316::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5817:8;2245;:18;2254:8;2245:18;;;;;;;;;;;;;;;:35;;;;;;;;;;;;:82;;;;2284:8;:18;2293:8;2284:18;;;;;;;;;;;;;;;:43;;;;;;;;;;;;2245:82;2224:197;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5841:80;5906:7;5915:5;5841:8;:18;5850:8;5841:18;;;;;;;;;;;;;;;:64;;:80;;;;;:::i;:::-;1657:1;5612:316;;;:::o;6467:260::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6640:8;2245;:18;2254:8;2245:18;;;;;;;;;;;;;;;:35;;;;;;;;;;;;:82;;;;2284:8;:18;2293:8;2284:18;;;;;;;;;;;;;;;:43;;;;;;;;;;;;2245:82;2224:197;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6664:56;6712:7;6664:8;:18;6673:8;6664:18;;;;;;;;;;;;;;;:47;;:56;;;;:::i;:::-;1657:1;6467:260;;:::o;17982:215::-;18053:16;18081:39;18123:8;:18;18132:8;18123:18;;;;;;;;;;;;;;;18081:60;;18163:7;:27;;;;;;;;;;;;18151:39;;17982:215;;;;:::o;2894:29::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;17568:217::-;17653:4;17669:39;17711:8;:18;17720:8;17711:18;;;;;;;;;;;;;;;17669:60;;17746:7;:32;;;;;;;;;;;;17739:39;;;17568:217;;;:::o;17140:200::-;17216:4;17232:39;17274:8;:18;17283:8;17274:18;;;;;;;;;;;;;;;17232:60;;17309:7;:24;;;;;;;;;;;;17302:31;;;17140:200;;;:::o;16413:721::-;16511:16;16537:27;16574:28;16612:29;16651:27;16688:21;16721:39;16763:8;:18;16772:8;16763:18;;;;;;;;;;;;;;;16721:60;;16802:7;:16;;;16791:27;;16850:7;:27;;;16828:49;;16910:7;:28;;;16887:51;;16975:7;:32;;;;;;;;;;;;16948:59;;17042:7;:32;;;;;;;;;;;;17017:57;;17103:7;:24;;;;;;;;;;;;17084:43;;16413:721;;;;;;;;:::o;21173:109::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21252:23;:21;:23::i;:::-;21173:109::o;20311:269::-;20418:17;20451:40;20494:16;:23;20511:5;20494:23;;;;;;;;;;;;;;;:33;20518:8;20494:33;;;;;;;;;;;;;;;20451:76;;20549:4;:24;;;;;;;;;;;;20537:36;;;;20311:269;;;;;:::o;20952:215::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21108:18;21059:17;;:68;;;;;;;;;;;;;;;;;;21137:23;:21;:23::i;:::-;20952:215;:::o;12224:224::-;12310:7;12329:39;12371:8;:18;12380:8;12371:18;;;;;;;;;;;;;;;12329:60;;12406:7;:35;;;;;;;;;;;;12399:42;;;12224:224;;;:::o;1642:137:57:-;1061:9;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1740:1;1703:40;;1724:6;;;;;;;;;;;1703:40;;;;;;;;;;;;1770:1;1753:6;;:19;;;;;;;;;;;;;;;;;;1642:137::o;15234:230:25:-;15324:7;15343:39;15385:8;:18;15394:8;15385:18;;;;;;;;;;;;;;;15343:60;;15420:7;:37;;;15413:44;;;15234:230;;;:::o;857:77:57:-;895:7;921:6;;;;;;;;;;;914:13;;857:77;:::o;4765:329:25:-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4932:8;2245;:18;2254:8;2245:18;;;;;;;;;;;;;;;:35;;;;;;;;;;;;:82;;;;2284:8;:18;2293:8;2284:18;;;;;;;;;;;;;;;:43;;;;;;;;;;;;2245:82;2224:197;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;4956:39;4998:8;:18;5007:8;4998:18;;;;;;;;;;;;;;;4956:60;;5051:35;5078:7;5051;:22;;;:26;;:35;;;;:::i;:::-;5026:7;:22;;:60;;;;2431:1;1657;4765:329;;:::o;1208:92:57:-;1248:4;1287:6;;;;;;;;;;;1271:22;;:12;:10;:12::i;:::-;:22;;;1264:29;;1208:92;:::o;14333:417:25:-;14419:7;14438:39;14480:8;:18;14489:8;14480:18;;;;;;;;;;;;;;;14438:60;;14549:1;14512:7;:33;;;:38;14509:185;;;14602:7;:35;;;;;;;;;;;;14573:108;;;:110;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14573:110:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14573:110:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14573:110:25;;;;;;;;;;;;;;;;14566:117;;;;;14509:185;14710:7;:33;;;14703:40;;;14333:417;;;;:::o;22640:219::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;22743:39;22785:8;:18;22794:8;22785:18;;;;;;;;;;;;;;;22743:60;;22848:4;22813:7;:32;;;:39;;;;;;;;;;;;;;;;;;1991:1;22640:219;:::o;13681:212::-;13762:7;13781:39;13823:8;:18;13832:8;13823:18;;;;;;;;;;;;;;;13781:60;;13858:7;:28;;;13851:35;;;13681:212;;;:::o;18277:237::-;18378:4;18394:40;18437:16;:23;18454:5;18437:23;;;;;;;;;;;;;;;:33;18461:8;18437:33;;;;;;;;;;;;;;;18394:76;;18487:4;:20;;;;;;;;;;;;18480:27;;;18277:237;;;;:::o;14756:472::-;14837:7;14856:39;14898:8;:18;14907:8;14898:18;;;;;;;;;;;;;;;14856:60;;14926:25;14973:17;;;;;;;;;;;:38;;;:40;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14973:40:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14973:40:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14973:40:25;;;;;;;;;;;;;;;;14926:88;;15063:1;15029:7;:30;;;:35;15025:149;;;15127:6;:26;;;15154:8;15127:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;15127:36:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;15127:36:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;15127:36:25;;;;;;;;;;;;;;;;15120:43;;;;;;15025:149;15191:7;:30;;;15184:37;;;;14756:472;;;;:::o;19357:683::-;19482:30;19526:31;19571:24;19608:40;19651:16;:23;19668:5;19651:23;;;;;;;;;;;;;;;:33;19675:8;19651:33;;;;;;;;;;;;;;;19608:76;;19694:39;19736:8;:18;19745:8;19736:18;;;;;;;;;;;;;;;19694:60;;19790:4;:27;;;19765:52;;19853:99;19909:4;19931:7;19853:38;:99::i;:::-;19827:125;;19982:51;20010:22;19982:23;:27;;:51;;;;:::i;:::-;19963:70;;19357:683;;;;;;;:::o;9949:268::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10070:40;10113:16;:23;10130:5;10113:23;;;;;;;;;;;;;;;:33;10137:8;10113:33;;;;;;;;;;;;;;;10070:76;;10178:32;10202:7;10178:4;:19;;;:23;;:32;;;;:::i;:::-;10156:4;:19;;:54;;;;1657:1;9949:268;;;:::o;10591:402::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10740:40;10783:16;:23;10800:5;10783:23;;;;;;;;;;;;;;;:33;10807:8;10783:33;;;;;;;;;;;;;;;10740:76;;10865:7;10834:4;:27;;;:38;;10826:80;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10946:40;10978:7;10946:4;:27;;;:31;;:40;;;;:::i;:::-;10916:4;:27;;:70;;;;1657:1;10591:402;;;:::o;22060:144::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;22160:8;:18;22169:8;22160:18;;;;;;;;;;;;;;;:35;;;;:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22160:37:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22160:37:25;;;;22060:144;:::o;24351:259::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;24494:39;24536:8;:18;24545:8;24536:18;;;;;;;;;;;;;;;24494:60;;24594:9;24564:7;:27;;:39;;;;1991:1;24351:259;;:::o;6121:255::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6288:80;6353:7;6362:5;6288:8;:18;6297:8;6288:18;;;;;;;;;;;;;;;:64;;:80;;;;;:::i;:::-;6121:255;;;:::o;15918:235::-;16009:7;16028:39;16070:8;:18;16079:8;16070:18;;;;;;;;;;;;;;;16028:60;;16105:7;:41;;;16098:48;;;15918:235;;;:::o;23092:385::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23182:39;23224:8;:18;23233:8;23224:18;;;;;;;;;;;;;;;23182:60;;23313:1;23274:7;:36;;;:40;:101;;;;;23374:1;23330:7;:41;;;:45;23274:101;23253:184;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23466:4;23447:7;:16;;;:23;;;;;;;;;;;;;;;;;;1991:1;23092:385;:::o;14117:210::-;14197:7;14216:39;14258:8;:18;14267:8;14258:18;;;;;;;;;;;;;;;14216:60;;14293:7;:27;;;14286:34;;;14117:210;;;:::o;15688:224::-;15773:7;15792:39;15834:8;:18;15843:8;15834:18;;;;;;;;;;;;;;;15792:60;;15869:7;:36;;;15862:43;;;15688:224;;;:::o;20630:155::-;20706:7;20732:46;:8;:18;20741:8;20732:18;;;;;;;;;;;;;;;:44;:46::i;:::-;20725:53;;20630:155;;;:::o;12902:200::-;12977:7;12996:39;13038:8;:18;13047:8;13038:18;;;;;;;;;;;;;;;12996:60;;13073:7;:22;;;13066:29;;;12902:200;;;:::o;15470:212::-;15551:7;15570:39;15612:8;:18;15621:8;15612:18;;;;;;;;;;;;;;;15570:60;;15647:7;:28;;;15640:35;;;15470:212;;;:::o;1377:53::-;;;;;;;;;;;;;:::o;25157:558::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;25337:26;25382:11;25337:58;;25450:15;;;;;;;;;;;25440:25;;:6;:25;;;25436:273;;25481:58;25512:5;25519:10;25531:7;25487:6;25481:30;;;;:58;;;;;;:::i;:::-;25436:273;;;25591:7;25578:9;:20;;25570:86;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;25670:10;:19;;:28;25690:7;25670:28;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;25670:28:25;25436:273;1657:1;25157:558;;;;:::o;6824:178::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6939:56;6987:7;6939:8;:18;6948:8;6939:18;;;;;;;;;;;;;;;:47;;:56;;;;:::i;:::-;6824:178;;:::o;13108:209::-;13185:7;13204:39;13246:8;:18;13255:8;13246:18;;;;;;;;;;;;;;;13204:60;;13281:29;:7;:27;:29::i;:::-;13274:36;;;13108:209;;;:::o;23831:245::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23965:39;24007:8;:18;24016:8;24007:18;;;;;;;;;;;;;;;23965:60;;24065:4;24035:7;:27;;:34;;;;1991:1;23831:245;;:::o;22865:221::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;22969:39;23011:8;:18;23020:8;23011:18;;;;;;;;;;;;;;;22969:60;;23074:5;23039:7;:32;;;:40;;;;;;;;;;;;;;;;;;1991:1;22865:221;:::o;9675:268::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9796:40;9839:16;:23;9856:5;9839:23;;;;;;;;;;;;;;;:33;9863:8;9839:33;;;;;;;;;;;;;;;9796:76;;9904:32;9928:7;9904:4;:19;;;:23;;:32;;;;:::i;:::-;9882:4;:19;;:54;;;;1657:1;9675:268;;;:::o;12656:240::-;12733:7;12752:39;12794:8;:18;12803:8;12794:18;;;;;;;;;;;;;;;12752:60;;12829;12856:32;12879:8;12856:22;:32::i;:::-;12829:7;:22;;;:26;;:60;;;;:::i;:::-;12822:67;;;12656:240;;;:::o;13323:140::-;13394:7;13420:36;:8;:18;13429:8;13420:18;;;;;;;;;;;;;;;:34;:36::i;:::-;13413:43;;13323:140;;;:::o;22486:148::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;22587:8;:18;22596:8;22587:18;;;;;;;;;;;;;;;:38;;;;:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;22587:40:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;22587:40:25;;;;22486:148;:::o;21837:217::-;1890:10;1840:60;;:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1840:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1840:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1840:46:25;;;;;;;;;;;;;;;;:60;;;1819:162;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;21988:8;:18;21997:8;21988:18;;;;;;;;;;;;;;;:34;;;;22023:23;21988:59;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;21988:59:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;21988:59:25;;;;21837:217;;:::o;11916:219::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;12018:40;12061:16;:23;12078:5;12061:23;;;;;;;;;;;;;;;:33;12085:8;12061:33;;;;;;;;;;;;;;;12018:76;;12127:1;12104:4;:20;;:24;;;;1657:1;11916:219;;:::o;13899:212::-;13980:7;13999:39;14041:8;:18;14050:8;14041:18;;;;;;;;;;;;;;;13999:60;;14076:7;:28;;;14069:35;;;13899:212;;;:::o;1928:107:57:-;1061:9;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2000:28;2019:8;2000:18;:28::i;:::-;1928:107;:::o;20046:259:25:-;20148:7;20167:40;20210:16;:23;20227:5;20210:23;;;;;;;;;;;;;;;:33;20234:8;20210:33;;;;;;;;;;;;;;;20167:76;;20260:4;:38;;;20253:45;;;20046:259;;;;:::o;10999:262::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;11129:40;11172:16;:23;11189:5;11172:23;;;;;;;;;;;;;;;:33;11196:8;11172:33;;;;;;;;;;;;;;;11129:76;;11238:16;11215:4;:20;;;:39;;;;;;;;;;;;;;;;;;1657:1;10999:262;;;:::o;24865:286::-;1590:10;1568:32;;:18;;;;;;;;;;;:32;;;1560:87;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;24998:15;;;;;;;;;;;24986:27;;:8;:27;;;24982:163;;25028:44;25057:5;25064:7;25034:8;25028:28;;;;:44;;;;;:::i;:::-;24982:163;;;25111:5;:14;;:23;25126:7;25111:23;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;25111:23:25;24982:163;24865:286;;;:::o;18519:225::-;18606:7;18625:40;18668:16;:23;18685:5;18668:23;;;;;;;;;;;;;;;:33;18692:8;18668:33;;;;;;;;;;;;;;;18625:76;;18718:4;:19;;;18711:26;;;18519:225;;;;:::o;4555:410:28:-;4652:30;4685:58;4711:31;:5;:20;;;:29;:31::i;:::-;4685:18;:7;:16;:18::i;:::-;:25;;:58;;;;:::i;:::-;4652:91;;4754:26;4783:44;4810:16;:14;:16::i;:::-;4783:22;:26;;:44;;;;:::i;:::-;4754:73;;4875:83;4914:5;:34;;;4875:18;:25;;:83;;;;:::i;:::-;4838:5;:34;;:120;;;;4555:410;;;;:::o;834:176:56:-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;10730:167:28:-;10874:15;10836:8;:28;;;:54;;;;;;;;;;;;;;;;;;10730:167;:::o;842:202:61:-;942:95;961:5;991;:18;;;:27;;;;1020:4;1026:2;1030:5;968:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;49:4:-1;39:7;30;26:21;22:32;13:7;6:49;968:68:61;;;;;;;38:4:-1;29:7;25:18;67:10;61:17;96:58;199:8;192:4;186;182:15;179:29;167:10;160:49;0:215;;;968:68:61;942:18;:95::i;:::-;842:202;;;;:::o;1274:134:56:-;1332:7;1358:43;1362:1;1365;1358:43;;;;;;;;;;;;;;;;;:3;:43::i;:::-;1351:50;;1274:134;;;;:::o;9037:1163:28:-;9211:7;9181:8;:26;;;:37;;9173:76;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9260:32;9295:8;:26;;;9260:61;;9402:39;9433:7;9402:8;:26;;;:30;;:39;;;;:::i;:::-;9373:8;:26;;:68;;;;9486:1;9456:8;:26;;;:31;9452:171;;;9544:1;9503:8;:38;;:42;;;;9606:7;;;9452:171;9719:26;9748:32;9774:5;9748:18;:7;:16;:18::i;:::-;:25;;:32;;;;:::i;:::-;9719:61;;9790:36;9829:82;9872:8;:38;;;9829:35;:24;:33;:35::i;:::-;:42;;:82;;;;:::i;:::-;9790:121;;9962:18;9930:28;:50;;9922:99;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10073:120;10146:37;:8;:26;;;:35;:37::i;:::-;10073:52;10106:18;10073:28;:32;;:52;;;;:::i;:::-;:59;;:120;;;;:::i;:::-;10032:8;:38;;:161;;;;9037:1163;;;;;;;:::o;8248:783::-;8383:32;8418:8;:26;;;8383:61;;8524:39;8555:7;8524:8;:26;;;:30;;:39;;;;:::i;:::-;8495:8;:26;;:68;;;;8660:26;8689:32;8715:5;8689:18;:7;:16;:18::i;:::-;:25;;:32;;;;:::i;:::-;8660:61;;8731:36;8770:82;8813:8;:38;;;8770:35;:24;:33;:35::i;:::-;:42;;:82;;;;:::i;:::-;8731:121;;8904:120;8977:37;:8;:26;;;:35;:37::i;:::-;8904:52;8927:28;8904:18;:22;;:52;;;;:::i;:::-;:59;;:120;;;;:::i;:::-;8863:8;:38;;:161;;;;8248:783;;;;;;:::o;10206:184::-;10341:42;10375:7;10341:8;:29;;;:33;;:42;;;;:::i;:::-;10309:8;:29;;:74;;;;10206:184;;:::o;10396:328::-;10540:7;10507:8;:29;;;:40;;10499:134;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10675:42;10709:7;10675:8;:29;;;:33;;:42;;;;:::i;:::-;10643:8;:29;;:74;;;;10396:328;;:::o;2652:299::-;2737:7;2785:1;2761:5;:20;;;:25;2757:39;;;2795:1;2788:8;;;;2757:39;2807:20;2830:55;2858:5;:26;;;2830:5;:23;;;:27;;:55;;;;:::i;:::-;2807:78;;2903:41;2923:5;:20;;;2903:12;:19;;:41;;;;:::i;:::-;2896:48;;;2652:299;;;;:::o;26964:336:25:-;27035:24;27062:5;27035:32;;27082:9;27094:1;27082:13;;27077:154;27101:12;:19;;;;27097:1;:23;27077:154;;;27162:8;27143:27;;:12;27156:1;27143:15;;;;;;;;;;;;;;;;;;;;;;;;;:27;;;27139:92;;;27212:4;27190:26;;27139:92;27122:3;;;;;;;27077:154;;;;27245:19;27240:53;;27266:12;27284:8;27266:27;;39:1:-1;33:3;27:10;23:18;57:10;52:3;45:23;79:10;72:17;;0:93;27266:27:25;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;27240:53;26964:336;;:::o;3700:849:28:-;3779:23;3805:32;3831:5;3805:25;:32::i;:::-;3779:58;;3870:1;3852:15;:19;3848:695;;;3955:34;3992:81;4019:5;:26;;;4047:5;:25;;;;;;;;;;;;3992:26;:81::i;:::-;3955:118;;4125:99;4176:5;:34;;;4125:26;:33;;:99;;;;:::i;:::-;4088:5;:34;;:136;;;;4239:39;4281:86;4308:5;:31;;;4341:5;:25;;;;;;;;;;;;4281:26;:86::i;:::-;4239:128;;4423:109;4479:5;:39;;;4423:31;:38;;:109;;;;:::i;:::-;4381:5;:39;;:151;;;;3848:695;;;3700:849;;:::o;26722:236:25:-;26818:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;26818:46:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;26818:46:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;26818:46:25;;;;;;;;;;;;;;;;26793:91;;;:93;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;26793:93:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;26793:93:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;26793:93:25;;;;;;;;;;;;;;;;26775:15;;:111;;;;;;;;;;;;;;;;;;26917:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;26917:34:25;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;26917:34:25;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;26917:34:25;;;;;;;;;;;;;;;;26896:18;;:55;;;;;;;;;;;;;;;;;;26722:236::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;6904:1338:28:-;7088:7;7144:1;7112:5;:28;;;:33;7108:47;;;7154:1;7147:8;;;;7108:47;7166:33;7202:39;:5;:28;;;:37;:39::i;:::-;7166:75;;7251:25;7279:1;7251:29;;7290:25;7318:1;7290:29;;7358:1;7334:5;:21;;;:25;7330:464;;;7395:76;7422:5;:21;;;7445:5;:25;;;;;;;;;;;;7395:26;:76::i;:::-;7375:96;;7330:464;;;7558:225;7743:5;:39;;;7558:160;7675:8;:42;;;7558:92;7585:8;:34;;;7621:8;:28;;;;;;;;;;;;7558:26;:92::i;:::-;:116;;:160;;;;:::i;:::-;:184;;:225;;;;:::i;:::-;7538:245;;7330:464;7824:88;:64;7870:17;7824:25;:45;;:64;;;;:::i;:::-;:86;:88::i;:::-;7804:108;;7947:5;:28;;;7926:17;:49;7923:278;;;8151:39;8184:5;8151;:28;;;:32;;:39;;;;:::i;:::-;8144:46;;;;;;;7923:278;8218:17;8211:24;;;;;6904:1338;;;;;:::o;3102:368::-;3220:7;3244:17;3264:171;3397:8;:37;;;3264:112;3304:8;:29;;;3347:8;:28;;;;;;;;;;;;3264:26;:112::i;:::-;:132;;:171;;;;:::i;:::-;3244:191;;3453:9;3446:16;;;3102:368;;;:::o;10903:181::-;10992:7;11018:59;11048:7;:28;;;11018:7;:25;;;:29;;:59;;;;:::i;:::-;11011:66;;10903:181;;;:::o;2136:225:57:-;2229:1;2209:22;;:8;:22;;;;2201:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2318:8;2289:38;;2310:6;;;;;;;;;;;2289:38;;;;;;;;;;;;2346:8;2337:6;;:17;;;;;;;;;;;;;;;;;;2136:225;:::o;662:174:61:-;744:85;763:5;793;:14;;;:23;;;;818:2;822:5;770:58;;;;;;;;;;;;;;;;;;;;;;;;;49:4:-1;39:7;30;26:21;22:32;13:7;6:49;770:58:61;;;;;;;38:4:-1;29:7;25:18;67:10;61:17;96:58;199:8;192:4;186;182:15;179:29;167:10;160:49;0:215;;;770:58:61;744:18;:85::i;:::-;662:174;;;:::o;1584:105:29:-;1636:7;1662:20;547:3;1662:1;:5;;:20;;;;:::i;:::-;1655:27;;1584:105;;;:::o;1313:154::-;1374:7;1393:13;1413:1;1409;:5;;;;;;1393:21;;1432:28;1458:1;1432:21;1442:10;454:4;1442:1;:5;;:10;;;;:::i;:::-;1432:5;:9;;:21;;;;:::i;:::-;:25;;:28;;;;:::i;:::-;1425:35;;;1313:154;;;;:::o;557:74::-;595:7;454:4;614:10;;557:74;:::o;1183:124::-;1244:7;1270:30;454:4;1270:21;1282:8;1288:1;1282;:5;;:8;;;;:::i;:::-;506:1;454:4;500:7;;;;;;1270:11;;:21;;;;:::i;:::-;:25;;:30;;;;:::i;:::-;1263:37;;1183:124;;;;:::o;2666:1095:61:-;3261:27;3269:5;3261:25;;;:27::i;:::-;3253:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3395:12;3409:23;3444:5;3436:19;;3456:4;3436:25;;;;;;;;;;;;;36:153:-1;66:2;61:3;58:11;36:153;;182:3;176:10;171:3;164:23;98:2;93:3;89:12;82:19;;123:2;118:3;114:12;107:19;;148:2;143:3;139:12;132:19;;36:153;;;274:1;267:3;263:2;259:12;254:3;250:22;246:30;315:4;311:9;305:3;299:10;295:26;356:4;350:3;344:10;340:21;389:7;380;377:20;372:3;365:33;3:399;;;3436:25:61;;;;;;;;;;;;;;;;;;;;;;;;14:1:-1;21;16:31;;;;75:4;69:11;64:16;;144:4;140:9;133:4;115:16;111:27;107:43;104:1;100:51;94:4;87:65;169:16;166:1;159:27;225:16;222:1;215:4;212:1;208:12;193:49;7:242;;16:31;36:4;31:9;;7:242;;3394:67:61;;;;3479:7;3471:52;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3558:1;3538:10;:17;:21;3534:221;;;3678:10;3667:30;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3667:30:61;;;;;;;;;;;;;;;;3659:85;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3534:221;2666:1095;;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;11158:385:28:-;11259:7;11314:22;11339:41;11359:20;11339:41;;:15;:19;;:41;;;;:::i;:::-;11314:66;;11391:17;11411:61;11444:27;573:8;11444:25;:27::i;:::-;11411:25;:14;:23;:25::i;:::-;:32;;:61;;;;:::i;:::-;11391:81;;11491:45;11519:16;:14;:16::i;:::-;11491:23;11504:9;11491:5;:12;;:23;;;;:::i;:::-;:27;;:45;;;;:::i;:::-;11484:52;;;;11158:385;;;;:::o;1473:105:29:-;1525:7;1551:20;547:3;1551:1;:5;;:20;;;;:::i;:::-;1544:27;;1473:105;;;:::o;2159:459:56:-;2217:7;2463:1;2458;:6;2454:45;;;2487:1;2480:8;;;;2454:45;2509:9;2525:1;2521;:5;2509:17;;2553:1;2548;2544;:5;;;;;;:10;2536:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2610:1;2603:8;;;2159:459;;;;;:::o;3073:130::-;3131:7;3157:39;3161:1;3164;3157:39;;;;;;;;;;;;;;;;;:3;:39::i;:::-;3150:46;;3073:130;;;;:::o;3718:338::-;3804:7;3901:1;3897;:5;3904:12;3889:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;3889:28:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3927:9;3943:1;3939;:5;;;;;;3927:17;;4048:1;4041:8;;;3718:338;;;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/ownership/Ownable.sol\";\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\";\nimport \"openzeppelin-solidity/contracts/utils/Address.sol\";\nimport \"../libraries/CoreLibrary.sol\";\nimport \"../configuration/LendingPoolAddressesProvider.sol\";\nimport \"../interfaces/IPriceOracle.sol\";\nimport \"../interfaces/ILendingRateOracle.sol\";\nimport \"../interfaces/IReserveInterestRateStrategy.sol\";\nimport \"../interfaces/INetworkMetadataProvider.sol\";\nimport \"../libraries/WadRayMath.sol\";\n\n\n/*************************************************************************************\n@title LendingPoolCore contract\n@author Aave\n@notice Contains all the data and the funds deposited into a lending pool\n *************************************************************************************/\n\ncontract LendingPoolCore is Ownable {\n\n using SafeMath for uint256;\n using WadRayMath for uint256;\n using CoreLibrary for CoreLibrary.ReserveData;\n using SafeERC20 for ERC20;\n using Address for address payable;\n\n /**\n @dev ethereumAddress represents a ERC20 contract address with which the pool identifies ETH\n */\n address ethereumAddress;\n\n address lendingPoolAddress;\n\n\n LendingPoolAddressesProvider public addressesProvider;\n\n /**\n @dev only lending pools can use functions affected by this modifier\n */\n modifier onlyLendingPool {\n require(lendingPoolAddress == msg.sender, \"The caller must be a lending pool contract\");\n _;\n }\n\n /**\n @dev only lending pools configurator can use functions affected by this modifier\n */\n modifier onlyLendingPoolConfigurator {\n require(\n addressesProvider.getLendingPoolConfigurator() == msg.sender,\n \"The caller must be a lending pool configurator contract\"\n );\n _;\n }\n\n\n /**\n @dev functions affected by this modifier can only be invoked if a reserve is enabled for borrowing and/or collateral\n */\n modifier onlyReserveWithEnabledBorrowingOrCollateral(address _reserve) {\n require(\n reserves[_reserve].borrowingEnabled || reserves[_reserve].usageAsCollateralEnabled,\n \"Reserve is not enabled for borrowing or for being used as collateral\"\n );\n _;\n }\n\n /**\n @dev functions affected by this modifier can only be invoked if a reserve is enabled for borrowing\n */\n modifier onlyReserveWithEnabledBorrowing(address _reserve) {\n require(reserves[_reserve].borrowingEnabled, \"Reserve is not enabled for borrowing\");\n _;\n }\n\n mapping(address => CoreLibrary.ReserveData) reserves;\n mapping(address => mapping(address => CoreLibrary.UserReserveData)) usersReserveData;\n \n address[] public reservesList;\n\n constructor(LendingPoolAddressesProvider _addressesProvider) public {\n addressesProvider = _addressesProvider;\n refreshConfigInternal();\n }\n\n /**\n @dev functions to update reserves data\n */\n\n /**\n @notice Updates the reserve Liquidity cumulative interest Ci and the Variable borrows cumulative index Bvc. Please refer to the\n whitepaper for further information.\n */\n function updateReserveCumulativeIndexes(address _reserve) external onlyLendingPool {\n reserves[_reserve].updateCumulativeIndexes();\n }\n\n /**\n @notice cumulates a fixed amount of liquidity to the reserve, considered as a specific interest accrued in one block. Please refer\n to the whitepaper for further information.\n */\n\n function cumulateLiquidityToReserveLiquidityIndex(address _reserve, uint256 _amount) external onlyLendingPool {\n reserves[_reserve].cumulateToLiquidityIndex(_amount);\n }\n\n /**\n @notice Updates the reserve current fixed borrow rate Rf, the current variable borrow rate Rv and the current liquidity rate Rl.\n Please refer to the whitepaper for further information.\n */\n\n function updateReserveInterestRates(address _reserve) external onlyLendingPool {\n\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n (reserve.currentLiquidityRate,\n reserve.currentFixedBorrowRate,\n reserve.currentVariableBorrowRate) = IReserveInterestRateStrategy(reserve.interestRateStrategyAddress).\n calculateInterestRates(\n _reserve,\n reserve.getReserveUtilizationRate(),\n reserve.totalBorrowsFixed,\n reserve.totalBorrowsVariable,\n reserve.currentAverageFixedBorrowRate\n );\n }\n\n /**\n @notice increases the total liquidity Lt of a reserve\n */\n\n function increaseReserveTotalLiquidity(address _reserve, uint256 _amount)\n external\n onlyLendingPool\n onlyReserveWithEnabledBorrowingOrCollateral(_reserve)\n {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n reserve.totalLiquidity = reserve.totalLiquidity.add(_amount);\n\n }\n\n /**\n @notice decreases the total liquidity Lt of a reserve\n */\n\n function decreaseReserveTotalLiquidity(address _reserve, uint256 _amount) external onlyLendingPool {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n reserve.totalLiquidity = reserve.totalLiquidity.sub(_amount);\n }\n\n /**\n @notice increases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper\n for further information.\n */\n\n function increaseReserveTotalBorrowsFixedAndUpdateAverageRate(address _reserve, uint256 _amount, uint256 _rate)\n external\n onlyLendingPool\n onlyReserveWithEnabledBorrowingOrCollateral(_reserve)\n {\n reserves[_reserve].increaseTotalBorrowsFixedAndUpdateAverageRate(_amount, _rate);\n }\n\n\n /**\n @notice decreases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper\n for further information.\n */\n\n\n function decreaseReserveTotalBorrowsFixedAndUpdateAverageRate(address _reserve, uint256 _amount, uint256 _rate)\n external\n onlyLendingPool\n {\n reserves[_reserve].decreaseTotalBorrowsFixedAndUpdateAverageRate(_amount, _rate);\n\n }\n /**\n @notice increases the the total borrow variable of a reserve Bv.\n */\n\n function increaseReserveTotalBorrowsVariable(address _reserve, uint256 _amount)\n external\n onlyLendingPool\n onlyReserveWithEnabledBorrowingOrCollateral(_reserve)\n {\n reserves[_reserve].increaseTotalBorrowsVariable(_amount);\n }\n\n /**\n @notice decreases the the total borrow variable of a reserve Bv.\n */\n\n\n function decreaseReserveTotalBorrowsVariable(address _reserve, uint256 _amount) external onlyLendingPool {\n reserves[_reserve].decreaseTotalBorrowsVariable(_amount);\n }\n\n /***************\n @dev increases the proper total borrows on a reserve depending on the type of interest rate chosen by the user\n ***************/\n\n function updateReserveTotalBorrowsByRateMode(\n address _reserve,\n address _user,\n uint256 _principalBalance,\n uint256 _balanceIncrease,\n CoreLibrary.InterestRateMode _newBorrowRateMode,\n uint256 _fixedRate\n ) external onlyLendingPool {\n CoreLibrary.InterestRateMode currentRateMode = getUserCurrentBorrowRateMode(_reserve, _user);\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n\n\n if (currentRateMode == CoreLibrary.InterestRateMode.FIXED) {\n // there was no previous borrow or previous borrow was fixed\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n reserve.decreaseTotalBorrowsFixedAndUpdateAverageRate(_principalBalance, user.fixedBorrowRate);\n\n if (_newBorrowRateMode == CoreLibrary.InterestRateMode.FIXED) {\n reserve.increaseTotalBorrowsFixedAndUpdateAverageRate(_principalBalance.add(_balanceIncrease), _fixedRate);\n } else if (_newBorrowRateMode == CoreLibrary.InterestRateMode.VARIABLE) {\n //switching the whole amount borrowed to variable\n reserve.increaseTotalBorrowsVariable(_principalBalance.add(_balanceIncrease));\n }\n } else {\n // previous borrow was variable\n if (_newBorrowRateMode == CoreLibrary.InterestRateMode.FIXED) {\n reserve.decreaseTotalBorrowsVariable(_principalBalance);\n reserve.increaseTotalBorrowsFixedAndUpdateAverageRate(_principalBalance.add(_balanceIncrease), _fixedRate);\n } else if (_newBorrowRateMode == CoreLibrary.InterestRateMode.VARIABLE) {\n //switching the whole amount borrowed to variable\n reserve.increaseTotalBorrowsVariable(_balanceIncrease);\n }\n }\n }\n\n /**\n @notice refreshes reserve last updated block number Bl\n */\n function setReserveLastUpdate(address _reserve) external onlyLendingPool {\n reserves[_reserve].setLastUpdate();\n }\n\n\n /***************\n @dev functions to update users reserve data\n */\n\n function updateUserLastVariableBorrowCumulativeIndex(address _reserve, address _user) external onlyLendingPool {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n\n user.lastVariableBorrowCumulativeIndex = reserve.lastVariableBorrowCumulativeIndex;\n }\n\n function increaseUserOriginationFee(address _reserve, address _user, uint256 _amount) external onlyLendingPool {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n user.originationFee = user.originationFee.add(_amount);\n }\n\n function decreaseUserOriginationFee(address _reserve, address _user, uint256 _amount) external onlyLendingPool {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n user.originationFee = user.originationFee.sub(_amount);\n }\n\n function increaseUserPrincipalBorrowBalance(address _reserve, address _user, uint256 _amount)\n external\n onlyLendingPool\n onlyReserveWithEnabledBorrowing(_reserve)\n {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n user.principalBorrowBalance = user.principalBorrowBalance.add(_amount);\n }\n\n function decreaseUserPrincipalBorrowBalance(address _reserve, address _user, uint256 _amount)\n external\n onlyLendingPool\n {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n require(user.principalBorrowBalance >= _amount, \"The borrow balance is too low\");\n user.principalBorrowBalance = user.principalBorrowBalance.sub(_amount);\n }\n\n function setUserUseReserveAsCollateral(address _reserve, address _user, bool _useAsCollateral) external onlyLendingPool {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n user.useAsCollateral = _useAsCollateral;\n }\n\n function setUserLastUpdate(address _reserve, address _user) external onlyLendingPool {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n\n //solium-disable-next-line\n user.lastUpdateTimestamp = uint40(block.timestamp);\n }\n\n /******************\n @dev updates the fixed borrow rate for the user\n *******************/\n function updateUserFixedBorrowRate(address _reserve, address _user) external onlyLendingPool {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n\n user.fixedBorrowRate = getReserveCurrentFixedBorrowRate(_reserve);\n }\n\n function resetUserFixedBorrowRate(address _reserve, address _user) external onlyLendingPool {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n user.fixedBorrowRate = 0;\n }\n\n /*********************\n @dev reserve accessors\n *********************/\n\n function getReserveInterestRateStrategyAddress(address _reserve) public view returns (address) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.interestRateStrategyAddress;\n }\n\n function getReserveATokenAddress(address _reserve) public view returns (address) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.aTokenAddress;\n }\n\n function getReserveAvailableLiquidity(address _reserve) public view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.totalLiquidity.sub(getReserveTotalBorrows(_reserve));\n }\n\n function getReserveTotalLiquidity(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.totalLiquidity;\n }\n\n function getReserveNormalizedIncome(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.getNormalizedIncome();\n }\n\n function getReserveTotalBorrows(address _reserve) public view returns (uint256) {\n return reserves[_reserve].getTotalBorrows();\n }\n\n function getReserveTotalBorrowsFixed(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.totalBorrowsFixed;\n }\n\n function getReserveTotalBorrowsVariable(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.totalBorrowsVariable;\n }\n\n function getReserveLiquidationThreshold(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.liquidationThreshold;\n }\n\n function getReserveLiquidationDiscount(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.liquidationDiscount;\n }\n\n function getReserveCurrentVariableBorrowRate(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n\n if(reserve.currentVariableBorrowRate == 0) {\n return IReserveInterestRateStrategy(reserve.interestRateStrategyAddress)\n .getBaseVariableBorrowRate();\n }\n return reserve.currentVariableBorrowRate;\n }\n\n function getReserveCurrentFixedBorrowRate(address _reserve) public view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n ILendingRateOracle oracle = ILendingRateOracle(addressesProvider.getLendingRateOracle());\n\n if (reserve.currentFixedBorrowRate == 0) {\n //no fixed rate borrows yet\n return oracle.getMarketBorrowRate(_reserve);\n }\n\n return reserve.currentFixedBorrowRate;\n }\n\n function getReserveCurrentAverageFixedBorrowRate(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.currentAverageFixedBorrowRate;\n }\n\n function getReserveCurrentLiquidityRate(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.currentLiquidityRate;\n }\n\n function getReserveLiquidityCumulativeIndex(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.lastLiquidityCumulativeIndex;\n }\n\n function getReserveVariableBorrowsCumulativeIndex(address _reserve) external view returns (uint256) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.lastVariableBorrowCumulativeIndex;\n }\n\n /**\n * @dev this function aggregates the configuration parameters of the reserve.\n * It's used in the LendingPoolDataProvider specifically to save gas, and avoid\n * multiple external contract calls to fetch the same data.\n */\n\n function getReserveConfiguration(address _reserve)\n external\n view\n returns (uint256 decimals,\n uint256 baseLTVasCollateral,\n uint256 liquidationThreshold,\n bool usageAsCollateralEnabled,\n bool fixedBorrowRateEnabled,\n bool borrowingEnabled) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n decimals = reserve.decimals;\n baseLTVasCollateral = reserve.baseLTVasCollateral;\n liquidationThreshold = reserve.liquidationThreshold;\n usageAsCollateralEnabled = reserve.usageAsCollateralEnabled;\n fixedBorrowRateEnabled = reserve.isFixedBorrowRateEnabled;\n borrowingEnabled = reserve.borrowingEnabled;\n }\n\n function isReserveBorrowingEnabled(address _reserve) external view returns (bool) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.borrowingEnabled;\n }\n\n function isReserveUsageAsCollateralEnabled(address _reserve) external view returns (bool) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.usageAsCollateralEnabled;\n }\n\n function getReserveIsFixedBorrowRateEnabled(address _reserve) external view returns (bool) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.isFixedBorrowRateEnabled;\n }\n\n function getReserveIsActive(address _reserve) external view returns(bool) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n return reserve.isActive;\n }\n\n\n function getReserveLastUpdate(address _reserve) external view returns (uint40 timestamp) {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n timestamp = reserve.lastUpdateTimestamp;\n }\n\n /******************\n @dev user accessors\n ******************/\n\n function isUserUseReserveAsCollateralEnabled(address _reserve, address _user) external view returns (bool) {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n return user.useAsCollateral;\n }\n function getUserOriginationFee(address _reserve, address _user) external view returns (uint256) {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n return user.originationFee;\n }\n\n function getUserCurrentBorrowRateMode(address _reserve, address _user)\n public\n view\n returns (CoreLibrary.InterestRateMode)\n {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n return user.fixedBorrowRate > 0 ? CoreLibrary.InterestRateMode.FIXED : CoreLibrary.InterestRateMode.VARIABLE;\n }\n\n function getUserCurrentFixedBorrowRate(address _reserve, address _user) external view returns (uint256) {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n return user.fixedBorrowRate;\n }\n\n function getUserBorrowBalances(\n address _reserve,\n address _user)\n external view returns (\n uint256 principalBorrowBalance,\n uint256 compoundedBorrowBalance,\n uint256 compoundedAmount) {\n\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n\n principalBorrowBalance = user.principalBorrowBalance;\n compoundedBorrowBalance = CoreLibrary.getCompoundedBorrowBalance(\n user,\n reserve\n );\n\n compoundedAmount = compoundedBorrowBalance.sub(principalBorrowBalance);\n }\n\n function getUserVariableBorrowCumulativeIndex(address _reserve, address _user) external view returns (uint256) {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n return user.lastVariableBorrowCumulativeIndex;\n }\n\n function getUserLastUpdate(address _reserve, address _user)\n external\n view\n returns (uint256 timestamp)\n {\n CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve];\n timestamp = user.lastUpdateTimestamp;\n }\n\n /**\n @dev utility functions\n */\n\n function getReserveUtilizationRate(address _reserve) external view returns (uint256) {\n return reserves[_reserve].getReserveUtilizationRate();\n }\n\n function getReserves() external view returns (address[] memory) {\n return reservesList;\n }\n\n /**\n @dev Core configuration functions\n */\n\n function setAddressesProvider(address _addressesProvider ) external onlyLendingPoolConfigurator {\n\n addressesProvider = LendingPoolAddressesProvider(_addressesProvider);\n refreshConfigInternal();\n }\n\n function refreshConfiguration() external onlyLendingPoolConfigurator {\n refreshConfigInternal();\n }\n\n function initReserve(address _reserve, address _aTokenAddress, uint256 _decimals, address _interestRateStrategyAddress)\n external\n onlyLendingPoolConfigurator\n {\n reserves[_reserve].init(_aTokenAddress, _decimals, _interestRateStrategyAddress);\n addReserveToListInternal(_reserve);\n\n }\n\n function setReserveInterestRateStrategyAddress(address _reserve, address _rateStrategyAddress) external onlyLendingPoolConfigurator {\n reserves[_reserve].interestRateStrategyAddress = _rateStrategyAddress;\n }\n\n function enableBorrowingOnReserve(\n address _reserve,\n bool _fixedBorrowRateEnabled\n ) external onlyLendingPoolConfigurator {\n reserves[_reserve].enableBorrowing(_fixedBorrowRateEnabled);\n }\n\n function disableBorrowingOnReserve(address _reserve) external onlyLendingPoolConfigurator {\n reserves[_reserve].disableBorrowing();\n }\n\n function enableReserveAsCollateral(address _reserve, uint256 _baseLTVasCollateral, uint256 _liquidationThreshold)\n external\n onlyLendingPoolConfigurator\n {\n reserves[_reserve].enableAsCollateral(_baseLTVasCollateral, _liquidationThreshold);\n }\n\n function disableReserveAsCollateral(address _reserve) external onlyLendingPoolConfigurator {\n reserves[_reserve].disableAsCollateral();\n }\n\n function enableReserveFixedBorrowRate(address _reserve) external onlyLendingPoolConfigurator {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n reserve.isFixedBorrowRateEnabled = true;\n }\n\n function disableReserveFixedBorrowRate(address _reserve) external onlyLendingPoolConfigurator {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n reserve.isFixedBorrowRateEnabled = false;\n }\n\n function activateReserve(address _reserve) external onlyLendingPoolConfigurator {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n\n require(\n reserve.lastLiquidityCumulativeIndex > 0 &&\n reserve.lastVariableBorrowCumulativeIndex > 0,\n \"Reserve has not been initialized yet\"\n );\n reserve.isActive = true;\n }\n\n function deactivateReserve(address _reserve) external onlyLendingPoolConfigurator {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n reserve.isActive = false;\n }\n\n\n /***************\n @dev functions to update available collaterals\n @dev the interest rate and the ltv are expressed in percentage\n */\n\n function setReserveBaseLTVasCollateral(address _reserve, uint256 _ltv)\n external\n onlyLendingPoolConfigurator {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n reserve.baseLTVasCollateral = _ltv;\n }\n\n function setReserveLiquidationThreshold(address _reserve, uint256 _threshold)\n external\n onlyLendingPoolConfigurator\n {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n reserve.liquidationThreshold = _threshold;\n }\n\n function setReserveLiquidationDiscount(address _reserve, uint256 _discount)\n external\n onlyLendingPoolConfigurator\n {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n reserve.liquidationDiscount = _discount;\n }\n\n /**\n @notice ETH/token transfer functions\n */\n function() external payable {\n //only contracts can send ETH to the core\n require(msg.sender.isContract(), \"Only contracts can send ether to the Lending pool core\");\n\n }\n\n function transferToUser(address _reserve, address payable _user, uint256 _amount) external onlyLendingPool {\n if (_reserve != ethereumAddress){\n ERC20(_reserve).safeTransfer(_user, _amount);\n }\n else {\n _user.transfer(_amount);\n }\n }\n\n function transferToFeeCollectionAddress(address _token, address _user, uint256 _amount, address destination)\n external\n payable\n onlyLendingPool\n {\n address payable feeAddress = address(uint160(destination)); //cast the address to payable\n\n if (_token != ethereumAddress) {\n ERC20(_token).safeTransferFrom(_user, feeAddress, _amount);\n } else {\n require(msg.value >= _amount, \"The amount and the value sent to deposit do not match\");\n feeAddress.transfer(_amount);\n }\n }\n\n function transferToReserve(address _reserve, address payable _user, uint256 _amount) external payable onlyLendingPool {\n CoreLibrary.ReserveData storage reserve = reserves[_reserve];\n\n require(\n reserve.usageAsCollateralEnabled || reserve.borrowingEnabled,\n \"The reserve isn't enabled for borrowing or as collateral\"\n );\n\n if (_reserve != ethereumAddress){\n require(msg.value == 0, \"User is sending ETH along with the ERC20 transfer. Check the value attribute of the transaction\");\n ERC20(_reserve).safeTransferFrom(_user, address(this), _amount);\n\n }\n else {\n require(msg.value >= _amount, \"The amount and the value sent to deposit do not match\");\n\n if(msg.value > _amount) { //send back excess ETH\n uint256 excessAmount = msg.value.sub(_amount);\n _user.transfer(excessAmount);\n }\n }\n }\n\n /**\n @notice internal functions\n */\n\n\n function refreshConfigInternal() internal {\n\n ethereumAddress = INetworkMetadataProvider(addressesProvider.getNetworkMetadataProvider()).getEthereumAddress();\n lendingPoolAddress = addressesProvider.getLendingPool();\n }\n\n function addReserveToListInternal(address _reserve) internal {\n bool reserveAlreadyAdded = false;\n for (uint256 i = 0; i < reservesList.length; i++)\n if (reservesList[i] == _reserve) {\n reserveAlreadyAdded = true;\n }\n if (!reserveAlreadyAdded) reservesList.push(_reserve);\n }\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "exportedSymbols": { + "LendingPoolCore": [ + 6682 + ] + }, + "id": 6683, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 4659, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:25" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "id": 4660, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 11255, + "src": "25:63:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 4661, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 11141, + "src": "89:59:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "id": 4662, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 12007, + "src": "149:67:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "id": 4663, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 11660, + "src": "217:63:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "file": "openzeppelin-solidity/contracts/utils/Address.sol", + "id": 4664, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 12082, + "src": "281:59:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "file": "../libraries/CoreLibrary.sol", + "id": 4665, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 8995, + "src": "341:38:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 4666, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 1358, + "src": "380:59:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol", + "file": "../interfaces/IPriceOracle.sol", + "id": 4667, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 1960, + "src": "440:40:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol", + "file": "../interfaces/ILendingRateOracle.sol", + "id": 4668, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 1910, + "src": "481:46:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol", + "file": "../interfaces/IReserveInterestRateStrategy.sol", + "id": 4669, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 1987, + "src": "528:56:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "file": "../interfaces/INetworkMetadataProvider.sol", + "id": 4670, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 1933, + "src": "585:52:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 4671, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 9175, + "src": "638:37:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 4672, + "name": "Ownable", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11254, + "src": "1001:7:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Ownable_$11254", + "typeString": "contract Ownable" + } + }, + "id": 4673, + "nodeType": "InheritanceSpecifier", + "src": "1001:7:25" + } + ], + "contractDependencies": [ + 10953, + 11254 + ], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title LendingPoolCore contract\n@author Aave\n@notice Contains all the data and the funds deposited into a lending pool************************************************************************************", + "fullyImplemented": true, + "id": 6682, + "linearizedBaseContracts": [ + 6682, + 11254, + 10953 + ], + "name": "LendingPoolCore", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 4676, + "libraryName": { + "contractScope": null, + "id": 4674, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "1022:8:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1016:27:25", + "typeName": { + "id": 4675, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1035:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 4679, + "libraryName": { + "contractScope": null, + "id": 4677, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "1054:10:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1048:29:25", + "typeName": { + "id": 4678, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1069:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 4682, + "libraryName": { + "contractScope": null, + "id": 4680, + "name": "CoreLibrary", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8994, + "src": "1088:11:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_CoreLibrary_$8994", + "typeString": "library CoreLibrary" + } + }, + "nodeType": "UsingForDirective", + "src": "1082:46:25", + "typeName": { + "contractScope": null, + "id": 4681, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "1104:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + } + }, + { + "id": 4685, + "libraryName": { + "contractScope": null, + "id": 4683, + "name": "SafeERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12006, + "src": "1139:9:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + }, + "nodeType": "UsingForDirective", + "src": "1133:26:25", + "typeName": { + "contractScope": null, + "id": 4684, + "name": "ERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11659, + "src": "1153:5:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + } + }, + { + "id": 4688, + "libraryName": { + "contractScope": null, + "id": 4686, + "name": "Address", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12081, + "src": "1170:7:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + }, + "nodeType": "UsingForDirective", + "src": "1164:34:25", + "typeName": { + "id": 4687, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1182:15:25", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + }, + { + "constant": false, + "id": 4690, + "name": "ethereumAddress", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "1313:23:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4689, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1313:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4692, + "name": "lendingPoolAddress", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "1343:26:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4691, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1343:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4694, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "1377:53:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 4693, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1377:28:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "public" + }, + { + "body": { + "id": 4705, + "nodeType": "Block", + "src": "1550:115:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 4700, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 4697, + "name": "lendingPoolAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4692, + "src": "1568:18:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4698, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "1590:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 4699, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1590:10:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "1568:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c20636f6e7472616374", + "id": 4701, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1602:44:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a630c1f6937c43653bd3cbe824a9088f40dc120875fe6c5545d9a34152a6c2c1", + "typeString": "literal_string \"The caller must be a lending pool contract\"" + }, + "value": "The caller must be a lending pool contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_a630c1f6937c43653bd3cbe824a9088f40dc120875fe6c5545d9a34152a6c2c1", + "typeString": "literal_string \"The caller must be a lending pool contract\"" + } + ], + "id": 4696, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1560:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4702, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1560:87:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4703, + "nodeType": "ExpressionStatement", + "src": "1560:87:25" + }, + { + "id": 4704, + "nodeType": "PlaceholderStatement", + "src": "1657:1:25" + } + ] + }, + "documentation": "@dev only lending pools can use functions affected by this modifier", + "id": 4706, + "name": "onlyLendingPool", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 4695, + "nodeType": "ParameterList", + "parameters": [], + "src": "1550:0:25" + }, + "src": "1525:140:25", + "visibility": "internal" + }, + { + "body": { + "id": 4719, + "nodeType": "Block", + "src": "1809:190:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 4714, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4709, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "1840:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4710, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolConfigurator", + "nodeType": "MemberAccess", + "referencedDeclaration": 1141, + "src": "1840:44:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 4711, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1840:46:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4712, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "1890:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 4713, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1890:10:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "1840:60:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c20636f6e666967757261746f7220636f6e7472616374", + "id": 4715, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1914:57:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8c7f0d16bf0dd67d21ca9dc67d55c2a427e32bd5c515428d66032bf648ff5ae2", + "typeString": "literal_string \"The caller must be a lending pool configurator contract\"" + }, + "value": "The caller must be a lending pool configurator contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_8c7f0d16bf0dd67d21ca9dc67d55c2a427e32bd5c515428d66032bf648ff5ae2", + "typeString": "literal_string \"The caller must be a lending pool configurator contract\"" + } + ], + "id": 4708, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1819:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4716, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1819:162:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4717, + "nodeType": "ExpressionStatement", + "src": "1819:162:25" + }, + { + "id": 4718, + "nodeType": "PlaceholderStatement", + "src": "1991:1:25" + } + ] + }, + "documentation": "@dev only lending pools configurator can use functions affected by this modifier", + "id": 4720, + "name": "onlyLendingPoolConfigurator", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 4707, + "nodeType": "ParameterList", + "parameters": [], + "src": "1809:0:25" + }, + "src": "1772:227:25", + "visibility": "internal" + }, + { + "body": { + "id": 4738, + "nodeType": "Block", + "src": "2214:225:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 4733, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4725, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "2245:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4727, + "indexExpression": { + "argumentTypes": null, + "id": 4726, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4722, + "src": "2254:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2245:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4728, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "2245:35:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4729, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "2284:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4731, + "indexExpression": { + "argumentTypes": null, + "id": 4730, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4722, + "src": "2293:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2284:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4732, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "2284:43:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "2245:82:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "52657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e67206f7220666f72206265696e67207573656420617320636f6c6c61746572616c", + "id": 4734, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2341:70:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_9a45699ae27cf613d2e94f669de055bca9fb1bb85c238d47e03d344368cacf25", + "typeString": "literal_string \"Reserve is not enabled for borrowing or for being used as collateral\"" + }, + "value": "Reserve is not enabled for borrowing or for being used as collateral" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_9a45699ae27cf613d2e94f669de055bca9fb1bb85c238d47e03d344368cacf25", + "typeString": "literal_string \"Reserve is not enabled for borrowing or for being used as collateral\"" + } + ], + "id": 4724, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2224:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4735, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2224:197:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4736, + "nodeType": "ExpressionStatement", + "src": "2224:197:25" + }, + { + "id": 4737, + "nodeType": "PlaceholderStatement", + "src": "2431:1:25" + } + ] + }, + "documentation": "@dev functions affected by this modifier can only be invoked if a reserve is enabled for borrowing and/or collateral", + "id": 4739, + "name": "onlyReserveWithEnabledBorrowingOrCollateral", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 4723, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4722, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4739, + "src": "2196:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4721, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2196:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2195:18:25" + }, + "src": "2143:296:25", + "visibility": "internal" + }, + { + "body": { + "id": 4752, + "nodeType": "Block", + "src": "2623:112:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4744, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "2641:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4746, + "indexExpression": { + "argumentTypes": null, + "id": 4745, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4741, + "src": "2650:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2641:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4747, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "2641:35:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "52657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e67", + "id": 4748, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2678:38:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + }, + "value": "Reserve is not enabled for borrowing" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + } + ], + "id": 4743, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2633:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4749, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2633:84:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4750, + "nodeType": "ExpressionStatement", + "src": "2633:84:25" + }, + { + "id": 4751, + "nodeType": "PlaceholderStatement", + "src": "2727:1:25" + } + ] + }, + "documentation": "@dev functions affected by this modifier can only be invoked if a reserve is enabled for borrowing", + "id": 4753, + "name": "onlyReserveWithEnabledBorrowing", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 4742, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4741, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4753, + "src": "2605:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4740, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2605:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2604:18:25" + }, + "src": "2564:171:25", + "visibility": "internal" + }, + { + "constant": false, + "id": 4757, + "name": "reserves", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "2741:52:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData)" + }, + "typeName": { + "id": 4756, + "keyType": { + "id": 4754, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2749:7:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "2741:43:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData)" + }, + "valueType": { + "contractScope": null, + "id": 4755, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "2760:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4763, + "name": "usersReserveData", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "2799:84:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData))" + }, + "typeName": { + "id": 4762, + "keyType": { + "id": 4758, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2807:7:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "2799:67:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData))" + }, + "valueType": { + "id": 4761, + "keyType": { + "id": 4759, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2826:7:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "2818:47:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData)" + }, + "valueType": { + "contractScope": null, + "id": 4760, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "2837:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + } + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4766, + "name": "reservesList", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "2894:29:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 4764, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2894:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 4765, + "length": null, + "nodeType": "ArrayTypeName", + "src": "2894:9:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "public" + }, + { + "body": { + "id": 4778, + "nodeType": "Block", + "src": "2998:88:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 4773, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 4771, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "3008:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 4772, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4768, + "src": "3028:18:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "3008:38:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4774, + "nodeType": "ExpressionStatement", + "src": "3008:38:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 4775, + "name": "refreshConfigInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6639, + "src": "3056:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$", + "typeString": "function ()" + } + }, + "id": 4776, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3056:23:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4777, + "nodeType": "ExpressionStatement", + "src": "3056:23:25" + } + ] + }, + "documentation": null, + "id": 4779, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4769, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4768, + "name": "_addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 4779, + "src": "2942:47:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 4767, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "2942:28:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2941:49:25" + }, + "returnParameters": { + "id": 4770, + "nodeType": "ParameterList", + "parameters": [], + "src": "2998:0:25" + }, + "scope": 6682, + "src": "2930:156:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 4792, + "nodeType": "Block", + "src": "3423:61:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4786, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "3433:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4788, + "indexExpression": { + "argumentTypes": null, + "id": 4787, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4781, + "src": "3442:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "3433:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4789, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "updateCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 8432, + "src": "3433:42:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer)" + } + }, + "id": 4790, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3433:44:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4791, + "nodeType": "ExpressionStatement", + "src": "3433:44:25" + } + ] + }, + "documentation": "@notice Updates the reserve Liquidity cumulative interest Ci and the Variable borrows cumulative index Bvc. Please refer to the\nwhitepaper for further information.", + "id": 4793, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4784, + "modifierName": { + "argumentTypes": null, + "id": 4783, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "3407:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "3407:15:25" + } + ], + "name": "updateReserveCumulativeIndexes", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4782, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4781, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4793, + "src": "3380:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4780, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3380:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3379:18:25" + }, + "returnParameters": { + "id": 4785, + "nodeType": "ParameterList", + "parameters": [], + "src": "3423:0:25" + }, + "scope": 6682, + "src": "3340:144:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4809, + "nodeType": "Block", + "src": "3798:69:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4806, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4797, + "src": "3852:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4802, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "3808:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4804, + "indexExpression": { + "argumentTypes": null, + "id": 4803, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4795, + "src": "3817:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "3808:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4805, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "cumulateToLiquidityIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8471, + "src": "3808:43:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 4807, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3808:52:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4808, + "nodeType": "ExpressionStatement", + "src": "3808:52:25" + } + ] + }, + "documentation": "@notice cumulates a fixed amount of liquidity to the reserve, considered as a specific interest accrued in one block. Please refer\nto the whitepaper for further information.", + "id": 4810, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4800, + "modifierName": { + "argumentTypes": null, + "id": 4799, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "3782:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "3782:15:25" + } + ], + "name": "cumulateLiquidityToReserveLiquidityIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4798, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4795, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4810, + "src": "3738:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4794, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3738:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4797, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4810, + "src": "3756:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4796, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3756:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3737:35:25" + }, + "returnParameters": { + "id": 4801, + "nodeType": "ParameterList", + "parameters": [], + "src": "3798:0:25" + }, + "scope": 6682, + "src": "3688:179:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4851, + "nodeType": "Block", + "src": "4162:522:25", + "statements": [ + { + "assignments": [ + 4820 + ], + "declarations": [ + { + "constant": false, + "id": 4820, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 4851, + "src": "4173:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 4819, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "4173:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4824, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4821, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "4215:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4823, + "indexExpression": { + "argumentTypes": null, + "id": 4822, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4812, + "src": "4224:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "4215:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4173:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 4849, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4825, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4244:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4827, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8289, + "src": "4244:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4828, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4282:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4829, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8297, + "src": "4282:30:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4830, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4322:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4831, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8295, + "src": "4322:33:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 4832, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "4243:113:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4838, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4812, + "src": "4474:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4839, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4496:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4840, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveUtilizationRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8354, + "src": "4496:33:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 4841, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4496:35:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4842, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4545:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4843, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "4545:25:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4844, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4584:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4845, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "4584:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4846, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4626:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4847, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "4626:37:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4834, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4388:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4835, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "interestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8313, + "src": "4388:35:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4833, + "name": "IReserveInterestRateStrategy", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1986, + "src": "4359:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IReserveInterestRateStrategy_$1986_$", + "typeString": "type(contract IReserveInterestRateStrategy)" + } + }, + "id": 4836, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4359:65:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IReserveInterestRateStrategy_$1986", + "typeString": "contract IReserveInterestRateStrategy" + } + }, + "id": 4837, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "calculateInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 1985, + "src": "4359:101:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,uint256,uint256,uint256,uint256) view external returns (uint256,uint256,uint256)" + } + }, + "id": 4848, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4359:318:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "src": "4243:434:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4850, + "nodeType": "ExpressionStatement", + "src": "4243:434:25" + } + ] + }, + "documentation": "@notice Updates the reserve current fixed borrow rate Rf, the current variable borrow rate Rv and the current liquidity rate Rl.\nPlease refer to the whitepaper for further information.", + "id": 4852, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4815, + "modifierName": { + "argumentTypes": null, + "id": 4814, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "4146:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4146:15:25" + } + ], + "name": "updateReserveInterestRates", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4813, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4812, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4852, + "src": "4119:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4811, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4119:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4118:18:25" + }, + "returnParameters": { + "id": 4816, + "nodeType": "ParameterList", + "parameters": [], + "src": "4162:0:25" + }, + "scope": 6682, + "src": "4083:601:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4882, + "nodeType": "Block", + "src": "4946:148:25", + "statements": [ + { + "assignments": [ + 4867 + ], + "declarations": [ + { + "constant": false, + "id": 4867, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 4882, + "src": "4956:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 4866, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "4956:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4871, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4868, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "4998:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4870, + "indexExpression": { + "argumentTypes": null, + "id": 4869, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4854, + "src": "5007:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "4998:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4956:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 4880, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4872, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4867, + "src": "5026:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4874, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "5026:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4878, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4856, + "src": "5078:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4875, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4867, + "src": "5051:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4876, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "5051:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 4877, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "5051:26:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 4879, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5051:35:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5026:60:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 4881, + "nodeType": "ExpressionStatement", + "src": "5026:60:25" + } + ] + }, + "documentation": "@notice increases the total liquidity Lt of a reserve", + "id": 4883, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4859, + "modifierName": { + "argumentTypes": null, + "id": 4858, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "4864:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4864:15:25" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 4861, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4854, + "src": "4932:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 4862, + "modifierName": { + "argumentTypes": null, + "id": 4860, + "name": "onlyReserveWithEnabledBorrowingOrCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4739, + "src": "4888:43:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "4888:53:25" + } + ], + "name": "increaseReserveTotalLiquidity", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4857, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4854, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4883, + "src": "4804:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4853, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4804:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4856, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4883, + "src": "4822:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4855, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4822:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4803:35:25" + }, + "returnParameters": { + "id": 4863, + "nodeType": "ParameterList", + "parameters": [], + "src": "4946:0:25" + }, + "scope": 6682, + "src": "4765:329:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4910, + "nodeType": "Block", + "src": "5274:147:25", + "statements": [ + { + "assignments": [ + 4895 + ], + "declarations": [ + { + "constant": false, + "id": 4895, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 4910, + "src": "5284:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 4894, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "5284:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4899, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4896, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "5326:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4898, + "indexExpression": { + "argumentTypes": null, + "id": 4897, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4885, + "src": "5335:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "5326:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5284:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 4908, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4900, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4895, + "src": "5354:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4902, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "5354:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4906, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4887, + "src": "5406:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4903, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4895, + "src": "5379:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4904, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "5379:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 4905, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "5379:26:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 4907, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5379:35:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5354:60:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 4909, + "nodeType": "ExpressionStatement", + "src": "5354:60:25" + } + ] + }, + "documentation": "@notice decreases the total liquidity Lt of a reserve", + "id": 4911, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4890, + "modifierName": { + "argumentTypes": null, + "id": 4889, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "5258:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5258:15:25" + } + ], + "name": "decreaseReserveTotalLiquidity", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4888, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4885, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4911, + "src": "5214:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4884, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5214:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4887, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4911, + "src": "5232:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4886, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5232:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5213:35:25" + }, + "returnParameters": { + "id": 4891, + "nodeType": "ParameterList", + "parameters": [], + "src": "5274:0:25" + }, + "scope": 6682, + "src": "5175:246:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4933, + "nodeType": "Block", + "src": "5831:97:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4929, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4915, + "src": "5906:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4930, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4917, + "src": "5915:5:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4925, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "5841:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4927, + "indexExpression": { + "argumentTypes": null, + "id": 4926, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4913, + "src": "5850:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "5841:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4928, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8793, + "src": "5841:64:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 4931, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5841:80:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4932, + "nodeType": "ExpressionStatement", + "src": "5841:80:25" + } + ] + }, + "documentation": "@notice increases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper\nfor further information.", + "id": 4934, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4920, + "modifierName": { + "argumentTypes": null, + "id": 4919, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "5749:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5749:15:25" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 4922, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4913, + "src": "5817:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 4923, + "modifierName": { + "argumentTypes": null, + "id": 4921, + "name": "onlyReserveWithEnabledBorrowingOrCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4739, + "src": "5773:43:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "5773:53:25" + } + ], + "name": "increaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4918, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4913, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4934, + "src": "5674:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4912, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5674:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4915, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4934, + "src": "5692:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4914, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5692:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4917, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 4934, + "src": "5709:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4916, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5709:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5673:50:25" + }, + "returnParameters": { + "id": 4924, + "nodeType": "ParameterList", + "parameters": [], + "src": "5831:0:25" + }, + "scope": 6682, + "src": "5612:316:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4953, + "nodeType": "Block", + "src": "6278:98:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4949, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4938, + "src": "6353:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4950, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4940, + "src": "6362:5:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4945, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "6288:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4947, + "indexExpression": { + "argumentTypes": null, + "id": 4946, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4936, + "src": "6297:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "6288:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4948, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8880, + "src": "6288:64:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 4951, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6288:80:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4952, + "nodeType": "ExpressionStatement", + "src": "6288:80:25" + } + ] + }, + "documentation": "@notice decreases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper\nfor further information.", + "id": 4954, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4943, + "modifierName": { + "argumentTypes": null, + "id": 4942, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "6258:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6258:15:25" + } + ], + "name": "decreaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4941, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4936, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4954, + "src": "6183:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4935, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6183:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4938, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4954, + "src": "6201:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4937, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6201:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4940, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 4954, + "src": "6218:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4939, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6218:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6182:50:25" + }, + "returnParameters": { + "id": 4944, + "nodeType": "ParameterList", + "parameters": [], + "src": "6278:0:25" + }, + "scope": 6682, + "src": "6121:255:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4973, + "nodeType": "Block", + "src": "6654:73:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4970, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4958, + "src": "6712:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4966, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "6664:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4968, + "indexExpression": { + "argumentTypes": null, + "id": 4967, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4956, + "src": "6673:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "6664:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4969, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8898, + "src": "6664:47:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 4971, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6664:56:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4972, + "nodeType": "ExpressionStatement", + "src": "6664:56:25" + } + ] + }, + "documentation": "@notice increases the the total borrow variable of a reserve Bv.", + "id": 4974, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4961, + "modifierName": { + "argumentTypes": null, + "id": 4960, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "6572:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6572:15:25" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 4963, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4956, + "src": "6640:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 4964, + "modifierName": { + "argumentTypes": null, + "id": 4962, + "name": "onlyReserveWithEnabledBorrowingOrCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4739, + "src": "6596:43:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "6596:53:25" + } + ], + "name": "increaseReserveTotalBorrowsVariable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4959, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4956, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4974, + "src": "6512:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4955, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6512:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4958, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4974, + "src": "6530:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4957, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6530:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6511:35:25" + }, + "returnParameters": { + "id": 4965, + "nodeType": "ParameterList", + "parameters": [], + "src": "6654:0:25" + }, + "scope": 6682, + "src": "6467:260:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4990, + "nodeType": "Block", + "src": "6929:73:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4987, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4978, + "src": "6987:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4983, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "6939:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4985, + "indexExpression": { + "argumentTypes": null, + "id": 4984, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4976, + "src": "6948:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "6939:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4986, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8924, + "src": "6939:47:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 4988, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6939:56:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4989, + "nodeType": "ExpressionStatement", + "src": "6939:56:25" + } + ] + }, + "documentation": "@notice decreases the the total borrow variable of a reserve Bv.", + "id": 4991, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4981, + "modifierName": { + "argumentTypes": null, + "id": 4980, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "6913:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6913:15:25" + } + ], + "name": "decreaseReserveTotalBorrowsVariable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4979, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4976, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4991, + "src": "6869:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4975, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6869:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4978, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4991, + "src": "6887:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4977, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6887:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6868:35:25" + }, + "returnParameters": { + "id": 4982, + "nodeType": "ParameterList", + "parameters": [], + "src": "6929:0:25" + }, + "scope": 6682, + "src": "6824:178:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5120, + "nodeType": "Block", + "src": "7446:1566:25", + "statements": [ + { + "assignments": [ + 5011 + ], + "declarations": [ + { + "constant": false, + "id": 5011, + "name": "currentRateMode", + "nodeType": "VariableDeclaration", + "scope": 5120, + "src": "7456:44:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 5010, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "7456:28:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5016, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5013, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4993, + "src": "7532:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 5014, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4995, + "src": "7542:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 5012, + "name": "getUserCurrentBorrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5988, + "src": "7503:28:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5015, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7503:45:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7456:92:25" + }, + { + "assignments": [ + 5020 + ], + "declarations": [ + { + "constant": false, + "id": 5020, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5120, + "src": "7558:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5019, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "7558:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5024, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5021, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "7600:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5023, + "indexExpression": { + "argumentTypes": null, + "id": 5022, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4993, + "src": "7609:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "7600:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7558:60:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 5029, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 5025, + "name": "currentRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5011, + "src": "7634:15:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5026, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "7653:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5027, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "7653:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5028, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7653:34:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "7634:53:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 5118, + "nodeType": "Block", + "src": "8440:566:25", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 5086, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 5082, + "name": "_newBorrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5001, + "src": "8502:18:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5083, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "8524:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5084, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "8524:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5085, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8524:34:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "8502:56:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 5108, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 5104, + "name": "_newBorrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5001, + "src": "8782:18:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5105, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "8804:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5106, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "8804:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5107, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "VARIABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8804:37:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "8782:59:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 5116, + "nodeType": "IfStatement", + "src": "8778:218:25", + "trueBody": { + "id": 5115, + "nodeType": "Block", + "src": "8843:153:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5112, + "name": "_balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4999, + "src": "8964:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5109, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "8927:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5111, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8898, + "src": "8927:36:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 5113, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8927:54:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5114, + "nodeType": "ExpressionStatement", + "src": "8927:54:25" + } + ] + } + }, + "id": 5117, + "nodeType": "IfStatement", + "src": "8498:498:25", + "trueBody": { + "id": 5103, + "nodeType": "Block", + "src": "8560:212:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5090, + "name": "_principalBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4997, + "src": "8615:17:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5087, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "8578:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5089, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8924, + "src": "8578:36:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 5091, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8578:55:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5092, + "nodeType": "ExpressionStatement", + "src": "8578:55:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5098, + "name": "_balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4999, + "src": "8727:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5096, + "name": "_principalBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4997, + "src": "8705:17:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5097, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8705:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5099, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8705:39:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 5100, + "name": "_fixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5003, + "src": "8746:10:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5093, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "8651:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5095, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8793, + "src": "8651:53:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 5101, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8651:106:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5102, + "nodeType": "ExpressionStatement", + "src": "8651:106:25" + } + ] + } + } + ] + }, + "id": 5119, + "nodeType": "IfStatement", + "src": "7630:1376:25", + "trueBody": { + "id": 5081, + "nodeType": "Block", + "src": "7689:745:25", + "statements": [ + { + "assignments": [ + 5033 + ], + "declarations": [ + { + "constant": false, + "id": 5033, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5081, + "src": "7776:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5032, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "7776:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5039, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5034, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "7819:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5036, + "indexExpression": { + "argumentTypes": null, + "id": 5035, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4995, + "src": "7836:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "7819:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5038, + "indexExpression": { + "argumentTypes": null, + "id": 5037, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4993, + "src": "7843:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "7819:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7776:76:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5043, + "name": "_principalBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4997, + "src": "7920:17:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5044, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5033, + "src": "7939:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5045, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "7939:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5040, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "7866:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5042, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8880, + "src": "7866:53:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 5046, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7866:94:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5047, + "nodeType": "ExpressionStatement", + "src": "7866:94:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 5052, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 5048, + "name": "_newBorrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5001, + "src": "7979:18:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5049, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "8001:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5050, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "8001:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5051, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8001:34:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "7979:56:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 5068, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 5064, + "name": "_newBorrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5001, + "src": "8187:18:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5065, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "8209:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5066, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "8209:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5067, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "VARIABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8209:37:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "8187:59:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 5079, + "nodeType": "IfStatement", + "src": "8183:241:25", + "trueBody": { + "id": 5078, + "nodeType": "Block", + "src": "8248:176:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5074, + "name": "_balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4999, + "src": "8391:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5072, + "name": "_principalBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4997, + "src": "8369:17:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5073, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8369:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5075, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8369:39:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5069, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "8332:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5071, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8898, + "src": "8332:36:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 5076, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8332:77:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5077, + "nodeType": "ExpressionStatement", + "src": "8332:77:25" + } + ] + } + }, + "id": 5080, + "nodeType": "IfStatement", + "src": "7975:449:25", + "trueBody": { + "id": 5063, + "nodeType": "Block", + "src": "8037:139:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5058, + "name": "_balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4999, + "src": "8131:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5056, + "name": "_principalBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4997, + "src": "8109:17:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5057, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8109:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5059, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8109:39:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 5060, + "name": "_fixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5003, + "src": "8150:10:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5053, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "8055:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5055, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8793, + "src": "8055:53:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 5061, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8055:106:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5062, + "nodeType": "ExpressionStatement", + "src": "8055:106:25" + } + ] + } + } + ] + } + } + ] + }, + "documentation": "*************\n@dev increases the proper total borrows on a reserve depending on the type of interest rate chosen by the user**************", + "id": 5121, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5006, + "modifierName": { + "argumentTypes": null, + "id": 5005, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "7430:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "7430:15:25" + } + ], + "name": "updateReserveTotalBorrowsByRateMode", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5004, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4993, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7221:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4992, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7221:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4995, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7247:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4994, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7247:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4997, + "name": "_principalBalance", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7270:25:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4996, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7270:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4999, + "name": "_balanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7305:24:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4998, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7305:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5001, + "name": "_newBorrowRateMode", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7339:47:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 5000, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "7339:28:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5003, + "name": "_fixedRate", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7396:18:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5002, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7396:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7211:209:25" + }, + "returnParameters": { + "id": 5007, + "nodeType": "ParameterList", + "parameters": [], + "src": "7446:0:25" + }, + "scope": 6682, + "src": "7167:1845:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5134, + "nodeType": "Block", + "src": "9166:51:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5128, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "9176:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5130, + "indexExpression": { + "argumentTypes": null, + "id": 5129, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5123, + "src": "9185:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9176:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 5131, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "setLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8939, + "src": "9176:32:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer)" + } + }, + "id": 5132, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9176:34:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5133, + "nodeType": "ExpressionStatement", + "src": "9176:34:25" + } + ] + }, + "documentation": "@notice refreshes reserve last updated block number Bl", + "id": 5135, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5126, + "modifierName": { + "argumentTypes": null, + "id": 5125, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "9150:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "9150:15:25" + } + ], + "name": "setReserveLastUpdate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5124, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5123, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5135, + "src": "9123:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5122, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9123:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9122:18:25" + }, + "returnParameters": { + "id": 5127, + "nodeType": "ParameterList", + "parameters": [], + "src": "9166:0:25" + }, + "scope": 6682, + "src": "9093:124:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5169, + "nodeType": "Block", + "src": "9413:256:25", + "statements": [ + { + "assignments": [ + 5147 + ], + "declarations": [ + { + "constant": false, + "id": 5147, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5169, + "src": "9423:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5146, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "9423:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5153, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5148, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "9466:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5150, + "indexExpression": { + "argumentTypes": null, + "id": 5149, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5139, + "src": "9483:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9466:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5152, + "indexExpression": { + "argumentTypes": null, + "id": 5151, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5137, + "src": "9490:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9466:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9423:76:25" + }, + { + "assignments": [ + 5157 + ], + "declarations": [ + { + "constant": false, + "id": 5157, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5169, + "src": "9509:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5156, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "9509:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5161, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5158, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "9551:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5160, + "indexExpression": { + "argumentTypes": null, + "id": 5159, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5137, + "src": "9560:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9551:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9509:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5167, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5162, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5147, + "src": "9580:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5164, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8274, + "src": "9580:38:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5165, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5157, + "src": "9621:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5166, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "9621:41:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9580:82:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5168, + "nodeType": "ExpressionStatement", + "src": "9580:82:25" + } + ] + }, + "documentation": "*************\n@dev functions to update users reserve data", + "id": 5170, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5142, + "modifierName": { + "argumentTypes": null, + "id": 5141, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "9397:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "9397:15:25" + } + ], + "name": "updateUserLastVariableBorrowCumulativeIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5140, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5137, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5170, + "src": "9355:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5136, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9355:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5139, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5170, + "src": "9373:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5138, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9373:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9354:33:25" + }, + "returnParameters": { + "id": 5143, + "nodeType": "ParameterList", + "parameters": [], + "src": "9413:0:25" + }, + "scope": 6682, + "src": "9302:367:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5201, + "nodeType": "Block", + "src": "9786:157:25", + "statements": [ + { + "assignments": [ + 5184 + ], + "declarations": [ + { + "constant": false, + "id": 5184, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5201, + "src": "9796:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5183, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "9796:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5190, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5185, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "9839:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5187, + "indexExpression": { + "argumentTypes": null, + "id": 5186, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5174, + "src": "9856:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9839:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5189, + "indexExpression": { + "argumentTypes": null, + "id": 5188, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5172, + "src": "9863:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9839:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9796:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5199, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5191, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5184, + "src": "9882:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5193, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "originationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 8276, + "src": "9882:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5197, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5176, + "src": "9928:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5194, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5184, + "src": "9904:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5195, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "originationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 8276, + "src": "9904:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5196, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "9904:23:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5198, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9904:32:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9882:54:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5200, + "nodeType": "ExpressionStatement", + "src": "9882:54:25" + } + ] + }, + "documentation": null, + "id": 5202, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5179, + "modifierName": { + "argumentTypes": null, + "id": 5178, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "9770:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "9770:15:25" + } + ], + "name": "increaseUserOriginationFee", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5177, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5172, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5202, + "src": "9711:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5171, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9711:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5174, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5202, + "src": "9729:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5173, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9729:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5176, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 5202, + "src": "9744:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5175, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9744:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9710:50:25" + }, + "returnParameters": { + "id": 5180, + "nodeType": "ParameterList", + "parameters": [], + "src": "9786:0:25" + }, + "scope": 6682, + "src": "9675:268:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5233, + "nodeType": "Block", + "src": "10060:157:25", + "statements": [ + { + "assignments": [ + 5216 + ], + "declarations": [ + { + "constant": false, + "id": 5216, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5233, + "src": "10070:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5215, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "10070:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5222, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5217, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "10113:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5219, + "indexExpression": { + "argumentTypes": null, + "id": 5218, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5206, + "src": "10130:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10113:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5221, + "indexExpression": { + "argumentTypes": null, + "id": 5220, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5204, + "src": "10137:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10113:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "10070:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5231, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5223, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5216, + "src": "10156:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5225, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "originationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 8276, + "src": "10156:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5229, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5208, + "src": "10202:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5226, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5216, + "src": "10178:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5227, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "originationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 8276, + "src": "10178:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5228, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "10178:23:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5230, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10178:32:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10156:54:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5232, + "nodeType": "ExpressionStatement", + "src": "10156:54:25" + } + ] + }, + "documentation": null, + "id": 5234, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5211, + "modifierName": { + "argumentTypes": null, + "id": 5210, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "10044:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "10044:15:25" + } + ], + "name": "decreaseUserOriginationFee", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5209, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5204, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5234, + "src": "9985:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5203, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9985:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5206, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5234, + "src": "10003:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5205, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10003:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5208, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 5234, + "src": "10018:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5207, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10018:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9984:50:25" + }, + "returnParameters": { + "id": 5212, + "nodeType": "ParameterList", + "parameters": [], + "src": "10060:0:25" + }, + "scope": 6682, + "src": "9949:268:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5268, + "nodeType": "Block", + "src": "10412:173:25", + "statements": [ + { + "assignments": [ + 5251 + ], + "declarations": [ + { + "constant": false, + "id": 5251, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5268, + "src": "10422:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5250, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "10422:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5257, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5252, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "10465:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5254, + "indexExpression": { + "argumentTypes": null, + "id": 5253, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5238, + "src": "10482:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10465:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5256, + "indexExpression": { + "argumentTypes": null, + "id": 5255, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5236, + "src": "10489:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10465:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "10422:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5266, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5258, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5251, + "src": "10508:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5260, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "10508:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5264, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5240, + "src": "10570:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5261, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5251, + "src": "10538:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5262, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "10538:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5263, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "10538:31:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5265, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10538:40:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10508:70:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5267, + "nodeType": "ExpressionStatement", + "src": "10508:70:25" + } + ] + }, + "documentation": null, + "id": 5269, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5243, + "modifierName": { + "argumentTypes": null, + "id": 5242, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "10342:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "10342:15:25" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 5245, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5236, + "src": "10398:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 5246, + "modifierName": { + "argumentTypes": null, + "id": 5244, + "name": "onlyReserveWithEnabledBorrowing", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4753, + "src": "10366:31:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "10366:41:25" + } + ], + "name": "increaseUserPrincipalBorrowBalance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5241, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5236, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5269, + "src": "10267:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5235, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10267:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5238, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5269, + "src": "10285:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5237, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10285:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5240, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 5269, + "src": "10300:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5239, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10300:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10266:50:25" + }, + "returnParameters": { + "id": 5247, + "nodeType": "ParameterList", + "parameters": [], + "src": "10412:0:25" + }, + "scope": 6682, + "src": "10223:362:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5308, + "nodeType": "Block", + "src": "10730:263:25", + "statements": [ + { + "assignments": [ + 5283 + ], + "declarations": [ + { + "constant": false, + "id": 5283, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5308, + "src": "10740:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5282, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "10740:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5289, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5284, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "10783:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5286, + "indexExpression": { + "argumentTypes": null, + "id": 5285, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5273, + "src": "10800:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10783:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5288, + "indexExpression": { + "argumentTypes": null, + "id": 5287, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5271, + "src": "10807:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10783:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "10740:76:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 5294, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5291, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5283, + "src": "10834:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5292, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "10834:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 5293, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5275, + "src": "10865:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10834:38:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520626f72726f772062616c616e636520697320746f6f206c6f77", + "id": 5295, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "10874:31:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_123a7f21cf668d1416a24569213afa79d97c3368899a9765f824f8894421c2af", + "typeString": "literal_string \"The borrow balance is too low\"" + }, + "value": "The borrow balance is too low" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_123a7f21cf668d1416a24569213afa79d97c3368899a9765f824f8894421c2af", + "typeString": "literal_string \"The borrow balance is too low\"" + } + ], + "id": 5290, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "10826:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 5296, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10826:80:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5297, + "nodeType": "ExpressionStatement", + "src": "10826:80:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5306, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5298, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5283, + "src": "10916:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5300, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "10916:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5304, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5275, + "src": "10978:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5301, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5283, + "src": "10946:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5302, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "10946:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5303, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "10946:31:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5305, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10946:40:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10916:70:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5307, + "nodeType": "ExpressionStatement", + "src": "10916:70:25" + } + ] + }, + "documentation": null, + "id": 5309, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5278, + "modifierName": { + "argumentTypes": null, + "id": 5277, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "10710:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "10710:15:25" + } + ], + "name": "decreaseUserPrincipalBorrowBalance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5276, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5271, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5309, + "src": "10635:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5270, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10635:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5273, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5309, + "src": "10653:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5272, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10653:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5275, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 5309, + "src": "10668:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5274, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10668:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10634:50:25" + }, + "returnParameters": { + "id": 5279, + "nodeType": "ParameterList", + "parameters": [], + "src": "10730:0:25" + }, + "scope": 6682, + "src": "10591:402:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5336, + "nodeType": "Block", + "src": "11119:142:25", + "statements": [ + { + "assignments": [ + 5323 + ], + "declarations": [ + { + "constant": false, + "id": 5323, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5336, + "src": "11129:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5322, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "11129:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5329, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5324, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "11172:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5326, + "indexExpression": { + "argumentTypes": null, + "id": 5325, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5313, + "src": "11189:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11172:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5328, + "indexExpression": { + "argumentTypes": null, + "id": 5327, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5311, + "src": "11196:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11172:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "11129:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5334, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5330, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5323, + "src": "11215:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5332, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "useAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8282, + "src": "11215:20:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 5333, + "name": "_useAsCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5315, + "src": "11238:16:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "11215:39:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 5335, + "nodeType": "ExpressionStatement", + "src": "11215:39:25" + } + ] + }, + "documentation": null, + "id": 5337, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5318, + "modifierName": { + "argumentTypes": null, + "id": 5317, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "11103:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "11103:15:25" + } + ], + "name": "setUserUseReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5316, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5311, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5337, + "src": "11038:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5310, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11038:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5313, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5337, + "src": "11056:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5312, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11056:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5315, + "name": "_useAsCollateral", + "nodeType": "VariableDeclaration", + "scope": 5337, + "src": "11071:21:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5314, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "11071:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11037:56:25" + }, + "returnParameters": { + "id": 5319, + "nodeType": "ParameterList", + "parameters": [], + "src": "11119:0:25" + }, + "scope": 6682, + "src": "10999:262:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5365, + "nodeType": "Block", + "src": "11352:189:25", + "statements": [ + { + "assignments": [ + 5349 + ], + "declarations": [ + { + "constant": false, + "id": 5349, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5365, + "src": "11362:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5348, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "11362:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5355, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5350, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "11405:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5352, + "indexExpression": { + "argumentTypes": null, + "id": 5351, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5341, + "src": "11422:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11405:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5354, + "indexExpression": { + "argumentTypes": null, + "id": 5353, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5339, + "src": "11429:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11405:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "11362:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5363, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5356, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5349, + "src": "11484:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5358, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8280, + "src": "11484:24:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5360, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "11518:5:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 5361, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11518:15:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 5359, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "11511:6:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint40_$", + "typeString": "type(uint40)" + }, + "typeName": "uint40" + }, + "id": 5362, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11511:23:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "src": "11484:50:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "id": 5364, + "nodeType": "ExpressionStatement", + "src": "11484:50:25" + } + ] + }, + "documentation": null, + "id": 5366, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5344, + "modifierName": { + "argumentTypes": null, + "id": 5343, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "11336:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "11336:15:25" + } + ], + "name": "setUserLastUpdate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5342, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5339, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5366, + "src": "11294:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5338, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11294:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5341, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5366, + "src": "11312:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5340, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11312:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11293:33:25" + }, + "returnParameters": { + "id": 5345, + "nodeType": "ParameterList", + "parameters": [], + "src": "11352:0:25" + }, + "scope": 6682, + "src": "11267:274:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5393, + "nodeType": "Block", + "src": "11741:169:25", + "statements": [ + { + "assignments": [ + 5378 + ], + "declarations": [ + { + "constant": false, + "id": 5378, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5393, + "src": "11751:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5377, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "11751:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5384, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5379, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "11794:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5381, + "indexExpression": { + "argumentTypes": null, + "id": 5380, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5370, + "src": "11811:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11794:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5383, + "indexExpression": { + "argumentTypes": null, + "id": 5382, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5368, + "src": "11818:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11794:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "11751:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5391, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5385, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5378, + "src": "11838:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5387, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "11838:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5389, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5368, + "src": "11894:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 5388, + "name": "getReserveCurrentFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5681, + "src": "11861:32:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 5390, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11861:42:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11838:65:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5392, + "nodeType": "ExpressionStatement", + "src": "11838:65:25" + } + ] + }, + "documentation": "****************\n@dev updates the fixed borrow rate for the user******************", + "id": 5394, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5373, + "modifierName": { + "argumentTypes": null, + "id": 5372, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "11725:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "11725:15:25" + } + ], + "name": "updateUserFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5371, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5368, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5394, + "src": "11683:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5367, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11683:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5370, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5394, + "src": "11701:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5369, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11701:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11682:33:25" + }, + "returnParameters": { + "id": 5374, + "nodeType": "ParameterList", + "parameters": [], + "src": "11741:0:25" + }, + "scope": 6682, + "src": "11648:262:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5419, + "nodeType": "Block", + "src": "12008:127:25", + "statements": [ + { + "assignments": [ + 5406 + ], + "declarations": [ + { + "constant": false, + "id": 5406, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5419, + "src": "12018:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5405, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "12018:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5412, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5407, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "12061:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5409, + "indexExpression": { + "argumentTypes": null, + "id": 5408, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5398, + "src": "12078:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "12061:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5411, + "indexExpression": { + "argumentTypes": null, + "id": 5410, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5396, + "src": "12085:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "12061:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "12018:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5417, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5413, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5406, + "src": "12104:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5415, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "12104:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "30", + "id": 5416, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "12127:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "12104:24:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5418, + "nodeType": "ExpressionStatement", + "src": "12104:24:25" + } + ] + }, + "documentation": null, + "id": 5420, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5401, + "modifierName": { + "argumentTypes": null, + "id": 5400, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "11992:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "11992:15:25" + } + ], + "name": "resetUserFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5399, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5396, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5420, + "src": "11950:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5395, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11950:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5398, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5420, + "src": "11968:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5397, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11968:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11949:33:25" + }, + "returnParameters": { + "id": 5402, + "nodeType": "ParameterList", + "parameters": [], + "src": "12008:0:25" + }, + "scope": 6682, + "src": "11916:219:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5438, + "nodeType": "Block", + "src": "12319:129:25", + "statements": [ + { + "assignments": [ + 5430 + ], + "declarations": [ + { + "constant": false, + "id": 5430, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5438, + "src": "12329:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5429, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "12329:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5434, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5431, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "12371:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5433, + "indexExpression": { + "argumentTypes": null, + "id": 5432, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5422, + "src": "12380:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "12371:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "12329:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5435, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5430, + "src": "12406:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5436, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "interestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8313, + "src": "12406:35:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 5426, + "id": 5437, + "nodeType": "Return", + "src": "12399:42:25" + } + ] + }, + "documentation": "*******************\n@dev reserve accessors********************", + "id": 5439, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveInterestRateStrategyAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5423, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5422, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5439, + "src": "12271:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5421, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12271:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12270:18:25" + }, + "returnParameters": { + "id": 5426, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5425, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5439, + "src": "12310:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5424, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12310:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12309:9:25" + }, + "scope": 6682, + "src": "12224:224:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 5457, + "nodeType": "Block", + "src": "12535:115:25", + "statements": [ + { + "assignments": [ + 5449 + ], + "declarations": [ + { + "constant": false, + "id": 5449, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5457, + "src": "12545:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5448, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "12545:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5453, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5450, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "12587:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5452, + "indexExpression": { + "argumentTypes": null, + "id": 5451, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5441, + "src": "12596:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "12587:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "12545:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5454, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5449, + "src": "12622:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5455, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "aTokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8311, + "src": "12622:21:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 5445, + "id": 5456, + "nodeType": "Return", + "src": "12615:28:25" + } + ] + }, + "documentation": null, + "id": 5458, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveATokenAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5442, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5441, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5458, + "src": "12487:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5440, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12487:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12486:18:25" + }, + "returnParameters": { + "id": 5445, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5444, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5458, + "src": "12526:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5443, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12526:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12525:9:25" + }, + "scope": 6682, + "src": "12454:196:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 5481, + "nodeType": "Block", + "src": "12742:154:25", + "statements": [ + { + "assignments": [ + 5468 + ], + "declarations": [ + { + "constant": false, + "id": 5468, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5481, + "src": "12752:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5467, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "12752:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5472, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5469, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "12794:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5471, + "indexExpression": { + "argumentTypes": null, + "id": 5470, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5460, + "src": "12803:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "12794:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "12752:60:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5477, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5460, + "src": "12879:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 5476, + "name": "getReserveTotalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5535, + "src": "12856:22:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 5478, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12856:32:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5473, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5468, + "src": "12829:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5474, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "12829:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5475, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "12829:26:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5479, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12829:60:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5464, + "id": 5480, + "nodeType": "Return", + "src": "12822:67:25" + } + ] + }, + "documentation": null, + "id": 5482, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveAvailableLiquidity", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5461, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5460, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5482, + "src": "12694:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5459, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12694:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12693:18:25" + }, + "returnParameters": { + "id": 5464, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5463, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5482, + "src": "12733:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5462, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12733:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12732:9:25" + }, + "scope": 6682, + "src": "12656:240:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 5500, + "nodeType": "Block", + "src": "12986:116:25", + "statements": [ + { + "assignments": [ + 5492 + ], + "declarations": [ + { + "constant": false, + "id": 5492, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5500, + "src": "12996:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5491, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "12996:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5496, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5493, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "13038:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5495, + "indexExpression": { + "argumentTypes": null, + "id": 5494, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5484, + "src": "13047:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "13038:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "12996:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5497, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5492, + "src": "13073:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5498, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "13073:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5488, + "id": 5499, + "nodeType": "Return", + "src": "13066:29:25" + } + ] + }, + "documentation": null, + "id": 5501, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveTotalLiquidity", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5485, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5484, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5501, + "src": "12936:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5483, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12936:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12935:18:25" + }, + "returnParameters": { + "id": 5488, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5487, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5501, + "src": "12977:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5486, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12977:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12976:9:25" + }, + "scope": 6682, + "src": "12902:200:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5520, + "nodeType": "Block", + "src": "13194:123:25", + "statements": [ + { + "assignments": [ + 5511 + ], + "declarations": [ + { + "constant": false, + "id": 5511, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5520, + "src": "13204:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5510, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "13204:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5515, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5512, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "13246:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5514, + "indexExpression": { + "argumentTypes": null, + "id": 5513, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5503, + "src": "13255:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "13246:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13204:60:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 5516, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5511, + "src": "13281:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5517, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "getNormalizedIncome", + "nodeType": "MemberAccess", + "referencedDeclaration": 8377, + "src": "13281:27:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 5518, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13281:29:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5507, + "id": 5519, + "nodeType": "Return", + "src": "13274:36:25" + } + ] + }, + "documentation": null, + "id": 5521, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveNormalizedIncome", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5504, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5503, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5521, + "src": "13144:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5502, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13144:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13143:18:25" + }, + "returnParameters": { + "id": 5507, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5506, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5521, + "src": "13185:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5505, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13185:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13184:9:25" + }, + "scope": 6682, + "src": "13108:209:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5534, + "nodeType": "Block", + "src": "13403:60:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5528, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "13420:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5530, + "indexExpression": { + "argumentTypes": null, + "id": 5529, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5523, + "src": "13429:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "13420:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 5531, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "getTotalBorrows", + "nodeType": "MemberAccess", + "referencedDeclaration": 8954, + "src": "13420:34:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 5532, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13420:36:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5527, + "id": 5533, + "nodeType": "Return", + "src": "13413:43:25" + } + ] + }, + "documentation": null, + "id": 5535, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveTotalBorrows", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5524, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5523, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5535, + "src": "13355:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5522, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13355:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13354:18:25" + }, + "returnParameters": { + "id": 5527, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5526, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5535, + "src": "13394:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5525, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13394:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13393:9:25" + }, + "scope": 6682, + "src": "13323:140:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 5553, + "nodeType": "Block", + "src": "13556:119:25", + "statements": [ + { + "assignments": [ + 5545 + ], + "declarations": [ + { + "constant": false, + "id": 5545, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5553, + "src": "13566:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5544, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "13566:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5549, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5546, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "13608:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5548, + "indexExpression": { + "argumentTypes": null, + "id": 5547, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5537, + "src": "13617:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "13608:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13566:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5550, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5545, + "src": "13643:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5551, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "13643:25:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5541, + "id": 5552, + "nodeType": "Return", + "src": "13636:32:25" + } + ] + }, + "documentation": null, + "id": 5554, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveTotalBorrowsFixed", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5538, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5537, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5554, + "src": "13506:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5536, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13506:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13505:18:25" + }, + "returnParameters": { + "id": 5541, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5540, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5554, + "src": "13547:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5539, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13547:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13546:9:25" + }, + "scope": 6682, + "src": "13469:206:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5572, + "nodeType": "Block", + "src": "13771:122:25", + "statements": [ + { + "assignments": [ + 5564 + ], + "declarations": [ + { + "constant": false, + "id": 5564, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5572, + "src": "13781:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5563, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "13781:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5568, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5565, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "13823:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5567, + "indexExpression": { + "argumentTypes": null, + "id": 5566, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5556, + "src": "13832:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "13823:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13781:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5569, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5564, + "src": "13858:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5570, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "13858:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5560, + "id": 5571, + "nodeType": "Return", + "src": "13851:35:25" + } + ] + }, + "documentation": null, + "id": 5573, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveTotalBorrowsVariable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5557, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5556, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5573, + "src": "13721:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5555, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13721:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13720:18:25" + }, + "returnParameters": { + "id": 5560, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5559, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5573, + "src": "13762:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5558, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13762:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13761:9:25" + }, + "scope": 6682, + "src": "13681:212:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5591, + "nodeType": "Block", + "src": "13989:122:25", + "statements": [ + { + "assignments": [ + 5583 + ], + "declarations": [ + { + "constant": false, + "id": 5583, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5591, + "src": "13999:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5582, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "13999:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5587, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5584, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "14041:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5586, + "indexExpression": { + "argumentTypes": null, + "id": 5585, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5575, + "src": "14050:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "14041:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13999:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5588, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5583, + "src": "14076:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5589, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 8305, + "src": "14076:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5579, + "id": 5590, + "nodeType": "Return", + "src": "14069:35:25" + } + ] + }, + "documentation": null, + "id": 5592, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveLiquidationThreshold", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5576, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5575, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5592, + "src": "13939:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5574, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13939:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13938:18:25" + }, + "returnParameters": { + "id": 5579, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5578, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5592, + "src": "13980:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5577, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13980:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13979:9:25" + }, + "scope": 6682, + "src": "13899:212:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5610, + "nodeType": "Block", + "src": "14206:121:25", + "statements": [ + { + "assignments": [ + 5602 + ], + "declarations": [ + { + "constant": false, + "id": 5602, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5610, + "src": "14216:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5601, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "14216:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5606, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5603, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "14258:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5605, + "indexExpression": { + "argumentTypes": null, + "id": 5604, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5594, + "src": "14267:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "14258:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14216:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5607, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5602, + "src": "14293:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5608, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 8307, + "src": "14293:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5598, + "id": 5609, + "nodeType": "Return", + "src": "14286:34:25" + } + ] + }, + "documentation": null, + "id": 5611, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveLiquidationDiscount", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5595, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5594, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5611, + "src": "14156:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5593, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14156:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14155:18:25" + }, + "returnParameters": { + "id": 5598, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5597, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5611, + "src": "14197:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5596, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14197:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14196:9:25" + }, + "scope": 6682, + "src": "14117:210:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5642, + "nodeType": "Block", + "src": "14428:322:25", + "statements": [ + { + "assignments": [ + 5621 + ], + "declarations": [ + { + "constant": false, + "id": 5621, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5642, + "src": "14438:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5620, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "14438:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5625, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5622, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "14480:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5624, + "indexExpression": { + "argumentTypes": null, + "id": 5623, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5613, + "src": "14489:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "14480:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14438:60:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 5629, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5626, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5621, + "src": "14512:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5627, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8295, + "src": "14512:33:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 5628, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "14549:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "14512:38:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 5638, + "nodeType": "IfStatement", + "src": "14509:185:25", + "trueBody": { + "id": 5637, + "nodeType": "Block", + "src": "14552:142:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5631, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5621, + "src": "14602:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5632, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "interestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8313, + "src": "14602:35:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 5630, + "name": "IReserveInterestRateStrategy", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1986, + "src": "14573:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IReserveInterestRateStrategy_$1986_$", + "typeString": "type(contract IReserveInterestRateStrategy)" + } + }, + "id": 5633, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14573:65:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IReserveInterestRateStrategy_$1986", + "typeString": "contract IReserveInterestRateStrategy" + } + }, + "id": 5634, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getBaseVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 1966, + "src": "14573:108:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$", + "typeString": "function () view external returns (uint256)" + } + }, + "id": 5635, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14573:110:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5617, + "id": 5636, + "nodeType": "Return", + "src": "14566:117:25" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5639, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5621, + "src": "14710:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5640, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8295, + "src": "14710:33:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5617, + "id": 5641, + "nodeType": "Return", + "src": "14703:40:25" + } + ] + }, + "documentation": null, + "id": 5643, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveCurrentVariableBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5614, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5613, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5643, + "src": "14378:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5612, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14378:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14377:18:25" + }, + "returnParameters": { + "id": 5617, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5616, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5643, + "src": "14419:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5615, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14419:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14418:9:25" + }, + "scope": 6682, + "src": "14333:417:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5680, + "nodeType": "Block", + "src": "14846:382:25", + "statements": [ + { + "assignments": [ + 5653 + ], + "declarations": [ + { + "constant": false, + "id": 5653, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5680, + "src": "14856:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5652, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "14856:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5657, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5654, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "14898:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5656, + "indexExpression": { + "argumentTypes": null, + "id": 5655, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5645, + "src": "14907:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "14898:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14856:60:25" + }, + { + "assignments": [ + 5659 + ], + "declarations": [ + { + "constant": false, + "id": 5659, + "name": "oracle", + "nodeType": "VariableDeclaration", + "scope": 5680, + "src": "14926:25:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + }, + "typeName": { + "contractScope": null, + "id": 5658, + "name": "ILendingRateOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1909, + "src": "14926:18:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5665, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 5661, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "14973:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 5662, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingRateOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1291, + "src": "14973:38:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 5663, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14973:40:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 5660, + "name": "ILendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1909, + "src": "14954:18:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ILendingRateOracle_$1909_$", + "typeString": "type(contract ILendingRateOracle)" + } + }, + "id": 5664, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14954:60:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14926:88:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 5669, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5666, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5653, + "src": "15029:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5667, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8297, + "src": "15029:30:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 5668, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "15063:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "15029:35:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 5676, + "nodeType": "IfStatement", + "src": "15025:149:25", + "trueBody": { + "id": 5675, + "nodeType": "Block", + "src": "15066:108:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5672, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5645, + "src": "15154:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 5670, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5659, + "src": "15127:6:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "id": 5671, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getMarketBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 1887, + "src": "15127:26:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 5673, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15127:36:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5649, + "id": 5674, + "nodeType": "Return", + "src": "15120:43:25" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5677, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5653, + "src": "15191:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5678, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8297, + "src": "15191:30:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5649, + "id": 5679, + "nodeType": "Return", + "src": "15184:37:25" + } + ] + }, + "documentation": null, + "id": 5681, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveCurrentFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5646, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5645, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5681, + "src": "14798:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5644, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14798:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14797:18:25" + }, + "returnParameters": { + "id": 5649, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5648, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5681, + "src": "14837:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5647, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14837:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14836:9:25" + }, + "scope": 6682, + "src": "14756:472:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 5699, + "nodeType": "Block", + "src": "15333:131:25", + "statements": [ + { + "assignments": [ + 5691 + ], + "declarations": [ + { + "constant": false, + "id": 5691, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5699, + "src": "15343:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5690, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "15343:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5695, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5692, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "15385:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5694, + "indexExpression": { + "argumentTypes": null, + "id": 5693, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5683, + "src": "15394:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "15385:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "15343:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5696, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5691, + "src": "15420:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5697, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "15420:37:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5687, + "id": 5698, + "nodeType": "Return", + "src": "15413:44:25" + } + ] + }, + "documentation": null, + "id": 5700, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveCurrentAverageFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5684, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5683, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5700, + "src": "15283:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5682, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "15283:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15282:18:25" + }, + "returnParameters": { + "id": 5687, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5686, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5700, + "src": "15324:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5685, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "15324:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15323:9:25" + }, + "scope": 6682, + "src": "15234:230:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5718, + "nodeType": "Block", + "src": "15560:122:25", + "statements": [ + { + "assignments": [ + 5710 + ], + "declarations": [ + { + "constant": false, + "id": 5710, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5718, + "src": "15570:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5709, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "15570:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5714, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5711, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "15612:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5713, + "indexExpression": { + "argumentTypes": null, + "id": 5712, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5702, + "src": "15621:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "15612:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "15570:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5715, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5710, + "src": "15647:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5716, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8289, + "src": "15647:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5706, + "id": 5717, + "nodeType": "Return", + "src": "15640:35:25" + } + ] + }, + "documentation": null, + "id": 5719, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveCurrentLiquidityRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5703, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5702, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5719, + "src": "15510:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5701, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "15510:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15509:18:25" + }, + "returnParameters": { + "id": 5706, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5705, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5719, + "src": "15551:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5704, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "15551:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15550:9:25" + }, + "scope": 6682, + "src": "15470:212:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5737, + "nodeType": "Block", + "src": "15782:130:25", + "statements": [ + { + "assignments": [ + 5729 + ], + "declarations": [ + { + "constant": false, + "id": 5729, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5737, + "src": "15792:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5728, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "15792:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5733, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5730, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "15834:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5732, + "indexExpression": { + "argumentTypes": null, + "id": 5731, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5721, + "src": "15843:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "15834:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "15792:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5734, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5729, + "src": "15869:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5735, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "15869:36:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5725, + "id": 5736, + "nodeType": "Return", + "src": "15862:43:25" + } + ] + }, + "documentation": null, + "id": 5738, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveLiquidityCumulativeIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5722, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5721, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5738, + "src": "15732:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5720, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "15732:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15731:18:25" + }, + "returnParameters": { + "id": 5725, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5724, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5738, + "src": "15773:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5723, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "15773:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15772:9:25" + }, + "scope": 6682, + "src": "15688:224:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5756, + "nodeType": "Block", + "src": "16018:135:25", + "statements": [ + { + "assignments": [ + 5748 + ], + "declarations": [ + { + "constant": false, + "id": 5748, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5756, + "src": "16028:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5747, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "16028:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5752, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5749, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "16070:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5751, + "indexExpression": { + "argumentTypes": null, + "id": 5750, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5740, + "src": "16079:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "16070:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "16028:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5753, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5748, + "src": "16105:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5754, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "16105:41:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5744, + "id": 5755, + "nodeType": "Return", + "src": "16098:48:25" + } + ] + }, + "documentation": null, + "id": 5757, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveVariableBorrowsCumulativeIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5741, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5740, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5757, + "src": "15968:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5739, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "15968:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15967:18:25" + }, + "returnParameters": { + "id": 5744, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5743, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5757, + "src": "16009:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5742, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "16009:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "16008:9:25" + }, + "scope": 6682, + "src": "15918:235:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5812, + "nodeType": "Block", + "src": "16711:423:25", + "statements": [ + { + "assignments": [ + 5777 + ], + "declarations": [ + { + "constant": false, + "id": 5777, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5812, + "src": "16721:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5776, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "16721:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5781, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5778, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "16763:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5780, + "indexExpression": { + "argumentTypes": null, + "id": 5779, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5759, + "src": "16772:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "16763:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "16721:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5785, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5782, + "name": "decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5762, + "src": "16791:8:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5783, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "16802:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5784, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 8309, + "src": "16802:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "16791:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5786, + "nodeType": "ExpressionStatement", + "src": "16791:27:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5790, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5787, + "name": "baseLTVasCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5764, + "src": "16828:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5788, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "16850:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5789, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "baseLTVasCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8303, + "src": "16850:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "16828:49:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5791, + "nodeType": "ExpressionStatement", + "src": "16828:49:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5795, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5792, + "name": "liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5766, + "src": "16887:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5793, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "16910:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5794, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 8305, + "src": "16910:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "16887:51:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5796, + "nodeType": "ExpressionStatement", + "src": "16887:51:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5800, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5797, + "name": "usageAsCollateralEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5768, + "src": "16948:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5798, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "16975:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5799, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "16975:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "16948:59:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 5801, + "nodeType": "ExpressionStatement", + "src": "16948:59:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5805, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5802, + "name": "fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5770, + "src": "17017:22:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5803, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "17042:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5804, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "isFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8321, + "src": "17042:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "17017:57:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 5806, + "nodeType": "ExpressionStatement", + "src": "17017:57:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5810, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5807, + "name": "borrowingEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5772, + "src": "17084:16:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5808, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "17103:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5809, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "17103:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "17084:43:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 5811, + "nodeType": "ExpressionStatement", + "src": "17084:43:25" + } + ] + }, + "documentation": "@dev this function aggregates the configuration parameters of the reserve.\n It's used in the LendingPoolDataProvider specifically to save gas, and avoid\n multiple external contract calls to fetch the same data.", + "id": 5813, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveConfiguration", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5760, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5759, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16446:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5758, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "16446:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "16445:18:25" + }, + "returnParameters": { + "id": 5773, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5762, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16511:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5761, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "16511:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5764, + "name": "baseLTVasCollateral", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16537:27:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5763, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "16537:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5766, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16574:28:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5765, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "16574:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5768, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16612:29:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5767, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "16612:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5770, + "name": "fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16651:27:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5769, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "16651:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5772, + "name": "borrowingEnabled", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16688:21:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5771, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "16688:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "16510:200:25" + }, + "scope": 6682, + "src": "16413:721:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5831, + "nodeType": "Block", + "src": "17222:118:25", + "statements": [ + { + "assignments": [ + 5823 + ], + "declarations": [ + { + "constant": false, + "id": 5823, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5831, + "src": "17232:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5822, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "17232:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5827, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5824, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "17274:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5826, + "indexExpression": { + "argumentTypes": null, + "id": 5825, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5815, + "src": "17283:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "17274:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17232:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5828, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5823, + "src": "17309:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5829, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "17309:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 5819, + "id": 5830, + "nodeType": "Return", + "src": "17302:31:25" + } + ] + }, + "documentation": null, + "id": 5832, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isReserveBorrowingEnabled", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5816, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5815, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5832, + "src": "17175:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5814, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "17175:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17174:18:25" + }, + "returnParameters": { + "id": 5819, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5818, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5832, + "src": "17216:4:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5817, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "17216:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17215:6:25" + }, + "scope": 6682, + "src": "17140:200:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5850, + "nodeType": "Block", + "src": "17436:126:25", + "statements": [ + { + "assignments": [ + 5842 + ], + "declarations": [ + { + "constant": false, + "id": 5842, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5850, + "src": "17446:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5841, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "17446:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5846, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5843, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "17488:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5845, + "indexExpression": { + "argumentTypes": null, + "id": 5844, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5834, + "src": "17497:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "17488:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17446:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5847, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5842, + "src": "17523:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5848, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "17523:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 5838, + "id": 5849, + "nodeType": "Return", + "src": "17516:39:25" + } + ] + }, + "documentation": null, + "id": 5851, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isReserveUsageAsCollateralEnabled", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5835, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5834, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5851, + "src": "17389:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5833, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "17389:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17388:18:25" + }, + "returnParameters": { + "id": 5838, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5837, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5851, + "src": "17430:4:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5836, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "17430:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17429:6:25" + }, + "scope": 6682, + "src": "17346:216:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5869, + "nodeType": "Block", + "src": "17659:126:25", + "statements": [ + { + "assignments": [ + 5861 + ], + "declarations": [ + { + "constant": false, + "id": 5861, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5869, + "src": "17669:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5860, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "17669:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5865, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5862, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "17711:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5864, + "indexExpression": { + "argumentTypes": null, + "id": 5863, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5853, + "src": "17720:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "17711:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17669:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5866, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5861, + "src": "17746:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5867, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "isFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8321, + "src": "17746:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 5857, + "id": 5868, + "nodeType": "Return", + "src": "17739:39:25" + } + ] + }, + "documentation": null, + "id": 5870, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveIsFixedBorrowRateEnabled", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5854, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5853, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5870, + "src": "17612:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5852, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "17612:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17611:18:25" + }, + "returnParameters": { + "id": 5857, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5856, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5870, + "src": "17653:4:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5855, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "17653:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17652:6:25" + }, + "scope": 6682, + "src": "17568:217:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5888, + "nodeType": "Block", + "src": "17865:110:25", + "statements": [ + { + "assignments": [ + 5880 + ], + "declarations": [ + { + "constant": false, + "id": 5880, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5888, + "src": "17875:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5879, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "17875:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5884, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5881, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "17917:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5883, + "indexExpression": { + "argumentTypes": null, + "id": 5882, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5872, + "src": "17926:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "17917:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17875:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5885, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5880, + "src": "17952:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5886, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "isActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 8323, + "src": "17952:16:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 5876, + "id": 5887, + "nodeType": "Return", + "src": "17945:23:25" + } + ] + }, + "documentation": null, + "id": 5889, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveIsActive", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5873, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5872, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5889, + "src": "17819:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5871, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "17819:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17818:18:25" + }, + "returnParameters": { + "id": 5876, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5875, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5889, + "src": "17859:4:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5874, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "17859:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17858:6:25" + }, + "scope": 6682, + "src": "17791:184:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5909, + "nodeType": "Block", + "src": "18071:126:25", + "statements": [ + { + "assignments": [ + 5899 + ], + "declarations": [ + { + "constant": false, + "id": 5899, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5909, + "src": "18081:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5898, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "18081:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5903, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5900, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "18123:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5902, + "indexExpression": { + "argumentTypes": null, + "id": 5901, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5891, + "src": "18132:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18123:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "18081:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5907, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5904, + "name": "timestamp", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5894, + "src": "18151:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5905, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5899, + "src": "18163:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5906, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "18163:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "src": "18151:39:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "id": 5908, + "nodeType": "ExpressionStatement", + "src": "18151:39:25" + } + ] + }, + "documentation": null, + "id": 5910, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveLastUpdate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5892, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5891, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5910, + "src": "18012:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5890, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18012:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18011:18:25" + }, + "returnParameters": { + "id": 5895, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5894, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 5910, + "src": "18053:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 5893, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "18053:6:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18052:18:25" + }, + "scope": 6682, + "src": "17982:215:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5932, + "nodeType": "Block", + "src": "18384:130:25", + "statements": [ + { + "assignments": [ + 5922 + ], + "declarations": [ + { + "constant": false, + "id": 5922, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5932, + "src": "18394:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5921, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "18394:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5928, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5923, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "18437:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5925, + "indexExpression": { + "argumentTypes": null, + "id": 5924, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5914, + "src": "18454:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18437:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5927, + "indexExpression": { + "argumentTypes": null, + "id": 5926, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5912, + "src": "18461:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18437:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "18394:76:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5929, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5922, + "src": "18487:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5930, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "useAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8282, + "src": "18487:20:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 5918, + "id": 5931, + "nodeType": "Return", + "src": "18480:27:25" + } + ] + }, + "documentation": "****************\n@dev user accessors*****************", + "id": 5933, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isUserUseReserveAsCollateralEnabled", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5915, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5912, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5933, + "src": "18322:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5911, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18322:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5914, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5933, + "src": "18340:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5913, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18340:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18321:33:25" + }, + "returnParameters": { + "id": 5918, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5917, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5933, + "src": "18378:4:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5916, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "18378:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18377:6:25" + }, + "scope": 6682, + "src": "18277:237:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5955, + "nodeType": "Block", + "src": "18615:129:25", + "statements": [ + { + "assignments": [ + 5945 + ], + "declarations": [ + { + "constant": false, + "id": 5945, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5955, + "src": "18625:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5944, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "18625:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5951, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5946, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "18668:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5948, + "indexExpression": { + "argumentTypes": null, + "id": 5947, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5937, + "src": "18685:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18668:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5950, + "indexExpression": { + "argumentTypes": null, + "id": 5949, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5935, + "src": "18692:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18668:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "18625:76:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5952, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5945, + "src": "18718:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5953, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "originationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 8276, + "src": "18718:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5941, + "id": 5954, + "nodeType": "Return", + "src": "18711:26:25" + } + ] + }, + "documentation": null, + "id": 5956, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserOriginationFee", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5938, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5935, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5956, + "src": "18550:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5934, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18550:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5937, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5956, + "src": "18568:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5936, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18568:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18549:33:25" + }, + "returnParameters": { + "id": 5941, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5940, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5956, + "src": "18606:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5939, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "18606:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18605:9:25" + }, + "scope": 6682, + "src": "18519:225:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5987, + "nodeType": "Block", + "src": "18900:211:25", + "statements": [ + { + "assignments": [ + 5968 + ], + "declarations": [ + { + "constant": false, + "id": 5968, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5987, + "src": "18910:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5967, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "18910:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5974, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5969, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "18953:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5971, + "indexExpression": { + "argumentTypes": null, + "id": 5970, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5960, + "src": "18970:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18953:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5973, + "indexExpression": { + "argumentTypes": null, + "id": 5972, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5958, + "src": "18977:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18953:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "18910:76:25" + }, + { + "expression": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 5978, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5975, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5968, + "src": "19003:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5976, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "19003:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 5977, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "19026:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "19003:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5982, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "19067:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5983, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "19067:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5984, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "VARIABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "19067:37:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "id": 5985, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "19003:101:25", + "trueExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5979, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "19030:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5980, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "19030:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5981, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "19030:34:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "functionReturnParameters": 5964, + "id": 5986, + "nodeType": "Return", + "src": "18996:108:25" + } + ] + }, + "documentation": null, + "id": 5988, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserCurrentBorrowRateMode", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5961, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5958, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5988, + "src": "18788:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5957, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18788:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5960, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5988, + "src": "18806:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5959, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18806:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18787:33:25" + }, + "returnParameters": { + "id": 5964, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5963, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5988, + "src": "18866:28:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 5962, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "18866:28:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18865:30:25" + }, + "scope": 6682, + "src": "18750:361:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 6010, + "nodeType": "Block", + "src": "19221:130:25", + "statements": [ + { + "assignments": [ + 6000 + ], + "declarations": [ + { + "constant": false, + "id": 6000, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 6010, + "src": "19231:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5999, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "19231:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6006, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6001, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "19274:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 6003, + "indexExpression": { + "argumentTypes": null, + "id": 6002, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5992, + "src": "19291:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "19274:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 6005, + "indexExpression": { + "argumentTypes": null, + "id": 6004, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5990, + "src": "19298:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "19274:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "19231:76:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6007, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6000, + "src": "19324:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 6008, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "19324:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5996, + "id": 6009, + "nodeType": "Return", + "src": "19317:27:25" + } + ] + }, + "documentation": null, + "id": 6011, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserCurrentFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5993, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5990, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6011, + "src": "19156:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5989, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "19156:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5992, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6011, + "src": "19174:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5991, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "19174:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "19155:33:25" + }, + "returnParameters": { + "id": 5996, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5995, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 6011, + "src": "19212:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5994, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "19212:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "19211:9:25" + }, + "scope": 6682, + "src": "19117:234:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6062, + "nodeType": "Block", + "src": "19597:443:25", + "statements": [ + { + "assignments": [ + 6027 + ], + "declarations": [ + { + "constant": false, + "id": 6027, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 6062, + "src": "19608:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6026, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "19608:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6033, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6028, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "19651:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 6030, + "indexExpression": { + "argumentTypes": null, + "id": 6029, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6015, + "src": "19668:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "19651:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 6032, + "indexExpression": { + "argumentTypes": null, + "id": 6031, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6013, + "src": "19675:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "19651:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "19608:76:25" + }, + { + "assignments": [ + 6037 + ], + "declarations": [ + { + "constant": false, + "id": 6037, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6062, + "src": "19694:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6036, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "19694:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6041, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6038, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "19736:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6040, + "indexExpression": { + "argumentTypes": null, + "id": 6039, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6013, + "src": "19745:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "19736:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "19694:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6045, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6042, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6018, + "src": "19765:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6043, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6027, + "src": "19790:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 6044, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "19790:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "19765:52:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6046, + "nodeType": "ExpressionStatement", + "src": "19765:52:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6053, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6047, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6020, + "src": "19827:23:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6050, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6027, + "src": "19909:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + { + "argumentTypes": null, + "id": 6051, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6037, + "src": "19931:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + }, + { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + ], + "expression": { + "argumentTypes": null, + "id": 6048, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "19853:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 6049, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getCompoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8734, + "src": "19853:38:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_UserReserveData_$8283_storage_ptr_$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$", + "typeString": "function (struct CoreLibrary.UserReserveData storage pointer,struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 6052, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19853:99:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "19827:125:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6054, + "nodeType": "ExpressionStatement", + "src": "19827:125:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6060, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6055, + "name": "compoundedAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6022, + "src": "19963:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6058, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6018, + "src": "20010:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6056, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6020, + "src": "19982:23:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6057, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "19982:27:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6059, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19982:51:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "19963:70:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6061, + "nodeType": "ExpressionStatement", + "src": "19963:70:25" + } + ] + }, + "documentation": null, + "id": 6063, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserBorrowBalances", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6016, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6013, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6063, + "src": "19397:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6012, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "19397:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6015, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6063, + "src": "19423:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6014, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "19423:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "19387:50:25" + }, + "returnParameters": { + "id": 6023, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6018, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 6063, + "src": "19482:30:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6017, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "19482:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6020, + "name": "compoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 6063, + "src": "19526:31:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6019, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "19526:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6022, + "name": "compoundedAmount", + "nodeType": "VariableDeclaration", + "scope": 6063, + "src": "19571:24:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6021, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "19571:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "19468:128:25" + }, + "scope": 6682, + "src": "19357:683:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6085, + "nodeType": "Block", + "src": "20157:148:25", + "statements": [ + { + "assignments": [ + 6075 + ], + "declarations": [ + { + "constant": false, + "id": 6075, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 6085, + "src": "20167:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6074, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "20167:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6081, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6076, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "20210:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 6078, + "indexExpression": { + "argumentTypes": null, + "id": 6077, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6067, + "src": "20227:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "20210:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 6080, + "indexExpression": { + "argumentTypes": null, + "id": 6079, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6065, + "src": "20234:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "20210:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "20167:76:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6082, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6075, + "src": "20260:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 6083, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8274, + "src": "20260:38:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 6071, + "id": 6084, + "nodeType": "Return", + "src": "20253:45:25" + } + ] + }, + "documentation": null, + "id": 6086, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserVariableBorrowCumulativeIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6068, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6065, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6086, + "src": "20092:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6064, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20092:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6067, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6086, + "src": "20110:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6066, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20110:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20091:33:25" + }, + "returnParameters": { + "id": 6071, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6070, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 6086, + "src": "20148:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6069, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "20148:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20147:9:25" + }, + "scope": 6682, + "src": "20046:259:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6110, + "nodeType": "Block", + "src": "20441:139:25", + "statements": [ + { + "assignments": [ + 6098 + ], + "declarations": [ + { + "constant": false, + "id": 6098, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 6110, + "src": "20451:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6097, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "20451:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6104, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6099, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "20494:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 6101, + "indexExpression": { + "argumentTypes": null, + "id": 6100, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6090, + "src": "20511:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "20494:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 6103, + "indexExpression": { + "argumentTypes": null, + "id": 6102, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6088, + "src": "20518:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "20494:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "20451:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6108, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6105, + "name": "timestamp", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6093, + "src": "20537:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6106, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6098, + "src": "20549:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 6107, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8280, + "src": "20549:24:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "src": "20537:36:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6109, + "nodeType": "ExpressionStatement", + "src": "20537:36:25" + } + ] + }, + "documentation": null, + "id": 6111, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserLastUpdate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6091, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6088, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6111, + "src": "20338:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6087, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20338:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6090, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6111, + "src": "20356:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6089, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20356:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20337:33:25" + }, + "returnParameters": { + "id": 6094, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6093, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 6111, + "src": "20418:17:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6092, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "20418:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20417:19:25" + }, + "scope": 6682, + "src": "20311:269:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6124, + "nodeType": "Block", + "src": "20715:70:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6118, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "20732:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6120, + "indexExpression": { + "argumentTypes": null, + "id": 6119, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6113, + "src": "20741:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "20732:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6121, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveUtilizationRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8354, + "src": "20732:44:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 6122, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20732:46:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 6117, + "id": 6123, + "nodeType": "Return", + "src": "20725:53:25" + } + ] + }, + "documentation": "@dev utility functions", + "id": 6125, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveUtilizationRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6114, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6113, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6125, + "src": "20665:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6112, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20665:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20664:18:25" + }, + "returnParameters": { + "id": 6117, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6116, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 6125, + "src": "20706:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6115, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "20706:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20705:9:25" + }, + "scope": 6682, + "src": "20630:155:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6133, + "nodeType": "Block", + "src": "20855:36:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6131, + "name": "reservesList", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4766, + "src": "20872:12:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage", + "typeString": "address[] storage ref" + } + }, + "functionReturnParameters": 6130, + "id": 6132, + "nodeType": "Return", + "src": "20865:19:25" + } + ] + }, + "documentation": null, + "id": 6134, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserves", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6126, + "nodeType": "ParameterList", + "parameters": [], + "src": "20811:2:25" + }, + "returnParameters": { + "id": 6130, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6129, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 6134, + "src": "20837:16:25", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 6127, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20837:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 6128, + "length": null, + "nodeType": "ArrayTypeName", + "src": "20837:9:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20836:18:25" + }, + "scope": 6682, + "src": "20791:100:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6150, + "nodeType": "Block", + "src": "21048:119:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6145, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6141, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "21059:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6143, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6136, + "src": "21108:18:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6142, + "name": "LendingPoolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1357, + "src": "21079:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolAddressesProvider_$1357_$", + "typeString": "type(contract LendingPoolAddressesProvider)" + } + }, + "id": 6144, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21079:48:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "21059:68:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6146, + "nodeType": "ExpressionStatement", + "src": "21059:68:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 6147, + "name": "refreshConfigInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6639, + "src": "21137:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$", + "typeString": "function ()" + } + }, + "id": 6148, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21137:23:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6149, + "nodeType": "ExpressionStatement", + "src": "21137:23:25" + } + ] + }, + "documentation": "@dev Core configuration functions", + "id": 6151, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6139, + "modifierName": { + "argumentTypes": null, + "id": 6138, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "21020:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "21020:27:25" + } + ], + "name": "setAddressesProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6137, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6136, + "name": "_addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 6151, + "src": "20982:26:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6135, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20982:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20981:29:25" + }, + "returnParameters": { + "id": 6140, + "nodeType": "ParameterList", + "parameters": [], + "src": "21048:0:25" + }, + "scope": 6682, + "src": "20952:215:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6159, + "nodeType": "Block", + "src": "21242:40:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 6156, + "name": "refreshConfigInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6639, + "src": "21252:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$", + "typeString": "function ()" + } + }, + "id": 6157, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21252:23:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6158, + "nodeType": "ExpressionStatement", + "src": "21252:23:25" + } + ] + }, + "documentation": null, + "id": 6160, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6154, + "modifierName": { + "argumentTypes": null, + "id": 6153, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "21214:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "21214:27:25" + } + ], + "name": "refreshConfiguration", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6152, + "nodeType": "ParameterList", + "parameters": [], + "src": "21202:2:25" + }, + "returnParameters": { + "id": 6155, + "nodeType": "ParameterList", + "parameters": [], + "src": "21242:0:25" + }, + "scope": 6682, + "src": "21173:109:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6186, + "nodeType": "Block", + "src": "21465:142:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6177, + "name": "_aTokenAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6164, + "src": "21499:14:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 6178, + "name": "_decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6166, + "src": "21515:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 6179, + "name": "_interestRateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6168, + "src": "21526:28:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6173, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "21475:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6175, + "indexExpression": { + "argumentTypes": null, + "id": 6174, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6162, + "src": "21484:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "21475:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6176, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "init", + "nodeType": "MemberAccess", + "referencedDeclaration": 8545, + "src": "21475:23:25", + "typeDescriptions": { + "typeIdentifier": "t_function_delegatecall_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_address_$_t_uint256_$_t_address_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,address,uint256,address)" + } + }, + "id": 6180, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21475:80:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6181, + "nodeType": "ExpressionStatement", + "src": "21475:80:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6183, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6162, + "src": "21590:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6182, + "name": "addReserveToListInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6681, + "src": "21565:24:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 6184, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21565:34:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6185, + "nodeType": "ExpressionStatement", + "src": "21565:34:25" + } + ] + }, + "documentation": null, + "id": 6187, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6171, + "modifierName": { + "argumentTypes": null, + "id": 6170, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "21433:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "21433:27:25" + } + ], + "name": "initReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6169, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6162, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6187, + "src": "21309:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6161, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21309:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6164, + "name": "_aTokenAddress", + "nodeType": "VariableDeclaration", + "scope": 6187, + "src": "21327:22:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6163, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21327:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6166, + "name": "_decimals", + "nodeType": "VariableDeclaration", + "scope": 6187, + "src": "21351:17:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6165, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "21351:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6168, + "name": "_interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 6187, + "src": "21370:36:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6167, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21370:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "21308:99:25" + }, + "returnParameters": { + "id": 6172, + "nodeType": "ParameterList", + "parameters": [], + "src": "21465:0:25" + }, + "scope": 6682, + "src": "21288:319:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6203, + "nodeType": "Block", + "src": "21745:86:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6201, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6196, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "21755:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6198, + "indexExpression": { + "argumentTypes": null, + "id": 6197, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6189, + "src": "21764:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "21755:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6199, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "interestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8313, + "src": "21755:46:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 6200, + "name": "_rateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6191, + "src": "21804:20:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "21755:69:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 6202, + "nodeType": "ExpressionStatement", + "src": "21755:69:25" + } + ] + }, + "documentation": null, + "id": 6204, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6194, + "modifierName": { + "argumentTypes": null, + "id": 6193, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "21717:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "21717:27:25" + } + ], + "name": "setReserveInterestRateStrategyAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6192, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6189, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6204, + "src": "21660:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6188, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21660:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6191, + "name": "_rateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 6204, + "src": "21678:28:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6190, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21678:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "21659:48:25" + }, + "returnParameters": { + "id": 6195, + "nodeType": "ParameterList", + "parameters": [], + "src": "21745:0:25" + }, + "scope": 6682, + "src": "21613:218:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6220, + "nodeType": "Block", + "src": "21978:76:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6217, + "name": "_fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6208, + "src": "22023:23:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6213, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "21988:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6215, + "indexExpression": { + "argumentTypes": null, + "id": 6214, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6206, + "src": "21997:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "21988:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6216, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "enableBorrowing", + "nodeType": "MemberAccess", + "referencedDeclaration": 8573, + "src": "21988:34:25", + "typeDescriptions": { + "typeIdentifier": "t_function_delegatecall_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_bool_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,bool)" + } + }, + "id": 6218, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21988:59:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6219, + "nodeType": "ExpressionStatement", + "src": "21988:59:25" + } + ] + }, + "documentation": null, + "id": 6221, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6211, + "modifierName": { + "argumentTypes": null, + "id": 6210, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "21950:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "21950:27:25" + } + ], + "name": "enableBorrowingOnReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6209, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6206, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6221, + "src": "21880:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6205, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21880:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6208, + "name": "_fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 6221, + "src": "21906:28:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 6207, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "21906:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "21870:70:25" + }, + "returnParameters": { + "id": 6212, + "nodeType": "ParameterList", + "parameters": [], + "src": "21978:0:25" + }, + "scope": 6682, + "src": "21837:217:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6234, + "nodeType": "Block", + "src": "22150:54:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6228, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "22160:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6230, + "indexExpression": { + "argumentTypes": null, + "id": 6229, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6223, + "src": "22169:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "22160:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6231, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "disableBorrowing", + "nodeType": "MemberAccess", + "referencedDeclaration": 8585, + "src": "22160:35:25", + "typeDescriptions": { + "typeIdentifier": "t_function_delegatecall_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer)" + } + }, + "id": 6232, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22160:37:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6233, + "nodeType": "ExpressionStatement", + "src": "22160:37:25" + } + ] + }, + "documentation": null, + "id": 6235, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6226, + "modifierName": { + "argumentTypes": null, + "id": 6225, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "22122:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "22122:27:25" + } + ], + "name": "disableBorrowingOnReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6224, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6223, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6235, + "src": "22095:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6222, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "22095:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "22094:18:25" + }, + "returnParameters": { + "id": 6227, + "nodeType": "ParameterList", + "parameters": [], + "src": "22150:0:25" + }, + "scope": 6682, + "src": "22060:144:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6254, + "nodeType": "Block", + "src": "22381:99:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6250, + "name": "_baseLTVasCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6239, + "src": "22429:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 6251, + "name": "_liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6241, + "src": "22451:21:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6246, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "22391:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6248, + "indexExpression": { + "argumentTypes": null, + "id": 6247, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6237, + "src": "22400:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "22391:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6249, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "enableAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8634, + "src": "22391:37:25", + "typeDescriptions": { + "typeIdentifier": "t_function_delegatecall_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 6252, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22391:82:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6253, + "nodeType": "ExpressionStatement", + "src": "22391:82:25" + } + ] + }, + "documentation": null, + "id": 6255, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6244, + "modifierName": { + "argumentTypes": null, + "id": 6243, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "22349:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "22349:27:25" + } + ], + "name": "enableReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6242, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6237, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6255, + "src": "22245:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6236, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "22245:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6239, + "name": "_baseLTVasCollateral", + "nodeType": "VariableDeclaration", + "scope": 6255, + "src": "22263:28:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6238, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "22263:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6241, + "name": "_liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 6255, + "src": "22293:29:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6240, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "22293:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "22244:79:25" + }, + "returnParameters": { + "id": 6245, + "nodeType": "ParameterList", + "parameters": [], + "src": "22381:0:25" + }, + "scope": 6682, + "src": "22210:270:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6268, + "nodeType": "Block", + "src": "22577:57:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6262, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "22587:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6264, + "indexExpression": { + "argumentTypes": null, + "id": 6263, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6257, + "src": "22596:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "22587:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6265, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "disableAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8646, + "src": "22587:38:25", + "typeDescriptions": { + "typeIdentifier": "t_function_delegatecall_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer)" + } + }, + "id": 6266, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22587:40:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6267, + "nodeType": "ExpressionStatement", + "src": "22587:40:25" + } + ] + }, + "documentation": null, + "id": 6269, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6260, + "modifierName": { + "argumentTypes": null, + "id": 6259, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "22549:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "22549:27:25" + } + ], + "name": "disableReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6258, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6257, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6269, + "src": "22522:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6256, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "22522:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "22521:18:25" + }, + "returnParameters": { + "id": 6261, + "nodeType": "ParameterList", + "parameters": [], + "src": "22577:0:25" + }, + "scope": 6682, + "src": "22486:148:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6290, + "nodeType": "Block", + "src": "22733:126:25", + "statements": [ + { + "assignments": [ + 6279 + ], + "declarations": [ + { + "constant": false, + "id": 6279, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6290, + "src": "22743:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6278, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "22743:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6283, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6280, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "22785:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6282, + "indexExpression": { + "argumentTypes": null, + "id": 6281, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6271, + "src": "22794:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "22785:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "22743:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6288, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6284, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6279, + "src": "22813:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6286, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8321, + "src": "22813:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 6287, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "22848:4:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "22813:39:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6289, + "nodeType": "ExpressionStatement", + "src": "22813:39:25" + } + ] + }, + "documentation": null, + "id": 6291, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6274, + "modifierName": { + "argumentTypes": null, + "id": 6273, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "22705:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "22705:27:25" + } + ], + "name": "enableReserveFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6272, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6271, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6291, + "src": "22678:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6270, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "22678:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "22677:18:25" + }, + "returnParameters": { + "id": 6275, + "nodeType": "ParameterList", + "parameters": [], + "src": "22733:0:25" + }, + "scope": 6682, + "src": "22640:219:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6312, + "nodeType": "Block", + "src": "22959:127:25", + "statements": [ + { + "assignments": [ + 6301 + ], + "declarations": [ + { + "constant": false, + "id": 6301, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6312, + "src": "22969:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6300, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "22969:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6305, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6302, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "23011:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6304, + "indexExpression": { + "argumentTypes": null, + "id": 6303, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6293, + "src": "23020:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "23011:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "22969:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6310, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6306, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6301, + "src": "23039:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6308, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8321, + "src": "23039:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 6309, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23074:5:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "23039:40:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6311, + "nodeType": "ExpressionStatement", + "src": "23039:40:25" + } + ] + }, + "documentation": null, + "id": 6313, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6296, + "modifierName": { + "argumentTypes": null, + "id": 6295, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "22931:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "22931:27:25" + } + ], + "name": "disableReserveFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6294, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6293, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6313, + "src": "22904:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6292, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "22904:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "22903:18:25" + }, + "returnParameters": { + "id": 6297, + "nodeType": "ParameterList", + "parameters": [], + "src": "22959:0:25" + }, + "scope": 6682, + "src": "22865:221:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6347, + "nodeType": "Block", + "src": "23172:305:25", + "statements": [ + { + "assignments": [ + 6323 + ], + "declarations": [ + { + "constant": false, + "id": 6323, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6347, + "src": "23182:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6322, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "23182:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6327, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6324, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "23224:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6326, + "indexExpression": { + "argumentTypes": null, + "id": 6325, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6315, + "src": "23233:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "23224:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "23182:60:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 6337, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6332, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6329, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6323, + "src": "23274:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6330, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "23274:36:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6331, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23313:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "23274:40:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "&&", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6336, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6333, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6323, + "src": "23330:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6334, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "23330:41:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6335, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23374:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "23330:45:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "23274:101:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5265736572766520686173206e6f74206265656e20696e697469616c697a656420796574", + "id": 6338, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23389:38:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8e3fef771b2ec0a89d942c2f01fa56a2858b26f42bd351d7e7ecb9e7b2b9bd44", + "typeString": "literal_string \"Reserve has not been initialized yet\"" + }, + "value": "Reserve has not been initialized yet" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_8e3fef771b2ec0a89d942c2f01fa56a2858b26f42bd351d7e7ecb9e7b2b9bd44", + "typeString": "literal_string \"Reserve has not been initialized yet\"" + } + ], + "id": 6328, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "23253:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6339, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23253:184:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6340, + "nodeType": "ExpressionStatement", + "src": "23253:184:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6345, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6341, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6323, + "src": "23447:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6343, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 8323, + "src": "23447:16:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 6344, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23466:4:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "23447:23:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6346, + "nodeType": "ExpressionStatement", + "src": "23447:23:25" + } + ] + }, + "documentation": null, + "id": 6348, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6318, + "modifierName": { + "argumentTypes": null, + "id": 6317, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "23144:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "23144:27:25" + } + ], + "name": "activateReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6316, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6315, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6348, + "src": "23117:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6314, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "23117:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "23116:18:25" + }, + "returnParameters": { + "id": 6319, + "nodeType": "ParameterList", + "parameters": [], + "src": "23172:0:25" + }, + "scope": 6682, + "src": "23092:385:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6369, + "nodeType": "Block", + "src": "23565:111:25", + "statements": [ + { + "assignments": [ + 6358 + ], + "declarations": [ + { + "constant": false, + "id": 6358, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6369, + "src": "23575:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6357, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "23575:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6362, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6359, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "23617:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6361, + "indexExpression": { + "argumentTypes": null, + "id": 6360, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6350, + "src": "23626:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "23617:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "23575:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6367, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6363, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6358, + "src": "23645:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6365, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 8323, + "src": "23645:16:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 6366, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23664:5:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "23645:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6368, + "nodeType": "ExpressionStatement", + "src": "23645:24:25" + } + ] + }, + "documentation": null, + "id": 6370, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6353, + "modifierName": { + "argumentTypes": null, + "id": 6352, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "23537:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "23537:27:25" + } + ], + "name": "deactivateReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6351, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6350, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6370, + "src": "23510:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6349, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "23510:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "23509:18:25" + }, + "returnParameters": { + "id": 6354, + "nodeType": "ParameterList", + "parameters": [], + "src": "23565:0:25" + }, + "scope": 6682, + "src": "23483:193:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6393, + "nodeType": "Block", + "src": "23955:121:25", + "statements": [ + { + "assignments": [ + 6382 + ], + "declarations": [ + { + "constant": false, + "id": 6382, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6393, + "src": "23965:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6381, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "23965:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6386, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6383, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "24007:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6385, + "indexExpression": { + "argumentTypes": null, + "id": 6384, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6372, + "src": "24016:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "24007:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "23965:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6391, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6387, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6382, + "src": "24035:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6389, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "baseLTVasCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8303, + "src": "24035:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 6390, + "name": "_ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6374, + "src": "24065:4:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "24035:34:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6392, + "nodeType": "ExpressionStatement", + "src": "24035:34:25" + } + ] + }, + "documentation": "*************\n@dev functions to update available collaterals\n@dev the interest rate and the ltv are expressed in percentage", + "id": 6394, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6377, + "modifierName": { + "argumentTypes": null, + "id": 6376, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "23927:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "23927:27:25" + } + ], + "name": "setReserveBaseLTVasCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6375, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6372, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6394, + "src": "23870:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6371, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "23870:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6374, + "name": "_ltv", + "nodeType": "VariableDeclaration", + "scope": 6394, + "src": "23888:12:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6373, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "23888:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "23869:32:25" + }, + "returnParameters": { + "id": 6378, + "nodeType": "ParameterList", + "parameters": [], + "src": "23955:0:25" + }, + "scope": 6682, + "src": "23831:245:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6417, + "nodeType": "Block", + "src": "24217:128:25", + "statements": [ + { + "assignments": [ + 6406 + ], + "declarations": [ + { + "constant": false, + "id": 6406, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6417, + "src": "24227:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6405, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "24227:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6410, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6407, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "24269:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6409, + "indexExpression": { + "argumentTypes": null, + "id": 6408, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6396, + "src": "24278:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "24269:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "24227:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6415, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6411, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6406, + "src": "24297:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6413, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 8305, + "src": "24297:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 6414, + "name": "_threshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6398, + "src": "24328:10:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "24297:41:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6416, + "nodeType": "ExpressionStatement", + "src": "24297:41:25" + } + ] + }, + "documentation": null, + "id": 6418, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6401, + "modifierName": { + "argumentTypes": null, + "id": 6400, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "24185:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "24185:27:25" + } + ], + "name": "setReserveLiquidationThreshold", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6399, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6396, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6418, + "src": "24122:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6395, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24122:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6398, + "name": "_threshold", + "nodeType": "VariableDeclaration", + "scope": 6418, + "src": "24140:18:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6397, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "24140:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "24121:38:25" + }, + "returnParameters": { + "id": 6402, + "nodeType": "ParameterList", + "parameters": [], + "src": "24217:0:25" + }, + "scope": 6682, + "src": "24082:263:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6441, + "nodeType": "Block", + "src": "24484:126:25", + "statements": [ + { + "assignments": [ + 6430 + ], + "declarations": [ + { + "constant": false, + "id": 6430, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6441, + "src": "24494:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6429, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "24494:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6434, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6431, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "24536:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6433, + "indexExpression": { + "argumentTypes": null, + "id": 6432, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6420, + "src": "24545:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "24536:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "24494:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6439, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6435, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6430, + "src": "24564:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6437, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 8307, + "src": "24564:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 6438, + "name": "_discount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6422, + "src": "24594:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "24564:39:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6440, + "nodeType": "ExpressionStatement", + "src": "24564:39:25" + } + ] + }, + "documentation": null, + "id": 6442, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6425, + "modifierName": { + "argumentTypes": null, + "id": 6424, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "24452:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "24452:27:25" + } + ], + "name": "setReserveLiquidationDiscount", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6423, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6420, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6442, + "src": "24390:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6419, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24390:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6422, + "name": "_discount", + "nodeType": "VariableDeclaration", + "scope": 6442, + "src": "24408:17:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6421, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "24408:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "24389:37:25" + }, + "returnParameters": { + "id": 6426, + "nodeType": "ParameterList", + "parameters": [], + "src": "24484:0:25" + }, + "scope": 6682, + "src": "24351:259:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6453, + "nodeType": "Block", + "src": "24701:158:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6446, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "24769:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6447, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "24769:10:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 6448, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isContract", + "nodeType": "MemberAccess", + "referencedDeclaration": 12033, + "src": "24769:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$bound_to$_t_address_$", + "typeString": "function (address) view returns (bool)" + } + }, + "id": 6449, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24769:23:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "4f6e6c7920636f6e7472616374732063616e2073656e6420657468657220746f20746865204c656e64696e6720706f6f6c20636f7265", + "id": 6450, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "24794:56:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3fd12f4b5399ab92a8b412386ed256004469c08240f717e3bc9c0c1108d4c226", + "typeString": "literal_string \"Only contracts can send ether to the Lending pool core\"" + }, + "value": "Only contracts can send ether to the Lending pool core" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_3fd12f4b5399ab92a8b412386ed256004469c08240f717e3bc9c0c1108d4c226", + "typeString": "literal_string \"Only contracts can send ether to the Lending pool core\"" + } + ], + "id": 6445, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "24761:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6451, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24761:90:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6452, + "nodeType": "ExpressionStatement", + "src": "24761:90:25" + } + ] + }, + "documentation": "@notice ETH/token transfer functions", + "id": 6454, + "implemented": true, + "kind": "fallback", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6443, + "nodeType": "ParameterList", + "parameters": [], + "src": "24681:2:25" + }, + "returnParameters": { + "id": 6444, + "nodeType": "ParameterList", + "parameters": [], + "src": "24701:0:25" + }, + "scope": 6682, + "src": "24673:186:25", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6485, + "nodeType": "Block", + "src": "24972:179:25", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 6467, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6465, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6456, + "src": "24986:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 6466, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4690, + "src": "24998:15:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "24986:27:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 6483, + "nodeType": "Block", + "src": "25097:48:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6480, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6460, + "src": "25126:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6477, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6458, + "src": "25111:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 6479, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "25111:14:25", + "typeDescriptions": { + "typeIdentifier": "t_function_transfer_nonpayable$_t_uint256_$returns$__$", + "typeString": "function (uint256)" + } + }, + "id": 6481, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25111:23:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6482, + "nodeType": "ExpressionStatement", + "src": "25111:23:25" + } + ] + }, + "id": 6484, + "nodeType": "IfStatement", + "src": "24982:163:25", + "trueBody": { + "id": 6476, + "nodeType": "Block", + "src": "25014:69:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6472, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6458, + "src": "25057:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 6473, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6460, + "src": "25064:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6469, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6456, + "src": "25034:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6468, + "name": "ERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11659, + "src": "25028:5:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ERC20_$11659_$", + "typeString": "type(contract ERC20)" + } + }, + "id": 6470, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25028:15:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + }, + "id": 6471, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "safeTransfer", + "nodeType": "MemberAccess", + "referencedDeclaration": 11819, + "src": "25028:28:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$11786_$", + "typeString": "function (contract IERC20,address,uint256)" + } + }, + "id": 6474, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25028:44:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6475, + "nodeType": "ExpressionStatement", + "src": "25028:44:25" + } + ] + } + } + ] + }, + "documentation": null, + "id": 6486, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6463, + "modifierName": { + "argumentTypes": null, + "id": 6462, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "24956:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "24956:15:25" + } + ], + "name": "transferToUser", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6461, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6456, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6486, + "src": "24889:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6455, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24889:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6458, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6486, + "src": "24907:21:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 6457, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24907:15:25", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6460, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 6486, + "src": "24930:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6459, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "24930:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "24888:58:25" + }, + "returnParameters": { + "id": 6464, + "nodeType": "ParameterList", + "parameters": [], + "src": "24972:0:25" + }, + "scope": 6682, + "src": "24865:286:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6536, + "nodeType": "Block", + "src": "25327:388:25", + "statements": [ + { + "assignments": [ + 6500 + ], + "declarations": [ + { + "constant": false, + "id": 6500, + "name": "feeAddress", + "nodeType": "VariableDeclaration", + "scope": 6536, + "src": "25337:26:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 6499, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25337:15:25", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6506, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6503, + "name": "destination", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6494, + "src": "25382:11:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6502, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "25374:7:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint160_$", + "typeString": "type(uint160)" + }, + "typeName": "uint160" + }, + "id": 6504, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25374:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + ], + "id": 6501, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "25366:7:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 6505, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25366:29:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "25337:58:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 6509, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6507, + "name": "_token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6488, + "src": "25440:6:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 6508, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4690, + "src": "25450:15:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "25440:25:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 6534, + "nodeType": "Block", + "src": "25556:153:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6524, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6521, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "25578:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6522, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "25578:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 6523, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6492, + "src": "25591:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "25578:20:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520616d6f756e7420616e64207468652076616c75652073656e7420746f206465706f73697420646f206e6f74206d61746368", + "id": 6525, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "25600:55:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3ae30f23ff7837445ce2686dd35a110a057a45b669d9773b552977a0705cedbe", + "typeString": "literal_string \"The amount and the value sent to deposit do not match\"" + }, + "value": "The amount and the value sent to deposit do not match" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_3ae30f23ff7837445ce2686dd35a110a057a45b669d9773b552977a0705cedbe", + "typeString": "literal_string \"The amount and the value sent to deposit do not match\"" + } + ], + "id": 6520, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "25570:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6526, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25570:86:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6527, + "nodeType": "ExpressionStatement", + "src": "25570:86:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6531, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6492, + "src": "25690:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6528, + "name": "feeAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6500, + "src": "25670:10:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 6530, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "25670:19:25", + "typeDescriptions": { + "typeIdentifier": "t_function_transfer_nonpayable$_t_uint256_$returns$__$", + "typeString": "function (uint256)" + } + }, + "id": 6532, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25670:28:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6533, + "nodeType": "ExpressionStatement", + "src": "25670:28:25" + } + ] + }, + "id": 6535, + "nodeType": "IfStatement", + "src": "25436:273:25", + "trueBody": { + "id": 6519, + "nodeType": "Block", + "src": "25467:83:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6514, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6490, + "src": "25512:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 6515, + "name": "feeAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6500, + "src": "25519:10:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 6516, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6492, + "src": "25531:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6511, + "name": "_token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6488, + "src": "25487:6:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6510, + "name": "ERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11659, + "src": "25481:5:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ERC20_$11659_$", + "typeString": "type(contract ERC20)" + } + }, + "id": 6512, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25481:13:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + }, + "id": 6513, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "safeTransferFrom", + "nodeType": "MemberAccess", + "referencedDeclaration": 11844, + "src": "25481:30:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_address_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$11786_$", + "typeString": "function (contract IERC20,address,address,uint256)" + } + }, + "id": 6517, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25481:58:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6518, + "nodeType": "ExpressionStatement", + "src": "25481:58:25" + } + ] + } + } + ] + }, + "documentation": null, + "id": 6537, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6497, + "modifierName": { + "argumentTypes": null, + "id": 6496, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "25307:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "25307:15:25" + } + ], + "name": "transferToFeeCollectionAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6495, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6488, + "name": "_token", + "nodeType": "VariableDeclaration", + "scope": 6537, + "src": "25197:14:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6487, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25197:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6490, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6537, + "src": "25213:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6489, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25213:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6492, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 6537, + "src": "25228:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6491, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "25228:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6494, + "name": "destination", + "nodeType": "VariableDeclaration", + "scope": 6537, + "src": "25245:19:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6493, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25245:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "25196:69:25" + }, + "returnParameters": { + "id": 6498, + "nodeType": "ParameterList", + "parameters": [], + "src": "25327:0:25" + }, + "scope": 6682, + "src": "25157:558:25", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6618, + "nodeType": "Block", + "src": "25839:828:25", + "statements": [ + { + "assignments": [ + 6551 + ], + "declarations": [ + { + "constant": false, + "id": 6551, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6618, + "src": "25849:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6550, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "25849:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6555, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6552, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "25891:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6554, + "indexExpression": { + "argumentTypes": null, + "id": 6553, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6539, + "src": "25900:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "25891:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "25849:60:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 6561, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6557, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6551, + "src": "25941:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6558, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "25941:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6559, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6551, + "src": "25977:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6560, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "25977:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "25941:60:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520726573657276652069736e277420656e61626c656420666f7220626f72726f77696e67206f7220617320636f6c6c61746572616c", + "id": 6562, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26015:58:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_f17de541cec0bac47729f6ac1d107dfd1ea17a9f83c5ec26ca583eeaf6f392be", + "typeString": "literal_string \"The reserve isn't enabled for borrowing or as collateral\"" + }, + "value": "The reserve isn't enabled for borrowing or as collateral" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_f17de541cec0bac47729f6ac1d107dfd1ea17a9f83c5ec26ca583eeaf6f392be", + "typeString": "literal_string \"The reserve isn't enabled for borrowing or as collateral\"" + } + ], + "id": 6556, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "25920:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6563, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25920:163:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6564, + "nodeType": "ExpressionStatement", + "src": "25920:163:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 6567, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6565, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6539, + "src": "26098:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 6566, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4690, + "src": "26110:15:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "26098:27:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 6616, + "nodeType": "Block", + "src": "26365:296:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6592, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6589, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "26387:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6590, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "26387:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 6591, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6543, + "src": "26400:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "26387:20:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520616d6f756e7420616e64207468652076616c75652073656e7420746f206465706f73697420646f206e6f74206d61746368", + "id": 6593, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26409:55:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3ae30f23ff7837445ce2686dd35a110a057a45b669d9773b552977a0705cedbe", + "typeString": "literal_string \"The amount and the value sent to deposit do not match\"" + }, + "value": "The amount and the value sent to deposit do not match" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_3ae30f23ff7837445ce2686dd35a110a057a45b669d9773b552977a0705cedbe", + "typeString": "literal_string \"The amount and the value sent to deposit do not match\"" + } + ], + "id": 6588, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "26379:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6594, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26379:86:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6595, + "nodeType": "ExpressionStatement", + "src": "26379:86:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6599, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6596, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "26483:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6597, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "26483:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 6598, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6543, + "src": "26495:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "26483:19:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6615, + "nodeType": "IfStatement", + "src": "26480:171:25", + "trueBody": { + "id": 6614, + "nodeType": "Block", + "src": "26504:147:25", + "statements": [ + { + "assignments": [ + 6601 + ], + "declarations": [ + { + "constant": false, + "id": 6601, + "name": "excessAmount", + "nodeType": "VariableDeclaration", + "scope": 6614, + "src": "26545:20:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6600, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "26545:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6607, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6605, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6543, + "src": "26582:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6602, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "26568:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6603, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "26568:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6604, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "26568:13:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6606, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26568:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "26545:45:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6611, + "name": "excessAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6601, + "src": "26623:12:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6608, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6541, + "src": "26608:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 6610, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "26608:14:25", + "typeDescriptions": { + "typeIdentifier": "t_function_transfer_nonpayable$_t_uint256_$returns$__$", + "typeString": "function (uint256)" + } + }, + "id": 6612, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26608:28:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6613, + "nodeType": "ExpressionStatement", + "src": "26608:28:25" + } + ] + } + } + ] + }, + "id": 6617, + "nodeType": "IfStatement", + "src": "26094:567:25", + "trueBody": { + "id": 6587, + "nodeType": "Block", + "src": "26126:225:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6572, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6569, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "26148:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6570, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "26148:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6571, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26161:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "26148:14:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "557365722069732073656e64696e672045544820616c6f6e67207769746820746865204552433230207472616e736665722e20436865636b207468652076616c756520617474726962757465206f6620746865207472616e73616374696f6e", + "id": 6573, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26164:97:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_654c972fc326fcc5abc552221a5fd44bbee538da2cd9225ba1a47bbe69da9e08", + "typeString": "literal_string \"User is sending ETH along with the ERC20 transfer. Check the value attribute of the transaction\"" + }, + "value": "User is sending ETH along with the ERC20 transfer. Check the value attribute of the transaction" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_654c972fc326fcc5abc552221a5fd44bbee538da2cd9225ba1a47bbe69da9e08", + "typeString": "literal_string \"User is sending ETH along with the ERC20 transfer. Check the value attribute of the transaction\"" + } + ], + "id": 6568, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "26140:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6574, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26140:122:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6575, + "nodeType": "ExpressionStatement", + "src": "26140:122:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6580, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6541, + "src": "26309:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6582, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12212, + "src": "26324:4:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + ], + "id": 6581, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "26316:7:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 6583, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26316:13:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 6584, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6543, + "src": "26331:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6577, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6539, + "src": "26282:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6576, + "name": "ERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11659, + "src": "26276:5:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ERC20_$11659_$", + "typeString": "type(contract ERC20)" + } + }, + "id": 6578, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26276:15:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + }, + "id": 6579, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "safeTransferFrom", + "nodeType": "MemberAccess", + "referencedDeclaration": 11844, + "src": "26276:32:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_address_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$11786_$", + "typeString": "function (contract IERC20,address,address,uint256)" + } + }, + "id": 6585, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26276:63:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6586, + "nodeType": "ExpressionStatement", + "src": "26276:63:25" + } + ] + } + } + ] + }, + "documentation": null, + "id": 6619, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6546, + "modifierName": { + "argumentTypes": null, + "id": 6545, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "25823:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "25823:15:25" + } + ], + "name": "transferToReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6544, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6539, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6619, + "src": "25748:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6538, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25748:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6541, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6619, + "src": "25766:21:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 6540, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25766:15:25", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6543, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 6619, + "src": "25789:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6542, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "25789:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "25747:58:25" + }, + "returnParameters": { + "id": 6547, + "nodeType": "ParameterList", + "parameters": [], + "src": "25839:0:25" + }, + "scope": 6682, + "src": "25721:946:25", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6638, + "nodeType": "Block", + "src": "26764:194:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6630, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6622, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4690, + "src": "26775:15:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 6624, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "26818:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6625, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1216, + "src": "26818:44:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 6626, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26818:46:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6623, + "name": "INetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1932, + "src": "26793:24:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_INetworkMetadataProvider_$1932_$", + "typeString": "type(contract INetworkMetadataProvider)" + } + }, + "id": 6627, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26793:72:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 6628, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1926, + "src": "26793:91:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 6629, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26793:93:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "26775:111:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 6631, + "nodeType": "ExpressionStatement", + "src": "26775:111:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6636, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6632, + "name": "lendingPoolAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4692, + "src": "26896:18:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 6633, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "26917:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6634, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPool", + "nodeType": "MemberAccess", + "referencedDeclaration": 1058, + "src": "26917:32:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 6635, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26917:34:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "26896:55:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 6637, + "nodeType": "ExpressionStatement", + "src": "26896:55:25" + } + ] + }, + "documentation": "@notice internal functions", + "id": 6639, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "refreshConfigInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6620, + "nodeType": "ParameterList", + "parameters": [], + "src": "26752:2:25" + }, + "returnParameters": { + "id": 6621, + "nodeType": "ParameterList", + "parameters": [], + "src": "26764:0:25" + }, + "scope": 6682, + "src": "26722:236:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 6680, + "nodeType": "Block", + "src": "27025:275:25", + "statements": [ + { + "assignments": [ + 6645 + ], + "declarations": [ + { + "constant": false, + "id": 6645, + "name": "reserveAlreadyAdded", + "nodeType": "VariableDeclaration", + "scope": 6680, + "src": "27035:24:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 6644, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "27035:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6647, + "initialValue": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 6646, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "27062:5:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "nodeType": "VariableDeclarationStatement", + "src": "27035:32:25" + }, + { + "body": { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 6663, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6659, + "name": "reservesList", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4766, + "src": "27143:12:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage", + "typeString": "address[] storage ref" + } + }, + "id": 6661, + "indexExpression": { + "argumentTypes": null, + "id": 6660, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6649, + "src": "27156:1:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "27143:15:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 6662, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6641, + "src": "27162:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "27143:27:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6669, + "nodeType": "IfStatement", + "src": "27139:92:25", + "trueBody": { + "id": 6668, + "nodeType": "Block", + "src": "27172:59:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6666, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6664, + "name": "reserveAlreadyAdded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6645, + "src": "27190:19:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 6665, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "27212:4:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "27190:26:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6667, + "nodeType": "ExpressionStatement", + "src": "27190:26:25" + } + ] + } + }, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6655, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6652, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6649, + "src": "27097:1:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6653, + "name": "reservesList", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4766, + "src": "27101:12:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage", + "typeString": "address[] storage ref" + } + }, + "id": 6654, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "length", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "27101:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "27097:23:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6670, + "initializationExpression": { + "assignments": [ + 6649 + ], + "declarations": [ + { + "constant": false, + "id": 6649, + "name": "i", + "nodeType": "VariableDeclaration", + "scope": 6670, + "src": "27082:9:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6648, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "27082:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6651, + "initialValue": { + "argumentTypes": null, + "hexValue": "30", + "id": 6650, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "27094:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "nodeType": "VariableDeclarationStatement", + "src": "27082:13:25" + }, + "loopExpression": { + "expression": { + "argumentTypes": null, + "id": 6657, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "++", + "prefix": false, + "src": "27122:3:25", + "subExpression": { + "argumentTypes": null, + "id": 6656, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6649, + "src": "27122:1:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6658, + "nodeType": "ExpressionStatement", + "src": "27122:3:25" + }, + "nodeType": "ForStatement", + "src": "27077:154:25" + }, + { + "condition": { + "argumentTypes": null, + "id": 6672, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "27244:20:25", + "subExpression": { + "argumentTypes": null, + "id": 6671, + "name": "reserveAlreadyAdded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6645, + "src": "27245:19:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6679, + "nodeType": "IfStatement", + "src": "27240:53:25", + "trueBody": { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6676, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6641, + "src": "27284:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6673, + "name": "reservesList", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4766, + "src": "27266:12:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage", + "typeString": "address[] storage ref" + } + }, + "id": 6675, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "push", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "27266:17:25", + "typeDescriptions": { + "typeIdentifier": "t_function_arraypush_nonpayable$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) returns (uint256)" + } + }, + "id": 6677, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27266:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6678, + "nodeType": "ExpressionStatement", + "src": "27266:27:25" + } + } + ] + }, + "documentation": null, + "id": 6681, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "addReserveToListInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6642, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6641, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6681, + "src": "26998:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6640, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "26998:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "26997:18:25" + }, + "returnParameters": { + "id": 6643, + "nodeType": "ParameterList", + "parameters": [], + "src": "27025:0:25" + }, + "scope": 6682, + "src": "26964:336:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 6683, + "src": "973:26330:25" + } + ], + "src": "0:27304:25" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "exportedSymbols": { + "LendingPoolCore": [ + 6682 + ] + }, + "id": 6683, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 4659, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:25" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "id": 4660, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 11255, + "src": "25:63:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 4661, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 11141, + "src": "89:59:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "id": 4662, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 12007, + "src": "149:67:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "id": 4663, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 11660, + "src": "217:63:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "file": "openzeppelin-solidity/contracts/utils/Address.sol", + "id": 4664, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 12082, + "src": "281:59:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "file": "../libraries/CoreLibrary.sol", + "id": 4665, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 8995, + "src": "341:38:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 4666, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 1358, + "src": "380:59:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol", + "file": "../interfaces/IPriceOracle.sol", + "id": 4667, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 1960, + "src": "440:40:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol", + "file": "../interfaces/ILendingRateOracle.sol", + "id": 4668, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 1910, + "src": "481:46:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol", + "file": "../interfaces/IReserveInterestRateStrategy.sol", + "id": 4669, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 1987, + "src": "528:56:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "file": "../interfaces/INetworkMetadataProvider.sol", + "id": 4670, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 1933, + "src": "585:52:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 4671, + "nodeType": "ImportDirective", + "scope": 6683, + "sourceUnit": 9175, + "src": "638:37:25", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 4672, + "name": "Ownable", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11254, + "src": "1001:7:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Ownable_$11254", + "typeString": "contract Ownable" + } + }, + "id": 4673, + "nodeType": "InheritanceSpecifier", + "src": "1001:7:25" + } + ], + "contractDependencies": [ + 10953, + 11254 + ], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title LendingPoolCore contract\n@author Aave\n@notice Contains all the data and the funds deposited into a lending pool************************************************************************************", + "fullyImplemented": true, + "id": 6682, + "linearizedBaseContracts": [ + 6682, + 11254, + 10953 + ], + "name": "LendingPoolCore", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 4676, + "libraryName": { + "contractScope": null, + "id": 4674, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "1022:8:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1016:27:25", + "typeName": { + "id": 4675, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1035:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 4679, + "libraryName": { + "contractScope": null, + "id": 4677, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "1054:10:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1048:29:25", + "typeName": { + "id": 4678, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1069:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 4682, + "libraryName": { + "contractScope": null, + "id": 4680, + "name": "CoreLibrary", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8994, + "src": "1088:11:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_CoreLibrary_$8994", + "typeString": "library CoreLibrary" + } + }, + "nodeType": "UsingForDirective", + "src": "1082:46:25", + "typeName": { + "contractScope": null, + "id": 4681, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "1104:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + } + }, + { + "id": 4685, + "libraryName": { + "contractScope": null, + "id": 4683, + "name": "SafeERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12006, + "src": "1139:9:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + }, + "nodeType": "UsingForDirective", + "src": "1133:26:25", + "typeName": { + "contractScope": null, + "id": 4684, + "name": "ERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11659, + "src": "1153:5:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + } + }, + { + "id": 4688, + "libraryName": { + "contractScope": null, + "id": 4686, + "name": "Address", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12081, + "src": "1170:7:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + }, + "nodeType": "UsingForDirective", + "src": "1164:34:25", + "typeName": { + "id": 4687, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1182:15:25", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + }, + { + "constant": false, + "id": 4690, + "name": "ethereumAddress", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "1313:23:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4689, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1313:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4692, + "name": "lendingPoolAddress", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "1343:26:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4691, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1343:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4694, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "1377:53:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 4693, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1377:28:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "public" + }, + { + "body": { + "id": 4705, + "nodeType": "Block", + "src": "1550:115:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 4700, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 4697, + "name": "lendingPoolAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4692, + "src": "1568:18:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4698, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "1590:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 4699, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1590:10:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "1568:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c20636f6e7472616374", + "id": 4701, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1602:44:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a630c1f6937c43653bd3cbe824a9088f40dc120875fe6c5545d9a34152a6c2c1", + "typeString": "literal_string \"The caller must be a lending pool contract\"" + }, + "value": "The caller must be a lending pool contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_a630c1f6937c43653bd3cbe824a9088f40dc120875fe6c5545d9a34152a6c2c1", + "typeString": "literal_string \"The caller must be a lending pool contract\"" + } + ], + "id": 4696, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1560:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4702, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1560:87:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4703, + "nodeType": "ExpressionStatement", + "src": "1560:87:25" + }, + { + "id": 4704, + "nodeType": "PlaceholderStatement", + "src": "1657:1:25" + } + ] + }, + "documentation": "@dev only lending pools can use functions affected by this modifier", + "id": 4706, + "name": "onlyLendingPool", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 4695, + "nodeType": "ParameterList", + "parameters": [], + "src": "1550:0:25" + }, + "src": "1525:140:25", + "visibility": "internal" + }, + { + "body": { + "id": 4719, + "nodeType": "Block", + "src": "1809:190:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 4714, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4709, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "1840:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4710, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolConfigurator", + "nodeType": "MemberAccess", + "referencedDeclaration": 1141, + "src": "1840:44:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 4711, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1840:46:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4712, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "1890:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 4713, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1890:10:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "1840:60:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5468652063616c6c6572206d7573742062652061206c656e64696e6720706f6f6c20636f6e666967757261746f7220636f6e7472616374", + "id": 4715, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1914:57:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8c7f0d16bf0dd67d21ca9dc67d55c2a427e32bd5c515428d66032bf648ff5ae2", + "typeString": "literal_string \"The caller must be a lending pool configurator contract\"" + }, + "value": "The caller must be a lending pool configurator contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_8c7f0d16bf0dd67d21ca9dc67d55c2a427e32bd5c515428d66032bf648ff5ae2", + "typeString": "literal_string \"The caller must be a lending pool configurator contract\"" + } + ], + "id": 4708, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1819:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4716, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1819:162:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4717, + "nodeType": "ExpressionStatement", + "src": "1819:162:25" + }, + { + "id": 4718, + "nodeType": "PlaceholderStatement", + "src": "1991:1:25" + } + ] + }, + "documentation": "@dev only lending pools configurator can use functions affected by this modifier", + "id": 4720, + "name": "onlyLendingPoolConfigurator", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 4707, + "nodeType": "ParameterList", + "parameters": [], + "src": "1809:0:25" + }, + "src": "1772:227:25", + "visibility": "internal" + }, + { + "body": { + "id": 4738, + "nodeType": "Block", + "src": "2214:225:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 4733, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4725, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "2245:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4727, + "indexExpression": { + "argumentTypes": null, + "id": 4726, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4722, + "src": "2254:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2245:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4728, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "2245:35:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4729, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "2284:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4731, + "indexExpression": { + "argumentTypes": null, + "id": 4730, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4722, + "src": "2293:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2284:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4732, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "2284:43:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "2245:82:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "52657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e67206f7220666f72206265696e67207573656420617320636f6c6c61746572616c", + "id": 4734, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2341:70:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_9a45699ae27cf613d2e94f669de055bca9fb1bb85c238d47e03d344368cacf25", + "typeString": "literal_string \"Reserve is not enabled for borrowing or for being used as collateral\"" + }, + "value": "Reserve is not enabled for borrowing or for being used as collateral" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_9a45699ae27cf613d2e94f669de055bca9fb1bb85c238d47e03d344368cacf25", + "typeString": "literal_string \"Reserve is not enabled for borrowing or for being used as collateral\"" + } + ], + "id": 4724, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2224:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4735, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2224:197:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4736, + "nodeType": "ExpressionStatement", + "src": "2224:197:25" + }, + { + "id": 4737, + "nodeType": "PlaceholderStatement", + "src": "2431:1:25" + } + ] + }, + "documentation": "@dev functions affected by this modifier can only be invoked if a reserve is enabled for borrowing and/or collateral", + "id": 4739, + "name": "onlyReserveWithEnabledBorrowingOrCollateral", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 4723, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4722, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4739, + "src": "2196:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4721, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2196:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2195:18:25" + }, + "src": "2143:296:25", + "visibility": "internal" + }, + { + "body": { + "id": 4752, + "nodeType": "Block", + "src": "2623:112:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4744, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "2641:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4746, + "indexExpression": { + "argumentTypes": null, + "id": 4745, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4741, + "src": "2650:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2641:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4747, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "2641:35:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "52657365727665206973206e6f7420656e61626c656420666f7220626f72726f77696e67", + "id": 4748, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2678:38:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + }, + "value": "Reserve is not enabled for borrowing" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_38d2b93e5fe593cec5b64807b5cb409947def87c8c49ab300392286be98b3d22", + "typeString": "literal_string \"Reserve is not enabled for borrowing\"" + } + ], + "id": 4743, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2633:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 4749, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2633:84:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4750, + "nodeType": "ExpressionStatement", + "src": "2633:84:25" + }, + { + "id": 4751, + "nodeType": "PlaceholderStatement", + "src": "2727:1:25" + } + ] + }, + "documentation": "@dev functions affected by this modifier can only be invoked if a reserve is enabled for borrowing", + "id": 4753, + "name": "onlyReserveWithEnabledBorrowing", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 4742, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4741, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4753, + "src": "2605:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4740, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2605:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2604:18:25" + }, + "src": "2564:171:25", + "visibility": "internal" + }, + { + "constant": false, + "id": 4757, + "name": "reserves", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "2741:52:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData)" + }, + "typeName": { + "id": 4756, + "keyType": { + "id": 4754, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2749:7:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "2741:43:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData)" + }, + "valueType": { + "contractScope": null, + "id": 4755, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "2760:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4763, + "name": "usersReserveData", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "2799:84:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData))" + }, + "typeName": { + "id": 4762, + "keyType": { + "id": 4758, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2807:7:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "2799:67:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData))" + }, + "valueType": { + "id": 4761, + "keyType": { + "id": 4759, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2826:7:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "2818:47:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData)" + }, + "valueType": { + "contractScope": null, + "id": 4760, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "2837:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + } + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4766, + "name": "reservesList", + "nodeType": "VariableDeclaration", + "scope": 6682, + "src": "2894:29:25", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 4764, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2894:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 4765, + "length": null, + "nodeType": "ArrayTypeName", + "src": "2894:9:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "public" + }, + { + "body": { + "id": 4778, + "nodeType": "Block", + "src": "2998:88:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 4773, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 4771, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "3008:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 4772, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4768, + "src": "3028:18:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "3008:38:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 4774, + "nodeType": "ExpressionStatement", + "src": "3008:38:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 4775, + "name": "refreshConfigInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6639, + "src": "3056:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$", + "typeString": "function ()" + } + }, + "id": 4776, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3056:23:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4777, + "nodeType": "ExpressionStatement", + "src": "3056:23:25" + } + ] + }, + "documentation": null, + "id": 4779, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4769, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4768, + "name": "_addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 4779, + "src": "2942:47:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 4767, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "2942:28:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2941:49:25" + }, + "returnParameters": { + "id": 4770, + "nodeType": "ParameterList", + "parameters": [], + "src": "2998:0:25" + }, + "scope": 6682, + "src": "2930:156:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 4792, + "nodeType": "Block", + "src": "3423:61:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4786, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "3433:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4788, + "indexExpression": { + "argumentTypes": null, + "id": 4787, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4781, + "src": "3442:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "3433:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4789, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "updateCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 8432, + "src": "3433:42:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer)" + } + }, + "id": 4790, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3433:44:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4791, + "nodeType": "ExpressionStatement", + "src": "3433:44:25" + } + ] + }, + "documentation": "@notice Updates the reserve Liquidity cumulative interest Ci and the Variable borrows cumulative index Bvc. Please refer to the\nwhitepaper for further information.", + "id": 4793, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4784, + "modifierName": { + "argumentTypes": null, + "id": 4783, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "3407:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "3407:15:25" + } + ], + "name": "updateReserveCumulativeIndexes", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4782, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4781, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4793, + "src": "3380:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4780, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3380:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3379:18:25" + }, + "returnParameters": { + "id": 4785, + "nodeType": "ParameterList", + "parameters": [], + "src": "3423:0:25" + }, + "scope": 6682, + "src": "3340:144:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4809, + "nodeType": "Block", + "src": "3798:69:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4806, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4797, + "src": "3852:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4802, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "3808:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4804, + "indexExpression": { + "argumentTypes": null, + "id": 4803, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4795, + "src": "3817:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "3808:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4805, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "cumulateToLiquidityIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8471, + "src": "3808:43:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 4807, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3808:52:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4808, + "nodeType": "ExpressionStatement", + "src": "3808:52:25" + } + ] + }, + "documentation": "@notice cumulates a fixed amount of liquidity to the reserve, considered as a specific interest accrued in one block. Please refer\nto the whitepaper for further information.", + "id": 4810, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4800, + "modifierName": { + "argumentTypes": null, + "id": 4799, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "3782:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "3782:15:25" + } + ], + "name": "cumulateLiquidityToReserveLiquidityIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4798, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4795, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4810, + "src": "3738:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4794, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "3738:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4797, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4810, + "src": "3756:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4796, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3756:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3737:35:25" + }, + "returnParameters": { + "id": 4801, + "nodeType": "ParameterList", + "parameters": [], + "src": "3798:0:25" + }, + "scope": 6682, + "src": "3688:179:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4851, + "nodeType": "Block", + "src": "4162:522:25", + "statements": [ + { + "assignments": [ + 4820 + ], + "declarations": [ + { + "constant": false, + "id": 4820, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 4851, + "src": "4173:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 4819, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "4173:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4824, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4821, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "4215:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4823, + "indexExpression": { + "argumentTypes": null, + "id": 4822, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4812, + "src": "4224:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "4215:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4173:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 4849, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4825, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4244:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4827, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8289, + "src": "4244:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4828, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4282:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4829, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8297, + "src": "4282:30:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4830, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4322:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4831, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8295, + "src": "4322:33:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 4832, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "4243:113:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4838, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4812, + "src": "4474:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 4839, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4496:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4840, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveUtilizationRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8354, + "src": "4496:33:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 4841, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4496:35:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4842, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4545:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4843, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "4545:25:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4844, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4584:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4845, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "4584:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4846, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4626:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4847, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "4626:37:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4834, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4820, + "src": "4388:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4835, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "interestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8313, + "src": "4388:35:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 4833, + "name": "IReserveInterestRateStrategy", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1986, + "src": "4359:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IReserveInterestRateStrategy_$1986_$", + "typeString": "type(contract IReserveInterestRateStrategy)" + } + }, + "id": 4836, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4359:65:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IReserveInterestRateStrategy_$1986", + "typeString": "contract IReserveInterestRateStrategy" + } + }, + "id": 4837, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "calculateInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 1985, + "src": "4359:101:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,uint256,uint256,uint256,uint256) view external returns (uint256,uint256,uint256)" + } + }, + "id": 4848, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4359:318:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "src": "4243:434:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4850, + "nodeType": "ExpressionStatement", + "src": "4243:434:25" + } + ] + }, + "documentation": "@notice Updates the reserve current fixed borrow rate Rf, the current variable borrow rate Rv and the current liquidity rate Rl.\nPlease refer to the whitepaper for further information.", + "id": 4852, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4815, + "modifierName": { + "argumentTypes": null, + "id": 4814, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "4146:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4146:15:25" + } + ], + "name": "updateReserveInterestRates", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4813, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4812, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4852, + "src": "4119:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4811, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4119:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4118:18:25" + }, + "returnParameters": { + "id": 4816, + "nodeType": "ParameterList", + "parameters": [], + "src": "4162:0:25" + }, + "scope": 6682, + "src": "4083:601:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4882, + "nodeType": "Block", + "src": "4946:148:25", + "statements": [ + { + "assignments": [ + 4867 + ], + "declarations": [ + { + "constant": false, + "id": 4867, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 4882, + "src": "4956:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 4866, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "4956:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4871, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4868, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "4998:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4870, + "indexExpression": { + "argumentTypes": null, + "id": 4869, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4854, + "src": "5007:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "4998:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4956:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 4880, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4872, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4867, + "src": "5026:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4874, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "5026:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4878, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4856, + "src": "5078:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4875, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4867, + "src": "5051:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4876, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "5051:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 4877, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "5051:26:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 4879, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5051:35:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5026:60:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 4881, + "nodeType": "ExpressionStatement", + "src": "5026:60:25" + } + ] + }, + "documentation": "@notice increases the total liquidity Lt of a reserve", + "id": 4883, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4859, + "modifierName": { + "argumentTypes": null, + "id": 4858, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "4864:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "4864:15:25" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 4861, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4854, + "src": "4932:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 4862, + "modifierName": { + "argumentTypes": null, + "id": 4860, + "name": "onlyReserveWithEnabledBorrowingOrCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4739, + "src": "4888:43:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "4888:53:25" + } + ], + "name": "increaseReserveTotalLiquidity", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4857, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4854, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4883, + "src": "4804:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4853, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "4804:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4856, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4883, + "src": "4822:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4855, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4822:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "4803:35:25" + }, + "returnParameters": { + "id": 4863, + "nodeType": "ParameterList", + "parameters": [], + "src": "4946:0:25" + }, + "scope": 6682, + "src": "4765:329:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4910, + "nodeType": "Block", + "src": "5274:147:25", + "statements": [ + { + "assignments": [ + 4895 + ], + "declarations": [ + { + "constant": false, + "id": 4895, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 4910, + "src": "5284:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 4894, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "5284:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 4899, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4896, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "5326:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4898, + "indexExpression": { + "argumentTypes": null, + "id": 4897, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4885, + "src": "5335:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "5326:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5284:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 4908, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4900, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4895, + "src": "5354:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4902, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "5354:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4906, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4887, + "src": "5406:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 4903, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4895, + "src": "5379:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 4904, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "5379:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 4905, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "5379:26:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 4907, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5379:35:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5354:60:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 4909, + "nodeType": "ExpressionStatement", + "src": "5354:60:25" + } + ] + }, + "documentation": "@notice decreases the total liquidity Lt of a reserve", + "id": 4911, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4890, + "modifierName": { + "argumentTypes": null, + "id": 4889, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "5258:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5258:15:25" + } + ], + "name": "decreaseReserveTotalLiquidity", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4888, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4885, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4911, + "src": "5214:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4884, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5214:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4887, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4911, + "src": "5232:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4886, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5232:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5213:35:25" + }, + "returnParameters": { + "id": 4891, + "nodeType": "ParameterList", + "parameters": [], + "src": "5274:0:25" + }, + "scope": 6682, + "src": "5175:246:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4933, + "nodeType": "Block", + "src": "5831:97:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4929, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4915, + "src": "5906:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4930, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4917, + "src": "5915:5:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4925, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "5841:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4927, + "indexExpression": { + "argumentTypes": null, + "id": 4926, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4913, + "src": "5850:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "5841:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4928, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8793, + "src": "5841:64:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 4931, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5841:80:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4932, + "nodeType": "ExpressionStatement", + "src": "5841:80:25" + } + ] + }, + "documentation": "@notice increases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper\nfor further information.", + "id": 4934, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4920, + "modifierName": { + "argumentTypes": null, + "id": 4919, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "5749:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "5749:15:25" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 4922, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4913, + "src": "5817:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 4923, + "modifierName": { + "argumentTypes": null, + "id": 4921, + "name": "onlyReserveWithEnabledBorrowingOrCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4739, + "src": "5773:43:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "5773:53:25" + } + ], + "name": "increaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4918, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4913, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4934, + "src": "5674:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4912, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5674:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4915, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4934, + "src": "5692:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4914, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5692:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4917, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 4934, + "src": "5709:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4916, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5709:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5673:50:25" + }, + "returnParameters": { + "id": 4924, + "nodeType": "ParameterList", + "parameters": [], + "src": "5831:0:25" + }, + "scope": 6682, + "src": "5612:316:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4953, + "nodeType": "Block", + "src": "6278:98:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4949, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4938, + "src": "6353:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 4950, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4940, + "src": "6362:5:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4945, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "6288:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4947, + "indexExpression": { + "argumentTypes": null, + "id": 4946, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4936, + "src": "6297:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "6288:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4948, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8880, + "src": "6288:64:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 4951, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6288:80:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4952, + "nodeType": "ExpressionStatement", + "src": "6288:80:25" + } + ] + }, + "documentation": "@notice decreases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper\nfor further information.", + "id": 4954, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4943, + "modifierName": { + "argumentTypes": null, + "id": 4942, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "6258:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6258:15:25" + } + ], + "name": "decreaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4941, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4936, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4954, + "src": "6183:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4935, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6183:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4938, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4954, + "src": "6201:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4937, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6201:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4940, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 4954, + "src": "6218:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4939, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6218:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6182:50:25" + }, + "returnParameters": { + "id": 4944, + "nodeType": "ParameterList", + "parameters": [], + "src": "6278:0:25" + }, + "scope": 6682, + "src": "6121:255:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4973, + "nodeType": "Block", + "src": "6654:73:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4970, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4958, + "src": "6712:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4966, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "6664:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4968, + "indexExpression": { + "argumentTypes": null, + "id": 4967, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4956, + "src": "6673:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "6664:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4969, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8898, + "src": "6664:47:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 4971, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6664:56:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4972, + "nodeType": "ExpressionStatement", + "src": "6664:56:25" + } + ] + }, + "documentation": "@notice increases the the total borrow variable of a reserve Bv.", + "id": 4974, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4961, + "modifierName": { + "argumentTypes": null, + "id": 4960, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "6572:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6572:15:25" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 4963, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4956, + "src": "6640:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 4964, + "modifierName": { + "argumentTypes": null, + "id": 4962, + "name": "onlyReserveWithEnabledBorrowingOrCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4739, + "src": "6596:43:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "6596:53:25" + } + ], + "name": "increaseReserveTotalBorrowsVariable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4959, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4956, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4974, + "src": "6512:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4955, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6512:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4958, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4974, + "src": "6530:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4957, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6530:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6511:35:25" + }, + "returnParameters": { + "id": 4965, + "nodeType": "ParameterList", + "parameters": [], + "src": "6654:0:25" + }, + "scope": 6682, + "src": "6467:260:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 4990, + "nodeType": "Block", + "src": "6929:73:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 4987, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4978, + "src": "6987:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 4983, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "6939:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 4985, + "indexExpression": { + "argumentTypes": null, + "id": 4984, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4976, + "src": "6948:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "6939:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 4986, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8924, + "src": "6939:47:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 4988, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6939:56:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 4989, + "nodeType": "ExpressionStatement", + "src": "6939:56:25" + } + ] + }, + "documentation": "@notice decreases the the total borrow variable of a reserve Bv.", + "id": 4991, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 4981, + "modifierName": { + "argumentTypes": null, + "id": 4980, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "6913:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "6913:15:25" + } + ], + "name": "decreaseReserveTotalBorrowsVariable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 4979, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4976, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 4991, + "src": "6869:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4975, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6869:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4978, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 4991, + "src": "6887:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4977, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6887:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6868:35:25" + }, + "returnParameters": { + "id": 4982, + "nodeType": "ParameterList", + "parameters": [], + "src": "6929:0:25" + }, + "scope": 6682, + "src": "6824:178:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5120, + "nodeType": "Block", + "src": "7446:1566:25", + "statements": [ + { + "assignments": [ + 5011 + ], + "declarations": [ + { + "constant": false, + "id": 5011, + "name": "currentRateMode", + "nodeType": "VariableDeclaration", + "scope": 5120, + "src": "7456:44:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 5010, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "7456:28:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5016, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5013, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4993, + "src": "7532:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 5014, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4995, + "src": "7542:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 5012, + "name": "getUserCurrentBorrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5988, + "src": "7503:28:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5015, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7503:45:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7456:92:25" + }, + { + "assignments": [ + 5020 + ], + "declarations": [ + { + "constant": false, + "id": 5020, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5120, + "src": "7558:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5019, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "7558:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5024, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5021, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "7600:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5023, + "indexExpression": { + "argumentTypes": null, + "id": 5022, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4993, + "src": "7609:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "7600:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7558:60:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 5029, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 5025, + "name": "currentRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5011, + "src": "7634:15:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5026, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "7653:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5027, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "7653:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5028, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7653:34:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "7634:53:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 5118, + "nodeType": "Block", + "src": "8440:566:25", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 5086, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 5082, + "name": "_newBorrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5001, + "src": "8502:18:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5083, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "8524:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5084, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "8524:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5085, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8524:34:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "8502:56:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 5108, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 5104, + "name": "_newBorrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5001, + "src": "8782:18:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5105, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "8804:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5106, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "8804:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5107, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "VARIABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8804:37:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "8782:59:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 5116, + "nodeType": "IfStatement", + "src": "8778:218:25", + "trueBody": { + "id": 5115, + "nodeType": "Block", + "src": "8843:153:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5112, + "name": "_balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4999, + "src": "8964:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5109, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "8927:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5111, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8898, + "src": "8927:36:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 5113, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8927:54:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5114, + "nodeType": "ExpressionStatement", + "src": "8927:54:25" + } + ] + } + }, + "id": 5117, + "nodeType": "IfStatement", + "src": "8498:498:25", + "trueBody": { + "id": 5103, + "nodeType": "Block", + "src": "8560:212:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5090, + "name": "_principalBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4997, + "src": "8615:17:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5087, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "8578:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5089, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8924, + "src": "8578:36:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 5091, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8578:55:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5092, + "nodeType": "ExpressionStatement", + "src": "8578:55:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5098, + "name": "_balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4999, + "src": "8727:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5096, + "name": "_principalBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4997, + "src": "8705:17:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5097, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8705:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5099, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8705:39:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 5100, + "name": "_fixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5003, + "src": "8746:10:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5093, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "8651:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5095, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8793, + "src": "8651:53:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 5101, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8651:106:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5102, + "nodeType": "ExpressionStatement", + "src": "8651:106:25" + } + ] + } + } + ] + }, + "id": 5119, + "nodeType": "IfStatement", + "src": "7630:1376:25", + "trueBody": { + "id": 5081, + "nodeType": "Block", + "src": "7689:745:25", + "statements": [ + { + "assignments": [ + 5033 + ], + "declarations": [ + { + "constant": false, + "id": 5033, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5081, + "src": "7776:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5032, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "7776:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5039, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5034, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "7819:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5036, + "indexExpression": { + "argumentTypes": null, + "id": 5035, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4995, + "src": "7836:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "7819:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5038, + "indexExpression": { + "argumentTypes": null, + "id": 5037, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4993, + "src": "7843:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "7819:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7776:76:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5043, + "name": "_principalBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4997, + "src": "7920:17:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5044, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5033, + "src": "7939:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5045, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "7939:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5040, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "7866:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5042, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8880, + "src": "7866:53:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 5046, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7866:94:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5047, + "nodeType": "ExpressionStatement", + "src": "7866:94:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 5052, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 5048, + "name": "_newBorrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5001, + "src": "7979:18:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5049, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "8001:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5050, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "8001:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5051, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8001:34:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "7979:56:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 5068, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 5064, + "name": "_newBorrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5001, + "src": "8187:18:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5065, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "8209:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5066, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "8209:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5067, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "VARIABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8209:37:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "8187:59:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 5079, + "nodeType": "IfStatement", + "src": "8183:241:25", + "trueBody": { + "id": 5078, + "nodeType": "Block", + "src": "8248:176:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5074, + "name": "_balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4999, + "src": "8391:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5072, + "name": "_principalBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4997, + "src": "8369:17:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5073, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8369:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5075, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8369:39:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5069, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "8332:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5071, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8898, + "src": "8332:36:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256)" + } + }, + "id": 5076, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8332:77:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5077, + "nodeType": "ExpressionStatement", + "src": "8332:77:25" + } + ] + } + }, + "id": 5080, + "nodeType": "IfStatement", + "src": "7975:449:25", + "trueBody": { + "id": 5063, + "nodeType": "Block", + "src": "8037:139:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5058, + "name": "_balanceIncrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4999, + "src": "8131:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5056, + "name": "_principalBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4997, + "src": "8109:17:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5057, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "8109:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5059, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8109:39:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 5060, + "name": "_fixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5003, + "src": "8150:10:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 5053, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5020, + "src": "8055:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5055, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8793, + "src": "8055:53:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 5061, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8055:106:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5062, + "nodeType": "ExpressionStatement", + "src": "8055:106:25" + } + ] + } + } + ] + } + } + ] + }, + "documentation": "*************\n@dev increases the proper total borrows on a reserve depending on the type of interest rate chosen by the user**************", + "id": 5121, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5006, + "modifierName": { + "argumentTypes": null, + "id": 5005, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "7430:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "7430:15:25" + } + ], + "name": "updateReserveTotalBorrowsByRateMode", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5004, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 4993, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7221:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4992, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7221:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4995, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7247:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 4994, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "7247:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4997, + "name": "_principalBalance", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7270:25:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4996, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7270:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 4999, + "name": "_balanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7305:24:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 4998, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7305:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5001, + "name": "_newBorrowRateMode", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7339:47:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 5000, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "7339:28:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5003, + "name": "_fixedRate", + "nodeType": "VariableDeclaration", + "scope": 5121, + "src": "7396:18:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5002, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7396:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "7211:209:25" + }, + "returnParameters": { + "id": 5007, + "nodeType": "ParameterList", + "parameters": [], + "src": "7446:0:25" + }, + "scope": 6682, + "src": "7167:1845:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5134, + "nodeType": "Block", + "src": "9166:51:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5128, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "9176:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5130, + "indexExpression": { + "argumentTypes": null, + "id": 5129, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5123, + "src": "9185:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9176:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 5131, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "setLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8939, + "src": "9176:32:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer)" + } + }, + "id": 5132, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9176:34:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5133, + "nodeType": "ExpressionStatement", + "src": "9176:34:25" + } + ] + }, + "documentation": "@notice refreshes reserve last updated block number Bl", + "id": 5135, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5126, + "modifierName": { + "argumentTypes": null, + "id": 5125, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "9150:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "9150:15:25" + } + ], + "name": "setReserveLastUpdate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5124, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5123, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5135, + "src": "9123:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5122, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9123:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9122:18:25" + }, + "returnParameters": { + "id": 5127, + "nodeType": "ParameterList", + "parameters": [], + "src": "9166:0:25" + }, + "scope": 6682, + "src": "9093:124:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5169, + "nodeType": "Block", + "src": "9413:256:25", + "statements": [ + { + "assignments": [ + 5147 + ], + "declarations": [ + { + "constant": false, + "id": 5147, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5169, + "src": "9423:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5146, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "9423:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5153, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5148, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "9466:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5150, + "indexExpression": { + "argumentTypes": null, + "id": 5149, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5139, + "src": "9483:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9466:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5152, + "indexExpression": { + "argumentTypes": null, + "id": 5151, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5137, + "src": "9490:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9466:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9423:76:25" + }, + { + "assignments": [ + 5157 + ], + "declarations": [ + { + "constant": false, + "id": 5157, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5169, + "src": "9509:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5156, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "9509:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5161, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5158, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "9551:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5160, + "indexExpression": { + "argumentTypes": null, + "id": 5159, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5137, + "src": "9560:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9551:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9509:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5167, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5162, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5147, + "src": "9580:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5164, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8274, + "src": "9580:38:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5165, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5157, + "src": "9621:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5166, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "9621:41:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9580:82:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5168, + "nodeType": "ExpressionStatement", + "src": "9580:82:25" + } + ] + }, + "documentation": "*************\n@dev functions to update users reserve data", + "id": 5170, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5142, + "modifierName": { + "argumentTypes": null, + "id": 5141, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "9397:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "9397:15:25" + } + ], + "name": "updateUserLastVariableBorrowCumulativeIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5140, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5137, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5170, + "src": "9355:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5136, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9355:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5139, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5170, + "src": "9373:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5138, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9373:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9354:33:25" + }, + "returnParameters": { + "id": 5143, + "nodeType": "ParameterList", + "parameters": [], + "src": "9413:0:25" + }, + "scope": 6682, + "src": "9302:367:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5201, + "nodeType": "Block", + "src": "9786:157:25", + "statements": [ + { + "assignments": [ + 5184 + ], + "declarations": [ + { + "constant": false, + "id": 5184, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5201, + "src": "9796:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5183, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "9796:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5190, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5185, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "9839:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5187, + "indexExpression": { + "argumentTypes": null, + "id": 5186, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5174, + "src": "9856:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9839:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5189, + "indexExpression": { + "argumentTypes": null, + "id": 5188, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5172, + "src": "9863:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "9839:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "9796:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5199, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5191, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5184, + "src": "9882:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5193, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "originationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 8276, + "src": "9882:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5197, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5176, + "src": "9928:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5194, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5184, + "src": "9904:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5195, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "originationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 8276, + "src": "9904:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5196, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "9904:23:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5198, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9904:32:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9882:54:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5200, + "nodeType": "ExpressionStatement", + "src": "9882:54:25" + } + ] + }, + "documentation": null, + "id": 5202, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5179, + "modifierName": { + "argumentTypes": null, + "id": 5178, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "9770:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "9770:15:25" + } + ], + "name": "increaseUserOriginationFee", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5177, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5172, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5202, + "src": "9711:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5171, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9711:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5174, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5202, + "src": "9729:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5173, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9729:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5176, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 5202, + "src": "9744:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5175, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9744:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9710:50:25" + }, + "returnParameters": { + "id": 5180, + "nodeType": "ParameterList", + "parameters": [], + "src": "9786:0:25" + }, + "scope": 6682, + "src": "9675:268:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5233, + "nodeType": "Block", + "src": "10060:157:25", + "statements": [ + { + "assignments": [ + 5216 + ], + "declarations": [ + { + "constant": false, + "id": 5216, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5233, + "src": "10070:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5215, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "10070:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5222, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5217, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "10113:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5219, + "indexExpression": { + "argumentTypes": null, + "id": 5218, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5206, + "src": "10130:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10113:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5221, + "indexExpression": { + "argumentTypes": null, + "id": 5220, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5204, + "src": "10137:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10113:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "10070:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5231, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5223, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5216, + "src": "10156:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5225, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "originationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 8276, + "src": "10156:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5229, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5208, + "src": "10202:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5226, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5216, + "src": "10178:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5227, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "originationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 8276, + "src": "10178:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5228, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "10178:23:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5230, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10178:32:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10156:54:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5232, + "nodeType": "ExpressionStatement", + "src": "10156:54:25" + } + ] + }, + "documentation": null, + "id": 5234, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5211, + "modifierName": { + "argumentTypes": null, + "id": 5210, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "10044:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "10044:15:25" + } + ], + "name": "decreaseUserOriginationFee", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5209, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5204, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5234, + "src": "9985:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5203, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9985:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5206, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5234, + "src": "10003:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5205, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10003:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5208, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 5234, + "src": "10018:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5207, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10018:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9984:50:25" + }, + "returnParameters": { + "id": 5212, + "nodeType": "ParameterList", + "parameters": [], + "src": "10060:0:25" + }, + "scope": 6682, + "src": "9949:268:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5268, + "nodeType": "Block", + "src": "10412:173:25", + "statements": [ + { + "assignments": [ + 5251 + ], + "declarations": [ + { + "constant": false, + "id": 5251, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5268, + "src": "10422:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5250, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "10422:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5257, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5252, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "10465:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5254, + "indexExpression": { + "argumentTypes": null, + "id": 5253, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5238, + "src": "10482:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10465:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5256, + "indexExpression": { + "argumentTypes": null, + "id": 5255, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5236, + "src": "10489:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10465:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "10422:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5266, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5258, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5251, + "src": "10508:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5260, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "10508:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5264, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5240, + "src": "10570:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5261, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5251, + "src": "10538:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5262, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "10538:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5263, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "10538:31:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5265, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10538:40:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10508:70:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5267, + "nodeType": "ExpressionStatement", + "src": "10508:70:25" + } + ] + }, + "documentation": null, + "id": 5269, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5243, + "modifierName": { + "argumentTypes": null, + "id": 5242, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "10342:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "10342:15:25" + }, + { + "arguments": [ + { + "argumentTypes": null, + "id": 5245, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5236, + "src": "10398:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "id": 5246, + "modifierName": { + "argumentTypes": null, + "id": 5244, + "name": "onlyReserveWithEnabledBorrowing", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4753, + "src": "10366:31:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$_t_address_$", + "typeString": "modifier (address)" + } + }, + "nodeType": "ModifierInvocation", + "src": "10366:41:25" + } + ], + "name": "increaseUserPrincipalBorrowBalance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5241, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5236, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5269, + "src": "10267:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5235, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10267:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5238, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5269, + "src": "10285:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5237, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10285:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5240, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 5269, + "src": "10300:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5239, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10300:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10266:50:25" + }, + "returnParameters": { + "id": 5247, + "nodeType": "ParameterList", + "parameters": [], + "src": "10412:0:25" + }, + "scope": 6682, + "src": "10223:362:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5308, + "nodeType": "Block", + "src": "10730:263:25", + "statements": [ + { + "assignments": [ + 5283 + ], + "declarations": [ + { + "constant": false, + "id": 5283, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5308, + "src": "10740:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5282, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "10740:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5289, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5284, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "10783:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5286, + "indexExpression": { + "argumentTypes": null, + "id": 5285, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5273, + "src": "10800:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10783:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5288, + "indexExpression": { + "argumentTypes": null, + "id": 5287, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5271, + "src": "10807:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "10783:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "10740:76:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 5294, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5291, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5283, + "src": "10834:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5292, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "10834:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 5293, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5275, + "src": "10865:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10834:38:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520626f72726f772062616c616e636520697320746f6f206c6f77", + "id": 5295, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "10874:31:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_123a7f21cf668d1416a24569213afa79d97c3368899a9765f824f8894421c2af", + "typeString": "literal_string \"The borrow balance is too low\"" + }, + "value": "The borrow balance is too low" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_123a7f21cf668d1416a24569213afa79d97c3368899a9765f824f8894421c2af", + "typeString": "literal_string \"The borrow balance is too low\"" + } + ], + "id": 5290, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "10826:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 5296, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10826:80:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 5297, + "nodeType": "ExpressionStatement", + "src": "10826:80:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5306, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5298, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5283, + "src": "10916:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5300, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "10916:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5304, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5275, + "src": "10978:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5301, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5283, + "src": "10946:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5302, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "10946:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5303, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "10946:31:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5305, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10946:40:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10916:70:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5307, + "nodeType": "ExpressionStatement", + "src": "10916:70:25" + } + ] + }, + "documentation": null, + "id": 5309, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5278, + "modifierName": { + "argumentTypes": null, + "id": 5277, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "10710:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "10710:15:25" + } + ], + "name": "decreaseUserPrincipalBorrowBalance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5276, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5271, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5309, + "src": "10635:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5270, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10635:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5273, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5309, + "src": "10653:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5272, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10653:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5275, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 5309, + "src": "10668:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5274, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10668:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10634:50:25" + }, + "returnParameters": { + "id": 5279, + "nodeType": "ParameterList", + "parameters": [], + "src": "10730:0:25" + }, + "scope": 6682, + "src": "10591:402:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5336, + "nodeType": "Block", + "src": "11119:142:25", + "statements": [ + { + "assignments": [ + 5323 + ], + "declarations": [ + { + "constant": false, + "id": 5323, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5336, + "src": "11129:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5322, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "11129:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5329, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5324, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "11172:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5326, + "indexExpression": { + "argumentTypes": null, + "id": 5325, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5313, + "src": "11189:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11172:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5328, + "indexExpression": { + "argumentTypes": null, + "id": 5327, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5311, + "src": "11196:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11172:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "11129:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5334, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5330, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5323, + "src": "11215:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5332, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "useAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8282, + "src": "11215:20:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 5333, + "name": "_useAsCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5315, + "src": "11238:16:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "11215:39:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 5335, + "nodeType": "ExpressionStatement", + "src": "11215:39:25" + } + ] + }, + "documentation": null, + "id": 5337, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5318, + "modifierName": { + "argumentTypes": null, + "id": 5317, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "11103:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "11103:15:25" + } + ], + "name": "setUserUseReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5316, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5311, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5337, + "src": "11038:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5310, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11038:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5313, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5337, + "src": "11056:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5312, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11056:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5315, + "name": "_useAsCollateral", + "nodeType": "VariableDeclaration", + "scope": 5337, + "src": "11071:21:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5314, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "11071:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11037:56:25" + }, + "returnParameters": { + "id": 5319, + "nodeType": "ParameterList", + "parameters": [], + "src": "11119:0:25" + }, + "scope": 6682, + "src": "10999:262:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5365, + "nodeType": "Block", + "src": "11352:189:25", + "statements": [ + { + "assignments": [ + 5349 + ], + "declarations": [ + { + "constant": false, + "id": 5349, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5365, + "src": "11362:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5348, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "11362:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5355, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5350, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "11405:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5352, + "indexExpression": { + "argumentTypes": null, + "id": 5351, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5341, + "src": "11422:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11405:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5354, + "indexExpression": { + "argumentTypes": null, + "id": 5353, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5339, + "src": "11429:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11405:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "11362:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5363, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5356, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5349, + "src": "11484:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5358, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8280, + "src": "11484:24:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5360, + "name": "block", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12118, + "src": "11518:5:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_block", + "typeString": "block" + } + }, + "id": 5361, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "timestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "11518:15:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 5359, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "11511:6:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint40_$", + "typeString": "type(uint40)" + }, + "typeName": "uint40" + }, + "id": 5362, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11511:23:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "src": "11484:50:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "id": 5364, + "nodeType": "ExpressionStatement", + "src": "11484:50:25" + } + ] + }, + "documentation": null, + "id": 5366, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5344, + "modifierName": { + "argumentTypes": null, + "id": 5343, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "11336:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "11336:15:25" + } + ], + "name": "setUserLastUpdate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5342, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5339, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5366, + "src": "11294:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5338, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11294:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5341, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5366, + "src": "11312:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5340, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11312:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11293:33:25" + }, + "returnParameters": { + "id": 5345, + "nodeType": "ParameterList", + "parameters": [], + "src": "11352:0:25" + }, + "scope": 6682, + "src": "11267:274:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5393, + "nodeType": "Block", + "src": "11741:169:25", + "statements": [ + { + "assignments": [ + 5378 + ], + "declarations": [ + { + "constant": false, + "id": 5378, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5393, + "src": "11751:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5377, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "11751:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5384, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5379, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "11794:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5381, + "indexExpression": { + "argumentTypes": null, + "id": 5380, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5370, + "src": "11811:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11794:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5383, + "indexExpression": { + "argumentTypes": null, + "id": 5382, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5368, + "src": "11818:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "11794:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "11751:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5391, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5385, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5378, + "src": "11838:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5387, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "11838:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5389, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5368, + "src": "11894:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 5388, + "name": "getReserveCurrentFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5681, + "src": "11861:32:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 5390, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11861:42:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11838:65:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5392, + "nodeType": "ExpressionStatement", + "src": "11838:65:25" + } + ] + }, + "documentation": "****************\n@dev updates the fixed borrow rate for the user******************", + "id": 5394, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5373, + "modifierName": { + "argumentTypes": null, + "id": 5372, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "11725:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "11725:15:25" + } + ], + "name": "updateUserFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5371, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5368, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5394, + "src": "11683:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5367, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11683:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5370, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5394, + "src": "11701:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5369, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11701:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11682:33:25" + }, + "returnParameters": { + "id": 5374, + "nodeType": "ParameterList", + "parameters": [], + "src": "11741:0:25" + }, + "scope": 6682, + "src": "11648:262:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5419, + "nodeType": "Block", + "src": "12008:127:25", + "statements": [ + { + "assignments": [ + 5406 + ], + "declarations": [ + { + "constant": false, + "id": 5406, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5419, + "src": "12018:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5405, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "12018:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5412, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5407, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "12061:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5409, + "indexExpression": { + "argumentTypes": null, + "id": 5408, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5398, + "src": "12078:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "12061:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5411, + "indexExpression": { + "argumentTypes": null, + "id": 5410, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5396, + "src": "12085:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "12061:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "12018:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5417, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5413, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5406, + "src": "12104:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5415, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "12104:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "30", + "id": 5416, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "12127:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "12104:24:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5418, + "nodeType": "ExpressionStatement", + "src": "12104:24:25" + } + ] + }, + "documentation": null, + "id": 5420, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 5401, + "modifierName": { + "argumentTypes": null, + "id": 5400, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "11992:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "11992:15:25" + } + ], + "name": "resetUserFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5399, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5396, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5420, + "src": "11950:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5395, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11950:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5398, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5420, + "src": "11968:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5397, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11968:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11949:33:25" + }, + "returnParameters": { + "id": 5402, + "nodeType": "ParameterList", + "parameters": [], + "src": "12008:0:25" + }, + "scope": 6682, + "src": "11916:219:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5438, + "nodeType": "Block", + "src": "12319:129:25", + "statements": [ + { + "assignments": [ + 5430 + ], + "declarations": [ + { + "constant": false, + "id": 5430, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5438, + "src": "12329:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5429, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "12329:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5434, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5431, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "12371:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5433, + "indexExpression": { + "argumentTypes": null, + "id": 5432, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5422, + "src": "12380:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "12371:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "12329:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5435, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5430, + "src": "12406:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5436, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "interestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8313, + "src": "12406:35:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 5426, + "id": 5437, + "nodeType": "Return", + "src": "12399:42:25" + } + ] + }, + "documentation": "*******************\n@dev reserve accessors********************", + "id": 5439, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveInterestRateStrategyAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5423, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5422, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5439, + "src": "12271:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5421, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12271:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12270:18:25" + }, + "returnParameters": { + "id": 5426, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5425, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5439, + "src": "12310:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5424, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12310:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12309:9:25" + }, + "scope": 6682, + "src": "12224:224:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 5457, + "nodeType": "Block", + "src": "12535:115:25", + "statements": [ + { + "assignments": [ + 5449 + ], + "declarations": [ + { + "constant": false, + "id": 5449, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5457, + "src": "12545:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5448, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "12545:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5453, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5450, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "12587:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5452, + "indexExpression": { + "argumentTypes": null, + "id": 5451, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5441, + "src": "12596:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "12587:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "12545:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5454, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5449, + "src": "12622:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5455, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "aTokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8311, + "src": "12622:21:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 5445, + "id": 5456, + "nodeType": "Return", + "src": "12615:28:25" + } + ] + }, + "documentation": null, + "id": 5458, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveATokenAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5442, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5441, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5458, + "src": "12487:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5440, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12487:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12486:18:25" + }, + "returnParameters": { + "id": 5445, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5444, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5458, + "src": "12526:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5443, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12526:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12525:9:25" + }, + "scope": 6682, + "src": "12454:196:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 5481, + "nodeType": "Block", + "src": "12742:154:25", + "statements": [ + { + "assignments": [ + 5468 + ], + "declarations": [ + { + "constant": false, + "id": 5468, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5481, + "src": "12752:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5467, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "12752:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5472, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5469, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "12794:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5471, + "indexExpression": { + "argumentTypes": null, + "id": 5470, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5460, + "src": "12803:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "12794:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "12752:60:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5477, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5460, + "src": "12879:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 5476, + "name": "getReserveTotalBorrows", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5535, + "src": "12856:22:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view returns (uint256)" + } + }, + "id": 5478, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12856:32:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5473, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5468, + "src": "12829:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5474, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "12829:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5475, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "12829:26:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 5479, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12829:60:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5464, + "id": 5480, + "nodeType": "Return", + "src": "12822:67:25" + } + ] + }, + "documentation": null, + "id": 5482, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveAvailableLiquidity", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5461, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5460, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5482, + "src": "12694:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5459, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12694:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12693:18:25" + }, + "returnParameters": { + "id": 5464, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5463, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5482, + "src": "12733:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5462, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12733:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12732:9:25" + }, + "scope": 6682, + "src": "12656:240:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 5500, + "nodeType": "Block", + "src": "12986:116:25", + "statements": [ + { + "assignments": [ + 5492 + ], + "declarations": [ + { + "constant": false, + "id": 5492, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5500, + "src": "12996:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5491, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "12996:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5496, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5493, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "13038:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5495, + "indexExpression": { + "argumentTypes": null, + "id": 5494, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5484, + "src": "13047:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "13038:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "12996:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5497, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5492, + "src": "13073:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5498, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 8285, + "src": "13073:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5488, + "id": 5499, + "nodeType": "Return", + "src": "13066:29:25" + } + ] + }, + "documentation": null, + "id": 5501, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveTotalLiquidity", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5485, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5484, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5501, + "src": "12936:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5483, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12936:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12935:18:25" + }, + "returnParameters": { + "id": 5488, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5487, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5501, + "src": "12977:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5486, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12977:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12976:9:25" + }, + "scope": 6682, + "src": "12902:200:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5520, + "nodeType": "Block", + "src": "13194:123:25", + "statements": [ + { + "assignments": [ + 5511 + ], + "declarations": [ + { + "constant": false, + "id": 5511, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5520, + "src": "13204:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5510, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "13204:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5515, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5512, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "13246:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5514, + "indexExpression": { + "argumentTypes": null, + "id": 5513, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5503, + "src": "13255:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "13246:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13204:60:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 5516, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5511, + "src": "13281:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5517, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "getNormalizedIncome", + "nodeType": "MemberAccess", + "referencedDeclaration": 8377, + "src": "13281:27:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 5518, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13281:29:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5507, + "id": 5519, + "nodeType": "Return", + "src": "13274:36:25" + } + ] + }, + "documentation": null, + "id": 5521, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveNormalizedIncome", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5504, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5503, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5521, + "src": "13144:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5502, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13144:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13143:18:25" + }, + "returnParameters": { + "id": 5507, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5506, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5521, + "src": "13185:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5505, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13185:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13184:9:25" + }, + "scope": 6682, + "src": "13108:209:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5534, + "nodeType": "Block", + "src": "13403:60:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5528, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "13420:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5530, + "indexExpression": { + "argumentTypes": null, + "id": 5529, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5523, + "src": "13429:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "13420:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 5531, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "getTotalBorrows", + "nodeType": "MemberAccess", + "referencedDeclaration": 8954, + "src": "13420:34:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 5532, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13420:36:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5527, + "id": 5533, + "nodeType": "Return", + "src": "13413:43:25" + } + ] + }, + "documentation": null, + "id": 5535, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveTotalBorrows", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5524, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5523, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5535, + "src": "13355:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5522, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13355:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13354:18:25" + }, + "returnParameters": { + "id": 5527, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5526, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5535, + "src": "13394:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5525, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13394:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13393:9:25" + }, + "scope": 6682, + "src": "13323:140:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 5553, + "nodeType": "Block", + "src": "13556:119:25", + "statements": [ + { + "assignments": [ + 5545 + ], + "declarations": [ + { + "constant": false, + "id": 5545, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5553, + "src": "13566:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5544, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "13566:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5549, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5546, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "13608:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5548, + "indexExpression": { + "argumentTypes": null, + "id": 5547, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5537, + "src": "13617:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "13608:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13566:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5550, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5545, + "src": "13643:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5551, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 8291, + "src": "13643:25:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5541, + "id": 5552, + "nodeType": "Return", + "src": "13636:32:25" + } + ] + }, + "documentation": null, + "id": 5554, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveTotalBorrowsFixed", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5538, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5537, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5554, + "src": "13506:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5536, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13506:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13505:18:25" + }, + "returnParameters": { + "id": 5541, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5540, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5554, + "src": "13547:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5539, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13547:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13546:9:25" + }, + "scope": 6682, + "src": "13469:206:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5572, + "nodeType": "Block", + "src": "13771:122:25", + "statements": [ + { + "assignments": [ + 5564 + ], + "declarations": [ + { + "constant": false, + "id": 5564, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5572, + "src": "13781:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5563, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "13781:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5568, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5565, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "13823:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5567, + "indexExpression": { + "argumentTypes": null, + "id": 5566, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5556, + "src": "13832:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "13823:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13781:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5569, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5564, + "src": "13858:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5570, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "totalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 8293, + "src": "13858:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5560, + "id": 5571, + "nodeType": "Return", + "src": "13851:35:25" + } + ] + }, + "documentation": null, + "id": 5573, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveTotalBorrowsVariable", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5557, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5556, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5573, + "src": "13721:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5555, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13721:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13720:18:25" + }, + "returnParameters": { + "id": 5560, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5559, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5573, + "src": "13762:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5558, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13762:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13761:9:25" + }, + "scope": 6682, + "src": "13681:212:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5591, + "nodeType": "Block", + "src": "13989:122:25", + "statements": [ + { + "assignments": [ + 5583 + ], + "declarations": [ + { + "constant": false, + "id": 5583, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5591, + "src": "13999:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5582, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "13999:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5587, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5584, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "14041:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5586, + "indexExpression": { + "argumentTypes": null, + "id": 5585, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5575, + "src": "14050:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "14041:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13999:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5588, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5583, + "src": "14076:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5589, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 8305, + "src": "14076:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5579, + "id": 5590, + "nodeType": "Return", + "src": "14069:35:25" + } + ] + }, + "documentation": null, + "id": 5592, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveLiquidationThreshold", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5576, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5575, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5592, + "src": "13939:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5574, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "13939:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13938:18:25" + }, + "returnParameters": { + "id": 5579, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5578, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5592, + "src": "13980:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5577, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "13980:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "13979:9:25" + }, + "scope": 6682, + "src": "13899:212:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5610, + "nodeType": "Block", + "src": "14206:121:25", + "statements": [ + { + "assignments": [ + 5602 + ], + "declarations": [ + { + "constant": false, + "id": 5602, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5610, + "src": "14216:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5601, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "14216:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5606, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5603, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "14258:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5605, + "indexExpression": { + "argumentTypes": null, + "id": 5604, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5594, + "src": "14267:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "14258:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14216:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5607, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5602, + "src": "14293:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5608, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 8307, + "src": "14293:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5598, + "id": 5609, + "nodeType": "Return", + "src": "14286:34:25" + } + ] + }, + "documentation": null, + "id": 5611, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveLiquidationDiscount", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5595, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5594, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5611, + "src": "14156:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5593, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14156:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14155:18:25" + }, + "returnParameters": { + "id": 5598, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5597, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5611, + "src": "14197:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5596, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14197:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14196:9:25" + }, + "scope": 6682, + "src": "14117:210:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5642, + "nodeType": "Block", + "src": "14428:322:25", + "statements": [ + { + "assignments": [ + 5621 + ], + "declarations": [ + { + "constant": false, + "id": 5621, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5642, + "src": "14438:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5620, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "14438:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5625, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5622, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "14480:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5624, + "indexExpression": { + "argumentTypes": null, + "id": 5623, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5613, + "src": "14489:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "14480:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14438:60:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 5629, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5626, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5621, + "src": "14512:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5627, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8295, + "src": "14512:33:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 5628, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "14549:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "14512:38:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 5638, + "nodeType": "IfStatement", + "src": "14509:185:25", + "trueBody": { + "id": 5637, + "nodeType": "Block", + "src": "14552:142:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5631, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5621, + "src": "14602:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5632, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "interestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8313, + "src": "14602:35:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 5630, + "name": "IReserveInterestRateStrategy", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1986, + "src": "14573:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IReserveInterestRateStrategy_$1986_$", + "typeString": "type(contract IReserveInterestRateStrategy)" + } + }, + "id": 5633, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14573:65:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IReserveInterestRateStrategy_$1986", + "typeString": "contract IReserveInterestRateStrategy" + } + }, + "id": 5634, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getBaseVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 1966, + "src": "14573:108:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$", + "typeString": "function () view external returns (uint256)" + } + }, + "id": 5635, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14573:110:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5617, + "id": 5636, + "nodeType": "Return", + "src": "14566:117:25" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5639, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5621, + "src": "14710:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5640, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8295, + "src": "14710:33:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5617, + "id": 5641, + "nodeType": "Return", + "src": "14703:40:25" + } + ] + }, + "documentation": null, + "id": 5643, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveCurrentVariableBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5614, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5613, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5643, + "src": "14378:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5612, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14378:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14377:18:25" + }, + "returnParameters": { + "id": 5617, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5616, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5643, + "src": "14419:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5615, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14419:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14418:9:25" + }, + "scope": 6682, + "src": "14333:417:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5680, + "nodeType": "Block", + "src": "14846:382:25", + "statements": [ + { + "assignments": [ + 5653 + ], + "declarations": [ + { + "constant": false, + "id": 5653, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5680, + "src": "14856:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5652, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "14856:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5657, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5654, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "14898:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5656, + "indexExpression": { + "argumentTypes": null, + "id": 5655, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5645, + "src": "14907:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "14898:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14856:60:25" + }, + { + "assignments": [ + 5659 + ], + "declarations": [ + { + "constant": false, + "id": 5659, + "name": "oracle", + "nodeType": "VariableDeclaration", + "scope": 5680, + "src": "14926:25:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + }, + "typeName": { + "contractScope": null, + "id": 5658, + "name": "ILendingRateOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1909, + "src": "14926:18:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5665, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 5661, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "14973:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 5662, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingRateOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1291, + "src": "14973:38:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 5663, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14973:40:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 5660, + "name": "ILendingRateOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1909, + "src": "14954:18:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ILendingRateOracle_$1909_$", + "typeString": "type(contract ILendingRateOracle)" + } + }, + "id": 5664, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14954:60:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14926:88:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 5669, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5666, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5653, + "src": "15029:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5667, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8297, + "src": "15029:30:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 5668, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "15063:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "15029:35:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 5676, + "nodeType": "IfStatement", + "src": "15025:149:25", + "trueBody": { + "id": 5675, + "nodeType": "Block", + "src": "15066:108:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 5672, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5645, + "src": "15154:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 5670, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5659, + "src": "15127:6:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "id": 5671, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getMarketBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 1887, + "src": "15127:26:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 5673, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "15127:36:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5649, + "id": 5674, + "nodeType": "Return", + "src": "15120:43:25" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5677, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5653, + "src": "15191:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5678, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8297, + "src": "15191:30:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5649, + "id": 5679, + "nodeType": "Return", + "src": "15184:37:25" + } + ] + }, + "documentation": null, + "id": 5681, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveCurrentFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5646, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5645, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5681, + "src": "14798:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5644, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14798:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14797:18:25" + }, + "returnParameters": { + "id": 5649, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5648, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5681, + "src": "14837:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5647, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14837:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14836:9:25" + }, + "scope": 6682, + "src": "14756:472:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 5699, + "nodeType": "Block", + "src": "15333:131:25", + "statements": [ + { + "assignments": [ + 5691 + ], + "declarations": [ + { + "constant": false, + "id": 5691, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5699, + "src": "15343:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5690, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "15343:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5695, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5692, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "15385:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5694, + "indexExpression": { + "argumentTypes": null, + "id": 5693, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5683, + "src": "15394:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "15385:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "15343:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5696, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5691, + "src": "15420:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5697, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8299, + "src": "15420:37:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5687, + "id": 5698, + "nodeType": "Return", + "src": "15413:44:25" + } + ] + }, + "documentation": null, + "id": 5700, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveCurrentAverageFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5684, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5683, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5700, + "src": "15283:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5682, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "15283:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15282:18:25" + }, + "returnParameters": { + "id": 5687, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5686, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5700, + "src": "15324:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5685, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "15324:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15323:9:25" + }, + "scope": 6682, + "src": "15234:230:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5718, + "nodeType": "Block", + "src": "15560:122:25", + "statements": [ + { + "assignments": [ + 5710 + ], + "declarations": [ + { + "constant": false, + "id": 5710, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5718, + "src": "15570:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5709, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "15570:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5714, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5711, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "15612:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5713, + "indexExpression": { + "argumentTypes": null, + "id": 5712, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5702, + "src": "15621:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "15612:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "15570:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5715, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5710, + "src": "15647:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5716, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8289, + "src": "15647:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5706, + "id": 5717, + "nodeType": "Return", + "src": "15640:35:25" + } + ] + }, + "documentation": null, + "id": 5719, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveCurrentLiquidityRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5703, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5702, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5719, + "src": "15510:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5701, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "15510:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15509:18:25" + }, + "returnParameters": { + "id": 5706, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5705, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5719, + "src": "15551:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5704, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "15551:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15550:9:25" + }, + "scope": 6682, + "src": "15470:212:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5737, + "nodeType": "Block", + "src": "15782:130:25", + "statements": [ + { + "assignments": [ + 5729 + ], + "declarations": [ + { + "constant": false, + "id": 5729, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5737, + "src": "15792:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5728, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "15792:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5733, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5730, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "15834:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5732, + "indexExpression": { + "argumentTypes": null, + "id": 5731, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5721, + "src": "15843:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "15834:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "15792:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5734, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5729, + "src": "15869:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5735, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "15869:36:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5725, + "id": 5736, + "nodeType": "Return", + "src": "15862:43:25" + } + ] + }, + "documentation": null, + "id": 5738, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveLiquidityCumulativeIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5722, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5721, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5738, + "src": "15732:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5720, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "15732:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15731:18:25" + }, + "returnParameters": { + "id": 5725, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5724, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5738, + "src": "15773:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5723, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "15773:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15772:9:25" + }, + "scope": 6682, + "src": "15688:224:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5756, + "nodeType": "Block", + "src": "16018:135:25", + "statements": [ + { + "assignments": [ + 5748 + ], + "declarations": [ + { + "constant": false, + "id": 5748, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5756, + "src": "16028:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5747, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "16028:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5752, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5749, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "16070:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5751, + "indexExpression": { + "argumentTypes": null, + "id": 5750, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5740, + "src": "16079:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "16070:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "16028:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5753, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5748, + "src": "16105:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5754, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "16105:41:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5744, + "id": 5755, + "nodeType": "Return", + "src": "16098:48:25" + } + ] + }, + "documentation": null, + "id": 5757, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveVariableBorrowsCumulativeIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5741, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5740, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5757, + "src": "15968:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5739, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "15968:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "15967:18:25" + }, + "returnParameters": { + "id": 5744, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5743, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5757, + "src": "16009:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5742, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "16009:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "16008:9:25" + }, + "scope": 6682, + "src": "15918:235:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5812, + "nodeType": "Block", + "src": "16711:423:25", + "statements": [ + { + "assignments": [ + 5777 + ], + "declarations": [ + { + "constant": false, + "id": 5777, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5812, + "src": "16721:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5776, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "16721:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5781, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5778, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "16763:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5780, + "indexExpression": { + "argumentTypes": null, + "id": 5779, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5759, + "src": "16772:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "16763:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "16721:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5785, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5782, + "name": "decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5762, + "src": "16791:8:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5783, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "16802:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5784, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 8309, + "src": "16802:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "16791:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5786, + "nodeType": "ExpressionStatement", + "src": "16791:27:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5790, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5787, + "name": "baseLTVasCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5764, + "src": "16828:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5788, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "16850:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5789, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "baseLTVasCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8303, + "src": "16850:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "16828:49:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5791, + "nodeType": "ExpressionStatement", + "src": "16828:49:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5795, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5792, + "name": "liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5766, + "src": "16887:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5793, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "16910:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5794, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 8305, + "src": "16910:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "16887:51:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 5796, + "nodeType": "ExpressionStatement", + "src": "16887:51:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5800, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5797, + "name": "usageAsCollateralEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5768, + "src": "16948:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5798, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "16975:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5799, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "16975:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "16948:59:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 5801, + "nodeType": "ExpressionStatement", + "src": "16948:59:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5805, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5802, + "name": "fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5770, + "src": "17017:22:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5803, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "17042:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5804, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "isFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8321, + "src": "17042:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "17017:57:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 5806, + "nodeType": "ExpressionStatement", + "src": "17017:57:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5810, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5807, + "name": "borrowingEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5772, + "src": "17084:16:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5808, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5777, + "src": "17103:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5809, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "17103:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "17084:43:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 5811, + "nodeType": "ExpressionStatement", + "src": "17084:43:25" + } + ] + }, + "documentation": "@dev this function aggregates the configuration parameters of the reserve.\n It's used in the LendingPoolDataProvider specifically to save gas, and avoid\n multiple external contract calls to fetch the same data.", + "id": 5813, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveConfiguration", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5760, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5759, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16446:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5758, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "16446:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "16445:18:25" + }, + "returnParameters": { + "id": 5773, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5762, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16511:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5761, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "16511:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5764, + "name": "baseLTVasCollateral", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16537:27:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5763, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "16537:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5766, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16574:28:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5765, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "16574:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5768, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16612:29:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5767, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "16612:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5770, + "name": "fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16651:27:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5769, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "16651:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5772, + "name": "borrowingEnabled", + "nodeType": "VariableDeclaration", + "scope": 5813, + "src": "16688:21:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5771, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "16688:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "16510:200:25" + }, + "scope": 6682, + "src": "16413:721:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5831, + "nodeType": "Block", + "src": "17222:118:25", + "statements": [ + { + "assignments": [ + 5823 + ], + "declarations": [ + { + "constant": false, + "id": 5823, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5831, + "src": "17232:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5822, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "17232:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5827, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5824, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "17274:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5826, + "indexExpression": { + "argumentTypes": null, + "id": 5825, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5815, + "src": "17283:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "17274:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17232:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5828, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5823, + "src": "17309:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5829, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "17309:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 5819, + "id": 5830, + "nodeType": "Return", + "src": "17302:31:25" + } + ] + }, + "documentation": null, + "id": 5832, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isReserveBorrowingEnabled", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5816, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5815, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5832, + "src": "17175:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5814, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "17175:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17174:18:25" + }, + "returnParameters": { + "id": 5819, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5818, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5832, + "src": "17216:4:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5817, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "17216:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17215:6:25" + }, + "scope": 6682, + "src": "17140:200:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5850, + "nodeType": "Block", + "src": "17436:126:25", + "statements": [ + { + "assignments": [ + 5842 + ], + "declarations": [ + { + "constant": false, + "id": 5842, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5850, + "src": "17446:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5841, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "17446:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5846, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5843, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "17488:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5845, + "indexExpression": { + "argumentTypes": null, + "id": 5844, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5834, + "src": "17497:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "17488:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17446:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5847, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5842, + "src": "17523:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5848, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "17523:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 5838, + "id": 5849, + "nodeType": "Return", + "src": "17516:39:25" + } + ] + }, + "documentation": null, + "id": 5851, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isReserveUsageAsCollateralEnabled", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5835, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5834, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5851, + "src": "17389:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5833, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "17389:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17388:18:25" + }, + "returnParameters": { + "id": 5838, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5837, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5851, + "src": "17430:4:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5836, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "17430:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17429:6:25" + }, + "scope": 6682, + "src": "17346:216:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5869, + "nodeType": "Block", + "src": "17659:126:25", + "statements": [ + { + "assignments": [ + 5861 + ], + "declarations": [ + { + "constant": false, + "id": 5861, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5869, + "src": "17669:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5860, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "17669:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5865, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5862, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "17711:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5864, + "indexExpression": { + "argumentTypes": null, + "id": 5863, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5853, + "src": "17720:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "17711:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17669:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5866, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5861, + "src": "17746:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5867, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "isFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8321, + "src": "17746:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 5857, + "id": 5868, + "nodeType": "Return", + "src": "17739:39:25" + } + ] + }, + "documentation": null, + "id": 5870, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveIsFixedBorrowRateEnabled", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5854, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5853, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5870, + "src": "17612:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5852, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "17612:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17611:18:25" + }, + "returnParameters": { + "id": 5857, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5856, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5870, + "src": "17653:4:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5855, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "17653:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17652:6:25" + }, + "scope": 6682, + "src": "17568:217:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5888, + "nodeType": "Block", + "src": "17865:110:25", + "statements": [ + { + "assignments": [ + 5880 + ], + "declarations": [ + { + "constant": false, + "id": 5880, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5888, + "src": "17875:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5879, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "17875:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5884, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5881, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "17917:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5883, + "indexExpression": { + "argumentTypes": null, + "id": 5882, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5872, + "src": "17926:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "17917:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "17875:60:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5885, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5880, + "src": "17952:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5886, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "isActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 8323, + "src": "17952:16:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 5876, + "id": 5887, + "nodeType": "Return", + "src": "17945:23:25" + } + ] + }, + "documentation": null, + "id": 5889, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveIsActive", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5873, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5872, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5889, + "src": "17819:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5871, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "17819:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17818:18:25" + }, + "returnParameters": { + "id": 5876, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5875, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5889, + "src": "17859:4:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5874, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "17859:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "17858:6:25" + }, + "scope": 6682, + "src": "17791:184:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5909, + "nodeType": "Block", + "src": "18071:126:25", + "statements": [ + { + "assignments": [ + 5899 + ], + "declarations": [ + { + "constant": false, + "id": 5899, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 5909, + "src": "18081:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5898, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "18081:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5903, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5900, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "18123:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 5902, + "indexExpression": { + "argumentTypes": null, + "id": 5901, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5891, + "src": "18132:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18123:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "18081:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 5907, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 5904, + "name": "timestamp", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5894, + "src": "18151:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5905, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5899, + "src": "18163:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 5906, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8315, + "src": "18163:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "src": "18151:39:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "id": 5908, + "nodeType": "ExpressionStatement", + "src": "18151:39:25" + } + ] + }, + "documentation": null, + "id": 5910, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveLastUpdate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5892, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5891, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5910, + "src": "18012:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5890, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18012:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18011:18:25" + }, + "returnParameters": { + "id": 5895, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5894, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 5910, + "src": "18053:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 5893, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "18053:6:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18052:18:25" + }, + "scope": 6682, + "src": "17982:215:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5932, + "nodeType": "Block", + "src": "18384:130:25", + "statements": [ + { + "assignments": [ + 5922 + ], + "declarations": [ + { + "constant": false, + "id": 5922, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5932, + "src": "18394:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5921, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "18394:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5928, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5923, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "18437:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5925, + "indexExpression": { + "argumentTypes": null, + "id": 5924, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5914, + "src": "18454:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18437:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5927, + "indexExpression": { + "argumentTypes": null, + "id": 5926, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5912, + "src": "18461:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18437:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "18394:76:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5929, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5922, + "src": "18487:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5930, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "useAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8282, + "src": "18487:20:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 5918, + "id": 5931, + "nodeType": "Return", + "src": "18480:27:25" + } + ] + }, + "documentation": "****************\n@dev user accessors*****************", + "id": 5933, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isUserUseReserveAsCollateralEnabled", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5915, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5912, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5933, + "src": "18322:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5911, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18322:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5914, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5933, + "src": "18340:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5913, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18340:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18321:33:25" + }, + "returnParameters": { + "id": 5918, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5917, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5933, + "src": "18378:4:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 5916, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "18378:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18377:6:25" + }, + "scope": 6682, + "src": "18277:237:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5955, + "nodeType": "Block", + "src": "18615:129:25", + "statements": [ + { + "assignments": [ + 5945 + ], + "declarations": [ + { + "constant": false, + "id": 5945, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5955, + "src": "18625:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5944, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "18625:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5951, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5946, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "18668:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5948, + "indexExpression": { + "argumentTypes": null, + "id": 5947, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5937, + "src": "18685:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18668:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5950, + "indexExpression": { + "argumentTypes": null, + "id": 5949, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5935, + "src": "18692:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18668:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "18625:76:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5952, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5945, + "src": "18718:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5953, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "originationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 8276, + "src": "18718:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5941, + "id": 5954, + "nodeType": "Return", + "src": "18711:26:25" + } + ] + }, + "documentation": null, + "id": 5956, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserOriginationFee", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5938, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5935, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5956, + "src": "18550:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5934, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18550:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5937, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5956, + "src": "18568:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5936, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18568:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18549:33:25" + }, + "returnParameters": { + "id": 5941, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5940, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5956, + "src": "18606:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5939, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "18606:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18605:9:25" + }, + "scope": 6682, + "src": "18519:225:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 5987, + "nodeType": "Block", + "src": "18900:211:25", + "statements": [ + { + "assignments": [ + 5968 + ], + "declarations": [ + { + "constant": false, + "id": 5968, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 5987, + "src": "18910:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5967, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "18910:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 5974, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 5969, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "18953:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 5971, + "indexExpression": { + "argumentTypes": null, + "id": 5970, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5960, + "src": "18970:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18953:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 5973, + "indexExpression": { + "argumentTypes": null, + "id": 5972, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5958, + "src": "18977:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "18953:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "18910:76:25" + }, + { + "expression": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 5978, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5975, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5968, + "src": "19003:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 5976, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "19003:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 5977, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "19026:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "19003:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5982, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "19067:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5983, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "19067:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5984, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "VARIABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "19067:37:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "id": 5985, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "19003:101:25", + "trueExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 5979, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "19030:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 5980, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "19030:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 5981, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "19030:34:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "functionReturnParameters": 5964, + "id": 5986, + "nodeType": "Return", + "src": "18996:108:25" + } + ] + }, + "documentation": null, + "id": 5988, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserCurrentBorrowRateMode", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5961, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5958, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 5988, + "src": "18788:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5957, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18788:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5960, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 5988, + "src": "18806:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5959, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "18806:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18787:33:25" + }, + "returnParameters": { + "id": 5964, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5963, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 5988, + "src": "18866:28:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 5962, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "18866:28:25", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "18865:30:25" + }, + "scope": 6682, + "src": "18750:361:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 6010, + "nodeType": "Block", + "src": "19221:130:25", + "statements": [ + { + "assignments": [ + 6000 + ], + "declarations": [ + { + "constant": false, + "id": 6000, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 6010, + "src": "19231:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 5999, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "19231:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6006, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6001, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "19274:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 6003, + "indexExpression": { + "argumentTypes": null, + "id": 6002, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5992, + "src": "19291:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "19274:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 6005, + "indexExpression": { + "argumentTypes": null, + "id": 6004, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 5990, + "src": "19298:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "19274:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "19231:76:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6007, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6000, + "src": "19324:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 6008, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "fixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8278, + "src": "19324:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 5996, + "id": 6009, + "nodeType": "Return", + "src": "19317:27:25" + } + ] + }, + "documentation": null, + "id": 6011, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserCurrentFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 5993, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5990, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6011, + "src": "19156:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5989, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "19156:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 5992, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6011, + "src": "19174:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 5991, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "19174:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "19155:33:25" + }, + "returnParameters": { + "id": 5996, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 5995, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 6011, + "src": "19212:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 5994, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "19212:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "19211:9:25" + }, + "scope": 6682, + "src": "19117:234:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6062, + "nodeType": "Block", + "src": "19597:443:25", + "statements": [ + { + "assignments": [ + 6027 + ], + "declarations": [ + { + "constant": false, + "id": 6027, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 6062, + "src": "19608:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6026, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "19608:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6033, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6028, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "19651:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 6030, + "indexExpression": { + "argumentTypes": null, + "id": 6029, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6015, + "src": "19668:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "19651:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 6032, + "indexExpression": { + "argumentTypes": null, + "id": 6031, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6013, + "src": "19675:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "19651:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "19608:76:25" + }, + { + "assignments": [ + 6037 + ], + "declarations": [ + { + "constant": false, + "id": 6037, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6062, + "src": "19694:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6036, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "19694:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6041, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6038, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "19736:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6040, + "indexExpression": { + "argumentTypes": null, + "id": 6039, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6013, + "src": "19745:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "19736:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "19694:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6045, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6042, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6018, + "src": "19765:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6043, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6027, + "src": "19790:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 6044, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8272, + "src": "19790:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "19765:52:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6046, + "nodeType": "ExpressionStatement", + "src": "19765:52:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6053, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6047, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6020, + "src": "19827:23:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6050, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6027, + "src": "19909:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + { + "argumentTypes": null, + "id": 6051, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6037, + "src": "19931:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + }, + { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + ], + "expression": { + "argumentTypes": null, + "id": 6048, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "19853:11:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 6049, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getCompoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 8734, + "src": "19853:38:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_UserReserveData_$8283_storage_ptr_$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$", + "typeString": "function (struct CoreLibrary.UserReserveData storage pointer,struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 6052, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19853:99:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "19827:125:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6054, + "nodeType": "ExpressionStatement", + "src": "19827:125:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6060, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6055, + "name": "compoundedAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6022, + "src": "19963:16:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6058, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6018, + "src": "20010:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6056, + "name": "compoundedBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6020, + "src": "19982:23:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6057, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "19982:27:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6059, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "19982:51:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "19963:70:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6061, + "nodeType": "ExpressionStatement", + "src": "19963:70:25" + } + ] + }, + "documentation": null, + "id": 6063, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserBorrowBalances", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6016, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6013, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6063, + "src": "19397:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6012, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "19397:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6015, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6063, + "src": "19423:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6014, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "19423:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "19387:50:25" + }, + "returnParameters": { + "id": 6023, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6018, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 6063, + "src": "19482:30:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6017, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "19482:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6020, + "name": "compoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 6063, + "src": "19526:31:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6019, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "19526:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6022, + "name": "compoundedAmount", + "nodeType": "VariableDeclaration", + "scope": 6063, + "src": "19571:24:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6021, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "19571:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "19468:128:25" + }, + "scope": 6682, + "src": "19357:683:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6085, + "nodeType": "Block", + "src": "20157:148:25", + "statements": [ + { + "assignments": [ + 6075 + ], + "declarations": [ + { + "constant": false, + "id": 6075, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 6085, + "src": "20167:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6074, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "20167:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6081, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6076, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "20210:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 6078, + "indexExpression": { + "argumentTypes": null, + "id": 6077, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6067, + "src": "20227:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "20210:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 6080, + "indexExpression": { + "argumentTypes": null, + "id": 6079, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6065, + "src": "20234:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "20210:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "20167:76:25" + }, + { + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6082, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6075, + "src": "20260:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 6083, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8274, + "src": "20260:38:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 6071, + "id": 6084, + "nodeType": "Return", + "src": "20253:45:25" + } + ] + }, + "documentation": null, + "id": 6086, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserVariableBorrowCumulativeIndex", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6068, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6065, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6086, + "src": "20092:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6064, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20092:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6067, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6086, + "src": "20110:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6066, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20110:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20091:33:25" + }, + "returnParameters": { + "id": 6071, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6070, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 6086, + "src": "20148:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6069, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "20148:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20147:9:25" + }, + "scope": 6682, + "src": "20046:259:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6110, + "nodeType": "Block", + "src": "20441:139:25", + "statements": [ + { + "assignments": [ + 6098 + ], + "declarations": [ + { + "constant": false, + "id": 6098, + "name": "user", + "nodeType": "VariableDeclaration", + "scope": 6110, + "src": "20451:40:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6097, + "name": "CoreLibrary.UserReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8283, + "src": "20451:27:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6104, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6099, + "name": "usersReserveData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4763, + "src": "20494:16:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$_$", + "typeString": "mapping(address => mapping(address => struct CoreLibrary.UserReserveData storage ref))" + } + }, + "id": 6101, + "indexExpression": { + "argumentTypes": null, + "id": 6100, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6090, + "src": "20511:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "20494:23:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_UserReserveData_$8283_storage_$", + "typeString": "mapping(address => struct CoreLibrary.UserReserveData storage ref)" + } + }, + "id": 6103, + "indexExpression": { + "argumentTypes": null, + "id": 6102, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6088, + "src": "20518:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "20494:33:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage", + "typeString": "struct CoreLibrary.UserReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "20451:76:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6108, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6105, + "name": "timestamp", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6093, + "src": "20537:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6106, + "name": "user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6098, + "src": "20549:4:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserReserveData_$8283_storage_ptr", + "typeString": "struct CoreLibrary.UserReserveData storage pointer" + } + }, + "id": 6107, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastUpdateTimestamp", + "nodeType": "MemberAccess", + "referencedDeclaration": 8280, + "src": "20549:24:25", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "src": "20537:36:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6109, + "nodeType": "ExpressionStatement", + "src": "20537:36:25" + } + ] + }, + "documentation": null, + "id": 6111, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserLastUpdate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6091, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6088, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6111, + "src": "20338:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6087, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20338:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6090, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6111, + "src": "20356:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6089, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20356:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20337:33:25" + }, + "returnParameters": { + "id": 6094, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6093, + "name": "timestamp", + "nodeType": "VariableDeclaration", + "scope": 6111, + "src": "20418:17:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6092, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "20418:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20417:19:25" + }, + "scope": 6682, + "src": "20311:269:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6124, + "nodeType": "Block", + "src": "20715:70:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6118, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "20732:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6120, + "indexExpression": { + "argumentTypes": null, + "id": 6119, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6113, + "src": "20741:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "20732:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6121, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveUtilizationRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8354, + "src": "20732:44:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_struct$_ReserveData_$8324_storage_ptr_$returns$_t_uint256_$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer) view returns (uint256)" + } + }, + "id": 6122, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "20732:46:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 6117, + "id": 6123, + "nodeType": "Return", + "src": "20725:53:25" + } + ] + }, + "documentation": "@dev utility functions", + "id": 6125, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveUtilizationRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6114, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6113, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6125, + "src": "20665:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6112, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20665:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20664:18:25" + }, + "returnParameters": { + "id": 6117, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6116, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 6125, + "src": "20706:7:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6115, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "20706:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20705:9:25" + }, + "scope": 6682, + "src": "20630:155:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6133, + "nodeType": "Block", + "src": "20855:36:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6131, + "name": "reservesList", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4766, + "src": "20872:12:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage", + "typeString": "address[] storage ref" + } + }, + "functionReturnParameters": 6130, + "id": 6132, + "nodeType": "Return", + "src": "20865:19:25" + } + ] + }, + "documentation": null, + "id": 6134, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserves", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6126, + "nodeType": "ParameterList", + "parameters": [], + "src": "20811:2:25" + }, + "returnParameters": { + "id": 6130, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6129, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 6134, + "src": "20837:16:25", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 6127, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20837:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 6128, + "length": null, + "nodeType": "ArrayTypeName", + "src": "20837:9:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20836:18:25" + }, + "scope": 6682, + "src": "20791:100:25", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6150, + "nodeType": "Block", + "src": "21048:119:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6145, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6141, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "21059:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6143, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6136, + "src": "21108:18:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6142, + "name": "LendingPoolAddressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1357, + "src": "21079:28:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolAddressesProvider_$1357_$", + "typeString": "type(contract LendingPoolAddressesProvider)" + } + }, + "id": 6144, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21079:48:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "21059:68:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6146, + "nodeType": "ExpressionStatement", + "src": "21059:68:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 6147, + "name": "refreshConfigInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6639, + "src": "21137:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$", + "typeString": "function ()" + } + }, + "id": 6148, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21137:23:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6149, + "nodeType": "ExpressionStatement", + "src": "21137:23:25" + } + ] + }, + "documentation": "@dev Core configuration functions", + "id": 6151, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6139, + "modifierName": { + "argumentTypes": null, + "id": 6138, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "21020:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "21020:27:25" + } + ], + "name": "setAddressesProvider", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6137, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6136, + "name": "_addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 6151, + "src": "20982:26:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6135, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "20982:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "20981:29:25" + }, + "returnParameters": { + "id": 6140, + "nodeType": "ParameterList", + "parameters": [], + "src": "21048:0:25" + }, + "scope": 6682, + "src": "20952:215:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6159, + "nodeType": "Block", + "src": "21242:40:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 6156, + "name": "refreshConfigInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6639, + "src": "21252:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$__$returns$__$", + "typeString": "function ()" + } + }, + "id": 6157, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21252:23:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6158, + "nodeType": "ExpressionStatement", + "src": "21252:23:25" + } + ] + }, + "documentation": null, + "id": 6160, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6154, + "modifierName": { + "argumentTypes": null, + "id": 6153, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "21214:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "21214:27:25" + } + ], + "name": "refreshConfiguration", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6152, + "nodeType": "ParameterList", + "parameters": [], + "src": "21202:2:25" + }, + "returnParameters": { + "id": 6155, + "nodeType": "ParameterList", + "parameters": [], + "src": "21242:0:25" + }, + "scope": 6682, + "src": "21173:109:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6186, + "nodeType": "Block", + "src": "21465:142:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6177, + "name": "_aTokenAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6164, + "src": "21499:14:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 6178, + "name": "_decimals", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6166, + "src": "21515:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 6179, + "name": "_interestRateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6168, + "src": "21526:28:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6173, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "21475:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6175, + "indexExpression": { + "argumentTypes": null, + "id": 6174, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6162, + "src": "21484:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "21475:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6176, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "init", + "nodeType": "MemberAccess", + "referencedDeclaration": 8545, + "src": "21475:23:25", + "typeDescriptions": { + "typeIdentifier": "t_function_delegatecall_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_address_$_t_uint256_$_t_address_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,address,uint256,address)" + } + }, + "id": 6180, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21475:80:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6181, + "nodeType": "ExpressionStatement", + "src": "21475:80:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6183, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6162, + "src": "21590:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6182, + "name": "addReserveToListInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6681, + "src": "21565:24:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 6184, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21565:34:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6185, + "nodeType": "ExpressionStatement", + "src": "21565:34:25" + } + ] + }, + "documentation": null, + "id": 6187, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6171, + "modifierName": { + "argumentTypes": null, + "id": 6170, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "21433:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "21433:27:25" + } + ], + "name": "initReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6169, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6162, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6187, + "src": "21309:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6161, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21309:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6164, + "name": "_aTokenAddress", + "nodeType": "VariableDeclaration", + "scope": 6187, + "src": "21327:22:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6163, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21327:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6166, + "name": "_decimals", + "nodeType": "VariableDeclaration", + "scope": 6187, + "src": "21351:17:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6165, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "21351:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6168, + "name": "_interestRateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 6187, + "src": "21370:36:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6167, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21370:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "21308:99:25" + }, + "returnParameters": { + "id": 6172, + "nodeType": "ParameterList", + "parameters": [], + "src": "21465:0:25" + }, + "scope": 6682, + "src": "21288:319:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6203, + "nodeType": "Block", + "src": "21745:86:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6201, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6196, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "21755:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6198, + "indexExpression": { + "argumentTypes": null, + "id": 6197, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6189, + "src": "21764:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "21755:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6199, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "interestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 8313, + "src": "21755:46:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 6200, + "name": "_rateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6191, + "src": "21804:20:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "21755:69:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 6202, + "nodeType": "ExpressionStatement", + "src": "21755:69:25" + } + ] + }, + "documentation": null, + "id": 6204, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6194, + "modifierName": { + "argumentTypes": null, + "id": 6193, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "21717:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "21717:27:25" + } + ], + "name": "setReserveInterestRateStrategyAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6192, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6189, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6204, + "src": "21660:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6188, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21660:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6191, + "name": "_rateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 6204, + "src": "21678:28:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6190, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21678:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "21659:48:25" + }, + "returnParameters": { + "id": 6195, + "nodeType": "ParameterList", + "parameters": [], + "src": "21745:0:25" + }, + "scope": 6682, + "src": "21613:218:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6220, + "nodeType": "Block", + "src": "21978:76:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6217, + "name": "_fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6208, + "src": "22023:23:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6213, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "21988:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6215, + "indexExpression": { + "argumentTypes": null, + "id": 6214, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6206, + "src": "21997:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "21988:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6216, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "enableBorrowing", + "nodeType": "MemberAccess", + "referencedDeclaration": 8573, + "src": "21988:34:25", + "typeDescriptions": { + "typeIdentifier": "t_function_delegatecall_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_bool_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,bool)" + } + }, + "id": 6218, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "21988:59:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6219, + "nodeType": "ExpressionStatement", + "src": "21988:59:25" + } + ] + }, + "documentation": null, + "id": 6221, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6211, + "modifierName": { + "argumentTypes": null, + "id": 6210, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "21950:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "21950:27:25" + } + ], + "name": "enableBorrowingOnReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6209, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6206, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6221, + "src": "21880:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6205, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "21880:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6208, + "name": "_fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 6221, + "src": "21906:28:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 6207, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "21906:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "21870:70:25" + }, + "returnParameters": { + "id": 6212, + "nodeType": "ParameterList", + "parameters": [], + "src": "21978:0:25" + }, + "scope": 6682, + "src": "21837:217:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6234, + "nodeType": "Block", + "src": "22150:54:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6228, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "22160:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6230, + "indexExpression": { + "argumentTypes": null, + "id": 6229, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6223, + "src": "22169:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "22160:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6231, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "disableBorrowing", + "nodeType": "MemberAccess", + "referencedDeclaration": 8585, + "src": "22160:35:25", + "typeDescriptions": { + "typeIdentifier": "t_function_delegatecall_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer)" + } + }, + "id": 6232, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22160:37:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6233, + "nodeType": "ExpressionStatement", + "src": "22160:37:25" + } + ] + }, + "documentation": null, + "id": 6235, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6226, + "modifierName": { + "argumentTypes": null, + "id": 6225, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "22122:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "22122:27:25" + } + ], + "name": "disableBorrowingOnReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6224, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6223, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6235, + "src": "22095:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6222, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "22095:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "22094:18:25" + }, + "returnParameters": { + "id": 6227, + "nodeType": "ParameterList", + "parameters": [], + "src": "22150:0:25" + }, + "scope": 6682, + "src": "22060:144:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6254, + "nodeType": "Block", + "src": "22381:99:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6250, + "name": "_baseLTVasCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6239, + "src": "22429:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 6251, + "name": "_liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6241, + "src": "22451:21:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6246, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "22391:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6248, + "indexExpression": { + "argumentTypes": null, + "id": 6247, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6237, + "src": "22400:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "22391:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6249, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "enableAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8634, + "src": "22391:37:25", + "typeDescriptions": { + "typeIdentifier": "t_function_delegatecall_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$_t_uint256_$_t_uint256_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer,uint256,uint256)" + } + }, + "id": 6252, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22391:82:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6253, + "nodeType": "ExpressionStatement", + "src": "22391:82:25" + } + ] + }, + "documentation": null, + "id": 6255, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6244, + "modifierName": { + "argumentTypes": null, + "id": 6243, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "22349:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "22349:27:25" + } + ], + "name": "enableReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6242, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6237, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6255, + "src": "22245:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6236, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "22245:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6239, + "name": "_baseLTVasCollateral", + "nodeType": "VariableDeclaration", + "scope": 6255, + "src": "22263:28:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6238, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "22263:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6241, + "name": "_liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 6255, + "src": "22293:29:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6240, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "22293:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "22244:79:25" + }, + "returnParameters": { + "id": 6245, + "nodeType": "ParameterList", + "parameters": [], + "src": "22381:0:25" + }, + "scope": 6682, + "src": "22210:270:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6268, + "nodeType": "Block", + "src": "22577:57:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6262, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "22587:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6264, + "indexExpression": { + "argumentTypes": null, + "id": 6263, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6257, + "src": "22596:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "22587:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "id": 6265, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "disableAsCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8646, + "src": "22587:38:25", + "typeDescriptions": { + "typeIdentifier": "t_function_delegatecall_nonpayable$_t_struct$_ReserveData_$8324_storage_ptr_$returns$__$bound_to$_t_struct$_ReserveData_$8324_storage_ptr_$", + "typeString": "function (struct CoreLibrary.ReserveData storage pointer)" + } + }, + "id": 6266, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "22587:40:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6267, + "nodeType": "ExpressionStatement", + "src": "22587:40:25" + } + ] + }, + "documentation": null, + "id": 6269, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6260, + "modifierName": { + "argumentTypes": null, + "id": 6259, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "22549:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "22549:27:25" + } + ], + "name": "disableReserveAsCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6258, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6257, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6269, + "src": "22522:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6256, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "22522:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "22521:18:25" + }, + "returnParameters": { + "id": 6261, + "nodeType": "ParameterList", + "parameters": [], + "src": "22577:0:25" + }, + "scope": 6682, + "src": "22486:148:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6290, + "nodeType": "Block", + "src": "22733:126:25", + "statements": [ + { + "assignments": [ + 6279 + ], + "declarations": [ + { + "constant": false, + "id": 6279, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6290, + "src": "22743:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6278, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "22743:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6283, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6280, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "22785:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6282, + "indexExpression": { + "argumentTypes": null, + "id": 6281, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6271, + "src": "22794:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "22785:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "22743:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6288, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6284, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6279, + "src": "22813:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6286, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8321, + "src": "22813:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 6287, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "22848:4:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "22813:39:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6289, + "nodeType": "ExpressionStatement", + "src": "22813:39:25" + } + ] + }, + "documentation": null, + "id": 6291, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6274, + "modifierName": { + "argumentTypes": null, + "id": 6273, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "22705:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "22705:27:25" + } + ], + "name": "enableReserveFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6272, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6271, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6291, + "src": "22678:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6270, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "22678:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "22677:18:25" + }, + "returnParameters": { + "id": 6275, + "nodeType": "ParameterList", + "parameters": [], + "src": "22733:0:25" + }, + "scope": 6682, + "src": "22640:219:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6312, + "nodeType": "Block", + "src": "22959:127:25", + "statements": [ + { + "assignments": [ + 6301 + ], + "declarations": [ + { + "constant": false, + "id": 6301, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6312, + "src": "22969:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6300, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "22969:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6305, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6302, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "23011:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6304, + "indexExpression": { + "argumentTypes": null, + "id": 6303, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6293, + "src": "23020:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "23011:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "22969:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6310, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6306, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6301, + "src": "23039:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6308, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isFixedBorrowRateEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8321, + "src": "23039:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 6309, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23074:5:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "23039:40:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6311, + "nodeType": "ExpressionStatement", + "src": "23039:40:25" + } + ] + }, + "documentation": null, + "id": 6313, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6296, + "modifierName": { + "argumentTypes": null, + "id": 6295, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "22931:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "22931:27:25" + } + ], + "name": "disableReserveFixedBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6294, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6293, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6313, + "src": "22904:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6292, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "22904:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "22903:18:25" + }, + "returnParameters": { + "id": 6297, + "nodeType": "ParameterList", + "parameters": [], + "src": "22959:0:25" + }, + "scope": 6682, + "src": "22865:221:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6347, + "nodeType": "Block", + "src": "23172:305:25", + "statements": [ + { + "assignments": [ + 6323 + ], + "declarations": [ + { + "constant": false, + "id": 6323, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6347, + "src": "23182:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6322, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "23182:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6327, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6324, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "23224:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6326, + "indexExpression": { + "argumentTypes": null, + "id": 6325, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6315, + "src": "23233:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "23224:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "23182:60:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 6337, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6332, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6329, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6323, + "src": "23274:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6330, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8287, + "src": "23274:36:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6331, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23313:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "23274:40:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "&&", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6336, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6333, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6323, + "src": "23330:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6334, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "lastVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 8301, + "src": "23330:41:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6335, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23374:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "23330:45:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "23274:101:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5265736572766520686173206e6f74206265656e20696e697469616c697a656420796574", + "id": 6338, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23389:38:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8e3fef771b2ec0a89d942c2f01fa56a2858b26f42bd351d7e7ecb9e7b2b9bd44", + "typeString": "literal_string \"Reserve has not been initialized yet\"" + }, + "value": "Reserve has not been initialized yet" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_8e3fef771b2ec0a89d942c2f01fa56a2858b26f42bd351d7e7ecb9e7b2b9bd44", + "typeString": "literal_string \"Reserve has not been initialized yet\"" + } + ], + "id": 6328, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "23253:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6339, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "23253:184:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6340, + "nodeType": "ExpressionStatement", + "src": "23253:184:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6345, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6341, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6323, + "src": "23447:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6343, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 8323, + "src": "23447:16:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 6344, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23466:4:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "23447:23:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6346, + "nodeType": "ExpressionStatement", + "src": "23447:23:25" + } + ] + }, + "documentation": null, + "id": 6348, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6318, + "modifierName": { + "argumentTypes": null, + "id": 6317, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "23144:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "23144:27:25" + } + ], + "name": "activateReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6316, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6315, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6348, + "src": "23117:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6314, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "23117:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "23116:18:25" + }, + "returnParameters": { + "id": 6319, + "nodeType": "ParameterList", + "parameters": [], + "src": "23172:0:25" + }, + "scope": 6682, + "src": "23092:385:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6369, + "nodeType": "Block", + "src": "23565:111:25", + "statements": [ + { + "assignments": [ + 6358 + ], + "declarations": [ + { + "constant": false, + "id": 6358, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6369, + "src": "23575:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6357, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "23575:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6362, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6359, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "23617:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6361, + "indexExpression": { + "argumentTypes": null, + "id": 6360, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6350, + "src": "23626:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "23617:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "23575:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6367, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6363, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6358, + "src": "23645:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6365, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 8323, + "src": "23645:16:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 6366, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "23664:5:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "src": "23645:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6368, + "nodeType": "ExpressionStatement", + "src": "23645:24:25" + } + ] + }, + "documentation": null, + "id": 6370, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6353, + "modifierName": { + "argumentTypes": null, + "id": 6352, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "23537:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "23537:27:25" + } + ], + "name": "deactivateReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6351, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6350, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6370, + "src": "23510:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6349, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "23510:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "23509:18:25" + }, + "returnParameters": { + "id": 6354, + "nodeType": "ParameterList", + "parameters": [], + "src": "23565:0:25" + }, + "scope": 6682, + "src": "23483:193:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6393, + "nodeType": "Block", + "src": "23955:121:25", + "statements": [ + { + "assignments": [ + 6382 + ], + "declarations": [ + { + "constant": false, + "id": 6382, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6393, + "src": "23965:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6381, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "23965:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6386, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6383, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "24007:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6385, + "indexExpression": { + "argumentTypes": null, + "id": 6384, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6372, + "src": "24016:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "24007:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "23965:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6391, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6387, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6382, + "src": "24035:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6389, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "baseLTVasCollateral", + "nodeType": "MemberAccess", + "referencedDeclaration": 8303, + "src": "24035:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 6390, + "name": "_ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6374, + "src": "24065:4:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "24035:34:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6392, + "nodeType": "ExpressionStatement", + "src": "24035:34:25" + } + ] + }, + "documentation": "*************\n@dev functions to update available collaterals\n@dev the interest rate and the ltv are expressed in percentage", + "id": 6394, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6377, + "modifierName": { + "argumentTypes": null, + "id": 6376, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "23927:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "23927:27:25" + } + ], + "name": "setReserveBaseLTVasCollateral", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6375, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6372, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6394, + "src": "23870:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6371, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "23870:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6374, + "name": "_ltv", + "nodeType": "VariableDeclaration", + "scope": 6394, + "src": "23888:12:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6373, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "23888:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "23869:32:25" + }, + "returnParameters": { + "id": 6378, + "nodeType": "ParameterList", + "parameters": [], + "src": "23955:0:25" + }, + "scope": 6682, + "src": "23831:245:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6417, + "nodeType": "Block", + "src": "24217:128:25", + "statements": [ + { + "assignments": [ + 6406 + ], + "declarations": [ + { + "constant": false, + "id": 6406, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6417, + "src": "24227:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6405, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "24227:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6410, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6407, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "24269:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6409, + "indexExpression": { + "argumentTypes": null, + "id": 6408, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6396, + "src": "24278:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "24269:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "24227:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6415, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6411, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6406, + "src": "24297:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6413, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 8305, + "src": "24297:28:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 6414, + "name": "_threshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6398, + "src": "24328:10:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "24297:41:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6416, + "nodeType": "ExpressionStatement", + "src": "24297:41:25" + } + ] + }, + "documentation": null, + "id": 6418, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6401, + "modifierName": { + "argumentTypes": null, + "id": 6400, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "24185:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "24185:27:25" + } + ], + "name": "setReserveLiquidationThreshold", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6399, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6396, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6418, + "src": "24122:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6395, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24122:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6398, + "name": "_threshold", + "nodeType": "VariableDeclaration", + "scope": 6418, + "src": "24140:18:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6397, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "24140:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "24121:38:25" + }, + "returnParameters": { + "id": 6402, + "nodeType": "ParameterList", + "parameters": [], + "src": "24217:0:25" + }, + "scope": 6682, + "src": "24082:263:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6441, + "nodeType": "Block", + "src": "24484:126:25", + "statements": [ + { + "assignments": [ + 6430 + ], + "declarations": [ + { + "constant": false, + "id": 6430, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6441, + "src": "24494:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6429, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "24494:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6434, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6431, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "24536:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6433, + "indexExpression": { + "argumentTypes": null, + "id": 6432, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6420, + "src": "24545:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "24536:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "24494:60:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6439, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6435, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6430, + "src": "24564:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6437, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 8307, + "src": "24564:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 6438, + "name": "_discount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6422, + "src": "24594:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "24564:39:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6440, + "nodeType": "ExpressionStatement", + "src": "24564:39:25" + } + ] + }, + "documentation": null, + "id": 6442, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6425, + "modifierName": { + "argumentTypes": null, + "id": 6424, + "name": "onlyLendingPoolConfigurator", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4720, + "src": "24452:27:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "24452:27:25" + } + ], + "name": "setReserveLiquidationDiscount", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6423, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6420, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6442, + "src": "24390:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6419, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24390:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6422, + "name": "_discount", + "nodeType": "VariableDeclaration", + "scope": 6442, + "src": "24408:17:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6421, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "24408:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "24389:37:25" + }, + "returnParameters": { + "id": 6426, + "nodeType": "ParameterList", + "parameters": [], + "src": "24484:0:25" + }, + "scope": 6682, + "src": "24351:259:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6453, + "nodeType": "Block", + "src": "24701:158:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6446, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "24769:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6447, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "24769:10:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 6448, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isContract", + "nodeType": "MemberAccess", + "referencedDeclaration": 12033, + "src": "24769:21:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$bound_to$_t_address_$", + "typeString": "function (address) view returns (bool)" + } + }, + "id": 6449, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24769:23:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "4f6e6c7920636f6e7472616374732063616e2073656e6420657468657220746f20746865204c656e64696e6720706f6f6c20636f7265", + "id": 6450, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "24794:56:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3fd12f4b5399ab92a8b412386ed256004469c08240f717e3bc9c0c1108d4c226", + "typeString": "literal_string \"Only contracts can send ether to the Lending pool core\"" + }, + "value": "Only contracts can send ether to the Lending pool core" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_3fd12f4b5399ab92a8b412386ed256004469c08240f717e3bc9c0c1108d4c226", + "typeString": "literal_string \"Only contracts can send ether to the Lending pool core\"" + } + ], + "id": 6445, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "24761:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6451, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "24761:90:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6452, + "nodeType": "ExpressionStatement", + "src": "24761:90:25" + } + ] + }, + "documentation": "@notice ETH/token transfer functions", + "id": 6454, + "implemented": true, + "kind": "fallback", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6443, + "nodeType": "ParameterList", + "parameters": [], + "src": "24681:2:25" + }, + "returnParameters": { + "id": 6444, + "nodeType": "ParameterList", + "parameters": [], + "src": "24701:0:25" + }, + "scope": 6682, + "src": "24673:186:25", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6485, + "nodeType": "Block", + "src": "24972:179:25", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 6467, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6465, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6456, + "src": "24986:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 6466, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4690, + "src": "24998:15:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "24986:27:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 6483, + "nodeType": "Block", + "src": "25097:48:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6480, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6460, + "src": "25126:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6477, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6458, + "src": "25111:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 6479, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "25111:14:25", + "typeDescriptions": { + "typeIdentifier": "t_function_transfer_nonpayable$_t_uint256_$returns$__$", + "typeString": "function (uint256)" + } + }, + "id": 6481, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25111:23:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6482, + "nodeType": "ExpressionStatement", + "src": "25111:23:25" + } + ] + }, + "id": 6484, + "nodeType": "IfStatement", + "src": "24982:163:25", + "trueBody": { + "id": 6476, + "nodeType": "Block", + "src": "25014:69:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6472, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6458, + "src": "25057:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 6473, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6460, + "src": "25064:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6469, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6456, + "src": "25034:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6468, + "name": "ERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11659, + "src": "25028:5:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ERC20_$11659_$", + "typeString": "type(contract ERC20)" + } + }, + "id": 6470, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25028:15:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + }, + "id": 6471, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "safeTransfer", + "nodeType": "MemberAccess", + "referencedDeclaration": 11819, + "src": "25028:28:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$11786_$", + "typeString": "function (contract IERC20,address,uint256)" + } + }, + "id": 6474, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25028:44:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6475, + "nodeType": "ExpressionStatement", + "src": "25028:44:25" + } + ] + } + } + ] + }, + "documentation": null, + "id": 6486, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6463, + "modifierName": { + "argumentTypes": null, + "id": 6462, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "24956:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "24956:15:25" + } + ], + "name": "transferToUser", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6461, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6456, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6486, + "src": "24889:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6455, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24889:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6458, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6486, + "src": "24907:21:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 6457, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "24907:15:25", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6460, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 6486, + "src": "24930:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6459, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "24930:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "24888:58:25" + }, + "returnParameters": { + "id": 6464, + "nodeType": "ParameterList", + "parameters": [], + "src": "24972:0:25" + }, + "scope": 6682, + "src": "24865:286:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6536, + "nodeType": "Block", + "src": "25327:388:25", + "statements": [ + { + "assignments": [ + 6500 + ], + "declarations": [ + { + "constant": false, + "id": 6500, + "name": "feeAddress", + "nodeType": "VariableDeclaration", + "scope": 6536, + "src": "25337:26:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 6499, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25337:15:25", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6506, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6503, + "name": "destination", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6494, + "src": "25382:11:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6502, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "25374:7:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint160_$", + "typeString": "type(uint160)" + }, + "typeName": "uint160" + }, + "id": 6504, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25374:20:25", + "typeDescriptions": { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint160", + "typeString": "uint160" + } + ], + "id": 6501, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "25366:7:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 6505, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25366:29:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "25337:58:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 6509, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6507, + "name": "_token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6488, + "src": "25440:6:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 6508, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4690, + "src": "25450:15:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "25440:25:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 6534, + "nodeType": "Block", + "src": "25556:153:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6524, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6521, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "25578:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6522, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "25578:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 6523, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6492, + "src": "25591:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "25578:20:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520616d6f756e7420616e64207468652076616c75652073656e7420746f206465706f73697420646f206e6f74206d61746368", + "id": 6525, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "25600:55:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3ae30f23ff7837445ce2686dd35a110a057a45b669d9773b552977a0705cedbe", + "typeString": "literal_string \"The amount and the value sent to deposit do not match\"" + }, + "value": "The amount and the value sent to deposit do not match" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_3ae30f23ff7837445ce2686dd35a110a057a45b669d9773b552977a0705cedbe", + "typeString": "literal_string \"The amount and the value sent to deposit do not match\"" + } + ], + "id": 6520, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "25570:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6526, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25570:86:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6527, + "nodeType": "ExpressionStatement", + "src": "25570:86:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6531, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6492, + "src": "25690:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6528, + "name": "feeAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6500, + "src": "25670:10:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 6530, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "25670:19:25", + "typeDescriptions": { + "typeIdentifier": "t_function_transfer_nonpayable$_t_uint256_$returns$__$", + "typeString": "function (uint256)" + } + }, + "id": 6532, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25670:28:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6533, + "nodeType": "ExpressionStatement", + "src": "25670:28:25" + } + ] + }, + "id": 6535, + "nodeType": "IfStatement", + "src": "25436:273:25", + "trueBody": { + "id": 6519, + "nodeType": "Block", + "src": "25467:83:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6514, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6490, + "src": "25512:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 6515, + "name": "feeAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6500, + "src": "25519:10:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 6516, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6492, + "src": "25531:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6511, + "name": "_token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6488, + "src": "25487:6:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6510, + "name": "ERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11659, + "src": "25481:5:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ERC20_$11659_$", + "typeString": "type(contract ERC20)" + } + }, + "id": 6512, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25481:13:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + }, + "id": 6513, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "safeTransferFrom", + "nodeType": "MemberAccess", + "referencedDeclaration": 11844, + "src": "25481:30:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_address_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$11786_$", + "typeString": "function (contract IERC20,address,address,uint256)" + } + }, + "id": 6517, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25481:58:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6518, + "nodeType": "ExpressionStatement", + "src": "25481:58:25" + } + ] + } + } + ] + }, + "documentation": null, + "id": 6537, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6497, + "modifierName": { + "argumentTypes": null, + "id": 6496, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "25307:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "25307:15:25" + } + ], + "name": "transferToFeeCollectionAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6495, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6488, + "name": "_token", + "nodeType": "VariableDeclaration", + "scope": 6537, + "src": "25197:14:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6487, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25197:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6490, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6537, + "src": "25213:13:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6489, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25213:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6492, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 6537, + "src": "25228:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6491, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "25228:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6494, + "name": "destination", + "nodeType": "VariableDeclaration", + "scope": 6537, + "src": "25245:19:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6493, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25245:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "25196:69:25" + }, + "returnParameters": { + "id": 6498, + "nodeType": "ParameterList", + "parameters": [], + "src": "25327:0:25" + }, + "scope": 6682, + "src": "25157:558:25", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6618, + "nodeType": "Block", + "src": "25839:828:25", + "statements": [ + { + "assignments": [ + 6551 + ], + "declarations": [ + { + "constant": false, + "id": 6551, + "name": "reserve", + "nodeType": "VariableDeclaration", + "scope": 6618, + "src": "25849:39:25", + "stateVariable": false, + "storageLocation": "storage", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + }, + "typeName": { + "contractScope": null, + "id": 6550, + "name": "CoreLibrary.ReserveData", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8324, + "src": "25849:23:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6555, + "initialValue": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6552, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4757, + "src": "25891:8:25", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_struct$_ReserveData_$8324_storage_$", + "typeString": "mapping(address => struct CoreLibrary.ReserveData storage ref)" + } + }, + "id": 6554, + "indexExpression": { + "argumentTypes": null, + "id": 6553, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6539, + "src": "25900:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "25891:18:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage", + "typeString": "struct CoreLibrary.ReserveData storage ref" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "25849:60:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 6561, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6557, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6551, + "src": "25941:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6558, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8319, + "src": "25941:32:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6559, + "name": "reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6551, + "src": "25977:7:25", + "typeDescriptions": { + "typeIdentifier": "t_struct$_ReserveData_$8324_storage_ptr", + "typeString": "struct CoreLibrary.ReserveData storage pointer" + } + }, + "id": 6560, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowingEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 8317, + "src": "25977:24:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "25941:60:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520726573657276652069736e277420656e61626c656420666f7220626f72726f77696e67206f7220617320636f6c6c61746572616c", + "id": 6562, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26015:58:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_f17de541cec0bac47729f6ac1d107dfd1ea17a9f83c5ec26ca583eeaf6f392be", + "typeString": "literal_string \"The reserve isn't enabled for borrowing or as collateral\"" + }, + "value": "The reserve isn't enabled for borrowing or as collateral" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_f17de541cec0bac47729f6ac1d107dfd1ea17a9f83c5ec26ca583eeaf6f392be", + "typeString": "literal_string \"The reserve isn't enabled for borrowing or as collateral\"" + } + ], + "id": 6556, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "25920:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6563, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "25920:163:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6564, + "nodeType": "ExpressionStatement", + "src": "25920:163:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 6567, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6565, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6539, + "src": "26098:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 6566, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4690, + "src": "26110:15:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "26098:27:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 6616, + "nodeType": "Block", + "src": "26365:296:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6592, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6589, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "26387:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6590, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "26387:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 6591, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6543, + "src": "26400:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "26387:20:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520616d6f756e7420616e64207468652076616c75652073656e7420746f206465706f73697420646f206e6f74206d61746368", + "id": 6593, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26409:55:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3ae30f23ff7837445ce2686dd35a110a057a45b669d9773b552977a0705cedbe", + "typeString": "literal_string \"The amount and the value sent to deposit do not match\"" + }, + "value": "The amount and the value sent to deposit do not match" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_3ae30f23ff7837445ce2686dd35a110a057a45b669d9773b552977a0705cedbe", + "typeString": "literal_string \"The amount and the value sent to deposit do not match\"" + } + ], + "id": 6588, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "26379:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6594, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26379:86:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6595, + "nodeType": "ExpressionStatement", + "src": "26379:86:25" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6599, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6596, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "26483:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6597, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "26483:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 6598, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6543, + "src": "26495:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "26483:19:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6615, + "nodeType": "IfStatement", + "src": "26480:171:25", + "trueBody": { + "id": 6614, + "nodeType": "Block", + "src": "26504:147:25", + "statements": [ + { + "assignments": [ + 6601 + ], + "declarations": [ + { + "constant": false, + "id": 6601, + "name": "excessAmount", + "nodeType": "VariableDeclaration", + "scope": 6614, + "src": "26545:20:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6600, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "26545:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6607, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6605, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6543, + "src": "26582:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6602, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "26568:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6603, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "26568:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6604, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "26568:13:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6606, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26568:22:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "26545:45:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6611, + "name": "excessAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6601, + "src": "26623:12:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6608, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6541, + "src": "26608:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "id": 6610, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "26608:14:25", + "typeDescriptions": { + "typeIdentifier": "t_function_transfer_nonpayable$_t_uint256_$returns$__$", + "typeString": "function (uint256)" + } + }, + "id": 6612, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26608:28:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6613, + "nodeType": "ExpressionStatement", + "src": "26608:28:25" + } + ] + } + } + ] + }, + "id": 6617, + "nodeType": "IfStatement", + "src": "26094:567:25", + "trueBody": { + "id": 6587, + "nodeType": "Block", + "src": "26126:225:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6572, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6569, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "26148:3:25", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 6570, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "26148:9:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6571, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26161:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "26148:14:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "557365722069732073656e64696e672045544820616c6f6e67207769746820746865204552433230207472616e736665722e20436865636b207468652076616c756520617474726962757465206f6620746865207472616e73616374696f6e", + "id": 6573, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "26164:97:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_654c972fc326fcc5abc552221a5fd44bbee538da2cd9225ba1a47bbe69da9e08", + "typeString": "literal_string \"User is sending ETH along with the ERC20 transfer. Check the value attribute of the transaction\"" + }, + "value": "User is sending ETH along with the ERC20 transfer. Check the value attribute of the transaction" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_654c972fc326fcc5abc552221a5fd44bbee538da2cd9225ba1a47bbe69da9e08", + "typeString": "literal_string \"User is sending ETH along with the ERC20 transfer. Check the value attribute of the transaction\"" + } + ], + "id": 6568, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "26140:7:25", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 6574, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26140:122:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6575, + "nodeType": "ExpressionStatement", + "src": "26140:122:25" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6580, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6541, + "src": "26309:5:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6582, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12212, + "src": "26324:4:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + ], + "id": 6581, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "26316:7:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 6583, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26316:13:25", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 6584, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6543, + "src": "26331:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6577, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6539, + "src": "26282:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6576, + "name": "ERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11659, + "src": "26276:5:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_ERC20_$11659_$", + "typeString": "type(contract ERC20)" + } + }, + "id": 6578, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26276:15:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + }, + "id": 6579, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "safeTransferFrom", + "nodeType": "MemberAccess", + "referencedDeclaration": 11844, + "src": "26276:32:25", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_address_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$11786_$", + "typeString": "function (contract IERC20,address,address,uint256)" + } + }, + "id": 6585, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26276:63:25", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6586, + "nodeType": "ExpressionStatement", + "src": "26276:63:25" + } + ] + } + } + ] + }, + "documentation": null, + "id": 6619, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 6546, + "modifierName": { + "argumentTypes": null, + "id": 6545, + "name": "onlyLendingPool", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4706, + "src": "25823:15:25", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "25823:15:25" + } + ], + "name": "transferToReserve", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6544, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6539, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6619, + "src": "25748:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6538, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25748:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6541, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6619, + "src": "25766:21:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + "typeName": { + "id": 6540, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "25766:15:25", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6543, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 6619, + "src": "25789:15:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6542, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "25789:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "25747:58:25" + }, + "returnParameters": { + "id": 6547, + "nodeType": "ParameterList", + "parameters": [], + "src": "25839:0:25" + }, + "scope": 6682, + "src": "25721:946:25", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 6638, + "nodeType": "Block", + "src": "26764:194:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6630, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6622, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4690, + "src": "26775:15:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 6624, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "26818:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6625, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1216, + "src": "26818:44:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 6626, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26818:46:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6623, + "name": "INetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1932, + "src": "26793:24:25", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_INetworkMetadataProvider_$1932_$", + "typeString": "type(contract INetworkMetadataProvider)" + } + }, + "id": 6627, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26793:72:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 6628, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1926, + "src": "26793:91:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 6629, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26793:93:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "26775:111:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 6631, + "nodeType": "ExpressionStatement", + "src": "26775:111:25" + }, + { + "expression": { + "argumentTypes": null, + "id": 6636, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6632, + "name": "lendingPoolAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4692, + "src": "26896:18:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 6633, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4694, + "src": "26917:17:25", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6634, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPool", + "nodeType": "MemberAccess", + "referencedDeclaration": 1058, + "src": "26917:32:25", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 6635, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "26917:34:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "26896:55:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 6637, + "nodeType": "ExpressionStatement", + "src": "26896:55:25" + } + ] + }, + "documentation": "@notice internal functions", + "id": 6639, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "refreshConfigInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6620, + "nodeType": "ParameterList", + "parameters": [], + "src": "26752:2:25" + }, + "returnParameters": { + "id": 6621, + "nodeType": "ParameterList", + "parameters": [], + "src": "26764:0:25" + }, + "scope": 6682, + "src": "26722:236:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 6680, + "nodeType": "Block", + "src": "27025:275:25", + "statements": [ + { + "assignments": [ + 6645 + ], + "declarations": [ + { + "constant": false, + "id": 6645, + "name": "reserveAlreadyAdded", + "nodeType": "VariableDeclaration", + "scope": 6680, + "src": "27035:24:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 6644, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "27035:4:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6647, + "initialValue": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 6646, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "27062:5:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "nodeType": "VariableDeclarationStatement", + "src": "27035:32:25" + }, + { + "body": { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 6663, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6659, + "name": "reservesList", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4766, + "src": "27143:12:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage", + "typeString": "address[] storage ref" + } + }, + "id": 6661, + "indexExpression": { + "argumentTypes": null, + "id": 6660, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6649, + "src": "27156:1:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "27143:15:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 6662, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6641, + "src": "27162:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "27143:27:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6669, + "nodeType": "IfStatement", + "src": "27139:92:25", + "trueBody": { + "id": 6668, + "nodeType": "Block", + "src": "27172:59:25", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6666, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6664, + "name": "reserveAlreadyAdded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6645, + "src": "27190:19:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 6665, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "27212:4:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "src": "27190:26:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6667, + "nodeType": "ExpressionStatement", + "src": "27190:26:25" + } + ] + } + }, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6655, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6652, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6649, + "src": "27097:1:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6653, + "name": "reservesList", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4766, + "src": "27101:12:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage", + "typeString": "address[] storage ref" + } + }, + "id": 6654, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "length", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "27101:19:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "27097:23:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6670, + "initializationExpression": { + "assignments": [ + 6649 + ], + "declarations": [ + { + "constant": false, + "id": 6649, + "name": "i", + "nodeType": "VariableDeclaration", + "scope": 6670, + "src": "27082:9:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6648, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "27082:7:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6651, + "initialValue": { + "argumentTypes": null, + "hexValue": "30", + "id": 6650, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "27094:1:25", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "nodeType": "VariableDeclarationStatement", + "src": "27082:13:25" + }, + "loopExpression": { + "expression": { + "argumentTypes": null, + "id": 6657, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "++", + "prefix": false, + "src": "27122:3:25", + "subExpression": { + "argumentTypes": null, + "id": 6656, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6649, + "src": "27122:1:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6658, + "nodeType": "ExpressionStatement", + "src": "27122:3:25" + }, + "nodeType": "ForStatement", + "src": "27077:154:25" + }, + { + "condition": { + "argumentTypes": null, + "id": 6672, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "27244:20:25", + "subExpression": { + "argumentTypes": null, + "id": 6671, + "name": "reserveAlreadyAdded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6645, + "src": "27245:19:25", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6679, + "nodeType": "IfStatement", + "src": "27240:53:25", + "trueBody": { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6676, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6641, + "src": "27284:8:25", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6673, + "name": "reservesList", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 4766, + "src": "27266:12:25", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage", + "typeString": "address[] storage ref" + } + }, + "id": 6675, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "push", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "27266:17:25", + "typeDescriptions": { + "typeIdentifier": "t_function_arraypush_nonpayable$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) returns (uint256)" + } + }, + "id": 6677, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "27266:27:25", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6678, + "nodeType": "ExpressionStatement", + "src": "27266:27:25" + } + } + ] + }, + "documentation": null, + "id": 6681, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "addReserveToListInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6642, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6641, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 6681, + "src": "26998:16:25", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6640, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "26998:7:25", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "26997:18:25" + }, + "returnParameters": { + "id": 6643, + "nodeType": "ParameterList", + "parameters": [], + "src": "27025:0:25" + }, + "scope": 6682, + "src": "26964:336:25", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 6683, + "src": "973:26330:25" + } + ], + "src": "0:27304:25" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.705Z", + "devdoc": { + "author": "Aave", + "methods": { + "getReserveConfiguration(address)": { + "details": "this function aggregates the configuration parameters of the reserve. It's used in the LendingPoolDataProvider specifically to save gas, and avoid multiple external contract calls to fetch the same data." + }, + "getReserveInterestRateStrategyAddress(address)": { + "details": "reserve accessors********************" + }, + "getReserveUtilizationRate(address)": { + "details": "utility functions" + }, + "isOwner()": { + "details": "Returns true if the caller is the current owner." + }, + "isUserUseReserveAsCollateralEnabled(address,address)": { + "details": "user accessors*****************" + }, + "owner()": { + "details": "Returns the address of the current owner." + }, + "renounceOwnership()": { + "details": "Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner." + }, + "setAddressesProvider(address)": { + "details": "Core configuration functions" + }, + "setReserveBaseLTVasCollateral(address,uint256)": { + "details": "functions to update available collateralsthe interest rate and the ltv are expressed in percentage" + }, + "transferOwnership(address)": { + "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner." + }, + "updateReserveTotalBorrowsByRateMode(address,address,uint256,uint256,uint8,uint256)": { + "details": "increases the proper total borrows on a reserve depending on the type of interest rate chosen by the user**************" + }, + "updateUserFixedBorrowRate(address,address)": { + "details": "updates the fixed borrow rate for the user******************" + }, + "updateUserLastVariableBorrowCumulativeIndex(address,address)": { + "details": "functions to update users reserve data" + } + }, + "title": "LendingPoolCore contract" + }, + "userdoc": { + "methods": { + "cumulateLiquidityToReserveLiquidityIndex(address,uint256)": { + "notice": "cumulates a fixed amount of liquidity to the reserve, considered as a specific interest accrued in one block. Please refer to the whitepaper for further information." + }, + "decreaseReserveTotalBorrowsFixedAndUpdateAverageRate(address,uint256,uint256)": { + "notice": "decreases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper for further information." + }, + "decreaseReserveTotalBorrowsVariable(address,uint256)": { + "notice": "decreases the the total borrow variable of a reserve Bv." + }, + "decreaseReserveTotalLiquidity(address,uint256)": { + "notice": "decreases the total liquidity Lt of a reserve" + }, + "getReserveInterestRateStrategyAddress(address)": { + "notice": "*******************" + }, + "increaseReserveTotalBorrowsFixedAndUpdateAverageRate(address,uint256,uint256)": { + "notice": "increases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper for further information." + }, + "increaseReserveTotalBorrowsVariable(address,uint256)": { + "notice": "increases the the total borrow variable of a reserve Bv." + }, + "increaseReserveTotalLiquidity(address,uint256)": { + "notice": "increases the total liquidity Lt of a reserve" + }, + "isUserUseReserveAsCollateralEnabled(address,address)": { + "notice": "****************" + }, + "setReserveBaseLTVasCollateral(address,uint256)": { + "notice": "*************" + }, + "setReserveLastUpdate(address)": { + "notice": "refreshes reserve last updated block number Bl" + }, + "updateReserveCumulativeIndexes(address)": { + "notice": "Updates the reserve Liquidity cumulative interest Ci and the Variable borrows cumulative index Bvc. Please refer to the whitepaper for further information." + }, + "updateReserveInterestRates(address)": { + "notice": "Updates the reserve current fixed borrow rate Rf, the current variable borrow rate Rv and the current liquidity rate Rl. Please refer to the whitepaper for further information." + }, + "updateReserveTotalBorrowsByRateMode(address,address,uint256,uint256,uint8,uint256)": { + "notice": "*************" + }, + "updateUserFixedBorrowRate(address,address)": { + "notice": "****************" + }, + "updateUserLastVariableBorrowCumulativeIndex(address,address)": { + "notice": "*************" + } + }, + "notice": "***********************************************************************************Contains all the data and the funds deposited into a lending pool************************************************************************************" + } +} \ No newline at end of file diff --git a/client/src/contracts/LendingPoolDataProvider.json b/client/src/contracts/LendingPoolDataProvider.json new file mode 100644 index 0000000..e404956 --- /dev/null +++ b/client/src/contracts/LendingPoolDataProvider.json @@ -0,0 +1,27238 @@ +{ + "contractName": "LendingPoolDataProvider", + "abi": [ + { + "constant": false, + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isOwner", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "addressesProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "name": "_addressesProvider", + "type": "address" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "constant": true, + "inputs": [ + { + "name": "_user", + "type": "address" + } + ], + "name": "calculateUserGlobalData", + "outputs": [ + { + "name": "totalLiquidityBalanceETH", + "type": "uint256" + }, + { + "name": "totalCollateralBalanceETH", + "type": "uint256" + }, + { + "name": "totalBorrowBalanceETH", + "type": "uint256" + }, + { + "name": "currentLtv", + "type": "uint256" + }, + { + "name": "currentLiquidationThreshold", + "type": "uint256" + }, + { + "name": "healthFactor", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserUnderlyingAssetBalance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + } + ], + "name": "balanceDecreaseAllowed", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getHealthFactorLiquidationThreshold", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "pure", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveConfigurationData", + "outputs": [ + { + "name": "ltv", + "type": "uint256" + }, + { + "name": "liquidationThreshold", + "type": "uint256" + }, + { + "name": "liquidationDiscount", + "type": "uint256" + }, + { + "name": "rateStrategyAddress", + "type": "address" + }, + { + "name": "usageAsCollateralEnabled", + "type": "bool" + }, + { + "name": "borrowingEnabled", + "type": "bool" + }, + { + "name": "fixedBorrowRateEnabled", + "type": "bool" + }, + { + "name": "isActive", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getReserveData", + "outputs": [ + { + "name": "totalLiquidity", + "type": "uint256" + }, + { + "name": "availableLiquidity", + "type": "uint256" + }, + { + "name": "totalBorrowsFixed", + "type": "uint256" + }, + { + "name": "totalBorrowsVariable", + "type": "uint256" + }, + { + "name": "liquidityRate", + "type": "uint256" + }, + { + "name": "variableBorrowRate", + "type": "uint256" + }, + { + "name": "fixedBorrowRate", + "type": "uint256" + }, + { + "name": "averageFixedBorrowRate", + "type": "uint256" + }, + { + "name": "utilizationRate", + "type": "uint256" + }, + { + "name": "liquidityIndex", + "type": "uint256" + }, + { + "name": "variableBorrowIndex", + "type": "uint256" + }, + { + "name": "aTokenAddress", + "type": "address" + }, + { + "name": "lastUpdateTimestamp", + "type": "uint40" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserAccountData", + "outputs": [ + { + "name": "totalLiquidityETH", + "type": "uint256" + }, + { + "name": "totalCollateralETH", + "type": "uint256" + }, + { + "name": "totalBorrowsETH", + "type": "uint256" + }, + { + "name": "availableBorrowsETH", + "type": "uint256" + }, + { + "name": "currentLiquidationThreshold", + "type": "uint256" + }, + { + "name": "ltv", + "type": "uint256" + }, + { + "name": "healthFactor", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserReserveData", + "outputs": [ + { + "name": "currentATokenBalance", + "type": "uint256" + }, + { + "name": "currentUnderlyingBalance", + "type": "uint256" + }, + { + "name": "currentBorrowBalance", + "type": "uint256" + }, + { + "name": "principalBorrowBalance", + "type": "uint256" + }, + { + "name": "borrowRateMode", + "type": "uint256" + }, + { + "name": "borrowRate", + "type": "uint256" + }, + { + "name": "liquidityRate", + "type": "uint256" + }, + { + "name": "originationFee", + "type": "uint256" + }, + { + "name": "variableBorrowIndex", + "type": "uint256" + }, + { + "name": "lastUpdateTimestamp", + "type": "uint256" + }, + { + "name": "usageAsCollateralEnabled", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_reserve", + "type": "address" + } + ], + "name": "getCoreActualReserveBalance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserUnderlyingAssetBalance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserReserveData\",\"outputs\":[{\"name\":\"currentATokenBalance\",\"type\":\"uint256\"},{\"name\":\"currentUnderlyingBalance\",\"type\":\"uint256\"},{\"name\":\"currentBorrowBalance\",\"type\":\"uint256\"},{\"name\":\"principalBorrowBalance\",\"type\":\"uint256\"},{\"name\":\"borrowRateMode\",\"type\":\"uint256\"},{\"name\":\"borrowRate\",\"type\":\"uint256\"},{\"name\":\"liquidityRate\",\"type\":\"uint256\"},{\"name\":\"originationFee\",\"type\":\"uint256\"},{\"name\":\"variableBorrowIndex\",\"type\":\"uint256\"},{\"name\":\"lastUpdateTimestamp\",\"type\":\"uint256\"},{\"name\":\"usageAsCollateralEnabled\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"calculateUserGlobalData\",\"outputs\":[{\"name\":\"totalLiquidityBalanceETH\",\"type\":\"uint256\"},{\"name\":\"totalCollateralBalanceETH\",\"type\":\"uint256\"},{\"name\":\"totalBorrowBalanceETH\",\"type\":\"uint256\"},{\"name\":\"currentLtv\",\"type\":\"uint256\"},{\"name\":\"currentLiquidationThreshold\",\"type\":\"uint256\"},{\"name\":\"healthFactor\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveData\",\"outputs\":[{\"name\":\"totalLiquidity\",\"type\":\"uint256\"},{\"name\":\"availableLiquidity\",\"type\":\"uint256\"},{\"name\":\"totalBorrowsFixed\",\"type\":\"uint256\"},{\"name\":\"totalBorrowsVariable\",\"type\":\"uint256\"},{\"name\":\"liquidityRate\",\"type\":\"uint256\"},{\"name\":\"variableBorrowRate\",\"type\":\"uint256\"},{\"name\":\"fixedBorrowRate\",\"type\":\"uint256\"},{\"name\":\"averageFixedBorrowRate\",\"type\":\"uint256\"},{\"name\":\"utilizationRate\",\"type\":\"uint256\"},{\"name\":\"liquidityIndex\",\"type\":\"uint256\"},{\"name\":\"variableBorrowIndex\",\"type\":\"uint256\"},{\"name\":\"aTokenAddress\",\"type\":\"address\"},{\"name\":\"lastUpdateTimestamp\",\"type\":\"uint40\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getReserveConfigurationData\",\"outputs\":[{\"name\":\"ltv\",\"type\":\"uint256\"},{\"name\":\"liquidationThreshold\",\"type\":\"uint256\"},{\"name\":\"liquidationDiscount\",\"type\":\"uint256\"},{\"name\":\"rateStrategyAddress\",\"type\":\"address\"},{\"name\":\"usageAsCollateralEnabled\",\"type\":\"bool\"},{\"name\":\"borrowingEnabled\",\"type\":\"bool\"},{\"name\":\"fixedBorrowRateEnabled\",\"type\":\"bool\"},{\"name\":\"isActive\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getHealthFactorLiquidationThreshold\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"pure\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"}],\"name\":\"balanceDecreaseAllowed\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isOwner\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"}],\"name\":\"getCoreActualReserveBalance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserAccountData\",\"outputs\":[{\"name\":\"totalLiquidityETH\",\"type\":\"uint256\"},{\"name\":\"totalCollateralETH\",\"type\":\"uint256\"},{\"name\":\"totalBorrowsETH\",\"type\":\"uint256\"},{\"name\":\"availableBorrowsETH\",\"type\":\"uint256\"},{\"name\":\"currentLiquidationThreshold\",\"type\":\"uint256\"},{\"name\":\"ltv\",\"type\":\"uint256\"},{\"name\":\"healthFactor\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"addressesProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_addressesProvider\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"}],\"devdoc\":{\"author\":\"Aave\",\"methods\":{\"getCoreActualReserveBalance(address)\":{\"details\":\"provides the actual balance of a reserve, by checking the core balance of the underlying ERC20/Ether\"},\"isOwner()\":{\"details\":\"Returns true if the caller is the current owner.\"},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}},\"title\":\"LendingPoolDataProvider contract\"},\"userdoc\":{\"methods\":{\"calculateUserGlobalData(address)\":{\"notice\":\"calculates the user data across the reserves. this includes the total liquidity/collateral/borrow balances in ETH, the average Loan To Value, the average Liquidation Ratio, and the Health factor.\"},\"getUserUnderlyingAssetBalance(address,address)\":{\"notice\":\"gets the underlying asset balance of a user based on the corresponding aToken balance.\"}},\"notice\":\"***********************************************************************************Implements functions to fetch data from the core, and aggregate them in order to allow computation on the compounded balances and the account balances in ETH************************************************************************************\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol\":\"LendingPoolDataProvider\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x0ae6004410cd58a1c5151e67959167cf58cd5e77e8b625677826e295905fb318\",\"urls\":[\"bzzr://d223bea23f0e9bd70844e9852f490be93d30fc1c31bf114c807d0e4fe07d929b\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol\":{\"keccak256\":\"0xcd8c22e8b9f5c5c4bdb5b5262beafa93486c3b15262283c053afd423eca6e16b\",\"urls\":[\"bzzr://a9a5076a121f51ea42d9ebddc2684f299a0b57c0321837b5776c3a9eb26be97e\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol\":{\"keccak256\":\"0x479a8627304b58f37a4adbe06a72c7a056ad7ce6793a4ea66deeba04c6e443c8\",\"urls\":[\"bzzr://92bb0ae9b38ab361638c71c81f650ff8115da42cb4f50a0ee7a6fb5e03e5e640\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol\":{\"keccak256\":\"0x3f74e899243a66d556c0fa81875ab95ed1e3af1909b0281d03fe89590b95121f\",\"urls\":[\"bzzr://ef6ed6edeb1ec124bf1749991346f0708214f7e12c353175d36b491bce45d7a4\"]},\"/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol\":{\"keccak256\":\"0x3b825dc98b6a7aa21e9c9b05e1951bec7b5d7c84b7a0e8de0750069ccb31ebac\",\"urls\":[\"bzzr://8a616caca158d63de8db6037a2162c1effaaa71f6d7095a11516e03f7ea391d0\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol\":{\"keccak256\":\"0xdf72f6345d96ca2731656811b508db7f8e4975776d6de39ab24dbe4a13794fd8\",\"urls\":[\"bzzr://687ac9b4f396f264af2645041f5532b6881ec8c92dad3e505ca96477957c784d\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":{\"keccak256\":\"0xeeae2b67fa36103fe1c3a4e346b9c04171f9065949953abd00104c357834b0e3\",\"urls\":[\"bzzr://4e3bd29abfa796726532c3e42dd8039ab0f93388d7bbf358428dbc9b0399664a\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x0adf744884b9262f507aba565d1c96c82397f58d399a2dc2c60a452953197574\",\"urls\":[\"bzzr://03099f88c041565b5ac13ea7e645a8f9bff0c29bfa584c7969372ce12c5473f5\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol\":{\"keccak256\":\"0x35a7f1a34259948cdcb03084718f765215fe69559f557b395d9d6e18c63ac823\",\"urls\":[\"bzzr://f529e265dd06192a1d552f1f41c245790419562dfb52e7be9d443c758ccb72d0\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol\":{\"keccak256\":\"0x3f4ef00886795fb781b76e1fab7ce2f0422de9d0941bc8d5d9c377ad100e9a33\",\"urls\":[\"bzzr://8aff91a48f36ed3d3da74fc48d65cbc20e56e45172790ae38f18e234883ece70\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol\":{\"keccak256\":\"0xca757f989e0e7519d03d4e3086028e3022306ec4bb7f610fa78bff866f04c998\",\"urls\":[\"bzzr://f381f642ecce43d76d9e0011ea3c7c6218d1eaa2e0d3a7d5aecd55552cc0fb27\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol\":{\"keccak256\":\"0xe9e88d47e58f59345bb70a48960878e8b6d7525e3fe4f03c63f575599123957a\",\"urls\":[\"bzzr://ab72dddd7f00500a59b72b7f2f938ca25ae859517d524e446dc92a37f5f4a4e3\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol\":{\"keccak256\":\"0x8cd409571214e2d2f9196b8a31ce04bb44919ce7b12e66301c216c3de70a3f5f\",\"urls\":[\"bzzr://87f2c373a1f51ca84ac1132e72e3ef5a43e7a4f4f10341a63993c2cbdb769b64\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol\":{\"keccak256\":\"0xb8b4844881a9ea5c3f0f2584061efcbfb6c96863ca3a07b960d2f9d323293cac\",\"urls\":[\"bzzr://8cb1c5dcce198c0f60c21bd9807b361fc214a60d4b3aa3442153b045b51a4325\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol\":{\"keccak256\":\"0x547550bb7c7e61190fddae1b4dbe71932c9acdaf1d196524ee99c3340a5bec2d\",\"urls\":[\"bzzr://4a9ee0d136529517d7586cb3842177dbd767d9c34fdb035b0a90e8f4cc4d1b35\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol\":{\"keccak256\":\"0x4a3a810b7ebe742e897e1fd428b3eeed2196d3acea58eaf9c566ed10d545d2ed\",\"urls\":[\"bzzr://729aefb3f89f616c954a0735f8b4dd8804bdd0351e96f8e904fdb3e78a109b6c\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]},\"openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol\":{\"keccak256\":\"0xe86fdc15fbc379ecf14d6aa4f51b87c0be8476e114e23c171b790a6717230655\",\"urls\":[\"bzzr://364c5847b4ee3ac37a6ad6e54a288889ac3d2a85757b7999c00c719db6cd871d\"]}},\"version\":1}", + "bytecode": "0x60806040523480156200001157600080fd5b506040516020806200414e833981018060405260208110156200003357600080fd5b8101908080519060200190929190505050620000546200021b60201b60201c565b6000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600260006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508073ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156200019757600080fd5b505afa158015620001ac573d6000803e3d6000fd5b505050506040513d6020811015620001c357600080fd5b8101908080519060200190929190505050600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505062000223565b600033905090565b613f1b80620002336000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c806376e9d6151161008c578063b7b2e0b111610066578063b7b2e0b114610569578063bf92857c146105c1578063c72c4d1014610643578063f2fde38b1461068d576100ea565b806376e9d615146104775780638da5cb5b146104fd5780638f32d59b14610547576100ea565b806335ea6a75116100c857806335ea6a75146102a45780633e1501411461038a5780633e44bee81461044f578063715018a61461046d576100ea565b806318a4dbca146100ef57806328dd2d01146101675780632c6d0e9b14610229575b600080fd5b6101516004803603604081101561010557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506106d1565b6040518082815260200191505060405180910390f35b6101c96004803603604081101561017d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610871565b604051808c81526020018b81526020018a8152602001898152602001888152602001878152602001868152602001858152602001848152602001838152602001821515151581526020019b50505050505050505050505060405180910390f35b61026b6004803603602081101561023f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061152e565b60405180878152602001868152602001858152602001848152602001838152602001828152602001965050505050505060405180910390f35b6102e6600480360360208110156102ba57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050611d52565b604051808e81526020018d81526020018c81526020018b81526020018a81526020018981526020018881526020018781526020018681526020018581526020018481526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018264ffffffffff1664ffffffffff1681526020019d505050505050505050505050505060405180910390f35b6103cc600480360360208110156103a057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506128a3565b604051808981526020018881526020018781526020018673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001851515151581526020018415151515815260200183151515158152602001821515151581526020019850505050505050505060405180910390f35b610457612c74565b6040518082815260200191505060405180910390f35b610475612c84565b005b6104e36004803603606081101561048d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050612dbd565b604051808215151515815260200191505060405180910390f35b6105056132bc565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61054f6132e5565b604051808215151515815260200191505060405180910390f35b6105ab6004803603602081101561057f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613343565b6040518082815260200191505060405180910390f35b610603600480360360208110156105d757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506135aa565b6040518088815260200187815260200186815260200185815260200184815260200183815260200182815260200197505050505050505060405180910390f35b61064b6135ee565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6106cf600480360360208110156106a357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613614565b005b600080600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee856040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561077357600080fd5b505afa158015610787573d6000803e3d6000fd5b505050506040513d602081101561079d57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16633af9e669846040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561082d57600080fd5b505afa158015610841573d6000803e3d6000fd5b505050506040513d602081101561085757600080fd5b810190808051906020019092919050505091505092915050565b6000806000806000806000806000806000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee8e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561092157600080fd5b505afa158015610935573d6000803e3d6000fd5b505050506040513d602081101561094b57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166370a082318d6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156109d857600080fd5b505afa1580156109ec573d6000803e3d6000fd5b505050506040513d6020811015610a0257600080fd5b81019080805190602001909291905050509a50600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee8e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015610ab457600080fd5b505afa158015610ac8573d6000803e3d6000fd5b505050506040513d6020811015610ade57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16633af9e6698d6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015610b6b57600080fd5b505afa158015610b7f573d6000803e3d6000fd5b505050506040513d6020811015610b9557600080fd5b810190808051906020019092919050505099506000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631ca19f198f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015610c7d57600080fd5b505afa158015610c91573d6000803e3d6000fd5b505050506040513d6020811015610ca757600080fd5b81019080805190602001909291905050509050600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd8f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b158015610d8d57600080fd5b505afa158015610da1573d6000803e3d6000fd5b505050506040513d6060811015610db757600080fd5b8101908080519060200190929190805190602001909291908051906020019092919050505050809b50819a505050806001811115610df157fe5b975060006001811115610e0057fe5b816001811115610e0c57fe5b14610ef057600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663906c0a418f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015610eb057600080fd5b505afa158015610ec4573d6000803e3d6000fd5b505050506040513d6020811015610eda57600080fd5b8101908080519060200190929190505050610fff565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166344e636b78f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015610fc357600080fd5b505afa158015610fd7573d6000803e3d6000fd5b505050506040513d6020811015610fed57600080fd5b81019080805190602001909291905050505b9650600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c540148e8f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156110a057600080fd5b505afa1580156110b4573d6000803e3d6000fd5b505050506040513d60208110156110ca57600080fd5b81019080805190602001909291905050509550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663feab31ac8f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156111b057600080fd5b505afa1580156111c4573d6000803e3d6000fd5b505050506040513d60208110156111da57600080fd5b81019080805190602001909291905050509450600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f6ea8d768f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156112c057600080fd5b505afa1580156112d4573d6000803e3d6000fd5b505050506040513d60208110156112ea57600080fd5b81019080805190602001909291905050509350600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166366d103f38f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156113d057600080fd5b505afa1580156113e4573d6000803e3d6000fd5b505050506040513d60208110156113fa57600080fd5b81019080805190602001909291905050509250600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b8f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156114e057600080fd5b505afa1580156114f4573d6000803e3d6000fd5b505050506040513d602081101561150a57600080fd5b81019080805190602001909291905050509150509295989b509295989b9093969950565b6000806000806000806000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fca513a86040518163ffffffff1660e01b815260040160206040518083038186803b1580156115a157600080fd5b505afa1580156115b5573d6000803e3d6000fd5b505050506040513d60208110156115cb57600080fd5b810190808051906020019092919050505090506115e6613e0c565b6060600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630902f1ac6040518163ffffffff1660e01b815260040160006040518083038186803b15801561165057600080fd5b505afa158015611664573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250602081101561168e57600080fd5b8101908080516401000000008111156116a657600080fd5b828101905060208101848111156116bc57600080fd5b81518560208202830111640100000000821117156116d957600080fd5b5050929190505050905060008090505b8151811015611cee57600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd83838151811061173c57fe5b60200260200101518d6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b1580156117d857600080fd5b505afa1580156117ec573d6000803e3d6000fd5b505050506040513d606081101561180257600080fd5b810190808051906020019092919080519060200190929190805190602001909291905050509091505083606001818152505061185182828151811061184357fe5b60200260200101518c6106d1565b83604001818152505060008360400151148015611872575060008360600151145b1561187c57611ce1565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635fc526ff8383815181106118c657fe5b60200260200101516040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060c06040518083038186803b15801561192e57600080fd5b505afa158015611942573d6000803e3d6000fd5b505050506040513d60c081101561195857600080fd5b81019080805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190505050905050866080018760a0018860c0018960e0018415151515815250848152508481525084815250505050508260800151600a0a8360200181815250508373ffffffffffffffffffffffffffffffffffffffff1663b3596f078383815181106119ff57fe5b60200260200101516040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611a6757600080fd5b505afa158015611a7b573d6000803e3d6000fd5b505050506040513d6020811015611a9157600080fd5b8101908080519060200190929190505050836000018181525050600083604001511115611ca3576000611aeb8460200151611add8660400151876000015161369a90919063ffffffff16565b61372090919063ffffffff16565b9050611b00818c61376a90919063ffffffff16565b9a508360e001518015611c305750600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b848481518110611b5857fe5b60200260200101518e6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015611bf457600080fd5b505afa158015611c08573d6000803e3d6000fd5b505050506040513d6020811015611c1e57600080fd5b81019080805190602001909291905050505b15611ca157611c48818b61376a90919063ffffffff16565b9950611c73611c648560a001518361369a90919063ffffffff16565b8961376a90919063ffffffff16565b9750611c9e611c8f8560c001518361369a90919063ffffffff16565b8861376a90919063ffffffff16565b96505b505b600083606001511115611ce057611cdd611cce846060015185600001516137f290919063ffffffff16565b8961376a90919063ffffffff16565b97505b5b80806001019150506116e9565b5060008811611cfe576000611d12565b611d11888761372090919063ffffffff16565b5b955060008811611d23576000611d37565b611d36888661372090919063ffffffff16565b5b9450611d4488888761384d565b935050505091939550919395565b6000806000806000806000806000806000806000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c33cfd908f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611e0557600080fd5b505afa158015611e19573d6000803e3d6000fd5b505050506040513d6020811015611e2f57600080fd5b81019080805190602001909291905050509c50600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e24030198f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611ee157600080fd5b505afa158015611ef5573d6000803e3d6000fd5b505050506040513d6020811015611f0b57600080fd5b81019080805190602001909291905050509b50600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663308f9d558f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611fbd57600080fd5b505afa158015611fd1573d6000803e3d6000fd5b505050506040513d6020811015611fe757600080fd5b81019080805190602001909291905050509a50600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166398bd47378f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561209957600080fd5b505afa1580156120ad573d6000803e3d6000fd5b505050506040513d60208110156120c357600080fd5b81019080805190602001909291905050509950600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c540148e8f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561217557600080fd5b505afa158015612189573d6000803e3d6000fd5b505050506040513d602081101561219f57600080fd5b81019080805190602001909291905050509850600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663906c0a418f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561225157600080fd5b505afa158015612265573d6000803e3d6000fd5b505050506040513d602081101561227b57600080fd5b81019080805190602001909291905050509750600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e7d3b968f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561232d57600080fd5b505afa158015612341573d6000803e3d6000fd5b505050506040513d602081101561235757600080fd5b81019080805190602001909291905050509650600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637269e8538f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561240957600080fd5b505afa15801561241d573d6000803e3d6000fd5b505050506040513d602081101561243357600080fd5b81019080805190602001909291905050509550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663bfacad848f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156124e557600080fd5b505afa1580156124f9573d6000803e3d6000fd5b505050506040513d602081101561250f57600080fd5b81019080805190602001909291905050509450600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663bd7fd79a8f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156125c157600080fd5b505afa1580156125d5573d6000803e3d6000fd5b505050506040513d60208110156125eb57600080fd5b81019080805190602001909291905050509350600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b701d0938f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561269d57600080fd5b505afa1580156126b1573d6000803e3d6000fd5b505050506040513d60208110156126c757600080fd5b81019080805190602001909291905050509250600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee8f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561277957600080fd5b505afa15801561278d573d6000803e3d6000fd5b505050506040513d60208110156127a357600080fd5b81019080805190602001909291905050509150600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634f1446098f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561285557600080fd5b505afa158015612869573d6000803e3d6000fd5b505050506040513d602081101561287f57600080fd5b8101908080519060200190929190505050905091939597999b9d90929496989a9c50565b600080600080600080600080600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635fc526ff8a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060c06040518083038186803b15801561294e57600080fd5b505afa158015612962573d6000803e3d6000fd5b505050506040513d60c081101561297857600080fd5b81019080805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190505050909192939450809750819650829850839b50849c505050505050600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166305075d6e8a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015612a7457600080fd5b505afa158015612a88573d6000803e3d6000fd5b505050506040513d6020811015612a9e57600080fd5b81019080805190602001909291905050509050600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b77b19588a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015612b5057600080fd5b505afa158015612b64573d6000803e3d6000fd5b505050506040513d6020811015612b7a57600080fd5b81019080805190602001909291905050509550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636ae144168a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015612c2c57600080fd5b505afa158015612c40573d6000803e3d6000fd5b505050506040513d6020811015612c5657600080fd5b81019080805190602001909291905050509450919395975091939597565b6000670de0b6b3a7640000905090565b612c8c6132e5565b612cfe576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b6000612dc7613e53565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635fc526ff866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060c06040518083038186803b158015612e6657600080fd5b505afa158015612e7a573d6000803e3d6000fd5b505050506040513d60c0811015612e9057600080fd5b810190808051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509091929350905050836000018460800185610120018315151515815250838152508381525050505080610120015115806130185750600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b86866040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015612fdb57600080fd5b505afa158015612fef573d6000803e3d6000fd5b505050506040513d602081101561300557600080fd5b8101908080519060200190929190505050155b156130275760019150506132b5565b6130308461152e565b9091929394509091505083602001846040018560600183815250838152508381525050505060008160400151141561306c5760019150506132b5565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fca513a86040518163ffffffff1660e01b815260040160206040518083038186803b1580156130d657600080fd5b505afa1580156130ea573d6000803e3d6000fd5b505050506040513d602081101561310057600080fd5b810190808051906020019092919050505090506131f68260000151600a0a6131e8868473ffffffffffffffffffffffffffffffffffffffff1663b3596f078b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561319f57600080fd5b505afa1580156131b3573d6000803e3d6000fd5b505050506040513d60208110156131c957600080fd5b810190808051906020019092919050505061369a90919063ffffffff16565b61372090919063ffffffff16565b8260a001818152505061321a8260a0015183602001516138c190919063ffffffff16565b8260c00181815250506132808260c0015161327261324985608001518660a0015161369a90919063ffffffff16565b6132648660600151876020015161369a90919063ffffffff16565b6138c190919063ffffffff16565b61372090919063ffffffff16565b8260e001818152505060006132a28360c0015184604001518560e0015161384d565b9050670de0b6b3a7640000811193505050505b9392505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1661332761390b565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b1580156133ae57600080fd5b505afa1580156133c2573d6000803e3d6000fd5b505050506040513d60208110156133d857600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b15801561342e57600080fd5b505afa158015613442573d6000803e3d6000fd5b505050506040513d602081101561345857600080fd5b810190808051906020019092919050505090506000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905060008273ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614613584578473ffffffffffffffffffffffffffffffffffffffff166370a08231836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561354457600080fd5b505afa158015613558573d6000803e3d6000fd5b505050506040513d602081101561356e57600080fd5b810190808051906020019092919050505061359d565b8173ffffffffffffffffffffffffffffffffffffffff16315b9050809350505050919050565b60008060008060008060006135be8861152e565b809650819850829750839a50849b50859c505050505050506135e1868684613913565b9350919395979092949650565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b61361c6132e5565b61368e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b61369781613aea565b50565b6000808314156136ad576000905061371a565b60008284029050828482816136be57fe5b0414613715576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180613ecf6021913960400191505060405180910390fd5b809150505b92915050565b600061376283836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250613c2e565b905092915050565b6000808284019050838110156137e8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b6000613845670de0b6b3a7640000613837613816858761369a90919063ffffffff16565b6002670de0b6b3a76400008161382857fe5b0461376a90919063ffffffff16565b61372090919063ffffffff16565b905092915050565b60008083141561387f577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90506138ba565b6138b7836138a9606461389b868961369a90919063ffffffff16565b61372090919063ffffffff16565b613cf490919063ffffffff16565b90505b9392505050565b600061390383836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250613d4c565b905092915050565b600033905090565b60008061393c606461392e858861369a90919063ffffffff16565b61372090919063ffffffff16565b905083811015613950576000915050613ae3565b61396384826138c190919063ffffffff16565b90506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fbeefc3c6040518163ffffffff1660e01b815260040160206040518083038186803b1580156139cf57600080fd5b505afa1580156139e3573d6000803e3d6000fd5b505050506040513d60208110156139f957600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1663e563a7d033846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019250505060206040518083038186803b158015613a8e57600080fd5b505afa158015613aa2573d6000803e3d6000fd5b505050506040513d6020811015613ab857600080fd5b81019080805190602001909291905050509050613ade81836138c190919063ffffffff16565b925050505b9392505050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415613b70576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180613ea96026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60008083118290613cda576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015613c9f578082015181840152602081019050613c84565b50505050905090810190601f168015613ccc5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b506000838581613ce657fe5b049050809150509392505050565b60008060028381613d0157fe5b049050613d4383613d35613d26670de0b6b3a76400008861369a90919063ffffffff16565b8461376a90919063ffffffff16565b61372090919063ffffffff16565b91505092915050565b6000838311158290613df9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015613dbe578082015181840152602081019050613da3565b50505050905090810190601f168015613deb5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b604051806101000160405280600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000151581525090565b604051806101400160405280600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000815260200160008152602001600015158152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a165627a7a72305820d1b5223cb54494323613442874f07391e03859bbdc81a598614c8cd7e133497c0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100ea5760003560e01c806376e9d6151161008c578063b7b2e0b111610066578063b7b2e0b114610569578063bf92857c146105c1578063c72c4d1014610643578063f2fde38b1461068d576100ea565b806376e9d615146104775780638da5cb5b146104fd5780638f32d59b14610547576100ea565b806335ea6a75116100c857806335ea6a75146102a45780633e1501411461038a5780633e44bee81461044f578063715018a61461046d576100ea565b806318a4dbca146100ef57806328dd2d01146101675780632c6d0e9b14610229575b600080fd5b6101516004803603604081101561010557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506106d1565b6040518082815260200191505060405180910390f35b6101c96004803603604081101561017d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610871565b604051808c81526020018b81526020018a8152602001898152602001888152602001878152602001868152602001858152602001848152602001838152602001821515151581526020019b50505050505050505050505060405180910390f35b61026b6004803603602081101561023f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061152e565b60405180878152602001868152602001858152602001848152602001838152602001828152602001965050505050505060405180910390f35b6102e6600480360360208110156102ba57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050611d52565b604051808e81526020018d81526020018c81526020018b81526020018a81526020018981526020018881526020018781526020018681526020018581526020018481526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018264ffffffffff1664ffffffffff1681526020019d505050505050505050505050505060405180910390f35b6103cc600480360360208110156103a057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506128a3565b604051808981526020018881526020018781526020018673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001851515151581526020018415151515815260200183151515158152602001821515151581526020019850505050505050505060405180910390f35b610457612c74565b6040518082815260200191505060405180910390f35b610475612c84565b005b6104e36004803603606081101561048d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050612dbd565b604051808215151515815260200191505060405180910390f35b6105056132bc565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b61054f6132e5565b604051808215151515815260200191505060405180910390f35b6105ab6004803603602081101561057f57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613343565b6040518082815260200191505060405180910390f35b610603600480360360208110156105d757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506135aa565b6040518088815260200187815260200186815260200185815260200184815260200183815260200182815260200197505050505050505060405180910390f35b61064b6135ee565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6106cf600480360360208110156106a357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050613614565b005b600080600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee856040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561077357600080fd5b505afa158015610787573d6000803e3d6000fd5b505050506040513d602081101561079d57600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff16633af9e669846040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561082d57600080fd5b505afa158015610841573d6000803e3d6000fd5b505050506040513d602081101561085757600080fd5b810190808051906020019092919050505091505092915050565b6000806000806000806000806000806000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee8e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561092157600080fd5b505afa158015610935573d6000803e3d6000fd5b505050506040513d602081101561094b57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166370a082318d6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156109d857600080fd5b505afa1580156109ec573d6000803e3d6000fd5b505050506040513d6020811015610a0257600080fd5b81019080805190602001909291905050509a50600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee8e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015610ab457600080fd5b505afa158015610ac8573d6000803e3d6000fd5b505050506040513d6020811015610ade57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff16633af9e6698d6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015610b6b57600080fd5b505afa158015610b7f573d6000803e3d6000fd5b505050506040513d6020811015610b9557600080fd5b810190808051906020019092919050505099506000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631ca19f198f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015610c7d57600080fd5b505afa158015610c91573d6000803e3d6000fd5b505050506040513d6020811015610ca757600080fd5b81019080805190602001909291905050509050600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd8f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b158015610d8d57600080fd5b505afa158015610da1573d6000803e3d6000fd5b505050506040513d6060811015610db757600080fd5b8101908080519060200190929190805190602001909291908051906020019092919050505050809b50819a505050806001811115610df157fe5b975060006001811115610e0057fe5b816001811115610e0c57fe5b14610ef057600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663906c0a418f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015610eb057600080fd5b505afa158015610ec4573d6000803e3d6000fd5b505050506040513d6020811015610eda57600080fd5b8101908080519060200190929190505050610fff565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166344e636b78f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015610fc357600080fd5b505afa158015610fd7573d6000803e3d6000fd5b505050506040513d6020811015610fed57600080fd5b81019080805190602001909291905050505b9650600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c540148e8f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156110a057600080fd5b505afa1580156110b4573d6000803e3d6000fd5b505050506040513d60208110156110ca57600080fd5b81019080805190602001909291905050509550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663feab31ac8f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156111b057600080fd5b505afa1580156111c4573d6000803e3d6000fd5b505050506040513d60208110156111da57600080fd5b81019080805190602001909291905050509450600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663f6ea8d768f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156112c057600080fd5b505afa1580156112d4573d6000803e3d6000fd5b505050506040513d60208110156112ea57600080fd5b81019080805190602001909291905050509350600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166366d103f38f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156113d057600080fd5b505afa1580156113e4573d6000803e3d6000fd5b505050506040513d60208110156113fa57600080fd5b81019080805190602001909291905050509250600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b8f8f6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156114e057600080fd5b505afa1580156114f4573d6000803e3d6000fd5b505050506040513d602081101561150a57600080fd5b81019080805190602001909291905050509150509295989b509295989b9093969950565b6000806000806000806000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fca513a86040518163ffffffff1660e01b815260040160206040518083038186803b1580156115a157600080fd5b505afa1580156115b5573d6000803e3d6000fd5b505050506040513d60208110156115cb57600080fd5b810190808051906020019092919050505090506115e6613e0c565b6060600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16630902f1ac6040518163ffffffff1660e01b815260040160006040518083038186803b15801561165057600080fd5b505afa158015611664573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250602081101561168e57600080fd5b8101908080516401000000008111156116a657600080fd5b828101905060208101848111156116bc57600080fd5b81518560208202830111640100000000821117156116d957600080fd5b5050929190505050905060008090505b8151811015611cee57600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd83838151811061173c57fe5b60200260200101518d6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b1580156117d857600080fd5b505afa1580156117ec573d6000803e3d6000fd5b505050506040513d606081101561180257600080fd5b810190808051906020019092919080519060200190929190805190602001909291905050509091505083606001818152505061185182828151811061184357fe5b60200260200101518c6106d1565b83604001818152505060008360400151148015611872575060008360600151145b1561187c57611ce1565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635fc526ff8383815181106118c657fe5b60200260200101516040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060c06040518083038186803b15801561192e57600080fd5b505afa158015611942573d6000803e3d6000fd5b505050506040513d60c081101561195857600080fd5b81019080805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190505050905050866080018760a0018860c0018960e0018415151515815250848152508481525084815250505050508260800151600a0a8360200181815250508373ffffffffffffffffffffffffffffffffffffffff1663b3596f078383815181106119ff57fe5b60200260200101516040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611a6757600080fd5b505afa158015611a7b573d6000803e3d6000fd5b505050506040513d6020811015611a9157600080fd5b8101908080519060200190929190505050836000018181525050600083604001511115611ca3576000611aeb8460200151611add8660400151876000015161369a90919063ffffffff16565b61372090919063ffffffff16565b9050611b00818c61376a90919063ffffffff16565b9a508360e001518015611c305750600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b848481518110611b5857fe5b60200260200101518e6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015611bf457600080fd5b505afa158015611c08573d6000803e3d6000fd5b505050506040513d6020811015611c1e57600080fd5b81019080805190602001909291905050505b15611ca157611c48818b61376a90919063ffffffff16565b9950611c73611c648560a001518361369a90919063ffffffff16565b8961376a90919063ffffffff16565b9750611c9e611c8f8560c001518361369a90919063ffffffff16565b8861376a90919063ffffffff16565b96505b505b600083606001511115611ce057611cdd611cce846060015185600001516137f290919063ffffffff16565b8961376a90919063ffffffff16565b97505b5b80806001019150506116e9565b5060008811611cfe576000611d12565b611d11888761372090919063ffffffff16565b5b955060008811611d23576000611d37565b611d36888661372090919063ffffffff16565b5b9450611d4488888761384d565b935050505091939550919395565b6000806000806000806000806000806000806000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c33cfd908f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611e0557600080fd5b505afa158015611e19573d6000803e3d6000fd5b505050506040513d6020811015611e2f57600080fd5b81019080805190602001909291905050509c50600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e24030198f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611ee157600080fd5b505afa158015611ef5573d6000803e3d6000fd5b505050506040513d6020811015611f0b57600080fd5b81019080805190602001909291905050509b50600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663308f9d558f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611fbd57600080fd5b505afa158015611fd1573d6000803e3d6000fd5b505050506040513d6020811015611fe757600080fd5b81019080805190602001909291905050509a50600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166398bd47378f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561209957600080fd5b505afa1580156120ad573d6000803e3d6000fd5b505050506040513d60208110156120c357600080fd5b81019080805190602001909291905050509950600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c540148e8f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561217557600080fd5b505afa158015612189573d6000803e3d6000fd5b505050506040513d602081101561219f57600080fd5b81019080805190602001909291905050509850600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663906c0a418f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561225157600080fd5b505afa158015612265573d6000803e3d6000fd5b505050506040513d602081101561227b57600080fd5b81019080805190602001909291905050509750600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e7d3b968f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561232d57600080fd5b505afa158015612341573d6000803e3d6000fd5b505050506040513d602081101561235757600080fd5b81019080805190602001909291905050509650600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16637269e8538f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561240957600080fd5b505afa15801561241d573d6000803e3d6000fd5b505050506040513d602081101561243357600080fd5b81019080805190602001909291905050509550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663bfacad848f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156124e557600080fd5b505afa1580156124f9573d6000803e3d6000fd5b505050506040513d602081101561250f57600080fd5b81019080805190602001909291905050509450600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663bd7fd79a8f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156125c157600080fd5b505afa1580156125d5573d6000803e3d6000fd5b505050506040513d60208110156125eb57600080fd5b81019080805190602001909291905050509350600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b701d0938f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561269d57600080fd5b505afa1580156126b1573d6000803e3d6000fd5b505050506040513d60208110156126c757600080fd5b81019080805190602001909291905050509250600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee8f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561277957600080fd5b505afa15801561278d573d6000803e3d6000fd5b505050506040513d60208110156127a357600080fd5b81019080805190602001909291905050509150600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634f1446098f6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561285557600080fd5b505afa158015612869573d6000803e3d6000fd5b505050506040513d602081101561287f57600080fd5b8101908080519060200190929190505050905091939597999b9d90929496989a9c50565b600080600080600080600080600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635fc526ff8a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060c06040518083038186803b15801561294e57600080fd5b505afa158015612962573d6000803e3d6000fd5b505050506040513d60c081101561297857600080fd5b81019080805190602001909291908051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190505050909192939450809750819650829850839b50849c505050505050600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166305075d6e8a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015612a7457600080fd5b505afa158015612a88573d6000803e3d6000fd5b505050506040513d6020811015612a9e57600080fd5b81019080805190602001909291905050509050600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b77b19588a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015612b5057600080fd5b505afa158015612b64573d6000803e3d6000fd5b505050506040513d6020811015612b7a57600080fd5b81019080805190602001909291905050509550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16636ae144168a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015612c2c57600080fd5b505afa158015612c40573d6000803e3d6000fd5b505050506040513d6020811015612c5657600080fd5b81019080805190602001909291905050509450919395975091939597565b6000670de0b6b3a7640000905090565b612c8c6132e5565b612cfe576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a360008060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b6000612dc7613e53565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16635fc526ff866040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060c06040518083038186803b158015612e6657600080fd5b505afa158015612e7a573d6000803e3d6000fd5b505050506040513d60c0811015612e9057600080fd5b810190808051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509091929350905050836000018460800185610120018315151515815250838152508381525050505080610120015115806130185750600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b86866040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015612fdb57600080fd5b505afa158015612fef573d6000803e3d6000fd5b505050506040513d602081101561300557600080fd5b8101908080519060200190929190505050155b156130275760019150506132b5565b6130308461152e565b9091929394509091505083602001846040018560600183815250838152508381525050505060008160400151141561306c5760019150506132b5565b6000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fca513a86040518163ffffffff1660e01b815260040160206040518083038186803b1580156130d657600080fd5b505afa1580156130ea573d6000803e3d6000fd5b505050506040513d602081101561310057600080fd5b810190808051906020019092919050505090506131f68260000151600a0a6131e8868473ffffffffffffffffffffffffffffffffffffffff1663b3596f078b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561319f57600080fd5b505afa1580156131b3573d6000803e3d6000fd5b505050506040513d60208110156131c957600080fd5b810190808051906020019092919050505061369a90919063ffffffff16565b61372090919063ffffffff16565b8260a001818152505061321a8260a0015183602001516138c190919063ffffffff16565b8260c00181815250506132808260c0015161327261324985608001518660a0015161369a90919063ffffffff16565b6132648660600151876020015161369a90919063ffffffff16565b6138c190919063ffffffff16565b61372090919063ffffffff16565b8260e001818152505060006132a28360c0015184604001518560e0015161384d565b9050670de0b6b3a7640000811193505050505b9392505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1661332761390b565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b600080600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b1580156133ae57600080fd5b505afa1580156133c2573d6000803e3d6000fd5b505050506040513d60208110156133d857600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b15801561342e57600080fd5b505afa158015613442573d6000803e3d6000fd5b505050506040513d602081101561345857600080fd5b810190808051906020019092919050505090506000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905060008273ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff1614613584578473ffffffffffffffffffffffffffffffffffffffff166370a08231836040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561354457600080fd5b505afa158015613558573d6000803e3d6000fd5b505050506040513d602081101561356e57600080fd5b810190808051906020019092919050505061359d565b8173ffffffffffffffffffffffffffffffffffffffff16315b9050809350505050919050565b60008060008060008060006135be8861152e565b809650819850829750839a50849b50859c505050505050506135e1868684613913565b9350919395979092949650565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b61361c6132e5565b61368e576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b61369781613aea565b50565b6000808314156136ad576000905061371a565b60008284029050828482816136be57fe5b0414613715576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526021815260200180613ecf6021913960400191505060405180910390fd5b809150505b92915050565b600061376283836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250613c2e565b905092915050565b6000808284019050838110156137e8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b6000613845670de0b6b3a7640000613837613816858761369a90919063ffffffff16565b6002670de0b6b3a76400008161382857fe5b0461376a90919063ffffffff16565b61372090919063ffffffff16565b905092915050565b60008083141561387f577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90506138ba565b6138b7836138a9606461389b868961369a90919063ffffffff16565b61372090919063ffffffff16565b613cf490919063ffffffff16565b90505b9392505050565b600061390383836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250613d4c565b905092915050565b600033905090565b60008061393c606461392e858861369a90919063ffffffff16565b61372090919063ffffffff16565b905083811015613950576000915050613ae3565b61396384826138c190919063ffffffff16565b90506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fbeefc3c6040518163ffffffff1660e01b815260040160206040518083038186803b1580156139cf57600080fd5b505afa1580156139e3573d6000803e3d6000fd5b505050506040513d60208110156139f957600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff1663e563a7d033846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019250505060206040518083038186803b158015613a8e57600080fd5b505afa158015613aa2573d6000803e3d6000fd5b505050506040513d6020811015613ab857600080fd5b81019080805190602001909291905050509050613ade81836138c190919063ffffffff16565b925050505b9392505050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415613b70576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526026815260200180613ea96026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff166000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a3806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555050565b60008083118290613cda576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015613c9f578082015181840152602081019050613c84565b50505050905090810190601f168015613ccc5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b506000838581613ce657fe5b049050809150509392505050565b60008060028381613d0157fe5b049050613d4383613d35613d26670de0b6b3a76400008861369a90919063ffffffff16565b8461376a90919063ffffffff16565b61372090919063ffffffff16565b91505092915050565b6000838311158290613df9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015613dbe578082015181840152602081019050613da3565b50505050905090810190601f168015613deb5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b604051806101000160405280600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000151581525090565b604051806101400160405280600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000815260200160008152602001600015158152509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a165627a7a72305820d1b5223cb54494323613442874f07391e03859bbdc81a598614c8cd7e133497c0029", + "sourceMap": "851:13671:26:-;;;1306:196;8:9:-1;5:2;;;30:1;27;20:12;5:2;1306:196:26;;;;;;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1306:196:26;;;;;;;;;;;;;;;;707:12:57;:10;;;:12;;:::i;:::-;698:6;;:21;;;;;;;;;;;;;;;;;;767:6;;;;;;;;;;;734:40;;763:1;734:40;;;;;;;;;;;;1404:18:26;1384:17;;:38;;;;;;;;;;;;;;;;;;1455:18;:37;;;:39;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1455:39:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1455:39:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1455:39:26;;;;;;;;;;;;;;;;1432:4;;:63;;;;;;;;;;;;;;;;;;1306:196;851:13671;;788:96:55;833:15;867:10;860:17;;788:96;:::o;851:13671:26:-;;;;;;;", + "deployedSourceMap": "851:13671:26:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;851:13671:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5068:234;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5068:234:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;12367:1612;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;12367:1612:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2150:2795;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2150:2795:26;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;10097:1584;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;10097:1584:26;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9279:812;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9279:812:26;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9140:132;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1642:137:57;;;:::i;:::-;;6026:1763:26;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6026:1763:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;857:77:57;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1208:92;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;14112:408:26;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14112:408:26;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;11687:674;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11687:674:26;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;994:53;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1928:107:57;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1928:107:57;;;;;;;;;;;;;;;;;;;:::i;:::-;;5068:234:26;5161:7;5181:13;5204:4;;;;;;;;;;;:28;;;5233:8;5204:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5204:38:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5204:38:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5204:38:26;;;;;;;;;;;;;;;;5181:62;;5261:6;:26;;;5288:5;5261:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5261:33:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5261:33:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5261:33:26;;;;;;;;;;;;;;;;5254:40;;;5068:234;;;;:::o;12367:1612::-;12488:28;12530:32;12576:28;12618:30;12662:22;12698:18;12730:21;12765:22;12801:27;12842;12883:29;12967:4;;;;;;;;;;;:28;;;12996:8;12967:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12967:38:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;12967:38:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;12967:38:26;;;;;;;;;;;;;;;;12960:56;;;13017:5;12960:63;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;12960:63:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;12960:63:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;12960:63:26;;;;;;;;;;;;;;;;12937:86;;13067:4;;;;;;;;;;;:28;;;13096:8;13067:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13067:38:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13067:38:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13067:38:26;;;;;;;;;;;;;;;;13060:66;;;13127:5;13060:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13060:73:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13060:73:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13060:73:26;;;;;;;;;;;;;;;;13033:100;;13143:33;13179:4;;;;;;;;;;;:33;;;13213:8;13223:5;13179:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13179:50:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13179:50:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13179:50:26;;;;;;;;;;;;;;;;13143:86;;13297:4;;;;;;;;;;;:26;;;13324:8;13334:5;13297:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13297:43:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13297:43:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13297:43:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;13239:101;;;;;;;;;13375:4;13367:13;;;;;;;;13350:30;;13411:34;13403:42;;;;;;;;:4;:42;;;;;;;;;:173;;13526:4;;;;;;;;;;;:40;;;13567:8;13526:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13526:50:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13526:50:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13526:50:26;;;;;;;;;;;;;;;;13403:173;;;13460:4;;;;;;;;;;;:34;;;13495:8;13505:5;13460:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13460:51:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13460:51:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13460:51:26;;;;;;;;;;;;;;;;13403:173;13390:186;;13602:4;;;;;;;;;;;:35;;;13638:8;13602:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13602:45:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13602:45:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13602:45:26;;;;;;;;;;;;;;;;13586:61;;13674:4;;;;;;;;;;;:26;;;13701:8;13711:5;13674:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13674:43:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13674:43:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13674:43:26;;;;;;;;;;;;;;;;13657:60;;13749:4;;;;;;;;;;;:41;;;13791:8;13801:5;13749:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13749:58:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13749:58:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13749:58:26;;;;;;;;;;;;;;;;13727:80;;13839:4;;;;;;;;;;;:22;;;13862:8;13872:5;13839:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13839:39:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13839:39:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13839:39:26;;;;;;;;;;;;;;;;13817:61;;13915:4;;;;;;;;;;;:40;;;13956:8;13966:5;13915:57;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;13915:57:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;13915:57:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;13915:57:26;;;;;;;;;;;;;;;;13888:84;;12367:1612;;;;;;;;;;;;;;;:::o;2150:2795::-;2256:32;2302:33;2349:29;2392:18;2424:35;2473:20;2522:19;2557:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2557:34:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2557:34:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2557:34:26;;;;;;;;;;;;;;;;2522:70;;2602:35;;:::i;:::-;2648:25;2676:4;;;;;;;;;;;:16;;;:18;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2676:18:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2676:18:26;;;;;;39:16:-1;36:1;17:17;2:54;2676:18:26;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;13:2;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2676:18:26;;;;;;19:11:-1;14:3;11:20;8:2;;;44:1;41;34:12;8:2;71:11;66:3;62:21;55:28;;123:4;118:3;114:14;159:9;141:16;138:31;135:2;;;182:1;179;172:12;135:2;219:3;213:10;331:9;325:2;311:12;307:21;289:16;285:44;282:59;261:11;247:12;244:29;233:116;230:2;;;362:1;359;352:12;230:2;0:373;;2676:18:26;;;;;;2648:46;;2710:9;2722:1;2710:13;;2705:1802;2729:8;:15;2725:1;:19;2705:1802;;;2801:4;;;;;;;;;;;:26;;;2828:8;2837:1;2828:11;;;;;;;;;;;;;;2841:5;2801:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2801:46:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2801:46:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2801:46:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2766:81;;;;2768:4;:28;;2766:81;;;;;2895:49;2925:8;2934:1;2925:11;;;;;;;;;;;;;;2938:5;2895:29;:49::i;:::-;2861:4;:31;;:83;;;;;2997:1;2962:4;:31;;;:36;:73;;;;;3034:1;3002:4;:28;;;:33;2962:73;2959:118;;;3054:8;;2959:118;3272:4;;;;;;;;;;;:28;;;3301:8;3310:1;3301:11;;;;;;;;;;;;;;3272:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3272:41:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3272:41:26;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;3272:41:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3124:189;;;3125:4;:20;;3159:4;:12;;3185:4;:25;;3224:4;:29;;3124:189;;;;;;;;;;;;;;;;;;;;;;;;3350:4;:20;;;3344:2;:26;3327:4;:14;;:43;;;;;3408:6;:20;;;3429:8;3438:1;3429:11;;;;;;;;;;;;;;3408:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3408:33:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3408:33:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3408:33:26;;;;;;;;;;;;;;;;3384:4;:21;;:57;;;;;3541:1;3507:4;:31;;;:35;3503:800;;;3564:27;3594:116;3678:4;:14;;;3594:58;3620:4;:31;;;3594:4;:21;;;:25;;:58;;;;:::i;:::-;:62;;:116;;;;:::i;:::-;3564:146;;3755:49;3784:19;3755:24;:28;;:49;;;;:::i;:::-;3728:76;;3827:4;:29;;;:93;;;;;3860:4;;;;;;;;;;;:40;;;3901:8;3910:1;3901:11;;;;;;;;;;;;;;3914:5;3860:60;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3860:60:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3860:60:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3860:60:26;;;;;;;;;;;;;;;;3827:93;3823:466;;;3972:50;4002:19;3972:25;:29;;:50;;;;:::i;:::-;3944:78;;4057:53;4072:37;4096:4;:12;;;4072:19;:23;;:37;;;;:::i;:::-;4057:10;:14;;:53;;;;:::i;:::-;4044:66;;4162:108;4219:50;4243:4;:25;;;4219:19;:23;;:50;;;;:::i;:::-;4162:27;:56;;:108;;;;:::i;:::-;4132:138;;3823:466;3503:800;;4352:1;4321:4;:28;;;:32;4317:180;;;4397:85;4423:58;4452:4;:28;;;4423:4;:21;;;:28;;:58;;;;:::i;:::-;4397:21;:25;;:85;;;;:::i;:::-;4373:109;;4317:180;2705:1802;2746:3;;;;;;;2705:1802;;;;4558:1;4530:25;:29;:77;;4606:1;4530:77;;;4562:41;4577:25;4562:10;:14;;:41;;;;:::i;:::-;4530:77;4517:90;;4675:1;4647:25;:29;:94;;4740:1;4647:94;;;4679:58;4711:25;4679:27;:31;;:58;;;;:::i;:::-;4647:94;4617:124;;4767:170;4822:25;4861:21;4896:27;4767:41;:170::i;:::-;4752:185;;2150:2795;;;;;;;;;;:::o;10097:1584::-;10199:22;10235:26;10275:25;10314:28;10356:21;10391:26;10431:23;10468:30;10512:23;10549:22;10585:27;10626:21;10661:26;10733:4;;;;;;;;;;;:29;;;10763:8;10733:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;10733:39:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;10733:39:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;10733:39:26;;;;;;;;;;;;;;;;10716:56;;10803:4;;;;;;;;;;;:33;;;10837:8;10803:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;10803:43:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;10803:43:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;10803:43:26;;;;;;;;;;;;;;;;10782:64;;10876:4;;;;;;;;;;;:32;;;10909:8;10876:42;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;10876:42:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;10876:42:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;10876:42:26;;;;;;;;;;;;;;;;10856:62;;10951:4;;;;;;;;;;;:35;;;10987:8;10951:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;10951:45:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;10951:45:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;10951:45:26;;;;;;;;;;;;;;;;10928:68;;11022:4;;;;;;;;;;;:35;;;11058:8;11022:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11022:45:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11022:45:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11022:45:26;;;;;;;;;;;;;;;;11006:61;;11098:4;;;;;;;;;;;:40;;;11139:8;11098:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11098:50:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11098:50:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11098:50:26;;;;;;;;;;;;;;;;11077:71;;11176:4;;;;;;;;;;;:37;;;11214:8;11176:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11176:47:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11176:47:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11176:47:26;;;;;;;;;;;;;;;;11158:65;;11258:4;;;;;;;;;;;:44;;;11303:8;11258:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11258:54:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11258:54:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11258:54:26;;;;;;;;;;;;;;;;11233:79;;11340:4;;;;;;;;;;;:30;;;11371:8;11340:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11340:40:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11340:40:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11340:40:26;;;;;;;;;;;;;;;;11322:58;;11407:4;;;;;;;;;;;:39;;;11447:8;11407:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11407:49:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11407:49:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11407:49:26;;;;;;;;;;;;;;;;11390:66;;11488:4;;;;;;;;;;;:45;;;11534:8;11488:55;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11488:55:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11488:55:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11488:55:26;;;;;;;;;;;;;;;;11466:77;;11569:4;;;;;;;;;;;:28;;;11598:8;11569:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11569:38:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11569:38:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11569:38:26;;;;;;;;;;;;;;;;11553:54;;11639:4;;;;;;;;;;;:25;;;11665:8;11639:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;11639:35:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;11639:35:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;11639:35:26;;;;;;;;;;;;;;;;11617:57;;10097:1584;;;;;;;;;;;;;;;:::o;9279:812::-;9394:11;9419:28;9461:27;9502;9543:29;9586:21;9621:27;9662:13;9831:4;;;;;;;;;;;:28;;;9860:8;9831:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9831:38:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9831:38:26;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;9831:38:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;9691:178;;;;;;;;;;;;;;;;;;;;;;;;;;9890:4;;;;;;;;;;;:23;;;9914:8;9890:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9890:33:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9890:33:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9890:33:26;;;;;;;;;;;;;;;;9879:44;;9955:4;;;;;;;;;;;:34;;;9990:8;9955:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9955:44:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9955:44:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9955:44:26;;;;;;;;;;;;;;;;9933:66;;10032:4;;;;;;;;;;;:42;;;10075:8;10032:52;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;10032:52:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;10032:52:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;10032:52:26;;;;;;;;;;;;;;;;10010:74;;9279:812;;;;;;;;;:::o;9140:132::-;9207:4;1294;9223:42;;9140:132;:::o;1642:137:57:-;1061:9;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1740:1;1703:40;;1724:6;;;;;;;;;;;1703:40;;;;;;;;;;;;1770:1;1753:6;;:19;;;;;;;;;;;;;;;;;;1642:137::o;6026:1763:26:-;6128:4;6145:43;;:::i;:::-;6326:4;;;;;;;;;;;:28;;;6355:8;6326:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6326:38:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6326:38:26;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;6326:38:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6199:165;;;;;;;;6200:4;:13;;6233:4;:32;;6275:4;:36;;6199:165;;;;;;;;;;;;;;;;;;;6379:4;:36;;;6378:37;:99;;;;6420:4;;;;;;;;;;;:40;;;6461:8;6471:5;6420:57;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6420:57:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6420:57:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6420:57:26;;;;;;;;;;;;;;;;6419:58;6378:99;6375:212;;;6499:4;6492:11;;;;;6375:212;6730:30;6754:5;6730:23;:30::i;:::-;6597:163;;;;;;;;;;6608:4;:25;;6643:4;:21;;6684:4;:32;;6597:163;;;;;;;;;;;;;;;6799:1;6774:4;:21;;;:26;6771:114;;;6822:4;6815:11;;;;;6771:114;6895:19;6930:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6930:34:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6930:34:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6930:34:26;;;;;;;;;;;;;;;;6895:70;;7003:107;7096:4;:13;;;7090:2;:19;7003:69;7064:7;7003:6;:33;;;7037:8;7003:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7003:43:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7003:43:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;7003:43:26;;;;;;;;;;;;;;;;:60;;:69;;;;:::i;:::-;:86;;:107;;;;:::i;:::-;6976:4;:24;;:134;;;;;7158:55;7188:4;:24;;;7158:4;:25;;;:29;;:55;;;;:::i;:::-;7121:4;:34;;:92;;;;;7265:210;7440:4;:34;;;7265:157;7359:62;7388:4;:32;;;7359:4;:24;;;:28;;:62;;;;:::i;:::-;7265:76;7308:4;:32;;;7265:4;:25;;;:42;;:76;;;;:::i;:::-;:93;;:157;;;;:::i;:::-;:174;;:210;;;;:::i;:::-;7224:4;:38;;:251;;;;;7487:33;7523:177;7578:4;:34;;;7626:4;:21;;;7661:4;:38;;;7523:41;:177::i;:::-;7487:213;;1294:4;7718:25;:63;7711:70;;;;;6026:1763;;;;;;:::o;857:77:57:-;895:7;921:6;;;;;;;;;;;914:13;;857:77;:::o;1208:92::-;1248:4;1287:6;;;;;;;;;;;1271:22;;:12;:10;:12::i;:::-;:22;;;1264:29;;1208:92;:::o;14112:408:26:-;14189:7;14208:23;14258:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14258:46:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14258:46:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14258:46:26;;;;;;;;;;;;;;;;14234:90;;;:92;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14234:92:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14234:92:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14234:92:26;;;;;;;;;;;;;;;;14208:118;;14336:19;14366:4;;;;;;;;;;;14336:35;;14382:12;14409:15;14397:27;;:8;:27;;;:91;;14456:8;14449:26;;;14476:11;14449:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;14449:39:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;14449:39:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;14449:39:26;;;;;;;;;;;;;;;;14397:91;;;14427:11;:19;;;14397:91;14382:106;;14506:7;14499:14;;;;;14112:408;;;:::o;11687:674::-;11790:25;11829:26;11869:23;11906:27;11947:35;11996:11;12021:20;12213:30;12237:5;12213:23;:30::i;:::-;12066:177;;;;;;;;;;;;;;;;;;;;;;;;12276:78;12313:18;12333:15;12350:3;12276:36;:78::i;:::-;12254:100;;11687:674;;;;;;;;;:::o;994:53::-;;;;;;;;;;;;;:::o;1928:107:57:-;1061:9;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2000:28;2019:8;2000:18;:28::i;:::-;1928:107;:::o;2159:459:56:-;2217:7;2463:1;2458;:6;2454:45;;;2487:1;2480:8;;;;2454:45;2509:9;2525:1;2521;:5;2509:17;;2553:1;2548;2544;:5;;;;;;:10;2536:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2610:1;2603:8;;;2159:459;;;;;:::o;3073:130::-;3131:7;3157:39;3161:1;3164;3157:39;;;;;;;;;;;;;;;;;:3;:39::i;:::-;3150:46;;3073:130;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;893:124:29:-;954:7;980:30;362:4;980:21;992:8;998:1;992;:5;;:8;;;;:::i;:::-;414:1;362:4;408:7;;;;;;980:11;;:21;;;;:::i;:::-;:25;;:30;;;;:::i;:::-;973:37;;893:124;;;;:::o;8740:393:26:-;8958:7;9005:1;8985:16;:21;8981:45;;;9023:2;9008:18;;;;8981:45;9044:82;9109:16;9045:55;9096:3;9045:46;9070:20;9045;:24;;:46;;;;:::i;:::-;:50;;:55;;;;:::i;:::-;9044:64;;:82;;;;:::i;:::-;9037:89;;8740:393;;;;;;:::o;1274:134:56:-;1332:7;1358:43;1362:1;1365;1358:43;;;;;;;;;;;;;;;;;:3;:43::i;:::-;1351:50;;1274:134;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7962:684:26:-;8124:7;8144:24;8171:38;8205:3;8171:29;8196:3;8171:20;:24;;:29;;;;:::i;:::-;:33;;:38;;;;:::i;:::-;8144:65;;8268:16;8246:19;:38;8243:75;;;8306:1;8299:8;;;;;8243:75;8350:41;8374:16;8350:19;:23;;:41;;;;:::i;:::-;8328:63;;8425:17;8458;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8458:34:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8458:34:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8458:34:26;;;;;;;;;;;;;;;;8445:76;;;8535:10;8559:19;8445:143;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8445:143:26;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8445:143:26;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8445:143:26;;;;;;;;;;;;;;;;8425:163;;8605:34;8629:9;8605:19;:23;;:34;;;;:::i;:::-;8598:41;;;;7962:684;;;;;;:::o;2136:225:57:-;2229:1;2209:22;;:8;:22;;;;2201:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2318:8;2289:38;;2310:6;;;;;;;;;;;2289:38;;;;;;;;;;;;2346:8;2337:6;;:17;;;;;;;;;;;;;;;;;;2136:225;:::o;3718:338:56:-;3804:7;3901:1;3897;:5;3904:12;3889:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;3889:28:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3927:9;3943:1;3939;:5;;;;;;3927:17;;4048:1;4041:8;;;3718:338;;;;;:::o;1023:154:29:-;1084:7;1103:13;1123:1;1119;:5;;;;;;1103:21;;1142:28;1168:1;1142:21;1152:10;362:4;1152:1;:5;;:10;;;;:::i;:::-;1142:5;:9;;:21;;;;:::i;:::-;:25;;:28;;;;:::i;:::-;1135:35;;;1023:154;;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;851:13671:26:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/ownership/Ownable.sol\";\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\n\nimport \"../libraries/CoreLibrary.sol\";\nimport \"../configuration/LendingPoolAddressesProvider.sol\";\nimport \"../configuration/NetworkMetadataProvider.sol\";\nimport \"../libraries/WadRayMath.sol\";\nimport \"../interfaces/IFeeProvider.sol\";\nimport \"../tokenization/AToken.sol\";\n\nimport \"./LendingPoolCore.sol\";\n\n\n\n/*************************************************************************************\n@title LendingPoolDataProvider contract\n@author Aave\n@notice Implements functions to fetch data from the core, and aggregate them in order to allow computation\non the compounded balances and the account balances in ETH\n *************************************************************************************/\n\ncontract LendingPoolDataProvider is Ownable {\n using SafeMath for uint256;\n using WadRayMath for uint256;\n\n LendingPoolCore core;\n LendingPoolAddressesProvider public addressesProvider;\n\n /**\n @dev specifies the health factor threshold at which the user position is liquidated.\n 1 by default, if the health factor drops below 1, the loan gets liquidated.\n */\n uint256 constant HEALTH_FACTOR_LIQUIDATION_THRESHOLD = 1e18;\n\n\n constructor(LendingPoolAddressesProvider _addressesProvider) public {\n addressesProvider = _addressesProvider;\n core = LendingPoolCore(_addressesProvider.getLendingPoolCore());\n }\n\n /**\n @dev struct to hold calculateUserGlobalData() local computations\n */\n struct UserGlobalDataLocalVars {\n uint256 reserveUnitPrice;\n uint256 tokenUnit;\n uint256 compoundedLiquidityBalance;\n uint256 compoundedBorrowBalance;\n uint256 reserveDecimals;\n uint256 baseLtv;\n uint256 liquidationThreshold;\n bool usageAsCollateralEnabled;\n }\n\n /**\n @notice calculates the user data across the reserves.\n this includes the total liquidity/collateral/borrow balances in ETH,\n the average Loan To Value, the average Liquidation Ratio, and the Health factor.\n */\n function calculateUserGlobalData(address _user)\n public\n view\n returns (\n uint256 totalLiquidityBalanceETH,\n uint256 totalCollateralBalanceETH,\n uint256 totalBorrowBalanceETH,\n uint256 currentLtv,\n uint256 currentLiquidationThreshold,\n uint256 healthFactor\n )\n {\n IPriceOracle oracle = IPriceOracle(addressesProvider.getPriceOracle());\n UserGlobalDataLocalVars memory vars;\n\n address[] memory reserves = core.getReserves();\n\n for (uint256 i = 0; i < reserves.length; i++) {\n\n (,vars.compoundedBorrowBalance,) = core.getUserBorrowBalances(reserves[i], _user);\n vars.compoundedLiquidityBalance = getUserUnderlyingAssetBalance(reserves[i], _user);\n\n if(vars.compoundedLiquidityBalance == 0 && vars.compoundedBorrowBalance == 0){\n continue;\n }\n\n //fetch reserve data\n (vars.reserveDecimals,\n vars.baseLtv,\n vars.liquidationThreshold,\n vars.usageAsCollateralEnabled,\n ,) = core.getReserveConfiguration(reserves[i]);\n vars.tokenUnit = 10 ** vars.reserveDecimals;\n vars.reserveUnitPrice = oracle.getAssetPrice(reserves[i]);\n\n //liquidity and collateral balance\n if (vars.compoundedLiquidityBalance > 0) {\n\n\n uint256 liquidityBalanceETH = vars.reserveUnitPrice.mul(vars.compoundedLiquidityBalance).div(\n vars.tokenUnit\n );\n totalLiquidityBalanceETH = totalLiquidityBalanceETH.add(liquidityBalanceETH);\n\n if (vars.usageAsCollateralEnabled && core.isUserUseReserveAsCollateralEnabled(reserves[i], _user)) {\n totalCollateralBalanceETH = totalCollateralBalanceETH.add(liquidityBalanceETH);\n currentLtv = currentLtv.add(liquidityBalanceETH.mul(vars.baseLtv));\n currentLiquidationThreshold = currentLiquidationThreshold\n .add(liquidityBalanceETH.mul(vars.liquidationThreshold));\n }\n }\n\n if (vars.compoundedBorrowBalance > 0) {\n totalBorrowBalanceETH = totalBorrowBalanceETH.add(vars.reserveUnitPrice.wadMul(vars.compoundedBorrowBalance));\n }\n }\n\n currentLtv = totalCollateralBalanceETH > 0 ? currentLtv.div(totalCollateralBalanceETH) : 0;\n currentLiquidationThreshold = totalCollateralBalanceETH > 0 ? currentLiquidationThreshold.div(totalCollateralBalanceETH) : 0;\n\n healthFactor = calculateHealthFactorFromBalancesInternal(\n totalCollateralBalanceETH,\n totalBorrowBalanceETH,\n currentLiquidationThreshold\n );\n\n }\n\n\n /**\n @notice gets the underlying asset balance of a user based on the corresponding aToken balance.\n */\n\n function getUserUnderlyingAssetBalance(address _reserve, address _user) public view returns (uint256) {\n\n AToken aToken = AToken(core.getReserveATokenAddress(_reserve));\n\n return aToken.balanceOfUnderlying(_user);\n\n }\n /**\n @notice check if a specific balance decrease is allowed (i.e. doesn't bring the user borrow position health factor under 1)\n Used by the transferInternal() method of the aToken contract to check if a transfer of tokens is allowed.\n */\n\n struct balanceDecreaseAllowedLocalVars {\n uint256 decimals;\n uint256 collateralBalanceETH;\n uint256 borrowBalanceETH;\n uint256 currentLiquidationThreshold;\n uint256 reserveLiquidationThreshold;\n uint256 amountToDecreaseETH;\n uint256 collateralBalancefterDecrease;\n uint256 liquidationThresholdAfterDecrease;\n uint256 healthFactorAfterDecrease;\n bool reserveUsageAsCollateralEnabled;\n }\n\n function balanceDecreaseAllowed(address _reserve, address _user, uint _amount) external view returns (bool) {\n\n balanceDecreaseAllowedLocalVars memory vars;\n\n (vars.decimals,\n ,\n vars.reserveLiquidationThreshold,\n vars.reserveUsageAsCollateralEnabled,\n ,) = core.getReserveConfiguration(_reserve);\n\n if(!vars.reserveUsageAsCollateralEnabled || !core.isUserUseReserveAsCollateralEnabled(_reserve, _user)){\n return true; //if reserve is not used as collateral, no reasons to block the transfer\n }\n\n (,\n vars.collateralBalanceETH,\n vars.borrowBalanceETH,\n ,\n vars.currentLiquidationThreshold,\n ) = calculateUserGlobalData(_user);\n\n if(vars.borrowBalanceETH == 0){\n return true; //no borrows - no reasons to block the transfer\n }\n\n IPriceOracle oracle = IPriceOracle(addressesProvider.getPriceOracle());\n\n vars.amountToDecreaseETH = oracle\n .getAssetPrice(_reserve)\n .mul(_amount)\n .div(10 ** vars.decimals);\n\n vars.collateralBalancefterDecrease = vars.collateralBalanceETH.sub(vars.amountToDecreaseETH);\n\n vars.liquidationThresholdAfterDecrease = vars.collateralBalanceETH\n .mul(vars.currentLiquidationThreshold)\n .sub(vars.amountToDecreaseETH.mul(vars.reserveLiquidationThreshold))\n .div(vars.collateralBalancefterDecrease);\n\n\n uint256 healthFactorAfterDecrease = calculateHealthFactorFromBalancesInternal(\n vars.collateralBalancefterDecrease,\n vars.borrowBalanceETH,\n vars.liquidationThresholdAfterDecrease);\n\n return healthFactorAfterDecrease > HEALTH_FACTOR_LIQUIDATION_THRESHOLD;\n\n }\n\n /**\n @notice calculates the equivalent amount in ETH that an user can borrow, depeding on the available collateral and the\n average Loan To Value.\n */\n\n function calculateAvailableBorrowsETHInternal(uint256 collateralBalanceETH, uint256 borrowBalanceETH, uint256 ltv)\n internal\n view\n returns (uint256) {\n\n uint availableBorrowsETH = collateralBalanceETH.mul(ltv).div(100); //ltv is in percentage\n\n if(availableBorrowsETH < borrowBalanceETH){\n return 0;\n }\n\n availableBorrowsETH = availableBorrowsETH.sub(borrowBalanceETH);\n //calculate fee\n uint256 borrowFee = IFeeProvider(addressesProvider.getFeeProvider()).calculateLoanOriginationFee(\n msg.sender,\n availableBorrowsETH\n );\n return availableBorrowsETH.sub(borrowFee);\n }\n\n /**\n @notice calculates the health factor from the corresponding balances\n */\n function calculateHealthFactorFromBalancesInternal(\n uint256 collateralBalanceETH,\n uint256 borrowBalanceETH,\n uint256 liquidationThreshold\n )\n internal\n pure\n returns (uint256)\n {\n if (borrowBalanceETH == 0) return uint256(-1);\n\n return (collateralBalanceETH.mul(liquidationThreshold).div(100)).wadDiv(borrowBalanceETH);\n }\n\n\n function getHealthFactorLiquidationThreshold() public pure returns(uint) {\n return HEALTH_FACTOR_LIQUIDATION_THRESHOLD;\n }\n\n\n function getReserveConfigurationData(address _reserve)\n external\n view\n returns (\n uint256 ltv,\n uint256 liquidationThreshold,\n uint256 liquidationDiscount,\n address rateStrategyAddress,\n bool usageAsCollateralEnabled,\n bool borrowingEnabled,\n bool fixedBorrowRateEnabled,\n bool isActive)\n {\n (,\n ltv,\n liquidationThreshold,\n usageAsCollateralEnabled,\n fixedBorrowRateEnabled,\n borrowingEnabled) = core.getReserveConfiguration(_reserve);\n isActive = core.getReserveIsActive(_reserve);\n liquidationDiscount = core.getReserveLiquidationDiscount(_reserve);\n\n rateStrategyAddress = core.getReserveInterestRateStrategyAddress(_reserve);\n }\n\n function getReserveData(address _reserve)\n external\n view\n returns (\n uint256 totalLiquidity,\n uint256 availableLiquidity,\n uint256 totalBorrowsFixed,\n uint256 totalBorrowsVariable,\n uint256 liquidityRate,\n uint256 variableBorrowRate,\n uint256 fixedBorrowRate,\n uint256 averageFixedBorrowRate,\n uint256 utilizationRate,\n uint256 liquidityIndex,\n uint256 variableBorrowIndex,\n address aTokenAddress,\n uint40 lastUpdateTimestamp\n )\n {\n totalLiquidity = core.getReserveTotalLiquidity(_reserve);\n availableLiquidity = core.getReserveAvailableLiquidity(_reserve);\n totalBorrowsFixed = core.getReserveTotalBorrowsFixed(_reserve);\n totalBorrowsVariable = core.getReserveTotalBorrowsVariable(_reserve);\n liquidityRate = core.getReserveCurrentLiquidityRate(_reserve);\n variableBorrowRate = core.getReserveCurrentVariableBorrowRate(_reserve);\n fixedBorrowRate = core.getReserveCurrentFixedBorrowRate(_reserve);\n averageFixedBorrowRate = core.getReserveCurrentAverageFixedBorrowRate(_reserve);\n utilizationRate = core.getReserveUtilizationRate(_reserve);\n liquidityIndex = core.getReserveLiquidityCumulativeIndex(_reserve);\n variableBorrowIndex = core.getReserveVariableBorrowsCumulativeIndex(_reserve);\n aTokenAddress = core.getReserveATokenAddress(_reserve);\n lastUpdateTimestamp = core.getReserveLastUpdate(_reserve);\n }\n\n function getUserAccountData(address _user)\n external\n view\n returns (\n uint256 totalLiquidityETH,\n uint256 totalCollateralETH,\n uint256 totalBorrowsETH,\n uint256 availableBorrowsETH,\n uint256 currentLiquidationThreshold,\n uint256 ltv,\n uint256 healthFactor\n )\n {\n (totalLiquidityETH,\n totalCollateralETH,\n totalBorrowsETH,\n ltv,\n currentLiquidationThreshold,\n healthFactor) = calculateUserGlobalData(_user);\n\n availableBorrowsETH = calculateAvailableBorrowsETHInternal(totalCollateralETH, totalBorrowsETH, ltv);\n }\n\n function getUserReserveData(address _reserve, address _user)\n external\n view\n returns (\n uint256 currentATokenBalance,\n uint256 currentUnderlyingBalance,\n uint256 currentBorrowBalance,\n uint256 principalBorrowBalance,\n uint256 borrowRateMode,\n uint256 borrowRate,\n uint256 liquidityRate,\n uint256 originationFee,\n uint256 variableBorrowIndex,\n uint256 lastUpdateTimestamp,\n bool usageAsCollateralEnabled\n )\n {\n currentATokenBalance = AToken(core.getReserveATokenAddress(_reserve)).balanceOf(_user);\n currentUnderlyingBalance = AToken(core.getReserveATokenAddress(_reserve)).balanceOfUnderlying(_user);\n CoreLibrary.InterestRateMode mode = core.getUserCurrentBorrowRateMode(_reserve, _user);\n (principalBorrowBalance,\n currentBorrowBalance,) = core.getUserBorrowBalances(_reserve, _user);\n borrowRateMode = uint256(mode);\n borrowRate = mode == CoreLibrary.InterestRateMode.FIXED\n ? core.getUserCurrentFixedBorrowRate(_reserve, _user)\n : core.getReserveCurrentVariableBorrowRate(_reserve);\n liquidityRate = core.getReserveCurrentLiquidityRate(_reserve);\n originationFee = core.getUserOriginationFee(_reserve, _user);\n variableBorrowIndex = core.getUserVariableBorrowCumulativeIndex(_reserve, _user);\n lastUpdateTimestamp = core.getUserLastUpdate(_reserve, _user);\n usageAsCollateralEnabled = core.isUserUseReserveAsCollateralEnabled(_reserve, _user);\n }\n\n /**\n @dev provides the actual balance of a reserve, by checking the core balance of the underlying ERC20/Ether\n */\n\n function getCoreActualReserveBalance(address _reserve) external view returns(uint256){\n\n address ethereumAddress = NetworkMetadataProvider(addressesProvider.getNetworkMetadataProvider()).getEthereumAddress();\n address coreAddress = address(core);\n\n uint balance = _reserve == ethereumAddress ? coreAddress.balance : IERC20(_reserve).balanceOf(coreAddress);\n\n return balance;\n }\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol", + "exportedSymbols": { + "LendingPoolDataProvider": [ + 7660 + ] + }, + "id": 7661, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 6684, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:26" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "id": 6685, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 11255, + "src": "25:63:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 6686, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 11141, + "src": "89:59:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "file": "../libraries/CoreLibrary.sol", + "id": 6687, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 8995, + "src": "150:38:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 6688, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 1358, + "src": "189:59:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "file": "../configuration/NetworkMetadataProvider.sol", + "id": 6689, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 1479, + "src": "249:54:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 6690, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 9175, + "src": "304:37:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "file": "../interfaces/IFeeProvider.sol", + "id": 6691, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 1766, + "src": "342:40:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "file": "../tokenization/AToken.sol", + "id": 6692, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 10328, + "src": "383:36:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "./LendingPoolCore.sol", + "id": 6693, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 6683, + "src": "421:31:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 6694, + "name": "Ownable", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11254, + "src": "887:7:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Ownable_$11254", + "typeString": "contract Ownable" + } + }, + "id": 6695, + "nodeType": "InheritanceSpecifier", + "src": "887:7:26" + } + ], + "contractDependencies": [ + 10953, + 11254 + ], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title LendingPoolDataProvider contract\n@author Aave\n@notice Implements functions to fetch data from the core, and aggregate them in order to allow computation\non the compounded balances and the account balances in ETH************************************************************************************", + "fullyImplemented": true, + "id": 7660, + "linearizedBaseContracts": [ + 7660, + 11254, + 10953 + ], + "name": "LendingPoolDataProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 6698, + "libraryName": { + "contractScope": null, + "id": 6696, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "907:8:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "901:27:26", + "typeName": { + "id": 6697, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "920:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 6701, + "libraryName": { + "contractScope": null, + "id": 6699, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "939:10:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "933:29:26", + "typeName": { + "id": 6700, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "954:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "constant": false, + "id": 6703, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 7660, + "src": "968:20:26", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 6702, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "968:15:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6705, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 7660, + "src": "994:53:26", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 6704, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "994:28:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": true, + "id": 6708, + "name": "HEALTH_FACTOR_LIQUIDATION_THRESHOLD", + "nodeType": "VariableDeclaration", + "scope": 7660, + "src": "1239:59:26", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6706, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1239:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "31653138", + "id": 6707, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1294:4:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000_by_1", + "typeString": "int_const 1000000000000000000" + }, + "value": "1e18" + }, + "visibility": "internal" + }, + { + "body": { + "id": 6725, + "nodeType": "Block", + "src": "1374:128:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6715, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6713, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6705, + "src": "1384:17:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 6714, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6710, + "src": "1404:18:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "1384:38:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6716, + "nodeType": "ExpressionStatement", + "src": "1384:38:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6723, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6717, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "1432:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 6719, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6710, + "src": "1455:18:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6720, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "1455:37:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 6721, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1455:39:26", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 6718, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "1439:15:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 6722, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1439:56:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "src": "1432:63:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6724, + "nodeType": "ExpressionStatement", + "src": "1432:63:26" + } + ] + }, + "documentation": null, + "id": 6726, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6711, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6710, + "name": "_addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 6726, + "src": "1318:47:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 6709, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1318:28:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1317:49:26" + }, + "returnParameters": { + "id": 6712, + "nodeType": "ParameterList", + "parameters": [], + "src": "1374:0:26" + }, + "scope": 7660, + "src": "1306:196:26", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "canonicalName": "LendingPoolDataProvider.UserGlobalDataLocalVars", + "id": 6743, + "members": [ + { + "constant": false, + "id": 6728, + "name": "reserveUnitPrice", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1634:24:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6727, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1634:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6730, + "name": "tokenUnit", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1668:17:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6729, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1668:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6732, + "name": "compoundedLiquidityBalance", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1695:34:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6731, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1695:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6734, + "name": "compoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1739:31:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6733, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1739:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6736, + "name": "reserveDecimals", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1780:23:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6735, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1780:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6738, + "name": "baseLtv", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1813:15:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6737, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1813:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6740, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1838:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6739, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1838:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6742, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1876:29:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 6741, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "1876:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "UserGlobalDataLocalVars", + "nodeType": "StructDefinition", + "scope": 7660, + "src": "1593:319:26", + "visibility": "public" + }, + { + "body": { + "id": 6983, + "nodeType": "Block", + "src": "2512:2433:26", + "statements": [ + { + "assignments": [ + 6761 + ], + "declarations": [ + { + "constant": false, + "id": 6761, + "name": "oracle", + "nodeType": "VariableDeclaration", + "scope": 6983, + "src": "2522:19:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + }, + "typeName": { + "contractScope": null, + "id": 6760, + "name": "IPriceOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1959, + "src": "2522:12:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6767, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 6763, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6705, + "src": "2557:17:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6764, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getPriceOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1266, + "src": "2557:32:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 6765, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2557:34:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6762, + "name": "IPriceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1959, + "src": "2544:12:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IPriceOracle_$1959_$", + "typeString": "type(contract IPriceOracle)" + } + }, + "id": 6766, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2544:48:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2522:70:26" + }, + { + "assignments": [ + 6769 + ], + "declarations": [ + { + "constant": false, + "id": 6769, + "name": "vars", + "nodeType": "VariableDeclaration", + "scope": 6983, + "src": "2602:35:26", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars" + }, + "typeName": { + "contractScope": null, + "id": 6768, + "name": "UserGlobalDataLocalVars", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6743, + "src": "2602:23:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_storage_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6770, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "2602:35:26" + }, + { + "assignments": [ + 6774 + ], + "declarations": [ + { + "constant": false, + "id": 6774, + "name": "reserves", + "nodeType": "VariableDeclaration", + "scope": 6983, + "src": "2648:25:26", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 6772, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2648:7:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 6773, + "length": null, + "nodeType": "ArrayTypeName", + "src": "2648:9:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6778, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 6775, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "2676:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6776, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserves", + "nodeType": "MemberAccess", + "referencedDeclaration": 6134, + "src": "2676:16:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_array$_t_address_$dyn_memory_ptr_$", + "typeString": "function () view external returns (address[] memory)" + } + }, + "id": 6777, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2676:18:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2648:46:26" + }, + { + "body": { + "id": 6949, + "nodeType": "Block", + "src": "2751:1756:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6801, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6790, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "2768:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6792, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "compoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6734, + "src": "2768:28:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + null + ], + "id": 6793, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "2766:32:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$_t_uint256_$__$", + "typeString": "tuple(,uint256,)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6796, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "2828:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6798, + "indexExpression": { + "argumentTypes": null, + "id": 6797, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "2837:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2828:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 6799, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6745, + "src": "2841:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6794, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "2801:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6795, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "2801:26:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 6800, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2801:46:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "src": "2766:81:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6802, + "nodeType": "ExpressionStatement", + "src": "2766:81:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6812, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6803, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "2861:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6805, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "compoundedLiquidityBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6732, + "src": "2861:31:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6807, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "2925:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6809, + "indexExpression": { + "argumentTypes": null, + "id": 6808, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "2934:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2925:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 6810, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6745, + "src": "2938:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6806, + "name": "getUserUnderlyingAssetBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7008, + "src": "2895:29:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view returns (uint256)" + } + }, + "id": 6811, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2895:49:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2861:83:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6813, + "nodeType": "ExpressionStatement", + "src": "2861:83:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 6822, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6817, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6814, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "2962:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6815, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedLiquidityBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6732, + "src": "2962:31:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6816, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2997:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "2962:36:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "&&", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6821, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6818, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3002:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6819, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6734, + "src": "3002:28:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6820, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3034:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3002:33:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "2962:73:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6825, + "nodeType": "IfStatement", + "src": "2959:118:26", + "trueBody": { + "id": 6824, + "nodeType": "Block", + "src": "3036:41:26", + "statements": [ + { + "id": 6823, + "nodeType": "Continue", + "src": "3054:8:26" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 6842, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6826, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3125:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6828, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "reserveDecimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 6736, + "src": "3125:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6829, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3159:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6830, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "baseLtv", + "nodeType": "MemberAccess", + "referencedDeclaration": 6738, + "src": "3159:12:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6831, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3185:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6832, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 6740, + "src": "3185:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6833, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3224:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6834, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 6742, + "src": "3224:29:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + null, + null + ], + "id": 6835, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "3124:145:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$__$__$", + "typeString": "tuple(uint256,uint256,uint256,bool,,)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6838, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "3301:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6840, + "indexExpression": { + "argumentTypes": null, + "id": 6839, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "3310:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "3301:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6836, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "3272:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6837, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveConfiguration", + "nodeType": "MemberAccess", + "referencedDeclaration": 5813, + "src": "3272:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,bool,bool,bool)" + } + }, + "id": 6841, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3272:41:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "tuple(uint256,uint256,uint256,bool,bool,bool)" + } + }, + "src": "3124:189:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6843, + "nodeType": "ExpressionStatement", + "src": "3124:189:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6851, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6844, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3327:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6846, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "tokenUnit", + "nodeType": "MemberAccess", + "referencedDeclaration": 6730, + "src": "3327:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6850, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "3130", + "id": 6847, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3344:2:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_10_by_1", + "typeString": "int_const 10" + }, + "value": "10" + }, + "nodeType": "BinaryOperation", + "operator": "**", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6848, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3350:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6849, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "reserveDecimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 6736, + "src": "3350:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3344:26:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3327:43:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6852, + "nodeType": "ExpressionStatement", + "src": "3327:43:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6862, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6853, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3384:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6855, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "reserveUnitPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 6728, + "src": "3384:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6858, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "3429:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6860, + "indexExpression": { + "argumentTypes": null, + "id": 6859, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "3438:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "3429:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6856, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6761, + "src": "3408:6:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 6857, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getAssetPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 1941, + "src": "3408:20:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 6861, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3408:33:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3384:57:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6863, + "nodeType": "ExpressionStatement", + "src": "3384:57:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6867, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6864, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3507:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6865, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedLiquidityBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6732, + "src": "3507:31:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6866, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3541:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3507:35:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6930, + "nodeType": "IfStatement", + "src": "3503:800:26", + "trueBody": { + "id": 6929, + "nodeType": "Block", + "src": "3544:759:26", + "statements": [ + { + "assignments": [ + 6869 + ], + "declarations": [ + { + "constant": false, + "id": 6869, + "name": "liquidityBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 6929, + "src": "3564:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6868, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3564:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6880, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6877, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3678:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6878, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "tokenUnit", + "nodeType": "MemberAccess", + "referencedDeclaration": 6730, + "src": "3678:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6873, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3620:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6874, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedLiquidityBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6732, + "src": "3620:31:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6870, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3594:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6871, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "reserveUnitPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 6728, + "src": "3594:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6872, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "3594:25:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6875, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3594:58:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6876, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "3594:62:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6879, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3594:116:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3564:146:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6886, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6881, + "name": "totalLiquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6748, + "src": "3728:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6884, + "name": "liquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6869, + "src": "3784:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6882, + "name": "totalLiquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6748, + "src": "3755:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6883, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "3755:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6885, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3755:49:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3728:76:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6887, + "nodeType": "ExpressionStatement", + "src": "3728:76:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 6897, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6888, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3827:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6889, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 6742, + "src": "3827:29:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "&&", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6892, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "3901:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6894, + "indexExpression": { + "argumentTypes": null, + "id": 6893, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "3910:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "3901:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 6895, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6745, + "src": "3914:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6890, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "3860:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6891, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "3860:40:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 6896, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3860:60:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "3827:93:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6928, + "nodeType": "IfStatement", + "src": "3823:466:26", + "trueBody": { + "id": 6927, + "nodeType": "Block", + "src": "3922:367:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6903, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6898, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "3944:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6901, + "name": "liquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6869, + "src": "4002:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6899, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "3972:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6900, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "3972:29:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6902, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3972:50:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3944:78:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6904, + "nodeType": "ExpressionStatement", + "src": "3944:78:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6914, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6905, + "name": "currentLtv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6754, + "src": "4044:10:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6910, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "4096:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6911, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "baseLtv", + "nodeType": "MemberAccess", + "referencedDeclaration": 6738, + "src": "4096:12:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6908, + "name": "liquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6869, + "src": "4072:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6909, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "4072:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6912, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4072:37:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6906, + "name": "currentLtv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6754, + "src": "4057:10:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6907, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "4057:14:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6913, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4057:53:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4044:66:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6915, + "nodeType": "ExpressionStatement", + "src": "4044:66:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6925, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6916, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6756, + "src": "4132:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6921, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "4243:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6922, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 6740, + "src": "4243:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6919, + "name": "liquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6869, + "src": "4219:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6920, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "4219:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6923, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4219:50:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6917, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6756, + "src": "4162:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6918, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "4162:56:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6924, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4162:108:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4132:138:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6926, + "nodeType": "ExpressionStatement", + "src": "4132:138:26" + } + ] + } + } + ] + } + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6934, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6931, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "4321:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6932, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6734, + "src": "4321:28:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6933, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4352:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "4321:32:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6948, + "nodeType": "IfStatement", + "src": "4317:180:26", + "trueBody": { + "id": 6947, + "nodeType": "Block", + "src": "4355:142:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6945, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6935, + "name": "totalBorrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6752, + "src": "4373:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6941, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "4452:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6942, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6734, + "src": "4452:28:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6938, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "4423:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6939, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "reserveUnitPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 6728, + "src": "4423:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6940, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9072, + "src": "4423:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6943, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4423:58:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6936, + "name": "totalBorrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6752, + "src": "4397:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6937, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "4397:25:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6944, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4397:85:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4373:109:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6946, + "nodeType": "ExpressionStatement", + "src": "4373:109:26" + } + ] + } + } + ] + }, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6786, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6783, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "2725:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6784, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "2729:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6785, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "length", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2729:15:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2725:19:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6950, + "initializationExpression": { + "assignments": [ + 6780 + ], + "declarations": [ + { + "constant": false, + "id": 6780, + "name": "i", + "nodeType": "VariableDeclaration", + "scope": 6950, + "src": "2710:9:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6779, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2710:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6782, + "initialValue": { + "argumentTypes": null, + "hexValue": "30", + "id": 6781, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2722:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "nodeType": "VariableDeclarationStatement", + "src": "2710:13:26" + }, + "loopExpression": { + "expression": { + "argumentTypes": null, + "id": 6788, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "++", + "prefix": false, + "src": "2746:3:26", + "subExpression": { + "argumentTypes": null, + "id": 6787, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "2746:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6789, + "nodeType": "ExpressionStatement", + "src": "2746:3:26" + }, + "nodeType": "ForStatement", + "src": "2705:1802:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6961, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6951, + "name": "currentLtv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6754, + "src": "4517:10:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6954, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6952, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "4530:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6953, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4558:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "4530:29:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6959, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4606:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "id": 6960, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "4530:77:26", + "trueExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6957, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "4577:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6955, + "name": "currentLtv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6754, + "src": "4562:10:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6956, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "4562:14:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6958, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4562:41:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4517:90:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6962, + "nodeType": "ExpressionStatement", + "src": "4517:90:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6973, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6963, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6756, + "src": "4617:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6966, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6964, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "4647:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6965, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4675:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "4647:29:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6971, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4740:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "id": 6972, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "4647:94:26", + "trueExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6969, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "4711:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6967, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6756, + "src": "4679:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6968, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "4679:31:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6970, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4679:58:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4617:124:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6974, + "nodeType": "ExpressionStatement", + "src": "4617:124:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6981, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6975, + "name": "healthFactor", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6758, + "src": "4752:12:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6977, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "4822:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 6978, + "name": "totalBorrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6752, + "src": "4861:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 6979, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6756, + "src": "4896:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 6976, + "name": "calculateHealthFactorFromBalancesInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7255, + "src": "4767:41:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,uint256) pure returns (uint256)" + } + }, + "id": 6980, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4767:170:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4752:185:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6982, + "nodeType": "ExpressionStatement", + "src": "4752:185:26" + } + ] + }, + "documentation": "@notice calculates the user data across the reserves.\nthis includes the total liquidity/collateral/borrow balances in ETH,\nthe average Loan To Value, the average Liquidation Ratio, and the Health factor.", + "id": 6984, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateUserGlobalData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6746, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6745, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2183:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6744, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2183:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2182:15:26" + }, + "returnParameters": { + "id": 6759, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6748, + "name": "totalLiquidityBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2256:32:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6747, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2256:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6750, + "name": "totalCollateralBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2302:33:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6749, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2302:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6752, + "name": "totalBorrowBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2349:29:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6751, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2349:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6754, + "name": "currentLtv", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2392:18:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6753, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2392:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6756, + "name": "currentLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2424:35:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6755, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2424:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6758, + "name": "healthFactor", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2473:20:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6757, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2473:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2242:265:26" + }, + "scope": 7660, + "src": "2150:2795:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 7007, + "nodeType": "Block", + "src": "5170:132:26", + "statements": [ + { + "assignments": [ + 6994 + ], + "declarations": [ + { + "constant": false, + "id": 6994, + "name": "aToken", + "nodeType": "VariableDeclaration", + "scope": 7007, + "src": "5181:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + }, + "typeName": { + "contractScope": null, + "id": 6993, + "name": "AToken", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10327, + "src": "5181:6:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7001, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6998, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6986, + "src": "5233:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6996, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "5204:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6997, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "5204:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 6999, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5204:38:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6995, + "name": "AToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10327, + "src": "5197:6:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_AToken_$10327_$", + "typeString": "type(contract AToken)" + } + }, + "id": 7000, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5197:46:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5181:62:26" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7004, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6988, + "src": "5288:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7002, + "name": "aToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6994, + "src": "5261:6:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 7003, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOfUnderlying", + "nodeType": "MemberAccess", + "referencedDeclaration": 10212, + "src": "5261:26:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7005, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5261:33:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 6992, + "id": 7006, + "nodeType": "Return", + "src": "5254:40:26" + } + ] + }, + "documentation": "@notice gets the underlying asset balance of a user based on the corresponding aToken balance.", + "id": 7008, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserUnderlyingAssetBalance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6989, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6986, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7008, + "src": "5107:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6985, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5107:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6988, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 7008, + "src": "5125:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6987, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5125:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5106:33:26" + }, + "returnParameters": { + "id": 6992, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6991, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7008, + "src": "5161:7:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6990, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5161:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5160:9:26" + }, + "scope": 7660, + "src": "5068:234:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "canonicalName": "LendingPoolDataProvider.balanceDecreaseAllowedLocalVars", + "id": 7029, + "members": [ + { + "constant": false, + "id": 7010, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5611:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7009, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5611:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7012, + "name": "collateralBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5637:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7011, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5637:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7014, + "name": "borrowBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5675:24:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7013, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5675:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7016, + "name": "currentLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5709:35:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7015, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5709:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7018, + "name": "reserveLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5754:35:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7017, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5754:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7020, + "name": "amountToDecreaseETH", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5799:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7019, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5799:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7022, + "name": "collateralBalancefterDecrease", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5836:37:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7021, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5836:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7024, + "name": "liquidationThresholdAfterDecrease", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5883:41:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7023, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5883:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7026, + "name": "healthFactorAfterDecrease", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5934:33:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7025, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5934:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7028, + "name": "reserveUsageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5977:36:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7027, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "5977:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "balanceDecreaseAllowedLocalVars", + "nodeType": "StructDefinition", + "scope": 7660, + "src": "5562:458:26", + "visibility": "public" + }, + { + "body": { + "id": 7167, + "nodeType": "Block", + "src": "6134:1655:26", + "statements": [ + { + "assignments": [ + 7041 + ], + "declarations": [ + { + "constant": false, + "id": 7041, + "name": "vars", + "nodeType": "VariableDeclaration", + "scope": 7167, + "src": "6145:43:26", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars" + }, + "typeName": { + "contractScope": null, + "id": 7040, + "name": "balanceDecreaseAllowedLocalVars", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 7029, + "src": "6145:31:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_storage_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7042, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "6145:43:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7055, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7043, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6200:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7045, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "decimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 7010, + "src": "6200:13:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7046, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6233:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7047, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "reserveLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7018, + "src": "6233:32:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7048, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6275:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7049, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "reserveUsageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 7028, + "src": "6275:36:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + null, + null + ], + "id": 7050, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "6199:124:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$__$_t_uint256_$_t_bool_$__$__$", + "typeString": "tuple(uint256,,uint256,bool,,)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7053, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7031, + "src": "6355:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7051, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "6326:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7052, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveConfiguration", + "nodeType": "MemberAccess", + "referencedDeclaration": 5813, + "src": "6326:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,bool,bool,bool)" + } + }, + "id": 7054, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6326:38:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "tuple(uint256,uint256,uint256,bool,bool,bool)" + } + }, + "src": "6199:165:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7056, + "nodeType": "ExpressionStatement", + "src": "6199:165:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 7066, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7059, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "6378:37:26", + "subExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7057, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6379:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7058, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "reserveUsageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 7028, + "src": "6379:36:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "id": 7065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "6419:58:26", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7062, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7031, + "src": "6461:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7063, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7033, + "src": "6471:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7060, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "6420:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7061, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "6420:40:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 7064, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6420:57:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "6378:99:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7070, + "nodeType": "IfStatement", + "src": "6375:212:26", + "trueBody": { + "id": 7069, + "nodeType": "Block", + "src": "6478:109:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 7067, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6499:4:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "functionReturnParameters": 7039, + "id": 7068, + "nodeType": "Return", + "src": "6492:11:26" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7082, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7071, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6608:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7073, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "collateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7012, + "src": "6608:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7074, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6643:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7075, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "borrowBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7014, + "src": "6643:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7076, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6684:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7077, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7016, + "src": "6684:32:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + null + ], + "id": 7078, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "6597:130:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$_t_uint256_$_t_uint256_$__$_t_uint256_$__$", + "typeString": "tuple(,uint256,uint256,,uint256,)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7080, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7033, + "src": "6754:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7079, + "name": "calculateUserGlobalData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6984, + "src": "6730:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address) view returns (uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "id": 7081, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6730:30:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "src": "6597:163:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7083, + "nodeType": "ExpressionStatement", + "src": "6597:163:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7087, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7084, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6774:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7085, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7014, + "src": "6774:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 7086, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6799:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "6774:26:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7091, + "nodeType": "IfStatement", + "src": "6771:114:26", + "trueBody": { + "id": 7090, + "nodeType": "Block", + "src": "6801:84:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 7088, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6822:4:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "functionReturnParameters": 7039, + "id": 7089, + "nodeType": "Return", + "src": "6815:11:26" + } + ] + } + }, + { + "assignments": [ + 7093 + ], + "declarations": [ + { + "constant": false, + "id": 7093, + "name": "oracle", + "nodeType": "VariableDeclaration", + "scope": 7167, + "src": "6895:19:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + }, + "typeName": { + "contractScope": null, + "id": 7092, + "name": "IPriceOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1959, + "src": "6895:12:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7099, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 7095, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6705, + "src": "6930:17:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 7096, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getPriceOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1266, + "src": "6930:32:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 7097, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6930:34:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7094, + "name": "IPriceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1959, + "src": "6917:12:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IPriceOracle_$1959_$", + "typeString": "type(contract IPriceOracle)" + } + }, + "id": 7098, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6917:48:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6895:70:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7116, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7100, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6976:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7102, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "amountToDecreaseETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7020, + "src": "6976:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7114, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "3130", + "id": 7111, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7090:2:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_10_by_1", + "typeString": "int_const 10" + }, + "value": "10" + }, + "nodeType": "BinaryOperation", + "operator": "**", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7112, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7096:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7113, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 7010, + "src": "7096:13:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7090:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7108, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7035, + "src": "7064:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7105, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7031, + "src": "7037:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7103, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7093, + "src": "7003:6:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 7104, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getAssetPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 1941, + "src": "7003:33:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7106, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7003:43:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7107, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "7003:60:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7109, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7003:69:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7110, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "7003:86:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7115, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7003:107:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6976:134:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7117, + "nodeType": "ExpressionStatement", + "src": "6976:134:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7127, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7118, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7121:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7120, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "collateralBalancefterDecrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7022, + "src": "7121:34:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7124, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7188:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7125, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "amountToDecreaseETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7020, + "src": "7188:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7121, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7158:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7122, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7012, + "src": "7158:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7123, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "7158:29:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7126, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7158:55:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7121:92:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7128, + "nodeType": "ExpressionStatement", + "src": "7121:92:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7150, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7129, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7224:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7131, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationThresholdAfterDecrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7024, + "src": "7224:38:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7147, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7440:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7148, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralBalancefterDecrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7022, + "src": "7440:34:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7142, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7388:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7143, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "reserveLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7018, + "src": "7388:32:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7139, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7359:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7140, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "amountToDecreaseETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7020, + "src": "7359:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7141, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "7359:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7144, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7359:62:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7135, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7308:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7136, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7016, + "src": "7308:32:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7132, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7265:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7133, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7012, + "src": "7265:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7134, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "7265:42:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7137, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7265:76:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7138, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "7265:93:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7145, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7265:157:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7146, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "7265:174:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7149, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7265:210:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7224:251:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7151, + "nodeType": "ExpressionStatement", + "src": "7224:251:26" + }, + { + "assignments": [ + 7153 + ], + "declarations": [ + { + "constant": false, + "id": 7153, + "name": "healthFactorAfterDecrease", + "nodeType": "VariableDeclaration", + "scope": 7167, + "src": "7487:33:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7152, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7487:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7162, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7155, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7578:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7156, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralBalancefterDecrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7022, + "src": "7578:34:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7157, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7626:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7158, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7014, + "src": "7626:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7159, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7661:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7160, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationThresholdAfterDecrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7024, + "src": "7661:38:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 7154, + "name": "calculateHealthFactorFromBalancesInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7255, + "src": "7523:41:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,uint256) pure returns (uint256)" + } + }, + "id": 7161, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7523:177:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7487:213:26" + }, + { + "expression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7165, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7163, + "name": "healthFactorAfterDecrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7153, + "src": "7718:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 7164, + "name": "HEALTH_FACTOR_LIQUIDATION_THRESHOLD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6708, + "src": "7746:35:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7718:63:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 7039, + "id": 7166, + "nodeType": "Return", + "src": "7711:70:26" + } + ] + }, + "documentation": null, + "id": 7168, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "balanceDecreaseAllowed", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7036, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7031, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7168, + "src": "6058:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7030, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6058:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7033, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 7168, + "src": "6076:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7032, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6076:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7035, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 7168, + "src": "6091:12:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7034, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "6091:4:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6057:47:26" + }, + "returnParameters": { + "id": 7039, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7038, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7168, + "src": "6128:4:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7037, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "6128:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6127:6:26" + }, + "scope": 7660, + "src": "6026:1763:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 7221, + "nodeType": "Block", + "src": "8133:513:26", + "statements": [ + { + "assignments": [ + 7180 + ], + "declarations": [ + { + "constant": false, + "id": 7180, + "name": "availableBorrowsETH", + "nodeType": "VariableDeclaration", + "scope": 7221, + "src": "8144:24:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7179, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "8144:4:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7188, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 7186, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8205:3:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7183, + "name": "ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7174, + "src": "8196:3:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7181, + "name": "collateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7170, + "src": "8171:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7182, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "8171:24:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7184, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8171:29:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7185, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "8171:33:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7187, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8171:38:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8144:65:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7191, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7189, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7180, + "src": "8246:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "id": 7190, + "name": "borrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7172, + "src": "8268:16:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8246:38:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7195, + "nodeType": "IfStatement", + "src": "8243:75:26", + "trueBody": { + "id": 7194, + "nodeType": "Block", + "src": "8285:33:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 7192, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8306:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 7178, + "id": 7193, + "nodeType": "Return", + "src": "8299:8:26" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7201, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7196, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7180, + "src": "8328:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7199, + "name": "borrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7172, + "src": "8374:16:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7197, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7180, + "src": "8350:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7198, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "8350:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7200, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8350:41:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8328:63:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7202, + "nodeType": "ExpressionStatement", + "src": "8328:63:26" + }, + { + "assignments": [ + 7204 + ], + "declarations": [ + { + "constant": false, + "id": 7204, + "name": "borrowFee", + "nodeType": "VariableDeclaration", + "scope": 7221, + "src": "8425:17:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7203, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8425:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7215, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7211, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "8535:3:26", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 7212, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8535:10:26", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 7213, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7180, + "src": "8559:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 7206, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6705, + "src": "8458:17:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 7207, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeeProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1316, + "src": "8458:32:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 7208, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8458:34:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7205, + "name": "IFeeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1765, + "src": "8445:12:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IFeeProvider_$1765_$", + "typeString": "type(contract IFeeProvider)" + } + }, + "id": 7209, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8445:48:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFeeProvider_$1765", + "typeString": "contract IFeeProvider" + } + }, + "id": 7210, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "calculateLoanOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 1744, + "src": "8445:76:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (address,uint256) view external returns (uint256)" + } + }, + "id": 7214, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8445:143:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8425:163:26" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7218, + "name": "borrowFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7204, + "src": "8629:9:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7216, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7180, + "src": "8605:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7217, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "8605:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7219, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8605:34:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 7178, + "id": 7220, + "nodeType": "Return", + "src": "8598:41:26" + } + ] + }, + "documentation": "@notice calculates the equivalent amount in ETH that an user can borrow, depeding on the available collateral and the\naverage Loan To Value.", + "id": 7222, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateAvailableBorrowsETHInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7175, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7170, + "name": "collateralBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7222, + "src": "8008:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7169, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8008:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7172, + "name": "borrowBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7222, + "src": "8038:24:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7171, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8038:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7174, + "name": "ltv", + "nodeType": "VariableDeclaration", + "scope": 7222, + "src": "8064:11:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7173, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8064:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8007:69:26" + }, + "returnParameters": { + "id": 7178, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7177, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7222, + "src": "8124:7:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7176, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8124:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8123:9:26" + }, + "scope": 7660, + "src": "7962:684:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 7254, + "nodeType": "Block", + "src": "8971:162:26", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7235, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7233, + "name": "borrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7226, + "src": "8985:16:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 7234, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9005:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "8985:21:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7241, + "nodeType": "IfStatement", + "src": "8981:45:26", + "trueBody": { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7238, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "-", + "prefix": true, + "src": "9023:2:26", + "subExpression": { + "argumentTypes": null, + "hexValue": "31", + "id": 7237, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9024:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1_by_1", + "typeString": "int_const 1" + }, + "value": "1" + }, + "typeDescriptions": { + "typeIdentifier": "t_rational_minus_1_by_1", + "typeString": "int_const -1" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_minus_1_by_1", + "typeString": "int_const -1" + } + ], + "id": 7236, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "9015:7:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7239, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9015:11:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 7232, + "id": 7240, + "nodeType": "Return", + "src": "9008:18:26" + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7251, + "name": "borrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7226, + "src": "9109:16:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 7247, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9096:3:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7244, + "name": "liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7228, + "src": "9070:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7242, + "name": "collateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7224, + "src": "9045:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7243, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "9045:24:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7245, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9045:46:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7246, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "9045:50:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7248, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9045:55:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 7249, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "9044:57:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7250, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9099, + "src": "9044:64:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7252, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9044:82:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 7232, + "id": 7253, + "nodeType": "Return", + "src": "9037:89:26" + } + ] + }, + "documentation": "@notice calculates the health factor from the corresponding balances", + "id": 7255, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateHealthFactorFromBalancesInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7229, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7224, + "name": "collateralBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7255, + "src": "8800:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7223, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8800:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7226, + "name": "borrowBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7255, + "src": "8838:24:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7225, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8838:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7228, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 7255, + "src": "8872:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7227, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8872:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8790:120:26" + }, + "returnParameters": { + "id": 7232, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7231, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7255, + "src": "8958:7:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7230, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8958:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8957:9:26" + }, + "scope": 7660, + "src": "8740:393:26", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 7262, + "nodeType": "Block", + "src": "9213:59:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7260, + "name": "HEALTH_FACTOR_LIQUIDATION_THRESHOLD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6708, + "src": "9230:35:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 7259, + "id": 7261, + "nodeType": "Return", + "src": "9223:42:26" + } + ] + }, + "documentation": null, + "id": 7263, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getHealthFactorLiquidationThreshold", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7256, + "nodeType": "ParameterList", + "parameters": [], + "src": "9184:2:26" + }, + "returnParameters": { + "id": 7259, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7258, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7263, + "src": "9207:4:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7257, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "9207:4:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9206:6:26" + }, + "scope": 7660, + "src": "9140:132:26", + "stateMutability": "pure", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 7317, + "nodeType": "Block", + "src": "9681:410:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7294, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + { + "argumentTypes": null, + "id": 7284, + "name": "ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7268, + "src": "9702:3:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7285, + "name": "liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7270, + "src": "9715:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7286, + "name": "usageAsCollateralEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7276, + "src": "9745:24:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "id": 7287, + "name": "fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7280, + "src": "9779:22:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "id": 7288, + "name": "borrowingEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7278, + "src": "9811:16:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "id": 7289, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "9691:137:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "tuple(,uint256,uint256,bool,bool,bool)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7292, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7265, + "src": "9860:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7290, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "9831:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7291, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveConfiguration", + "nodeType": "MemberAccess", + "referencedDeclaration": 5813, + "src": "9831:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,bool,bool,bool)" + } + }, + "id": 7293, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9831:38:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "tuple(uint256,uint256,uint256,bool,bool,bool)" + } + }, + "src": "9691:178:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7295, + "nodeType": "ExpressionStatement", + "src": "9691:178:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7301, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7296, + "name": "isActive", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7282, + "src": "9879:8:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7299, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7265, + "src": "9914:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7297, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "9890:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7298, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveIsActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 5889, + "src": "9890:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 7300, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9890:33:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "9879:44:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 7302, + "nodeType": "ExpressionStatement", + "src": "9879:44:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7308, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7303, + "name": "liquidationDiscount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7272, + "src": "9933:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7306, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7265, + "src": "9990:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7304, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "9955:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7305, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveLiquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 5611, + "src": "9955:34:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7307, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9955:44:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9933:66:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7309, + "nodeType": "ExpressionStatement", + "src": "9933:66:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7315, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7310, + "name": "rateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7274, + "src": "10010:19:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7313, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7265, + "src": "10075:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7311, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "10032:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7312, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveInterestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5439, + "src": "10032:42:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 7314, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10032:52:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "10010:74:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 7316, + "nodeType": "ExpressionStatement", + "src": "10010:74:26" + } + ] + }, + "documentation": null, + "id": 7318, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveConfigurationData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7266, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7265, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9316:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7264, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9316:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9315:18:26" + }, + "returnParameters": { + "id": 7283, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7268, + "name": "ltv", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9394:11:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7267, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9394:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7270, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9419:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7269, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9419:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7272, + "name": "liquidationDiscount", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9461:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7271, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9461:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7274, + "name": "rateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9502:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7273, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9502:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7276, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9543:29:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7275, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "9543:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7278, + "name": "borrowingEnabled", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9586:21:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7277, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "9586:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7280, + "name": "fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9621:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7279, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "9621:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7282, + "name": "isActive", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9662:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7281, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "9662:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9380:296:26" + }, + "scope": 7660, + "src": "9279:812:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 7440, + "nodeType": "Block", + "src": "10706:975:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7354, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7349, + "name": "totalLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7323, + "src": "10716:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7352, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "10763:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7350, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "10733:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7351, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5501, + "src": "10733:29:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7353, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10733:39:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10716:56:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7355, + "nodeType": "ExpressionStatement", + "src": "10716:56:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7361, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7356, + "name": "availableLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7325, + "src": "10782:18:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7359, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "10837:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7357, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "10803:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7358, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveAvailableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5482, + "src": "10803:33:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7360, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10803:43:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10782:64:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7362, + "nodeType": "ExpressionStatement", + "src": "10782:64:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7368, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7363, + "name": "totalBorrowsFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7327, + "src": "10856:17:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7366, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "10909:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7364, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "10876:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7365, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveTotalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 5554, + "src": "10876:32:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7367, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10876:42:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10856:62:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7369, + "nodeType": "ExpressionStatement", + "src": "10856:62:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7375, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7370, + "name": "totalBorrowsVariable", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7329, + "src": "10928:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7373, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "10987:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7371, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "10951:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7372, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 5573, + "src": "10951:35:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7374, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10951:45:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10928:68:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7376, + "nodeType": "ExpressionStatement", + "src": "10928:68:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7382, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7377, + "name": "liquidityRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7331, + "src": "11006:13:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7380, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11058:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7378, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11022:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7379, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5719, + "src": "11022:35:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7381, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11022:45:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11006:61:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7383, + "nodeType": "ExpressionStatement", + "src": "11006:61:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7389, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7384, + "name": "variableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7333, + "src": "11077:18:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7387, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11139:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7385, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11098:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7386, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5643, + "src": "11098:40:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7388, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11098:50:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11077:71:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7390, + "nodeType": "ExpressionStatement", + "src": "11077:71:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7396, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7391, + "name": "fixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7335, + "src": "11158:15:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7394, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11214:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7392, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11176:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7393, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5681, + "src": "11176:37:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7395, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11176:47:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11158:65:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7397, + "nodeType": "ExpressionStatement", + "src": "11158:65:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7403, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7398, + "name": "averageFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7337, + "src": "11233:22:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7401, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11303:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7399, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11258:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7400, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5700, + "src": "11258:44:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7402, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11258:54:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11233:79:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7404, + "nodeType": "ExpressionStatement", + "src": "11233:79:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7410, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7405, + "name": "utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7339, + "src": "11322:15:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7408, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11371:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7406, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11340:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7407, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveUtilizationRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6125, + "src": "11340:30:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7409, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11340:40:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11322:58:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7411, + "nodeType": "ExpressionStatement", + "src": "11322:58:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7417, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7412, + "name": "liquidityIndex", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7341, + "src": "11390:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7415, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11447:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7413, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11407:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7414, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 5738, + "src": "11407:39:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7416, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11407:49:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11390:66:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7418, + "nodeType": "ExpressionStatement", + "src": "11390:66:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7424, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7419, + "name": "variableBorrowIndex", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7343, + "src": "11466:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7422, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11534:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7420, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11488:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7421, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveVariableBorrowsCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 5757, + "src": "11488:45:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7423, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11488:55:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11466:77:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7425, + "nodeType": "ExpressionStatement", + "src": "11466:77:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7431, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7426, + "name": "aTokenAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7345, + "src": "11553:13:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7429, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11598:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7427, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11569:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7428, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "11569:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 7430, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11569:38:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "11553:54:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 7432, + "nodeType": "ExpressionStatement", + "src": "11553:54:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7438, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7433, + "name": "lastUpdateTimestamp", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7347, + "src": "11617:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7436, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11665:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7434, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11639:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7435, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5910, + "src": "11639:25:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint40_$", + "typeString": "function (address) view external returns (uint40)" + } + }, + "id": 7437, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11639:35:26", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "src": "11617:57:26", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "id": 7439, + "nodeType": "ExpressionStatement", + "src": "11617:57:26" + } + ] + }, + "documentation": null, + "id": 7441, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7321, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7320, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10121:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7319, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10121:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10120:18:26" + }, + "returnParameters": { + "id": 7348, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7323, + "name": "totalLiquidity", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10199:22:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7322, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10199:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7325, + "name": "availableLiquidity", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10235:26:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7324, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10235:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7327, + "name": "totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10275:25:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7326, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10275:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7329, + "name": "totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10314:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7328, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10314:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7331, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10356:21:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7330, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10356:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7333, + "name": "variableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10391:26:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7332, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10391:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7335, + "name": "fixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10431:23:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7334, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10431:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7337, + "name": "averageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10468:30:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7336, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10468:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7339, + "name": "utilizationRate", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10512:23:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7338, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10512:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7341, + "name": "liquidityIndex", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10549:22:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7340, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10549:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7343, + "name": "variableBorrowIndex", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10585:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7342, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10585:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7345, + "name": "aTokenAddress", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10626:21:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7344, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10626:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7347, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10661:26:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 7346, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "10661:6:26", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10185:516:26" + }, + "scope": 7660, + "src": "10097:1584:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 7480, + "nodeType": "Block", + "src": "12056:305:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7470, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 7460, + "name": "totalLiquidityETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7446, + "src": "12067:17:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7461, + "name": "totalCollateralETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7448, + "src": "12094:18:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7462, + "name": "totalBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7450, + "src": "12122:15:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7463, + "name": "ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7456, + "src": "12147:3:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7464, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7454, + "src": "12160:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7465, + "name": "healthFactor", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7458, + "src": "12197:12:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 7466, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "12066:144:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7468, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7443, + "src": "12237:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7467, + "name": "calculateUserGlobalData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6984, + "src": "12213:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address) view returns (uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "id": 7469, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12213:30:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "src": "12066:177:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7471, + "nodeType": "ExpressionStatement", + "src": "12066:177:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7478, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7472, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7452, + "src": "12254:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7474, + "name": "totalCollateralETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7448, + "src": "12313:18:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7475, + "name": "totalBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7450, + "src": "12333:15:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7476, + "name": "ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7456, + "src": "12350:3:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 7473, + "name": "calculateAvailableBorrowsETHInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7222, + "src": "12276:36:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,uint256) view returns (uint256)" + } + }, + "id": 7477, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12276:78:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "12254:100:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7479, + "nodeType": "ExpressionStatement", + "src": "12254:100:26" + } + ] + }, + "documentation": null, + "id": 7481, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserAccountData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7444, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7443, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11715:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7442, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11715:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11714:15:26" + }, + "returnParameters": { + "id": 7459, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7446, + "name": "totalLiquidityETH", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11790:25:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7445, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11790:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7448, + "name": "totalCollateralETH", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11829:26:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7447, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11829:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7450, + "name": "totalBorrowsETH", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11869:23:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7449, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11869:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7452, + "name": "availableBorrowsETH", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11906:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7451, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11906:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7454, + "name": "currentLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11947:35:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7453, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11947:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7456, + "name": "ltv", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11996:11:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7455, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11996:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7458, + "name": "healthFactor", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "12021:20:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7457, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12021:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11776:275:26" + }, + "scope": 7660, + "src": "11687:674:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 7617, + "nodeType": "Block", + "src": "12927:1052:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7520, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7510, + "name": "currentATokenBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7488, + "src": "12937:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7518, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13017:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7514, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "12996:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7512, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "12967:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7513, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "12967:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 7515, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12967:38:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7511, + "name": "AToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10327, + "src": "12960:6:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_AToken_$10327_$", + "typeString": "type(contract AToken)" + } + }, + "id": 7516, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12960:46:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 7517, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOf", + "nodeType": "MemberAccess", + "referencedDeclaration": 11298, + "src": "12960:56:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7519, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12960:63:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "12937:86:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7521, + "nodeType": "ExpressionStatement", + "src": "12937:86:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7532, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7522, + "name": "currentUnderlyingBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7490, + "src": "13033:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7530, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13127:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7526, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13096:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7524, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13067:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7525, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "13067:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 7527, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13067:38:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7523, + "name": "AToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10327, + "src": "13060:6:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_AToken_$10327_$", + "typeString": "type(contract AToken)" + } + }, + "id": 7528, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13060:46:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 7529, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOfUnderlying", + "nodeType": "MemberAccess", + "referencedDeclaration": 10212, + "src": "13060:66:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7531, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13060:73:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13033:100:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7533, + "nodeType": "ExpressionStatement", + "src": "13033:100:26" + }, + { + "assignments": [ + 7537 + ], + "declarations": [ + { + "constant": false, + "id": 7537, + "name": "mode", + "nodeType": "VariableDeclaration", + "scope": 7617, + "src": "13143:33:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 7536, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "13143:28:26", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7543, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7540, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13213:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7541, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13223:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7538, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13179:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7539, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentBorrowRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5988, + "src": "13179:33:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view external returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 7542, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13179:50:26", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13143:86:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7552, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 7544, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7494, + "src": "13240:22:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7545, + "name": "currentBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7492, + "src": "13272:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + null + ], + "id": 7546, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "13239:55:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$__$", + "typeString": "tuple(uint256,uint256,)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7549, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13324:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7550, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13334:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7547, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13297:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7548, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "13297:26:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 7551, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13297:43:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "src": "13239:101:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7553, + "nodeType": "ExpressionStatement", + "src": "13239:101:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7558, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7554, + "name": "borrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7496, + "src": "13350:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7556, + "name": "mode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7537, + "src": "13375:4:26", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + ], + "id": 7555, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "13367:7:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7557, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13367:13:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13350:30:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7559, + "nodeType": "ExpressionStatement", + "src": "13350:30:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7576, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7560, + "name": "borrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7498, + "src": "13390:10:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 7565, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7561, + "name": "mode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7537, + "src": "13403:4:26", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7562, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "13411:11:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 7563, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "13411:28:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 7564, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "13411:34:26", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "13403:42:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7573, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13567:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7571, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13526:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7572, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5643, + "src": "13526:40:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7574, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13526:50:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7575, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "13403:173:26", + "trueExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7568, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13495:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7569, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13505:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7566, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13460:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7567, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6011, + "src": "13460:34:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7570, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13460:51:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13390:186:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7577, + "nodeType": "ExpressionStatement", + "src": "13390:186:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7583, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7578, + "name": "liquidityRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7500, + "src": "13586:13:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7581, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13638:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7579, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13602:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7580, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5719, + "src": "13602:35:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7582, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13602:45:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13586:61:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7584, + "nodeType": "ExpressionStatement", + "src": "13586:61:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7591, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7585, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7502, + "src": "13657:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7588, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13701:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7589, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13711:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7586, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13674:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7587, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 5956, + "src": "13674:26:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7590, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13674:43:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13657:60:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7592, + "nodeType": "ExpressionStatement", + "src": "13657:60:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7599, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7593, + "name": "variableBorrowIndex", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7504, + "src": "13727:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7596, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13791:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7597, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13801:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7594, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13749:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7595, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 6086, + "src": "13749:41:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7598, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13749:58:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13727:80:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7600, + "nodeType": "ExpressionStatement", + "src": "13727:80:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7607, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7601, + "name": "lastUpdateTimestamp", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7506, + "src": "13817:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7604, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13862:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7605, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13872:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7602, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13839:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7603, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6111, + "src": "13839:22:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7606, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13839:39:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13817:61:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7608, + "nodeType": "ExpressionStatement", + "src": "13817:61:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7615, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7609, + "name": "usageAsCollateralEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7508, + "src": "13888:24:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7612, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13956:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7613, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13966:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7610, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13915:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7611, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "13915:40:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 7614, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13915:57:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "13888:84:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 7616, + "nodeType": "ExpressionStatement", + "src": "13888:84:26" + } + ] + }, + "documentation": null, + "id": 7618, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserReserveData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7486, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7483, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12395:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7482, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12395:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7485, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12413:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7484, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12413:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12394:33:26" + }, + "returnParameters": { + "id": 7509, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7488, + "name": "currentATokenBalance", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12488:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7487, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12488:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7490, + "name": "currentUnderlyingBalance", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12530:32:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7489, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12530:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7492, + "name": "currentBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12576:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7491, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12576:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7494, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12618:30:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7493, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12618:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7496, + "name": "borrowRateMode", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12662:22:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7495, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12662:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7498, + "name": "borrowRate", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12698:18:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7497, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12698:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7500, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12730:21:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7499, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12730:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7502, + "name": "originationFee", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12765:22:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7501, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12765:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7504, + "name": "variableBorrowIndex", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12801:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7503, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12801:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7506, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12842:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7505, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12842:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7508, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12883:29:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7507, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "12883:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12474:448:26" + }, + "scope": 7660, + "src": "12367:1612:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 7658, + "nodeType": "Block", + "src": "14197:323:26", + "statements": [ + { + "assignments": [ + 7626 + ], + "declarations": [ + { + "constant": false, + "id": 7626, + "name": "ethereumAddress", + "nodeType": "VariableDeclaration", + "scope": 7658, + "src": "14208:23:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7625, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14208:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7634, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 7628, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6705, + "src": "14258:17:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 7629, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1216, + "src": "14258:44:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 7630, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14258:46:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7627, + "name": "NetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1478, + "src": "14234:23:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_NetworkMetadataProvider_$1478_$", + "typeString": "type(contract NetworkMetadataProvider)" + } + }, + "id": 7631, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14234:71:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_NetworkMetadataProvider_$1478", + "typeString": "contract NetworkMetadataProvider" + } + }, + "id": 7632, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1466, + "src": "14234:90:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 7633, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14234:92:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14208:118:26" + }, + { + "assignments": [ + 7636 + ], + "declarations": [ + { + "constant": false, + "id": 7636, + "name": "coreAddress", + "nodeType": "VariableDeclaration", + "scope": 7658, + "src": "14336:19:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7635, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14336:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7640, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7638, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "14366:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + ], + "id": 7637, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "14358:7:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 7639, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14358:13:26", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14336:35:26" + }, + { + "assignments": [ + 7642 + ], + "declarations": [ + { + "constant": false, + "id": 7642, + "name": "balance", + "nodeType": "VariableDeclaration", + "scope": 7658, + "src": "14382:12:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7641, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "14382:4:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7655, + "initialValue": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 7645, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7643, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7620, + "src": "14397:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 7644, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7626, + "src": "14409:15:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "14397:27:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7652, + "name": "coreAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7636, + "src": "14476:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7649, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7620, + "src": "14456:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7648, + "name": "IERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11786, + "src": "14449:6:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IERC20_$11786_$", + "typeString": "type(contract IERC20)" + } + }, + "id": 7650, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14449:16:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 7651, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOf", + "nodeType": "MemberAccess", + "referencedDeclaration": 11731, + "src": "14449:26:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7653, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14449:39:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7654, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "14397:91:26", + "trueExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7646, + "name": "coreAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7636, + "src": "14427:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 7647, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balance", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "14427:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14382:106:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7656, + "name": "balance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7642, + "src": "14506:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 7624, + "id": 7657, + "nodeType": "Return", + "src": "14499:14:26" + } + ] + }, + "documentation": "@dev provides the actual balance of a reserve, by checking the core balance of the underlying ERC20/Ether", + "id": 7659, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getCoreActualReserveBalance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7621, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7620, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7659, + "src": "14149:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7619, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14149:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14148:18:26" + }, + "returnParameters": { + "id": 7624, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7623, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7659, + "src": "14189:7:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7622, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14189:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14188:9:26" + }, + "scope": 7660, + "src": "14112:408:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 7661, + "src": "851:13671:26" + } + ], + "src": "0:14523:26" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol", + "exportedSymbols": { + "LendingPoolDataProvider": [ + 7660 + ] + }, + "id": 7661, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 6684, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:26" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "id": 6685, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 11255, + "src": "25:63:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 6686, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 11141, + "src": "89:59:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "file": "../libraries/CoreLibrary.sol", + "id": 6687, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 8995, + "src": "150:38:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 6688, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 1358, + "src": "189:59:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "file": "../configuration/NetworkMetadataProvider.sol", + "id": 6689, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 1479, + "src": "249:54:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 6690, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 9175, + "src": "304:37:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "file": "../interfaces/IFeeProvider.sol", + "id": 6691, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 1766, + "src": "342:40:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "file": "../tokenization/AToken.sol", + "id": 6692, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 10328, + "src": "383:36:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "./LendingPoolCore.sol", + "id": 6693, + "nodeType": "ImportDirective", + "scope": 7661, + "sourceUnit": 6683, + "src": "421:31:26", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 6694, + "name": "Ownable", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11254, + "src": "887:7:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Ownable_$11254", + "typeString": "contract Ownable" + } + }, + "id": 6695, + "nodeType": "InheritanceSpecifier", + "src": "887:7:26" + } + ], + "contractDependencies": [ + 10953, + 11254 + ], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title LendingPoolDataProvider contract\n@author Aave\n@notice Implements functions to fetch data from the core, and aggregate them in order to allow computation\non the compounded balances and the account balances in ETH************************************************************************************", + "fullyImplemented": true, + "id": 7660, + "linearizedBaseContracts": [ + 7660, + 11254, + 10953 + ], + "name": "LendingPoolDataProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 6698, + "libraryName": { + "contractScope": null, + "id": 6696, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "907:8:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "901:27:26", + "typeName": { + "id": 6697, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "920:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 6701, + "libraryName": { + "contractScope": null, + "id": 6699, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "939:10:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "933:29:26", + "typeName": { + "id": 6700, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "954:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "constant": false, + "id": 6703, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 7660, + "src": "968:20:26", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 6702, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "968:15:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6705, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 7660, + "src": "994:53:26", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 6704, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "994:28:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": true, + "id": 6708, + "name": "HEALTH_FACTOR_LIQUIDATION_THRESHOLD", + "nodeType": "VariableDeclaration", + "scope": 7660, + "src": "1239:59:26", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6706, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1239:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "31653138", + "id": 6707, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1294:4:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000_by_1", + "typeString": "int_const 1000000000000000000" + }, + "value": "1e18" + }, + "visibility": "internal" + }, + { + "body": { + "id": 6725, + "nodeType": "Block", + "src": "1374:128:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6715, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6713, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6705, + "src": "1384:17:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 6714, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6710, + "src": "1404:18:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "1384:38:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6716, + "nodeType": "ExpressionStatement", + "src": "1384:38:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6723, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6717, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "1432:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 6719, + "name": "_addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6710, + "src": "1455:18:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6720, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "1455:37:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 6721, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1455:39:26", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 6718, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "1439:15:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 6722, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1439:56:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "src": "1432:63:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6724, + "nodeType": "ExpressionStatement", + "src": "1432:63:26" + } + ] + }, + "documentation": null, + "id": 6726, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6711, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6710, + "name": "_addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 6726, + "src": "1318:47:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 6709, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1318:28:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1317:49:26" + }, + "returnParameters": { + "id": 6712, + "nodeType": "ParameterList", + "parameters": [], + "src": "1374:0:26" + }, + "scope": 7660, + "src": "1306:196:26", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "canonicalName": "LendingPoolDataProvider.UserGlobalDataLocalVars", + "id": 6743, + "members": [ + { + "constant": false, + "id": 6728, + "name": "reserveUnitPrice", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1634:24:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6727, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1634:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6730, + "name": "tokenUnit", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1668:17:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6729, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1668:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6732, + "name": "compoundedLiquidityBalance", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1695:34:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6731, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1695:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6734, + "name": "compoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1739:31:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6733, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1739:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6736, + "name": "reserveDecimals", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1780:23:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6735, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1780:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6738, + "name": "baseLtv", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1813:15:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6737, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1813:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6740, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1838:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6739, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1838:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6742, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 6743, + "src": "1876:29:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 6741, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "1876:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "UserGlobalDataLocalVars", + "nodeType": "StructDefinition", + "scope": 7660, + "src": "1593:319:26", + "visibility": "public" + }, + { + "body": { + "id": 6983, + "nodeType": "Block", + "src": "2512:2433:26", + "statements": [ + { + "assignments": [ + 6761 + ], + "declarations": [ + { + "constant": false, + "id": 6761, + "name": "oracle", + "nodeType": "VariableDeclaration", + "scope": 6983, + "src": "2522:19:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + }, + "typeName": { + "contractScope": null, + "id": 6760, + "name": "IPriceOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1959, + "src": "2522:12:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6767, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 6763, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6705, + "src": "2557:17:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 6764, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getPriceOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1266, + "src": "2557:32:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 6765, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2557:34:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6762, + "name": "IPriceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1959, + "src": "2544:12:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IPriceOracle_$1959_$", + "typeString": "type(contract IPriceOracle)" + } + }, + "id": 6766, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2544:48:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2522:70:26" + }, + { + "assignments": [ + 6769 + ], + "declarations": [ + { + "constant": false, + "id": 6769, + "name": "vars", + "nodeType": "VariableDeclaration", + "scope": 6983, + "src": "2602:35:26", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars" + }, + "typeName": { + "contractScope": null, + "id": 6768, + "name": "UserGlobalDataLocalVars", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6743, + "src": "2602:23:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_storage_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6770, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "2602:35:26" + }, + { + "assignments": [ + 6774 + ], + "declarations": [ + { + "constant": false, + "id": 6774, + "name": "reserves", + "nodeType": "VariableDeclaration", + "scope": 6983, + "src": "2648:25:26", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 6772, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2648:7:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 6773, + "length": null, + "nodeType": "ArrayTypeName", + "src": "2648:9:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6778, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 6775, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "2676:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6776, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserves", + "nodeType": "MemberAccess", + "referencedDeclaration": 6134, + "src": "2676:16:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_array$_t_address_$dyn_memory_ptr_$", + "typeString": "function () view external returns (address[] memory)" + } + }, + "id": 6777, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2676:18:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2648:46:26" + }, + { + "body": { + "id": 6949, + "nodeType": "Block", + "src": "2751:1756:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6801, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6790, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "2768:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6792, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "compoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6734, + "src": "2768:28:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + null + ], + "id": 6793, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "2766:32:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$_t_uint256_$__$", + "typeString": "tuple(,uint256,)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6796, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "2828:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6798, + "indexExpression": { + "argumentTypes": null, + "id": 6797, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "2837:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2828:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 6799, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6745, + "src": "2841:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6794, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "2801:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6795, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "2801:26:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 6800, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2801:46:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "src": "2766:81:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6802, + "nodeType": "ExpressionStatement", + "src": "2766:81:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6812, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6803, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "2861:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6805, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "compoundedLiquidityBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6732, + "src": "2861:31:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6807, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "2925:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6809, + "indexExpression": { + "argumentTypes": null, + "id": 6808, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "2934:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2925:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 6810, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6745, + "src": "2938:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6806, + "name": "getUserUnderlyingAssetBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7008, + "src": "2895:29:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view returns (uint256)" + } + }, + "id": 6811, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2895:49:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2861:83:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6813, + "nodeType": "ExpressionStatement", + "src": "2861:83:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 6822, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6817, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6814, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "2962:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6815, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedLiquidityBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6732, + "src": "2962:31:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6816, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2997:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "2962:36:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "&&", + "rightExpression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6821, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6818, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3002:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6819, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6734, + "src": "3002:28:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6820, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3034:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3002:33:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "2962:73:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6825, + "nodeType": "IfStatement", + "src": "2959:118:26", + "trueBody": { + "id": 6824, + "nodeType": "Block", + "src": "3036:41:26", + "statements": [ + { + "id": 6823, + "nodeType": "Continue", + "src": "3054:8:26" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 6842, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6826, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3125:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6828, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "reserveDecimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 6736, + "src": "3125:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6829, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3159:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6830, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "baseLtv", + "nodeType": "MemberAccess", + "referencedDeclaration": 6738, + "src": "3159:12:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6831, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3185:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6832, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 6740, + "src": "3185:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6833, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3224:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6834, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 6742, + "src": "3224:29:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + null, + null + ], + "id": 6835, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "3124:145:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$__$__$", + "typeString": "tuple(uint256,uint256,uint256,bool,,)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6838, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "3301:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6840, + "indexExpression": { + "argumentTypes": null, + "id": 6839, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "3310:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "3301:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6836, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "3272:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6837, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveConfiguration", + "nodeType": "MemberAccess", + "referencedDeclaration": 5813, + "src": "3272:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,bool,bool,bool)" + } + }, + "id": 6841, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3272:41:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "tuple(uint256,uint256,uint256,bool,bool,bool)" + } + }, + "src": "3124:189:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 6843, + "nodeType": "ExpressionStatement", + "src": "3124:189:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6851, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6844, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3327:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6846, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "tokenUnit", + "nodeType": "MemberAccess", + "referencedDeclaration": 6730, + "src": "3327:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6850, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "3130", + "id": 6847, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3344:2:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_10_by_1", + "typeString": "int_const 10" + }, + "value": "10" + }, + "nodeType": "BinaryOperation", + "operator": "**", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6848, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3350:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6849, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "reserveDecimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 6736, + "src": "3350:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3344:26:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3327:43:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6852, + "nodeType": "ExpressionStatement", + "src": "3327:43:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6862, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6853, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3384:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6855, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "reserveUnitPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 6728, + "src": "3384:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6858, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "3429:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6860, + "indexExpression": { + "argumentTypes": null, + "id": 6859, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "3438:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "3429:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6856, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6761, + "src": "3408:6:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 6857, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getAssetPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 1941, + "src": "3408:20:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 6861, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3408:33:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3384:57:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6863, + "nodeType": "ExpressionStatement", + "src": "3384:57:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6867, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6864, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3507:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6865, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedLiquidityBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6732, + "src": "3507:31:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6866, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3541:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3507:35:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6930, + "nodeType": "IfStatement", + "src": "3503:800:26", + "trueBody": { + "id": 6929, + "nodeType": "Block", + "src": "3544:759:26", + "statements": [ + { + "assignments": [ + 6869 + ], + "declarations": [ + { + "constant": false, + "id": 6869, + "name": "liquidityBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 6929, + "src": "3564:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6868, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3564:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6880, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6877, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3678:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6878, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "tokenUnit", + "nodeType": "MemberAccess", + "referencedDeclaration": 6730, + "src": "3678:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6873, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3620:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6874, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedLiquidityBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6732, + "src": "3620:31:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6870, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3594:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6871, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "reserveUnitPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 6728, + "src": "3594:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6872, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "3594:25:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6875, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3594:58:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6876, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "3594:62:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6879, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3594:116:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3564:146:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6886, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6881, + "name": "totalLiquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6748, + "src": "3728:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6884, + "name": "liquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6869, + "src": "3784:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6882, + "name": "totalLiquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6748, + "src": "3755:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6883, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "3755:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6885, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3755:49:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3728:76:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6887, + "nodeType": "ExpressionStatement", + "src": "3728:76:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 6897, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6888, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "3827:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6889, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "usageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 6742, + "src": "3827:29:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "&&", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 6892, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "3901:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6894, + "indexExpression": { + "argumentTypes": null, + "id": 6893, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "3910:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "3901:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 6895, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6745, + "src": "3914:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6890, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "3860:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6891, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "3860:40:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 6896, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3860:60:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "3827:93:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6928, + "nodeType": "IfStatement", + "src": "3823:466:26", + "trueBody": { + "id": 6927, + "nodeType": "Block", + "src": "3922:367:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6903, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6898, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "3944:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6901, + "name": "liquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6869, + "src": "4002:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6899, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "3972:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6900, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "3972:29:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6902, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3972:50:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3944:78:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6904, + "nodeType": "ExpressionStatement", + "src": "3944:78:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6914, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6905, + "name": "currentLtv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6754, + "src": "4044:10:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6910, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "4096:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6911, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "baseLtv", + "nodeType": "MemberAccess", + "referencedDeclaration": 6738, + "src": "4096:12:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6908, + "name": "liquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6869, + "src": "4072:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6909, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "4072:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6912, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4072:37:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6906, + "name": "currentLtv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6754, + "src": "4057:10:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6907, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "4057:14:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6913, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4057:53:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4044:66:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6915, + "nodeType": "ExpressionStatement", + "src": "4044:66:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6925, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6916, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6756, + "src": "4132:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6921, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "4243:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6922, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 6740, + "src": "4243:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6919, + "name": "liquidityBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6869, + "src": "4219:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6920, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "4219:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6923, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4219:50:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6917, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6756, + "src": "4162:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6918, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "4162:56:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6924, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4162:108:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4132:138:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6926, + "nodeType": "ExpressionStatement", + "src": "4132:138:26" + } + ] + } + } + ] + } + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6934, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6931, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "4321:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6932, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6734, + "src": "4321:28:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6933, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4352:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "4321:32:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 6948, + "nodeType": "IfStatement", + "src": "4317:180:26", + "trueBody": { + "id": 6947, + "nodeType": "Block", + "src": "4355:142:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 6945, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6935, + "name": "totalBorrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6752, + "src": "4373:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6941, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "4452:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6942, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "compoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 6734, + "src": "4452:28:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6938, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6769, + "src": "4423:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_UserGlobalDataLocalVars_$6743_memory_ptr", + "typeString": "struct LendingPoolDataProvider.UserGlobalDataLocalVars memory" + } + }, + "id": 6939, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "reserveUnitPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 6728, + "src": "4423:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6940, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadMul", + "nodeType": "MemberAccess", + "referencedDeclaration": 9072, + "src": "4423:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6943, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4423:58:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6936, + "name": "totalBorrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6752, + "src": "4397:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6937, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "4397:25:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6944, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4397:85:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4373:109:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6946, + "nodeType": "ExpressionStatement", + "src": "4373:109:26" + } + ] + } + } + ] + }, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6786, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6783, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "2725:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 6784, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6774, + "src": "2729:8:26", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 6785, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "length", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2729:15:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2725:19:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 6950, + "initializationExpression": { + "assignments": [ + 6780 + ], + "declarations": [ + { + "constant": false, + "id": 6780, + "name": "i", + "nodeType": "VariableDeclaration", + "scope": 6950, + "src": "2710:9:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6779, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2710:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 6782, + "initialValue": { + "argumentTypes": null, + "hexValue": "30", + "id": 6781, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2722:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "nodeType": "VariableDeclarationStatement", + "src": "2710:13:26" + }, + "loopExpression": { + "expression": { + "argumentTypes": null, + "id": 6788, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "++", + "prefix": false, + "src": "2746:3:26", + "subExpression": { + "argumentTypes": null, + "id": 6787, + "name": "i", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6780, + "src": "2746:1:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6789, + "nodeType": "ExpressionStatement", + "src": "2746:3:26" + }, + "nodeType": "ForStatement", + "src": "2705:1802:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6961, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6951, + "name": "currentLtv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6754, + "src": "4517:10:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6954, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6952, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "4530:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6953, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4558:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "4530:29:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6959, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4606:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "id": 6960, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "4530:77:26", + "trueExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6957, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "4577:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6955, + "name": "currentLtv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6754, + "src": "4562:10:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6956, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "4562:14:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6958, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4562:41:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4517:90:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6962, + "nodeType": "ExpressionStatement", + "src": "4517:90:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6973, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6963, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6756, + "src": "4617:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 6966, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 6964, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "4647:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6965, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4675:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "4647:29:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 6971, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4740:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "id": 6972, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "4647:94:26", + "trueExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6969, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "4711:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 6967, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6756, + "src": "4679:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6968, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "4679:31:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 6970, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4679:58:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4617:124:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6974, + "nodeType": "ExpressionStatement", + "src": "4617:124:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 6981, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 6975, + "name": "healthFactor", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6758, + "src": "4752:12:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6977, + "name": "totalCollateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6750, + "src": "4822:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 6978, + "name": "totalBorrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6752, + "src": "4861:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 6979, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6756, + "src": "4896:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 6976, + "name": "calculateHealthFactorFromBalancesInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7255, + "src": "4767:41:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,uint256) pure returns (uint256)" + } + }, + "id": 6980, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4767:170:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4752:185:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 6982, + "nodeType": "ExpressionStatement", + "src": "4752:185:26" + } + ] + }, + "documentation": "@notice calculates the user data across the reserves.\nthis includes the total liquidity/collateral/borrow balances in ETH,\nthe average Loan To Value, the average Liquidation Ratio, and the Health factor.", + "id": 6984, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateUserGlobalData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6746, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6745, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2183:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6744, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2183:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2182:15:26" + }, + "returnParameters": { + "id": 6759, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6748, + "name": "totalLiquidityBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2256:32:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6747, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2256:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6750, + "name": "totalCollateralBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2302:33:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6749, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2302:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6752, + "name": "totalBorrowBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2349:29:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6751, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2349:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6754, + "name": "currentLtv", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2392:18:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6753, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2392:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6756, + "name": "currentLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2424:35:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6755, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2424:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6758, + "name": "healthFactor", + "nodeType": "VariableDeclaration", + "scope": 6984, + "src": "2473:20:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6757, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2473:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2242:265:26" + }, + "scope": 7660, + "src": "2150:2795:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 7007, + "nodeType": "Block", + "src": "5170:132:26", + "statements": [ + { + "assignments": [ + 6994 + ], + "declarations": [ + { + "constant": false, + "id": 6994, + "name": "aToken", + "nodeType": "VariableDeclaration", + "scope": 7007, + "src": "5181:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + }, + "typeName": { + "contractScope": null, + "id": 6993, + "name": "AToken", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10327, + "src": "5181:6:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7001, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 6998, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6986, + "src": "5233:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 6996, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "5204:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 6997, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "5204:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 6999, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5204:38:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 6995, + "name": "AToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10327, + "src": "5197:6:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_AToken_$10327_$", + "typeString": "type(contract AToken)" + } + }, + "id": 7000, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5197:46:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5181:62:26" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7004, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6988, + "src": "5288:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7002, + "name": "aToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6994, + "src": "5261:6:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 7003, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOfUnderlying", + "nodeType": "MemberAccess", + "referencedDeclaration": 10212, + "src": "5261:26:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7005, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5261:33:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 6992, + "id": 7006, + "nodeType": "Return", + "src": "5254:40:26" + } + ] + }, + "documentation": "@notice gets the underlying asset balance of a user based on the corresponding aToken balance.", + "id": 7008, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserUnderlyingAssetBalance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 6989, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6986, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7008, + "src": "5107:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6985, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5107:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 6988, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 7008, + "src": "5125:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 6987, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "5125:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5106:33:26" + }, + "returnParameters": { + "id": 6992, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 6991, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7008, + "src": "5161:7:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 6990, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5161:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "5160:9:26" + }, + "scope": 7660, + "src": "5068:234:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "canonicalName": "LendingPoolDataProvider.balanceDecreaseAllowedLocalVars", + "id": 7029, + "members": [ + { + "constant": false, + "id": 7010, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5611:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7009, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5611:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7012, + "name": "collateralBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5637:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7011, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5637:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7014, + "name": "borrowBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5675:24:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7013, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5675:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7016, + "name": "currentLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5709:35:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7015, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5709:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7018, + "name": "reserveLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5754:35:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7017, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5754:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7020, + "name": "amountToDecreaseETH", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5799:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7019, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5799:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7022, + "name": "collateralBalancefterDecrease", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5836:37:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7021, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5836:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7024, + "name": "liquidationThresholdAfterDecrease", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5883:41:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7023, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5883:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7026, + "name": "healthFactorAfterDecrease", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5934:33:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7025, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5934:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7028, + "name": "reserveUsageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 7029, + "src": "5977:36:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7027, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "5977:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "balanceDecreaseAllowedLocalVars", + "nodeType": "StructDefinition", + "scope": 7660, + "src": "5562:458:26", + "visibility": "public" + }, + { + "body": { + "id": 7167, + "nodeType": "Block", + "src": "6134:1655:26", + "statements": [ + { + "assignments": [ + 7041 + ], + "declarations": [ + { + "constant": false, + "id": 7041, + "name": "vars", + "nodeType": "VariableDeclaration", + "scope": 7167, + "src": "6145:43:26", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars" + }, + "typeName": { + "contractScope": null, + "id": 7040, + "name": "balanceDecreaseAllowedLocalVars", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 7029, + "src": "6145:31:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_storage_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7042, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "6145:43:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7055, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7043, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6200:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7045, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "decimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 7010, + "src": "6200:13:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7046, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6233:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7047, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "reserveLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7018, + "src": "6233:32:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7048, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6275:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7049, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "reserveUsageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 7028, + "src": "6275:36:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + null, + null + ], + "id": 7050, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "6199:124:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$__$_t_uint256_$_t_bool_$__$__$", + "typeString": "tuple(uint256,,uint256,bool,,)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7053, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7031, + "src": "6355:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7051, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "6326:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7052, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveConfiguration", + "nodeType": "MemberAccess", + "referencedDeclaration": 5813, + "src": "6326:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,bool,bool,bool)" + } + }, + "id": 7054, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6326:38:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "tuple(uint256,uint256,uint256,bool,bool,bool)" + } + }, + "src": "6199:165:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7056, + "nodeType": "ExpressionStatement", + "src": "6199:165:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 7066, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7059, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "6378:37:26", + "subExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7057, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6379:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7058, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "reserveUsageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 7028, + "src": "6379:36:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "id": 7065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "6419:58:26", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7062, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7031, + "src": "6461:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7063, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7033, + "src": "6471:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7060, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "6420:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7061, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "6420:40:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 7064, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6420:57:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "6378:99:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7070, + "nodeType": "IfStatement", + "src": "6375:212:26", + "trueBody": { + "id": 7069, + "nodeType": "Block", + "src": "6478:109:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 7067, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6499:4:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "functionReturnParameters": 7039, + "id": 7068, + "nodeType": "Return", + "src": "6492:11:26" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7082, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7071, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6608:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7073, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "collateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7012, + "src": "6608:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7074, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6643:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7075, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "borrowBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7014, + "src": "6643:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7076, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6684:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7077, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "currentLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7016, + "src": "6684:32:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + null + ], + "id": 7078, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "6597:130:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$_t_uint256_$_t_uint256_$__$_t_uint256_$__$", + "typeString": "tuple(,uint256,uint256,,uint256,)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7080, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7033, + "src": "6754:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7079, + "name": "calculateUserGlobalData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6984, + "src": "6730:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address) view returns (uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "id": 7081, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6730:30:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "src": "6597:163:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7083, + "nodeType": "ExpressionStatement", + "src": "6597:163:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7087, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7084, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6774:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7085, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7014, + "src": "6774:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 7086, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6799:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "6774:26:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7091, + "nodeType": "IfStatement", + "src": "6771:114:26", + "trueBody": { + "id": 7090, + "nodeType": "Block", + "src": "6801:84:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 7088, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "6822:4:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "functionReturnParameters": 7039, + "id": 7089, + "nodeType": "Return", + "src": "6815:11:26" + } + ] + } + }, + { + "assignments": [ + 7093 + ], + "declarations": [ + { + "constant": false, + "id": 7093, + "name": "oracle", + "nodeType": "VariableDeclaration", + "scope": 7167, + "src": "6895:19:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + }, + "typeName": { + "contractScope": null, + "id": 7092, + "name": "IPriceOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1959, + "src": "6895:12:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7099, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 7095, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6705, + "src": "6930:17:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 7096, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getPriceOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1266, + "src": "6930:32:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 7097, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6930:34:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7094, + "name": "IPriceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1959, + "src": "6917:12:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IPriceOracle_$1959_$", + "typeString": "type(contract IPriceOracle)" + } + }, + "id": 7098, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6917:48:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6895:70:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7116, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7100, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "6976:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7102, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "amountToDecreaseETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7020, + "src": "6976:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7114, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "hexValue": "3130", + "id": 7111, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7090:2:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_10_by_1", + "typeString": "int_const 10" + }, + "value": "10" + }, + "nodeType": "BinaryOperation", + "operator": "**", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7112, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7096:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7113, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "decimals", + "nodeType": "MemberAccess", + "referencedDeclaration": 7010, + "src": "7096:13:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7090:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7108, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7035, + "src": "7064:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7105, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7031, + "src": "7037:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7103, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7093, + "src": "7003:6:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 7104, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getAssetPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 1941, + "src": "7003:33:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7106, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7003:43:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7107, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "7003:60:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7109, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7003:69:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7110, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "7003:86:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7115, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7003:107:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "6976:134:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7117, + "nodeType": "ExpressionStatement", + "src": "6976:134:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7127, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7118, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7121:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7120, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "collateralBalancefterDecrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7022, + "src": "7121:34:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7124, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7188:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7125, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "amountToDecreaseETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7020, + "src": "7188:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7121, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7158:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7122, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7012, + "src": "7158:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7123, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "7158:29:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7126, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7158:55:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7121:92:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7128, + "nodeType": "ExpressionStatement", + "src": "7121:92:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7150, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7129, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7224:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7131, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationThresholdAfterDecrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7024, + "src": "7224:38:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7147, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7440:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7148, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralBalancefterDecrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7022, + "src": "7440:34:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7142, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7388:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7143, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "reserveLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7018, + "src": "7388:32:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7139, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7359:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7140, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "amountToDecreaseETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7020, + "src": "7359:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7141, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "7359:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7144, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7359:62:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7135, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7308:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7136, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "currentLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7016, + "src": "7308:32:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7132, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7265:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7133, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7012, + "src": "7265:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7134, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "7265:42:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7137, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7265:76:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7138, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "7265:93:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7145, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7265:157:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7146, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "7265:174:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7149, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7265:210:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7224:251:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7151, + "nodeType": "ExpressionStatement", + "src": "7224:251:26" + }, + { + "assignments": [ + 7153 + ], + "declarations": [ + { + "constant": false, + "id": 7153, + "name": "healthFactorAfterDecrease", + "nodeType": "VariableDeclaration", + "scope": 7167, + "src": "7487:33:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7152, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "7487:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7162, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7155, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7578:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7156, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralBalancefterDecrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7022, + "src": "7578:34:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7157, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7626:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7158, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceETH", + "nodeType": "MemberAccess", + "referencedDeclaration": 7014, + "src": "7626:21:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7159, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7041, + "src": "7661:4:26", + "typeDescriptions": { + "typeIdentifier": "t_struct$_balanceDecreaseAllowedLocalVars_$7029_memory_ptr", + "typeString": "struct LendingPoolDataProvider.balanceDecreaseAllowedLocalVars memory" + } + }, + "id": 7160, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationThresholdAfterDecrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7024, + "src": "7661:38:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 7154, + "name": "calculateHealthFactorFromBalancesInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7255, + "src": "7523:41:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,uint256) pure returns (uint256)" + } + }, + "id": 7161, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7523:177:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "7487:213:26" + }, + { + "expression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7165, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7163, + "name": "healthFactorAfterDecrease", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7153, + "src": "7718:25:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 7164, + "name": "HEALTH_FACTOR_LIQUIDATION_THRESHOLD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6708, + "src": "7746:35:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "7718:63:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 7039, + "id": 7166, + "nodeType": "Return", + "src": "7711:70:26" + } + ] + }, + "documentation": null, + "id": 7168, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "balanceDecreaseAllowed", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7036, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7031, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7168, + "src": "6058:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7030, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6058:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7033, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 7168, + "src": "6076:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7032, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "6076:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7035, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 7168, + "src": "6091:12:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7034, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "6091:4:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6057:47:26" + }, + "returnParameters": { + "id": 7039, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7038, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7168, + "src": "6128:4:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7037, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "6128:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "6127:6:26" + }, + "scope": 7660, + "src": "6026:1763:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 7221, + "nodeType": "Block", + "src": "8133:513:26", + "statements": [ + { + "assignments": [ + 7180 + ], + "declarations": [ + { + "constant": false, + "id": 7180, + "name": "availableBorrowsETH", + "nodeType": "VariableDeclaration", + "scope": 7221, + "src": "8144:24:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7179, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "8144:4:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7188, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 7186, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8205:3:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7183, + "name": "ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7174, + "src": "8196:3:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7181, + "name": "collateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7170, + "src": "8171:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7182, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "8171:24:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7184, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8171:29:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7185, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "8171:33:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7187, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8171:38:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8144:65:26" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7191, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7189, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7180, + "src": "8246:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "id": 7190, + "name": "borrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7172, + "src": "8268:16:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8246:38:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7195, + "nodeType": "IfStatement", + "src": "8243:75:26", + "trueBody": { + "id": 7194, + "nodeType": "Block", + "src": "8285:33:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 7192, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8306:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 7178, + "id": 7193, + "nodeType": "Return", + "src": "8299:8:26" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7201, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7196, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7180, + "src": "8328:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7199, + "name": "borrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7172, + "src": "8374:16:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7197, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7180, + "src": "8350:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7198, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "8350:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7200, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8350:41:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8328:63:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7202, + "nodeType": "ExpressionStatement", + "src": "8328:63:26" + }, + { + "assignments": [ + 7204 + ], + "declarations": [ + { + "constant": false, + "id": 7204, + "name": "borrowFee", + "nodeType": "VariableDeclaration", + "scope": 7221, + "src": "8425:17:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7203, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8425:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7215, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7211, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "8535:3:26", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 7212, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "8535:10:26", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 7213, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7180, + "src": "8559:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 7206, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6705, + "src": "8458:17:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 7207, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getFeeProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1316, + "src": "8458:32:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 7208, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8458:34:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7205, + "name": "IFeeProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1765, + "src": "8445:12:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IFeeProvider_$1765_$", + "typeString": "type(contract IFeeProvider)" + } + }, + "id": 7209, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8445:48:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IFeeProvider_$1765", + "typeString": "contract IFeeProvider" + } + }, + "id": 7210, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "calculateLoanOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 1744, + "src": "8445:76:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (address,uint256) view external returns (uint256)" + } + }, + "id": 7214, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8445:143:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8425:163:26" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7218, + "name": "borrowFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7204, + "src": "8629:9:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7216, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7180, + "src": "8605:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7217, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "8605:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7219, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8605:34:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 7178, + "id": 7220, + "nodeType": "Return", + "src": "8598:41:26" + } + ] + }, + "documentation": "@notice calculates the equivalent amount in ETH that an user can borrow, depeding on the available collateral and the\naverage Loan To Value.", + "id": 7222, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateAvailableBorrowsETHInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7175, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7170, + "name": "collateralBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7222, + "src": "8008:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7169, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8008:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7172, + "name": "borrowBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7222, + "src": "8038:24:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7171, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8038:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7174, + "name": "ltv", + "nodeType": "VariableDeclaration", + "scope": 7222, + "src": "8064:11:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7173, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8064:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8007:69:26" + }, + "returnParameters": { + "id": 7178, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7177, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7222, + "src": "8124:7:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7176, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8124:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8123:9:26" + }, + "scope": 7660, + "src": "7962:684:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 7254, + "nodeType": "Block", + "src": "8971:162:26", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7235, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7233, + "name": "borrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7226, + "src": "8985:16:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 7234, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9005:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "8985:21:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7241, + "nodeType": "IfStatement", + "src": "8981:45:26", + "trueBody": { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7238, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "-", + "prefix": true, + "src": "9023:2:26", + "subExpression": { + "argumentTypes": null, + "hexValue": "31", + "id": 7237, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9024:1:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1_by_1", + "typeString": "int_const 1" + }, + "value": "1" + }, + "typeDescriptions": { + "typeIdentifier": "t_rational_minus_1_by_1", + "typeString": "int_const -1" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_minus_1_by_1", + "typeString": "int_const -1" + } + ], + "id": 7236, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "9015:7:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7239, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9015:11:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 7232, + "id": 7240, + "nodeType": "Return", + "src": "9008:18:26" + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7251, + "name": "borrowBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7226, + "src": "9109:16:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 7247, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9096:3:26", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7244, + "name": "liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7228, + "src": "9070:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7242, + "name": "collateralBalanceETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7224, + "src": "9045:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7243, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "9045:24:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7245, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9045:46:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7246, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "9045:50:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7248, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9045:55:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 7249, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "9044:57:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7250, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "wadDiv", + "nodeType": "MemberAccess", + "referencedDeclaration": 9099, + "src": "9044:64:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7252, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9044:82:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 7232, + "id": 7253, + "nodeType": "Return", + "src": "9037:89:26" + } + ] + }, + "documentation": "@notice calculates the health factor from the corresponding balances", + "id": 7255, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateHealthFactorFromBalancesInternal", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7229, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7224, + "name": "collateralBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7255, + "src": "8800:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7223, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8800:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7226, + "name": "borrowBalanceETH", + "nodeType": "VariableDeclaration", + "scope": 7255, + "src": "8838:24:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7225, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8838:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7228, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 7255, + "src": "8872:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7227, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8872:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8790:120:26" + }, + "returnParameters": { + "id": 7232, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7231, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7255, + "src": "8958:7:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7230, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8958:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8957:9:26" + }, + "scope": 7660, + "src": "8740:393:26", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 7262, + "nodeType": "Block", + "src": "9213:59:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7260, + "name": "HEALTH_FACTOR_LIQUIDATION_THRESHOLD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6708, + "src": "9230:35:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 7259, + "id": 7261, + "nodeType": "Return", + "src": "9223:42:26" + } + ] + }, + "documentation": null, + "id": 7263, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getHealthFactorLiquidationThreshold", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7256, + "nodeType": "ParameterList", + "parameters": [], + "src": "9184:2:26" + }, + "returnParameters": { + "id": 7259, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7258, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7263, + "src": "9207:4:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7257, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "9207:4:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9206:6:26" + }, + "scope": 7660, + "src": "9140:132:26", + "stateMutability": "pure", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 7317, + "nodeType": "Block", + "src": "9681:410:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7294, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + { + "argumentTypes": null, + "id": 7284, + "name": "ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7268, + "src": "9702:3:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7285, + "name": "liquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7270, + "src": "9715:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7286, + "name": "usageAsCollateralEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7276, + "src": "9745:24:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "id": 7287, + "name": "fixedBorrowRateEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7280, + "src": "9779:22:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "id": 7288, + "name": "borrowingEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7278, + "src": "9811:16:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "id": 7289, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "9691:137:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "tuple(,uint256,uint256,bool,bool,bool)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7292, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7265, + "src": "9860:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7290, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "9831:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7291, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveConfiguration", + "nodeType": "MemberAccess", + "referencedDeclaration": 5813, + "src": "9831:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,bool,bool,bool)" + } + }, + "id": 7293, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9831:38:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_bool_$_t_bool_$_t_bool_$", + "typeString": "tuple(uint256,uint256,uint256,bool,bool,bool)" + } + }, + "src": "9691:178:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7295, + "nodeType": "ExpressionStatement", + "src": "9691:178:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7301, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7296, + "name": "isActive", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7282, + "src": "9879:8:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7299, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7265, + "src": "9914:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7297, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "9890:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7298, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveIsActive", + "nodeType": "MemberAccess", + "referencedDeclaration": 5889, + "src": "9890:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 7300, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9890:33:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "9879:44:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 7302, + "nodeType": "ExpressionStatement", + "src": "9879:44:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7308, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7303, + "name": "liquidationDiscount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7272, + "src": "9933:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7306, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7265, + "src": "9990:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7304, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "9955:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7305, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveLiquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 5611, + "src": "9955:34:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7307, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9955:44:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9933:66:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7309, + "nodeType": "ExpressionStatement", + "src": "9933:66:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7315, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7310, + "name": "rateStrategyAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7274, + "src": "10010:19:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7313, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7265, + "src": "10075:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7311, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "10032:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7312, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveInterestRateStrategyAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5439, + "src": "10032:42:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 7314, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10032:52:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "10010:74:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 7316, + "nodeType": "ExpressionStatement", + "src": "10010:74:26" + } + ] + }, + "documentation": null, + "id": 7318, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveConfigurationData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7266, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7265, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9316:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7264, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9316:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9315:18:26" + }, + "returnParameters": { + "id": 7283, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7268, + "name": "ltv", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9394:11:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7267, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9394:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7270, + "name": "liquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9419:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7269, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9419:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7272, + "name": "liquidationDiscount", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9461:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7271, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "9461:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7274, + "name": "rateStrategyAddress", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9502:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7273, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "9502:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7276, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9543:29:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7275, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "9543:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7278, + "name": "borrowingEnabled", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9586:21:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7277, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "9586:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7280, + "name": "fixedBorrowRateEnabled", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9621:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7279, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "9621:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7282, + "name": "isActive", + "nodeType": "VariableDeclaration", + "scope": 7318, + "src": "9662:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7281, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "9662:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "9380:296:26" + }, + "scope": 7660, + "src": "9279:812:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 7440, + "nodeType": "Block", + "src": "10706:975:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7354, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7349, + "name": "totalLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7323, + "src": "10716:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7352, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "10763:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7350, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "10733:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7351, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5501, + "src": "10733:29:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7353, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10733:39:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10716:56:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7355, + "nodeType": "ExpressionStatement", + "src": "10716:56:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7361, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7356, + "name": "availableLiquidity", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7325, + "src": "10782:18:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7359, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "10837:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7357, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "10803:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7358, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveAvailableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5482, + "src": "10803:33:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7360, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10803:43:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10782:64:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7362, + "nodeType": "ExpressionStatement", + "src": "10782:64:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7368, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7363, + "name": "totalBorrowsFixed", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7327, + "src": "10856:17:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7366, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "10909:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7364, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "10876:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7365, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveTotalBorrowsFixed", + "nodeType": "MemberAccess", + "referencedDeclaration": 5554, + "src": "10876:32:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7367, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10876:42:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10856:62:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7369, + "nodeType": "ExpressionStatement", + "src": "10856:62:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7375, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7370, + "name": "totalBorrowsVariable", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7329, + "src": "10928:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7373, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "10987:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7371, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "10951:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7372, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 5573, + "src": "10951:35:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7374, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "10951:45:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10928:68:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7376, + "nodeType": "ExpressionStatement", + "src": "10928:68:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7382, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7377, + "name": "liquidityRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7331, + "src": "11006:13:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7380, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11058:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7378, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11022:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7379, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5719, + "src": "11022:35:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7381, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11022:45:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11006:61:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7383, + "nodeType": "ExpressionStatement", + "src": "11006:61:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7389, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7384, + "name": "variableBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7333, + "src": "11077:18:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7387, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11139:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7385, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11098:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7386, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5643, + "src": "11098:40:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7388, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11098:50:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11077:71:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7390, + "nodeType": "ExpressionStatement", + "src": "11077:71:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7396, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7391, + "name": "fixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7335, + "src": "11158:15:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7394, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11214:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7392, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11176:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7393, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5681, + "src": "11176:37:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7395, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11176:47:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11158:65:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7397, + "nodeType": "ExpressionStatement", + "src": "11158:65:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7403, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7398, + "name": "averageFixedBorrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7337, + "src": "11233:22:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7401, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11303:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7399, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11258:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7400, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentAverageFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5700, + "src": "11258:44:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7402, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11258:54:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11233:79:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7404, + "nodeType": "ExpressionStatement", + "src": "11233:79:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7410, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7405, + "name": "utilizationRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7339, + "src": "11322:15:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7408, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11371:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7406, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11340:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7407, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveUtilizationRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6125, + "src": "11340:30:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7409, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11340:40:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11322:58:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7411, + "nodeType": "ExpressionStatement", + "src": "11322:58:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7417, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7412, + "name": "liquidityIndex", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7341, + "src": "11390:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7415, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11447:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7413, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11407:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7414, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveLiquidityCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 5738, + "src": "11407:39:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7416, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11407:49:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11390:66:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7418, + "nodeType": "ExpressionStatement", + "src": "11390:66:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7424, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7419, + "name": "variableBorrowIndex", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7343, + "src": "11466:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7422, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11534:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7420, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11488:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7421, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveVariableBorrowsCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 5757, + "src": "11488:45:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7423, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11488:55:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "11466:77:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7425, + "nodeType": "ExpressionStatement", + "src": "11466:77:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7431, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7426, + "name": "aTokenAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7345, + "src": "11553:13:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7429, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11598:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7427, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11569:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7428, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "11569:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 7430, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11569:38:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "11553:54:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 7432, + "nodeType": "ExpressionStatement", + "src": "11553:54:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7438, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7433, + "name": "lastUpdateTimestamp", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7347, + "src": "11617:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7436, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7320, + "src": "11665:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7434, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "11639:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7435, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5910, + "src": "11639:25:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint40_$", + "typeString": "function (address) view external returns (uint40)" + } + }, + "id": 7437, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "11639:35:26", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "src": "11617:57:26", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "id": 7439, + "nodeType": "ExpressionStatement", + "src": "11617:57:26" + } + ] + }, + "documentation": null, + "id": 7441, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getReserveData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7321, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7320, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10121:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7319, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10121:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10120:18:26" + }, + "returnParameters": { + "id": 7348, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7323, + "name": "totalLiquidity", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10199:22:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7322, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10199:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7325, + "name": "availableLiquidity", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10235:26:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7324, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10235:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7327, + "name": "totalBorrowsFixed", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10275:25:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7326, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10275:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7329, + "name": "totalBorrowsVariable", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10314:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7328, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10314:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7331, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10356:21:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7330, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10356:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7333, + "name": "variableBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10391:26:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7332, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10391:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7335, + "name": "fixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10431:23:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7334, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10431:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7337, + "name": "averageFixedBorrowRate", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10468:30:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7336, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10468:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7339, + "name": "utilizationRate", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10512:23:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7338, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10512:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7341, + "name": "liquidityIndex", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10549:22:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7340, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10549:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7343, + "name": "variableBorrowIndex", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10585:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7342, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "10585:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7345, + "name": "aTokenAddress", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10626:21:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7344, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "10626:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7347, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 7441, + "src": "10661:26:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + }, + "typeName": { + "id": 7346, + "name": "uint40", + "nodeType": "ElementaryTypeName", + "src": "10661:6:26", + "typeDescriptions": { + "typeIdentifier": "t_uint40", + "typeString": "uint40" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "10185:516:26" + }, + "scope": 7660, + "src": "10097:1584:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 7480, + "nodeType": "Block", + "src": "12056:305:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7470, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 7460, + "name": "totalLiquidityETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7446, + "src": "12067:17:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7461, + "name": "totalCollateralETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7448, + "src": "12094:18:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7462, + "name": "totalBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7450, + "src": "12122:15:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7463, + "name": "ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7456, + "src": "12147:3:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7464, + "name": "currentLiquidationThreshold", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7454, + "src": "12160:27:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7465, + "name": "healthFactor", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7458, + "src": "12197:12:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 7466, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "12066:144:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7468, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7443, + "src": "12237:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7467, + "name": "calculateUserGlobalData", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6984, + "src": "12213:23:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address) view returns (uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "id": 7469, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12213:30:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "src": "12066:177:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7471, + "nodeType": "ExpressionStatement", + "src": "12066:177:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7478, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7472, + "name": "availableBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7452, + "src": "12254:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7474, + "name": "totalCollateralETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7448, + "src": "12313:18:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7475, + "name": "totalBorrowsETH", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7450, + "src": "12333:15:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7476, + "name": "ltv", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7456, + "src": "12350:3:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 7473, + "name": "calculateAvailableBorrowsETHInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7222, + "src": "12276:36:26", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_uint256_$_t_uint256_$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,uint256) view returns (uint256)" + } + }, + "id": 7477, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12276:78:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "12254:100:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7479, + "nodeType": "ExpressionStatement", + "src": "12254:100:26" + } + ] + }, + "documentation": null, + "id": 7481, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserAccountData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7444, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7443, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11715:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7442, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "11715:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11714:15:26" + }, + "returnParameters": { + "id": 7459, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7446, + "name": "totalLiquidityETH", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11790:25:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7445, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11790:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7448, + "name": "totalCollateralETH", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11829:26:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7447, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11829:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7450, + "name": "totalBorrowsETH", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11869:23:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7449, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11869:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7452, + "name": "availableBorrowsETH", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11906:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7451, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11906:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7454, + "name": "currentLiquidationThreshold", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11947:35:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7453, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11947:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7456, + "name": "ltv", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "11996:11:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7455, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "11996:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7458, + "name": "healthFactor", + "nodeType": "VariableDeclaration", + "scope": 7481, + "src": "12021:20:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7457, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12021:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "11776:275:26" + }, + "scope": 7660, + "src": "11687:674:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 7617, + "nodeType": "Block", + "src": "12927:1052:26", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7520, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7510, + "name": "currentATokenBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7488, + "src": "12937:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7518, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13017:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7514, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "12996:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7512, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "12967:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7513, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "12967:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 7515, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12967:38:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7511, + "name": "AToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10327, + "src": "12960:6:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_AToken_$10327_$", + "typeString": "type(contract AToken)" + } + }, + "id": 7516, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12960:46:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 7517, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOf", + "nodeType": "MemberAccess", + "referencedDeclaration": 11298, + "src": "12960:56:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7519, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "12960:63:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "12937:86:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7521, + "nodeType": "ExpressionStatement", + "src": "12937:86:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7532, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7522, + "name": "currentUnderlyingBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7490, + "src": "13033:24:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7530, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13127:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7526, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13096:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7524, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13067:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7525, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "13067:28:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 7527, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13067:38:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7523, + "name": "AToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10327, + "src": "13060:6:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_AToken_$10327_$", + "typeString": "type(contract AToken)" + } + }, + "id": 7528, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13060:46:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 7529, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOfUnderlying", + "nodeType": "MemberAccess", + "referencedDeclaration": 10212, + "src": "13060:66:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7531, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13060:73:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13033:100:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7533, + "nodeType": "ExpressionStatement", + "src": "13033:100:26" + }, + { + "assignments": [ + 7537 + ], + "declarations": [ + { + "constant": false, + "id": 7537, + "name": "mode", + "nodeType": "VariableDeclaration", + "scope": 7617, + "src": "13143:33:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 7536, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "13143:28:26", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7543, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7540, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13213:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7541, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13223:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7538, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13179:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7539, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentBorrowRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5988, + "src": "13179:33:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view external returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 7542, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13179:50:26", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "13143:86:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7552, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 7544, + "name": "principalBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7494, + "src": "13240:22:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7545, + "name": "currentBorrowBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7492, + "src": "13272:20:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + null + ], + "id": 7546, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "13239:55:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$__$", + "typeString": "tuple(uint256,uint256,)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7549, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13324:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7550, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13334:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7547, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13297:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7548, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "13297:26:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 7551, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13297:43:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "src": "13239:101:26", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7553, + "nodeType": "ExpressionStatement", + "src": "13239:101:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7558, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7554, + "name": "borrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7496, + "src": "13350:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7556, + "name": "mode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7537, + "src": "13375:4:26", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + ], + "id": 7555, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "13367:7:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7557, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13367:13:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13350:30:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7559, + "nodeType": "ExpressionStatement", + "src": "13350:30:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7576, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7560, + "name": "borrowRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7498, + "src": "13390:10:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 7565, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7561, + "name": "mode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7537, + "src": "13403:4:26", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7562, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "13411:11:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 7563, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "13411:28:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 7564, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "13411:34:26", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "13403:42:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7573, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13567:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7571, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13526:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7572, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentVariableBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5643, + "src": "13526:40:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7574, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13526:50:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7575, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "13403:173:26", + "trueExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7568, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13495:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7569, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13505:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7566, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13460:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7567, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6011, + "src": "13460:34:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7570, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13460:51:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13390:186:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7577, + "nodeType": "ExpressionStatement", + "src": "13390:186:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7583, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7578, + "name": "liquidityRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7500, + "src": "13586:13:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7581, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13638:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7579, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13602:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7580, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveCurrentLiquidityRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5719, + "src": "13602:35:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7582, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13602:45:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13586:61:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7584, + "nodeType": "ExpressionStatement", + "src": "13586:61:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7591, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7585, + "name": "originationFee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7502, + "src": "13657:14:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7588, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13701:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7589, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13711:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7586, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13674:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7587, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserOriginationFee", + "nodeType": "MemberAccess", + "referencedDeclaration": 5956, + "src": "13674:26:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7590, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13674:43:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13657:60:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7592, + "nodeType": "ExpressionStatement", + "src": "13657:60:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7599, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7593, + "name": "variableBorrowIndex", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7504, + "src": "13727:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7596, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13791:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7597, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13801:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7594, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13749:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7595, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserVariableBorrowCumulativeIndex", + "nodeType": "MemberAccess", + "referencedDeclaration": 6086, + "src": "13749:41:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7598, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13749:58:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13727:80:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7600, + "nodeType": "ExpressionStatement", + "src": "13727:80:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7607, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7601, + "name": "lastUpdateTimestamp", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7506, + "src": "13817:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7604, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13862:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7605, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13872:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7602, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13839:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7603, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6111, + "src": "13839:22:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7606, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13839:39:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "13817:61:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7608, + "nodeType": "ExpressionStatement", + "src": "13817:61:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7615, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 7609, + "name": "usageAsCollateralEnabled", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7508, + "src": "13888:24:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7612, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7483, + "src": "13956:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7613, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7485, + "src": "13966:5:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7610, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "13915:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7611, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "13915:40:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 7614, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "13915:57:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "13888:84:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 7616, + "nodeType": "ExpressionStatement", + "src": "13888:84:26" + } + ] + }, + "documentation": null, + "id": 7618, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserReserveData", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7486, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7483, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12395:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7482, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12395:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7485, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12413:13:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7484, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "12413:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12394:33:26" + }, + "returnParameters": { + "id": 7509, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7488, + "name": "currentATokenBalance", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12488:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7487, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12488:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7490, + "name": "currentUnderlyingBalance", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12530:32:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7489, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12530:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7492, + "name": "currentBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12576:28:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7491, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12576:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7494, + "name": "principalBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12618:30:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7493, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12618:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7496, + "name": "borrowRateMode", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12662:22:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7495, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12662:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7498, + "name": "borrowRate", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12698:18:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7497, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12698:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7500, + "name": "liquidityRate", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12730:21:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7499, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12730:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7502, + "name": "originationFee", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12765:22:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7501, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12765:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7504, + "name": "variableBorrowIndex", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12801:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7503, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12801:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7506, + "name": "lastUpdateTimestamp", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12842:27:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7505, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "12842:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7508, + "name": "usageAsCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 7618, + "src": "12883:29:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7507, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "12883:4:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "12474:448:26" + }, + "scope": 7660, + "src": "12367:1612:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 7658, + "nodeType": "Block", + "src": "14197:323:26", + "statements": [ + { + "assignments": [ + 7626 + ], + "declarations": [ + { + "constant": false, + "id": 7626, + "name": "ethereumAddress", + "nodeType": "VariableDeclaration", + "scope": 7658, + "src": "14208:23:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7625, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14208:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7634, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 7628, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6705, + "src": "14258:17:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 7629, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1216, + "src": "14258:44:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 7630, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14258:46:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7627, + "name": "NetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1478, + "src": "14234:23:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_NetworkMetadataProvider_$1478_$", + "typeString": "type(contract NetworkMetadataProvider)" + } + }, + "id": 7631, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14234:71:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_NetworkMetadataProvider_$1478", + "typeString": "contract NetworkMetadataProvider" + } + }, + "id": 7632, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1466, + "src": "14234:90:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 7633, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14234:92:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14208:118:26" + }, + { + "assignments": [ + 7636 + ], + "declarations": [ + { + "constant": false, + "id": 7636, + "name": "coreAddress", + "nodeType": "VariableDeclaration", + "scope": 7658, + "src": "14336:19:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7635, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14336:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7640, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7638, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6703, + "src": "14366:4:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + ], + "id": 7637, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "14358:7:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 7639, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14358:13:26", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14336:35:26" + }, + { + "assignments": [ + 7642 + ], + "declarations": [ + { + "constant": false, + "id": 7642, + "name": "balance", + "nodeType": "VariableDeclaration", + "scope": 7658, + "src": "14382:12:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7641, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "14382:4:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7655, + "initialValue": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 7645, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7643, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7620, + "src": "14397:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 7644, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7626, + "src": "14409:15:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "14397:27:26", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7652, + "name": "coreAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7636, + "src": "14476:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7649, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7620, + "src": "14456:8:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 7648, + "name": "IERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11786, + "src": "14449:6:26", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IERC20_$11786_$", + "typeString": "type(contract IERC20)" + } + }, + "id": 7650, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14449:16:26", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 7651, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOf", + "nodeType": "MemberAccess", + "referencedDeclaration": 11731, + "src": "14449:26:26", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7653, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "14449:39:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7654, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "14397:91:26", + "trueExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7646, + "name": "coreAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7636, + "src": "14427:11:26", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 7647, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balance", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "14427:19:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "14382:106:26" + }, + { + "expression": { + "argumentTypes": null, + "id": 7656, + "name": "balance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7642, + "src": "14506:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 7624, + "id": 7657, + "nodeType": "Return", + "src": "14499:14:26" + } + ] + }, + "documentation": "@dev provides the actual balance of a reserve, by checking the core balance of the underlying ERC20/Ether", + "id": 7659, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getCoreActualReserveBalance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7621, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7620, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 7659, + "src": "14149:16:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7619, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "14149:7:26", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14148:18:26" + }, + "returnParameters": { + "id": 7624, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7623, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 7659, + "src": "14189:7:26", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7622, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "14189:7:26", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "14188:9:26" + }, + "scope": 7660, + "src": "14112:408:26", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 7661, + "src": "851:13671:26" + } + ], + "src": "0:14523:26" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.763Z", + "devdoc": { + "author": "Aave", + "methods": { + "getCoreActualReserveBalance(address)": { + "details": "provides the actual balance of a reserve, by checking the core balance of the underlying ERC20/Ether" + }, + "isOwner()": { + "details": "Returns true if the caller is the current owner." + }, + "owner()": { + "details": "Returns the address of the current owner." + }, + "renounceOwnership()": { + "details": "Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner." + }, + "transferOwnership(address)": { + "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner." + } + }, + "title": "LendingPoolDataProvider contract" + }, + "userdoc": { + "methods": { + "calculateUserGlobalData(address)": { + "notice": "calculates the user data across the reserves. this includes the total liquidity/collateral/borrow balances in ETH, the average Loan To Value, the average Liquidation Ratio, and the Health factor." + }, + "getUserUnderlyingAssetBalance(address,address)": { + "notice": "gets the underlying asset balance of a user based on the corresponding aToken balance." + } + }, + "notice": "***********************************************************************************Implements functions to fetch data from the core, and aggregate them in order to allow computation on the compounded balances and the account balances in ETH************************************************************************************" + } +} \ No newline at end of file diff --git a/client/src/contracts/LendingPoolLiquidationManager.json b/client/src/contracts/LendingPoolLiquidationManager.json new file mode 100644 index 0000000..1b3e82a --- /dev/null +++ b/client/src/contracts/LendingPoolLiquidationManager.json @@ -0,0 +1,15759 @@ +{ + "contractName": "LendingPoolLiquidationManager", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "addressesProvider", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [], + "name": "LiquidationCompleted", + "type": "event" + }, + { + "constant": false, + "inputs": [ + { + "name": "_collateral", + "type": "address" + }, + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_user", + "type": "address" + }, + { + "name": "_purchaseAmount", + "type": "uint256" + }, + { + "name": "_receiveAToken", + "type": "bool" + } + ], + "name": "liquidationCall", + "outputs": [ + { + "name": "", + "type": "uint256" + }, + { + "name": "", + "type": "string" + } + ], + "payable": true, + "stateMutability": "payable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_collateral\",\"type\":\"address\"},{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_purchaseAmount\",\"type\":\"uint256\"},{\"name\":\"_receiveAToken\",\"type\":\"bool\"}],\"name\":\"liquidationCall\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"},{\"name\":\"\",\"type\":\"string\"}],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"addressesProvider\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"LiquidationCompleted\",\"type\":\"event\"}],\"devdoc\":{\"author\":\"Aave\",\"methods\":{\"liquidationCall(address,address,address,uint256,bool)\":{\"details\":\"_receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset.\"}},\"title\":\"LiquidationManager contract\"},\"userdoc\":{\"methods\":{\"liquidationCall(address,address,address,uint256,bool)\":{\"notice\":\"implements loan liquidation\"}},\"notice\":\"***********************************************************************************Implements the actions of the LendingPool, and exposes accessory methods to access the core information************************************************************************************\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol\":\"LendingPoolLiquidationManager\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x0ae6004410cd58a1c5151e67959167cf58cd5e77e8b625677826e295905fb318\",\"urls\":[\"bzzr://d223bea23f0e9bd70844e9852f490be93d30fc1c31bf114c807d0e4fe07d929b\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol\":{\"keccak256\":\"0xcd8c22e8b9f5c5c4bdb5b5262beafa93486c3b15262283c053afd423eca6e16b\",\"urls\":[\"bzzr://a9a5076a121f51ea42d9ebddc2684f299a0b57c0321837b5776c3a9eb26be97e\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol\":{\"keccak256\":\"0x479a8627304b58f37a4adbe06a72c7a056ad7ce6793a4ea66deeba04c6e443c8\",\"urls\":[\"bzzr://92bb0ae9b38ab361638c71c81f650ff8115da42cb4f50a0ee7a6fb5e03e5e640\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol\":{\"keccak256\":\"0x3f74e899243a66d556c0fa81875ab95ed1e3af1909b0281d03fe89590b95121f\",\"urls\":[\"bzzr://ef6ed6edeb1ec124bf1749991346f0708214f7e12c353175d36b491bce45d7a4\"]},\"/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol\":{\"keccak256\":\"0x3b825dc98b6a7aa21e9c9b05e1951bec7b5d7c84b7a0e8de0750069ccb31ebac\",\"urls\":[\"bzzr://8a616caca158d63de8db6037a2162c1effaaa71f6d7095a11516e03f7ea391d0\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol\":{\"keccak256\":\"0xdf72f6345d96ca2731656811b508db7f8e4975776d6de39ab24dbe4a13794fd8\",\"urls\":[\"bzzr://687ac9b4f396f264af2645041f5532b6881ec8c92dad3e505ca96477957c784d\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":{\"keccak256\":\"0xeeae2b67fa36103fe1c3a4e346b9c04171f9065949953abd00104c357834b0e3\",\"urls\":[\"bzzr://4e3bd29abfa796726532c3e42dd8039ab0f93388d7bbf358428dbc9b0399664a\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x0adf744884b9262f507aba565d1c96c82397f58d399a2dc2c60a452953197574\",\"urls\":[\"bzzr://03099f88c041565b5ac13ea7e645a8f9bff0c29bfa584c7969372ce12c5473f5\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol\":{\"keccak256\":\"0x35a7f1a34259948cdcb03084718f765215fe69559f557b395d9d6e18c63ac823\",\"urls\":[\"bzzr://f529e265dd06192a1d552f1f41c245790419562dfb52e7be9d443c758ccb72d0\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPool.sol\":{\"keccak256\":\"0x3f4ef00886795fb781b76e1fab7ce2f0422de9d0941bc8d5d9c377ad100e9a33\",\"urls\":[\"bzzr://8aff91a48f36ed3d3da74fc48d65cbc20e56e45172790ae38f18e234883ece70\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol\":{\"keccak256\":\"0xca757f989e0e7519d03d4e3086028e3022306ec4bb7f610fa78bff866f04c998\",\"urls\":[\"bzzr://f381f642ecce43d76d9e0011ea3c7c6218d1eaa2e0d3a7d5aecd55552cc0fb27\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol\":{\"keccak256\":\"0xe9e88d47e58f59345bb70a48960878e8b6d7525e3fe4f03c63f575599123957a\",\"urls\":[\"bzzr://ab72dddd7f00500a59b72b7f2f938ca25ae859517d524e446dc92a37f5f4a4e3\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol\":{\"keccak256\":\"0x8cd409571214e2d2f9196b8a31ce04bb44919ce7b12e66301c216c3de70a3f5f\",\"urls\":[\"bzzr://87f2c373a1f51ca84ac1132e72e3ef5a43e7a4f4f10341a63993c2cbdb769b64\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol\":{\"keccak256\":\"0xb8b4844881a9ea5c3f0f2584061efcbfb6c96863ca3a07b960d2f9d323293cac\",\"urls\":[\"bzzr://8cb1c5dcce198c0f60c21bd9807b361fc214a60d4b3aa3442153b045b51a4325\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol\":{\"keccak256\":\"0x547550bb7c7e61190fddae1b4dbe71932c9acdaf1d196524ee99c3340a5bec2d\",\"urls\":[\"bzzr://4a9ee0d136529517d7586cb3842177dbd767d9c34fdb035b0a90e8f4cc4d1b35\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol\":{\"keccak256\":\"0x4a3a810b7ebe742e897e1fd428b3eeed2196d3acea58eaf9c566ed10d545d2ed\",\"urls\":[\"bzzr://729aefb3f89f616c954a0735f8b4dd8804bdd0351e96f8e904fdb3e78a109b6c\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]},\"openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol\":{\"keccak256\":\"0xe86fdc15fbc379ecf14d6aa4f51b87c0be8476e114e23c171b790a6717230655\",\"urls\":[\"bzzr://364c5847b4ee3ac37a6ad6e54a288889ac3d2a85757b7999c00c719db6cd871d\"]}},\"version\":1}", + "bytecode": "0x608060405260016000819055506123da8061001b6000396000f3fe6080604052600436106100285760003560e01c8062a718a91461002d578063c72c4d1014610147575b600080fd5b6100c5600480360360a081101561004357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080351515906020019092919050505061019e565b6040518083815260200180602001828103825283818151815260200191508051906020019080838360005b8381101561010b5780820151818401526020810190506100f0565b50505050905090810190601f1680156101385780820380516001836020036101000a031916815260200191505b50935050505060405180910390f35b34801561015357600080fd5b5061015c611b86565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b600060606101aa612252565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632c6d0e9b876040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060c06040518083038186803b15801561024957600080fd5b505afa15801561025d573d6000803e3d6000fd5b505050506040513d60c081101561027357600080fd5b810190808051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509091929394509091929350909192509091509050816000018181525050600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633e44bee86040518163ffffffff1660e01b815260040160206040518083038186803b15801561033b57600080fd5b505afa15801561034f573d6000803e3d6000fd5b505050506040513d602081101561036557600080fd5b81019080805190602001909291905050508160000151106103b0576004600581111561038d57fe5b60405180606001604052806028815260200161235d602891399250925050611b7c565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318a4dbca89886040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561048357600080fd5b505afa158015610497573d6000803e3d6000fd5b505050506040513d60208110156104ad57600080fd5b810190808051906020019092919050505081602001818152505060008160200151141561052157600160058111156104e157fe5b6040518060400160405280601f81526020017f496e76616c696420636f6c6c61746572616c20746f206c6971756964617465008152509250925050611b7c565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318f9bbae896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156105c057600080fd5b505afa1580156105d4573d6000803e3d6000fd5b505050506040513d60208110156105ea57600080fd5b8101908080519060200190929190505050806107115750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b89886040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156106d457600080fd5b505afa1580156106e8573d6000803e3d6000fd5b505050506040513d60208110156106fe57600080fd5b8101908080519060200190929190505050155b8161014001901515908115158152505080610140015161075b576002600581111561073857fe5b6040518060600160405280602b81526020016122de602b91399250925050611b7c565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd88886040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b15801561082e57600080fd5b505afa158015610842573d6000803e3d6000fd5b505050506040513d606081101561085857600080fd5b810190808051906020019092919080519060200190929190805190602001909291905050509091508260400183606001828152508281525050506000816040015114156108cf57600360058111156108ac57fe5b6040518060600160405280602a8152602001612385602a91399250925050611b7c565b6108fa60646108ec60328460400151611bac90919063ffffffff16565b611c3290919063ffffffff16565b81608001818152505080608001518511610914578461091a565b80608001515b8160a001818152505060008061093a8a8a8560a001518660200151611c7c565b915091508260a0015181101561095557808360a00181815250505b85610a73576000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e24030198c6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156109fb57600080fd5b505afa158015610a0f573d6000803e3d6000fd5b505050506040513d6020811015610a2557600080fd5b81019080805190602001909291905050509050828110610a7157600580811115610a4b57fe5b60405180606001604052806033815260200161232a603391399550955050505050611b7c565b505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e8a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b158015610b1457600080fd5b505af1158015610b28573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631ca19f198b8b6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015610c0157600080fd5b505afa158015610c15573d6000803e3d6000fd5b505050506040513d6020811015610c2b57600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b08b86606001516040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015610ceb57600080fd5b505af1158015610cff573d6000803e3d6000fd5b5050505060006001811115610d1057fe5b816001811115610d1c57fe5b1415610f1d576000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166344e636b78c8c6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015610df757600080fd5b505afa158015610e0b573d6000803e3d6000fd5b505050506040513d6020811015610e2157600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b6e1f7028c610e8e88606001518960a0015161208290919063ffffffff16565b846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b158015610eff57600080fd5b505af1158015610f13573d6000803e3d6000fd5b5050505050610ff9565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663cc6ae7638b610f7787606001518860a0015161208290919063ffffffff16565b6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015610fe057600080fd5b505af1158015610ff4573d6000803e3d6000fd5b505050505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd6538b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561109a57600080fd5b505af11580156110ae573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb8b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561115357600080fd5b505af1158015611167573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a37b19578b8b6111c688606001518960a0015161208290919063ffffffff16565b6040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561126257600080fd5b505af1158015611276573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663405300df8b8b6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561134f57600080fd5b505af1158015611363573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e8c6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561140857600080fd5b505af115801561141c573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee8d6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156114c157600080fd5b505afa1580156114d5573d6000803e3d6000fd5b505050506040513d60208110156114eb57600080fd5b8101908080519060200190929190505050905060008173ffffffffffffffffffffffffffffffffffffffff1663b32d4610866040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b15801561155157600080fd5b505afa158015611565573d6000803e3d6000fd5b505050506040513d602081101561157b57600080fd5b81019080805190602001909291905050509050881561166c578173ffffffffffffffffffffffffffffffffffffffff1663f866c3198c33846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561164f57600080fd5b505af1158015611663573d6000803e3d6000fd5b5050505061197b565b8173ffffffffffffffffffffffffffffffffffffffff16633edb7cb88c836040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156116f357600080fd5b505af1158015611707573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663352ed9d48e876040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156117b457600080fd5b505af11580156117c8573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd6538e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561186d57600080fd5b505af1158015611881573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa93b2a58e33886040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561196257600080fd5b505af1158015611976573d6000803e3d6000fd5b505050505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb8e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b158015611a1c57600080fd5b505af1158015611a30573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166328fcf4d3348e338a60a001516040518563ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200193505050506000604051808303818588803b158015611b1557600080fd5b505af1158015611b29573d6000803e3d6000fd5b505050505060006005811115611b3b57fe5b6040518060400160405280600981526020017f4e6f206572726f72730000000000000000000000000000000000000000000000815250975097505050505050505b9550959350505050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080831415611bbf5760009050611c2c565b6000828402905082848281611bd057fe5b0414611c27576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806123096021913960400191505060405180910390fd5b809150505b92915050565b6000611c7483836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f0000000000008152506120cc565b905092915050565b60008060009150600090506000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fca513a86040518163ffffffff1660e01b815260040160206040518083038186803b158015611cf157600080fd5b505afa158015611d05573d6000803e3d6000fd5b505050506040513d6020811015611d1b57600080fd5b81019080805190602001909291905050509050611d366122ae565b8173ffffffffffffffffffffffffffffffffffffffff1663b3596f07896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611db357600080fd5b505afa158015611dc7573d6000803e3d6000fd5b505050506040513d6020811015611ddd57600080fd5b81019080805190602001909291905050508160400181815250508173ffffffffffffffffffffffffffffffffffffffff1663b3596f07886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611e7457600080fd5b505afa158015611e88573d6000803e3d6000fd5b505050506040513d6020811015611e9e57600080fd5b8101908080519060200190929190505050816060018181525050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b77b1958896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611f5757600080fd5b505afa158015611f6b573d6000803e3d6000fd5b505050506040513d6020811015611f8157600080fd5b8101908080519060200190929190505050816020018181525050611ff16064611fe38360200151611fd58560400151611fc78c8860600151611bac90919063ffffffff16565b611c3290919063ffffffff16565b611bac90919063ffffffff16565b611c3290919063ffffffff16565b81608001818152505084816080015111156120665784935061205f8160200151612051606461204385606001516120358a8860400151611bac90919063ffffffff16565b611c3290919063ffffffff16565b611bac90919063ffffffff16565b611c3290919063ffffffff16565b9250612071565b806080015193508592505b838393509350505094509492505050565b60006120c483836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250612192565b905092915050565b60008083118290612178576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561213d578082015181840152602081019050612122565b50505050905090810190601f16801561216a5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50600083858161218457fe5b049050809150509392505050565b600083831115829061223f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156122045780820151818401526020810190506121e9565b50505050905090810190601f1680156122315780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b604051806101600160405280600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000151581525090565b6040518060a001604052806000815260200160008152602001600081526020016000815260200160008152509056fe54686520636f6c6c61746572616c2063686f73656e2063616e6e6f74206265206c69757175696461746564536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7754686572652069736e277420656e6f756768206c697175696469747920617661696c61626c6520746f206c69717569646174654865616c746820666163746f72206973206e6f742062656c6f7720746865207468726573686f6c645573657220646964206e6f7420626f72726f7720746865207370656369666965642063757272656e6379a165627a7a72305820d0d19ed836a5e8b1a519ebd841d422340c7c9e4227eb7b8854518c2f2802a3030029", + "deployedBytecode": "0x6080604052600436106100285760003560e01c8062a718a91461002d578063c72c4d1014610147575b600080fd5b6100c5600480360360a081101561004357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080351515906020019092919050505061019e565b6040518083815260200180602001828103825283818151815260200191508051906020019080838360005b8381101561010b5780820151818401526020810190506100f0565b50505050905090810190601f1680156101385780820380516001836020036101000a031916815260200191505b50935050505060405180910390f35b34801561015357600080fd5b5061015c611b86565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b600060606101aa612252565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632c6d0e9b876040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060c06040518083038186803b15801561024957600080fd5b505afa15801561025d573d6000803e3d6000fd5b505050506040513d60c081101561027357600080fd5b810190808051906020019092919080519060200190929190805190602001909291908051906020019092919080519060200190929190805190602001909291905050509091929394509091929350909192509091509050816000018181525050600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16633e44bee86040518163ffffffff1660e01b815260040160206040518083038186803b15801561033b57600080fd5b505afa15801561034f573d6000803e3d6000fd5b505050506040513d602081101561036557600080fd5b81019080805190602001909291905050508160000151106103b0576004600581111561038d57fe5b60405180606001604052806028815260200161235d602891399250925050611b7c565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318a4dbca89886040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b15801561048357600080fd5b505afa158015610497573d6000803e3d6000fd5b505050506040513d60208110156104ad57600080fd5b810190808051906020019092919050505081602001818152505060008160200151141561052157600160058111156104e157fe5b6040518060400160405280601f81526020017f496e76616c696420636f6c6c61746572616c20746f206c6971756964617465008152509250925050611b7c565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166318f9bbae896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156105c057600080fd5b505afa1580156105d4573d6000803e3d6000fd5b505050506040513d60208110156105ea57600080fd5b8101908080519060200190929190505050806107115750600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639e3c4f3b89886040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b1580156106d457600080fd5b505afa1580156106e8573d6000803e3d6000fd5b505050506040513d60208110156106fe57600080fd5b8101908080519060200190929190505050155b8161014001901515908115158152505080610140015161075b576002600581111561073857fe5b6040518060600160405280602b81526020016122de602b91399250925050611b7c565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16639fb8afcd88886040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060606040518083038186803b15801561082e57600080fd5b505afa158015610842573d6000803e3d6000fd5b505050506040513d606081101561085857600080fd5b810190808051906020019092919080519060200190929190805190602001909291905050509091508260400183606001828152508281525050506000816040015114156108cf57600360058111156108ac57fe5b6040518060600160405280602a8152602001612385602a91399250925050611b7c565b6108fa60646108ec60328460400151611bac90919063ffffffff16565b611c3290919063ffffffff16565b81608001818152505080608001518511610914578461091a565b80608001515b8160a001818152505060008061093a8a8a8560a001518660200151611c7c565b915091508260a0015181101561095557808360a00181815250505b85610a73576000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663e24030198c6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156109fb57600080fd5b505afa158015610a0f573d6000803e3d6000fd5b505050506040513d6020811015610a2557600080fd5b81019080805190602001909291905050509050828110610a7157600580811115610a4b57fe5b60405180606001604052806033815260200161232a603391399550955050505050611b7c565b505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e8a6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b158015610b1457600080fd5b505af1158015610b28573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16631ca19f198b8b6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015610c0157600080fd5b505afa158015610c15573d6000803e3d6000fd5b505050506040513d6020811015610c2b57600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638e65a6b08b86606001516040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015610ceb57600080fd5b505af1158015610cff573d6000803e3d6000fd5b5050505060006001811115610d1057fe5b816001811115610d1c57fe5b1415610f1d576000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166344e636b78c8c6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019250505060206040518083038186803b158015610df757600080fd5b505afa158015610e0b573d6000803e3d6000fd5b505050506040513d6020811015610e2157600080fd5b81019080805190602001909291905050509050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b6e1f7028c610e8e88606001518960a0015161208290919063ffffffff16565b846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018381526020018281526020019350505050600060405180830381600087803b158015610eff57600080fd5b505af1158015610f13573d6000803e3d6000fd5b5050505050610ff9565b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663cc6ae7638b610f7787606001518860a0015161208290919063ffffffff16565b6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b158015610fe057600080fd5b505af1158015610ff4573d6000803e3d6000fd5b505050505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd6538b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561109a57600080fd5b505af11580156110ae573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb8b6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561115357600080fd5b505af1158015611167573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a37b19578b8b6111c688606001518960a0015161208290919063ffffffff16565b6040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561126257600080fd5b505af1158015611276573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663405300df8b8b6040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200192505050600060405180830381600087803b15801561134f57600080fd5b505af1158015611363573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166348dfc16e8c6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561140857600080fd5b505af115801561141c573d6000803e3d6000fd5b505050506000600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166334b3beee8d6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156114c157600080fd5b505afa1580156114d5573d6000803e3d6000fd5b505050506040513d60208110156114eb57600080fd5b8101908080519060200190929190505050905060008173ffffffffffffffffffffffffffffffffffffffff1663b32d4610866040518263ffffffff1660e01b81526004018082815260200191505060206040518083038186803b15801561155157600080fd5b505afa158015611565573d6000803e3d6000fd5b505050506040513d602081101561157b57600080fd5b81019080805190602001909291905050509050881561166c578173ffffffffffffffffffffffffffffffffffffffff1663f866c3198c33846040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561164f57600080fd5b505af1158015611663573d6000803e3d6000fd5b5050505061197b565b8173ffffffffffffffffffffffffffffffffffffffff16633edb7cb88c836040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156116f357600080fd5b505af1158015611707573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663352ed9d48e876040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050600060405180830381600087803b1580156117b457600080fd5b505af11580156117c8573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166342bbd6538e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b15801561186d57600080fd5b505af1158015611881573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fa93b2a58e33886040518463ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018281526020019350505050600060405180830381600087803b15801561196257600080fd5b505af1158015611976573d6000803e3d6000fd5b505050505b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16632717cbfb8e6040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050600060405180830381600087803b158015611a1c57600080fd5b505af1158015611a30573d6000803e3d6000fd5b50505050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166328fcf4d3348e338a60a001516040518563ffffffff1660e01b8152600401808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200193505050506000604051808303818588803b158015611b1557600080fd5b505af1158015611b29573d6000803e3d6000fd5b505050505060006005811115611b3b57fe5b6040518060400160405280600981526020017f4e6f206572726f72730000000000000000000000000000000000000000000000815250975097505050505050505b9550959350505050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600080831415611bbf5760009050611c2c565b6000828402905082848281611bd057fe5b0414611c27576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260218152602001806123096021913960400191505060405180910390fd5b809150505b92915050565b6000611c7483836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f0000000000008152506120cc565b905092915050565b60008060009150600090506000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663fca513a86040518163ffffffff1660e01b815260040160206040518083038186803b158015611cf157600080fd5b505afa158015611d05573d6000803e3d6000fd5b505050506040513d6020811015611d1b57600080fd5b81019080805190602001909291905050509050611d366122ae565b8173ffffffffffffffffffffffffffffffffffffffff1663b3596f07896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611db357600080fd5b505afa158015611dc7573d6000803e3d6000fd5b505050506040513d6020811015611ddd57600080fd5b81019080805190602001909291905050508160400181815250508173ffffffffffffffffffffffffffffffffffffffff1663b3596f07886040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611e7457600080fd5b505afa158015611e88573d6000803e3d6000fd5b505050506040513d6020811015611e9e57600080fd5b8101908080519060200190929190505050816060018181525050600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b77b1958896040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b158015611f5757600080fd5b505afa158015611f6b573d6000803e3d6000fd5b505050506040513d6020811015611f8157600080fd5b8101908080519060200190929190505050816020018181525050611ff16064611fe38360200151611fd58560400151611fc78c8860600151611bac90919063ffffffff16565b611c3290919063ffffffff16565b611bac90919063ffffffff16565b611c3290919063ffffffff16565b81608001818152505084816080015111156120665784935061205f8160200151612051606461204385606001516120358a8860400151611bac90919063ffffffff16565b611c3290919063ffffffff16565b611bac90919063ffffffff16565b611c3290919063ffffffff16565b9250612071565b806080015193508592505b838393509350505094509492505050565b60006120c483836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f770000815250612192565b905092915050565b60008083118290612178576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561213d578082015181840152602081019050612122565b50505050905090810190601f16801561216a5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b50600083858161218457fe5b049050809150509392505050565b600083831115829061223f576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b838110156122045780820151818401526020810190506121e9565b50505050905090810190601f1680156122315780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b604051806101600160405280600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000815260200160008152602001600081526020016000151581525090565b6040518060a001604052806000815260200160008152602001600081526020016000815260200160008152509056fe54686520636f6c6c61746572616c2063686f73656e2063616e6e6f74206265206c69757175696461746564536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f7754686572652069736e277420656e6f756768206c697175696469747920617661696c61626c6520746f206c69717569646174654865616c746820666163746f72206973206e6f742062656c6f7720746865207468726573686f6c645573657220646964206e6f7420626f72726f7720746865207370656369666965642063757272656e6379a165627a7a72305820d0d19ed836a5e8b1a519ebd841d422340c7c9e4227eb7b8854518c2f2802a3030029", + "sourceMap": "1080:9075:27:-;;;879:1:63;863:13;:17;;;;1080:9075:27;;;;;;", + "deployedSourceMap": "1080:9075:27:-;;;;;;;;;;;;;;;;;;;;;;;;;;2394:5550;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;2394:5550:27;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;2394:5550:27;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1251:53;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1251:53:27;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2394:5550;2567:7;2576:13;2605:36;;:::i;:::-;2679:12;;;;;;;;;;;:36;;;2716:5;2679:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2679:43:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2679:43:27;;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;2679:43:27;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2652:70;;;;;;;;;;;;;;;;;;;;2658:4;:17;;2652:70;;;;;2757:12;;;;;;;;;;;:48;;;:50;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2757:50:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2757:50:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2757:50:27;;;;;;;;;;;;;;;;2736:4;:17;;;:71;2733:209;;2838:47;2830:56;;;;;;;;2822:109;;;;;;;;;;;;;;;;;;;;;;;;2733:209;2981:12;;;;;;;;;;;:42;;;3024:11;3037:5;2981:62;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2981:62:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2981:62:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2981:62:27;;;;;;;;;;;;;;;;2952:4;:26;;:91;;;;;3175:1;3145:4;:26;;;:31;3142:155;;;3208:41;3200:50;;;;;;;;3192:94;;;;;;;;;;;;;;;;;;;;;;;;3142:155;3334:4;;;;;;;;;;;:38;;;3373:11;3334:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3334:51:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3334:51:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3334:51:27;;;;;;;;;;;;;;;;:128;;;;3402:4;;;;;;;;;;;:40;;;3443:11;3456:5;3402:60;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3402:60:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3402:60:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3402:60:27;;;;;;;;;;;;;;;;3401:61;3334:128;3307:4;:24;;:155;;;;;;;;;;;3564:4;:24;;;3560:169;;3620:49;3612:58;;;;;;;;3604:114;;;;;;;;;;;;;;;;;;;;;;;;3560:169;3909:4;;;;;;;;;;;:26;;;3936:8;3946:5;3909:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;3909:43:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;3909:43:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3909:43:27;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3844:108;;;3846:4;:32;;3879:4;:26;;3844:108;;;;;;;;;;4002:1;3966:4;:32;;;:37;3963:170;;;4034:40;4026:49;;;;;;;;4018:104;;;;;;;;;;;;;;;;;;;;;;;;3963:170;4260:79;4335:3;4260:70;1486:2;4260:4;:32;;;:36;;:70;;;;:::i;:::-;:74;;:79;;;;:::i;:::-;4223:4;:34;;:116;;;;;4399:4;:34;;;4381:15;:52;:155;;4521:15;4381:155;;;4460:4;:34;;;4381:155;4350:4;:28;;:186;;;;;4548:32;4590:29;4623:120;4663:11;4676:8;4686:4;:28;;;4716:4;:26;;;4623:39;:120::i;:::-;4547:196;;;;4992:4;:28;;;4968:21;:52;4965:133;;;5066:21;5035:4;:28;;:52;;;;;4965:133;5232:14;5228:342;;5261:34;5298:4;;;;;;;;;;;:33;;;5332:11;5298:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5298:46:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5298:46:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5298:46:27;;;;;;;;;;;;;;;;5261:83;;5391:24;5361:26;:54;5358:202;;5450:38;5442:47;;;;;;;;5434:111;;;;;;;;;;;;;;;;;;;;;;;;;;;5358:202;5228:342;;5620:4;;;;;;;;;;;:35;;;5656:8;5620:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5620:45:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5620:45:27;;;;5676:43;5722:4;;;;;;;;;;;:33;;;5756:8;5765:5;5722:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5722:49:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5722:49:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5722:49:27;;;;;;;;;;;;;;;;5676:95;;5782:4;;;;;;;;;;;:34;;;5817:8;5827:4;:26;;;5782:72;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5782:72:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5782:72:27;;;;5887:34;5869:52;;;;;;;;:14;:52;;;;;;;;;5865:465;;;5937:24;5964:4;;;;;;;;;;;:34;;;5999:8;6009:5;5964:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;5964:51:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;5964:51:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;5964:51:27;;;;;;;;;;;;;;;;5937:78;;6029:4;;;;;;;;;;;:57;;;6087:8;6097:60;6130:4;:26;;;6097:4;:28;;;:32;;:60;;;;:::i;:::-;6159:16;6029:147;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6029:147:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6029:147:27;;;;5865:465;;;;6207:4;;;;;;;;;;;:40;;;6248:8;6258:60;6291:4;:26;;;6258:4;:28;;;:32;;:60;;;;:::i;:::-;6207:112;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6207:112:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6207:112:27;;;;5865:465;6340:4;;;;;;;;;;;:31;;;6372:8;6340:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6340:41:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6340:41:27;;;;6391:4;;;;;;;;;;;:25;;;6417:8;6391:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6391:35:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6391:35:27;;;;6478:4;;;;;;;;;;;:39;;;6518:8;6528:5;6535:60;6568:4;:26;;;6535:4;:28;;;:32;;:60;;;;:::i;:::-;6478:118;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6478:118:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6478:118:27;;;;6606:4;;;;;;;;;;;:22;;;6629:8;6638:5;6606:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6606:38:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6606:38:27;;;;6691:4;;;;;;;;;;;:35;;;6727:11;6691:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6691:48:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6691:48:27;;;;6749:23;6782:4;;;;;;;;;;;:28;;;6811:11;6782:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6782:41:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6782:41:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6782:41:27;;;;;;;;;;;;;;;;6749:75;;6893:35;6931:16;:47;;;6979:24;6931:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;6931:73:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;6931:73:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;6931:73:27;;;;;;;;;;;;;;;;6893:111;;7104:14;7101:562;;;7134:16;:38;;;7173:5;7180:10;7192:27;7134:86;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7134:86:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7134:86:27;;;;7101:562;;;7352:16;:34;;;7387:5;7394:27;7352:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7352:70:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7352:70:27;;;;7436:4;;;;;;;;;;;:34;;;7471:11;7484:24;7436:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7436:73:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7436:73:27;;;;7523:4;;;;;;;;;;;:31;;;7555:11;7523:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7523:44:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7523:44:27;;;;7581:4;;;;;;;;;;;:19;;;7601:11;7614:10;7626:24;7581:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7581:70:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7581:70:27;;;;7101:562;7673:4;;;;;;;;;;;:25;;;7699:11;7673:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7673:38:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7673:38:27;;;;7778:4;;;;;;;;;;;:22;;;7807:9;7818:8;7828:10;7840:4;:28;;;7778:91;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;7778:91:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;7778:91:27;;;;;7896:26;7888:35;;;;;;;;7880:57;;;;;;;;;;;;;;;;;;;;;;;;;;;2394:5550;;;;;;;;;:::o;1251:53::-;;;;;;;;;;;;;:::o;2159:459:56:-;2217:7;2463:1;2458;:6;2454:45;;;2487:1;2480:8;;;;2454:45;2509:9;2525:1;2521;:5;2509:17;;2553:1;2548;2544;:5;;;;;;:10;2536:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2610:1;2603:8;;;2159:459;;;;;:::o;3073:130::-;3131:7;3157:39;3161:1;3164;3157:39;;;;;;;;;;;;;;;;;:3;:39::i;:::-;3150:46;;3073:130;;;;:::o;8505:1648:27:-;8707:24;8733:29;8794:1;8775:20;;8829:1;8805:25;;8840:19;8875:17;;;;;;;;;;;:32;;;:34;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;8875:34:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;8875:34:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;8875:34:27;;;;;;;;;;;;;;;;8840:70;;8921:51;;:::i;:::-;9006:6;:20;;;9027:11;9006:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9006:33:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9006:33:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9006:33:27;;;;;;;;;;;;;;;;8983:4;:20;;:56;;;;;9079:6;:20;;;9100:10;9079:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9079:32:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9079:32:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9079:32:27;;;;;;;;;;;;;;;;9049:4;:27;;:62;;;;;9148:4;;;;;;;;;;;:34;;;9183:11;9148:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;9148:47:27;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;9148:47:27;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;9148:47:27;;;;;;;;;;;;;;;;9121:4;:24;;:74;;;;;9429:152;9577:3;9429:130;9534:4;:24;;;9429:87;9495:4;:20;;;9429:48;9461:15;9429:4;:27;;;:31;;:48;;;;:::i;:::-;:65;;:87;;;;:::i;:::-;:104;;:130;;;;:::i;:::-;:147;;:152;;;;:::i;:::-;9391:4;:35;;:190;;;;;9633:22;9595:4;:35;;;:60;9592:496;;;9690:22;9671:41;;9750:182;9907:4;:24;;;9750:135;9881:3;9750:109;9831:4;:27;;;9750:59;9792:16;9750:4;:20;;;:41;;:59;;;;:::i;:::-;:80;;:109;;;;:::i;:::-;:130;;:135;;;;:::i;:::-;:156;;:182;;;;:::i;:::-;9726:206;;9592:496;;;9989:4;:35;;;9970:54;;10062:15;10038:39;;9592:496;10106:16;10124:21;10098:48;;;;;;8505:1648;;;;;;;:::o;1274:134:56:-;1332:7;1358:43;1362:1;1365;1358:43;;;;;;;;;;;;;;;;;:3;:43::i;:::-;1351:50;;1274:134;;;;:::o;3718:338::-;3804:7;3901:1;3897;:5;3904:12;3889:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;3889:28:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3927:9;3943:1;3939;:5;;;;;;3927:17;;4048:1;4041:8;;;3718:338;;;;;:::o;1732:187::-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;1080:9075:27:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\nimport \"openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol\";\nimport \"openzeppelin-solidity/contracts/utils/Address.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\";\n\nimport \"../configuration/LendingPoolAddressesProvider.sol\";\nimport \"../configuration/LendingPoolParametersProvider.sol\";\nimport \"../configuration/NetworkMetadataProvider.sol\";\nimport \"../tokenization/AToken.sol\";\nimport \"../libraries/CoreLibrary.sol\";\nimport \"../libraries/WadRayMath.sol\";\nimport \"../interfaces/IFeeProvider.sol\";\nimport \"../flashloan/interfaces/IFlashLoanReceiver.sol\";\nimport \"./LendingPoolCore.sol\";\nimport \"./LendingPoolDataProvider.sol\";\n\n\n\n/*************************************************************************************\n@title LiquidationManager contract\n@author Aave\n@notice Implements the actions of the LendingPool, and exposes accessory methods to access the core information\n *************************************************************************************/\n\n\ncontract LendingPoolLiquidationManager is ReentrancyGuard {\n\n using SafeMath for uint256;\n using WadRayMath for uint256;\n using Address for address payable;\n\n LendingPoolAddressesProvider public addressesProvider;\n LendingPoolCore core;\n LendingPoolDataProvider dataProvider;\n LendingPoolParametersProvider parametersProvider;\n\n\n uint256 constant LIQUIDATION_CLOSE_FACTOR_PERCENT = 50;\n enum LiquidationErrors {\n NO_ERROR,\n NO_COLLATERAL_AVAILABLE,\n COLLATERAL_CANNOT_BE_LIQUIDATED,\n CURRRENCY_NOT_BORROWED,\n HEALTH_FACTOR_ABOVE_THRESHOLD,\n NOT_ENOUGH_LIQUIDITY\n }\n\n event LiquidationCompleted();\n\n struct LiquidationCallLocalVars{\n uint256 healthFactor;\n uint256 userCollateralBalance;\n uint256 userCompoundedBorrowBalance;\n uint256 borrowBalanceIncrease;\n uint256 maxPrincipalAmountToLiquidate;\n uint256 actualAmountToLiquidate;\n uint256 liquidationRatio;\n uint256 collateralPrice;\n uint256 principalCurrencyPrice;\n uint256 maxAmountCollateralToLiquidate;\n bool isCollateralEnabled;\n\n }\n\n /**\n * @notice implements loan liquidation\n * @dev _receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset.\n */\n function liquidationCall(address _collateral, address _reserve, address _user, uint256 _purchaseAmount, bool _receiveAToken)\n external\n payable\n returns(uint256, string memory)\n {\n LiquidationCallLocalVars memory vars;\n\n (,,,,,vars.healthFactor) = dataProvider.calculateUserGlobalData(_user);\n\n if(vars.healthFactor >= dataProvider.getHealthFactorLiquidationThreshold()){\n return (uint256(LiquidationErrors.HEALTH_FACTOR_ABOVE_THRESHOLD), \"Health factor is not below the threshold\");\n }\n\n vars.userCollateralBalance = dataProvider.getUserUnderlyingAssetBalance(_collateral, _user);\n\n //if _user hasn't deposited this specific collateral, nothing can be liquidated\n if(vars.userCollateralBalance == 0) {\n return (uint256(LiquidationErrors.NO_COLLATERAL_AVAILABLE), \"Invalid collateral to liquidate\");\n }\n\n vars.isCollateralEnabled = core.isReserveUsageAsCollateralEnabled(_collateral) ||\n !core.isUserUseReserveAsCollateralEnabled(_collateral, _user);\n\n //if _collateral isn't enabled as collateral by _user, it cannot be liquidated\n if(!vars.isCollateralEnabled) {\n return (uint256(LiquidationErrors.COLLATERAL_CANNOT_BE_LIQUIDATED), \"The collateral chosen cannot be liuquidated\");\n }\n\n //if the user hasn't borrowed the specific currency defined by _reserve, it cannot be liquidated\n (,vars.userCompoundedBorrowBalance,vars.borrowBalanceIncrease) = core.getUserBorrowBalances(_reserve, _user);\n\n if(vars.userCompoundedBorrowBalance == 0){\n return (uint256(LiquidationErrors.CURRRENCY_NOT_BORROWED), \"User did not borrow the specified currency\");\n }\n\n //all clear - calculate the max principal amount that can be liquidated\n vars.maxPrincipalAmountToLiquidate = vars.userCompoundedBorrowBalance.mul(LIQUIDATION_CLOSE_FACTOR_PERCENT).div(100);\n\n vars.actualAmountToLiquidate = _purchaseAmount > vars.maxPrincipalAmountToLiquidate\n ?\n vars.maxPrincipalAmountToLiquidate\n :\n _purchaseAmount;\n\n (uint256 maxCollateralToLiquidate,\n uint256 principalAmountNeeded) = calculateAvailableCollateralToLiquidate(_collateral, _reserve, vars.actualAmountToLiquidate, vars.userCollateralBalance);\n\n //if principalAmountNeeded < vars.ActualAmountToLiquidate, there isn't enough\n //of _collateral to cover the actual amount that is being liquidated, hence we liquidate\n //a smaller amount\n\n if(principalAmountNeeded < vars.actualAmountToLiquidate){\n vars.actualAmountToLiquidate = principalAmountNeeded;\n }\n\n //if liquidator reclaims the underlying asset, we make sure there is enough available collateral in the reserve\n if(!_receiveAToken){\n uint256 currentAvailableCollateral = core.getReserveAvailableLiquidity(_collateral);\n if(currentAvailableCollateral >= maxCollateralToLiquidate){\n return (uint256(LiquidationErrors.NOT_ENOUGH_LIQUIDITY), \"There isn't enough liquidity available to liquidate\");\n }\n }\n\n //update principal reserve data\n core.updateReserveCumulativeIndexes(_reserve);\n\n CoreLibrary.InterestRateMode borrowRateMode = core.getUserCurrentBorrowRateMode(_reserve,_user);\n\n core.increaseReserveTotalLiquidity(_reserve, vars.borrowBalanceIncrease);\n\n if (borrowRateMode == CoreLibrary.InterestRateMode.FIXED) {\n uint256 currentFixedRate = core.getUserCurrentFixedBorrowRate(_reserve, _user);\n core.decreaseReserveTotalBorrowsFixedAndUpdateAverageRate(_reserve, vars.actualAmountToLiquidate.sub(vars.borrowBalanceIncrease), currentFixedRate);\n } else {\n core.decreaseReserveTotalBorrowsVariable(_reserve, vars.actualAmountToLiquidate.sub(vars.borrowBalanceIncrease));\n }\n\n core.updateReserveInterestRates(_reserve);\n core.setReserveLastUpdate(_reserve);\n //step 3: update user borrow data\n core.decreaseUserPrincipalBorrowBalance(_reserve, _user, vars.actualAmountToLiquidate.sub(vars.borrowBalanceIncrease));\n core.setUserLastUpdate(_reserve,_user);\n\n //update collateral reserve\n core.updateReserveCumulativeIndexes(_collateral);\n AToken collateralAtoken = AToken(core.getReserveATokenAddress(_collateral));\n\n //calculating aToken equivalent amount from vars.\n uint256 aTokenCollateralToLiquidate = collateralAtoken.underlyingAmountToATokenAmount(maxCollateralToLiquidate);\n\n //if liquidator reclaims the aToken, he receives the equivalent atoken amount\n if(_receiveAToken) {\n collateralAtoken.transferOnLiquidation(_user, msg.sender, aTokenCollateralToLiquidate);\n }\n else { //otherwise receives the underlying asset\n //burn the equivalent amount of atoken\n collateralAtoken.burnOnLiquidation(_user, aTokenCollateralToLiquidate);\n core.decreaseReserveTotalLiquidity(_collateral, maxCollateralToLiquidate);\n core.updateReserveInterestRates(_collateral);\n core.transferToUser(_collateral, msg.sender, maxCollateralToLiquidate);\n }\n\n core.setReserveLastUpdate(_collateral);\n\n //transfers the principal currency to the pool\n\n core.transferToReserve.value(msg.value)(_reserve, msg.sender, vars.actualAmountToLiquidate);\n\n return (uint256(LiquidationErrors.NO_ERROR), \"No errors\");\n }\n\n\n\n struct AvailableCollateralToLiquidateLocalVars{\n uint256 userCompoundedBorrowBalance;\n uint256 liquidationDiscount;\n uint256 collateralPrice;\n uint256 principalCurrencyPrice;\n uint256 maxAmountCollateralToLiquidate;\n }\n\n /**\n * @notice calculates how much of a specific collateral can be liquidated, given\n * a certain amount of principal currency.\n * @dev this function needs to be called after all the checks to validate the liquidation\n * have been performed, otherwise it might fail.\n */\n function calculateAvailableCollateralToLiquidate(\n address _collateral,\n address _principal,\n uint256 _purchaseAmount,\n uint256 _userCollateralBalance) internal view returns(uint256 collateralAmount, uint256 principalAmountNeeded) {\n\n collateralAmount = 0;\n principalAmountNeeded = 0;\n IPriceOracle oracle = IPriceOracle(addressesProvider.getPriceOracle());\n\n AvailableCollateralToLiquidateLocalVars memory vars;\n\n vars.collateralPrice = oracle.getAssetPrice(_collateral);\n vars.principalCurrencyPrice = oracle.getAssetPrice(_principal);\n vars.liquidationDiscount = core.getReserveLiquidationDiscount(_collateral);\n\n //this is the maximum possible amount of the selected collateral that can be liquidated, given the\n //max amount of principal currency that is available for liquidation.\n vars.maxAmountCollateralToLiquidate = vars.principalCurrencyPrice.mul(_purchaseAmount)\n .div(vars.collateralPrice)\n .mul(vars.liquidationDiscount)\n .div(100);\n\n if(vars.maxAmountCollateralToLiquidate > _userCollateralBalance) {\n collateralAmount = _userCollateralBalance;\n principalAmountNeeded = vars.collateralPrice\n .mul(collateralAmount)\n .div(vars.principalCurrencyPrice)\n .mul(100)\n .div(vars.liquidationDiscount);\n }\n else{\n collateralAmount = vars.maxAmountCollateralToLiquidate;\n principalAmountNeeded = _purchaseAmount;\n }\n\n return (collateralAmount, principalAmountNeeded);\n }\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol", + "exportedSymbols": { + "LendingPoolLiquidationManager": [ + 8254 + ] + }, + "id": 8255, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 7662, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:27" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 7663, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 11141, + "src": "26:59:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "file": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "id": 7664, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 12114, + "src": "86:67:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "file": "openzeppelin-solidity/contracts/utils/Address.sol", + "id": 7665, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 12082, + "src": "154:59:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "id": 7666, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 11787, + "src": "214:64:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 7667, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 1358, + "src": "280:59:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol", + "file": "../configuration/LendingPoolParametersProvider.sol", + "id": 7668, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 1419, + "src": "340:60:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "file": "../configuration/NetworkMetadataProvider.sol", + "id": 7669, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 1479, + "src": "401:54:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "file": "../tokenization/AToken.sol", + "id": 7670, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 10328, + "src": "456:36:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "file": "../libraries/CoreLibrary.sol", + "id": 7671, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 8995, + "src": "493:38:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 7672, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 9175, + "src": "532:37:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "file": "../interfaces/IFeeProvider.sol", + "id": 7673, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 1766, + "src": "570:40:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol", + "file": "../flashloan/interfaces/IFlashLoanReceiver.sol", + "id": 7674, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 1734, + "src": "611:56:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "./LendingPoolCore.sol", + "id": 7675, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 6683, + "src": "668:31:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol", + "file": "./LendingPoolDataProvider.sol", + "id": 7676, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 7661, + "src": "700:39:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 7677, + "name": "ReentrancyGuard", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12113, + "src": "1122:15:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ReentrancyGuard_$12113", + "typeString": "contract ReentrancyGuard" + } + }, + "id": 7678, + "nodeType": "InheritanceSpecifier", + "src": "1122:15:27" + } + ], + "contractDependencies": [ + 12113 + ], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title LiquidationManager contract\n@author Aave\n@notice Implements the actions of the LendingPool, and exposes accessory methods to access the core information************************************************************************************", + "fullyImplemented": true, + "id": 8254, + "linearizedBaseContracts": [ + 8254, + 12113 + ], + "name": "LendingPoolLiquidationManager", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 7681, + "libraryName": { + "contractScope": null, + "id": 7679, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "1151:8:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1145:27:27", + "typeName": { + "id": 7680, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1164:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 7684, + "libraryName": { + "contractScope": null, + "id": 7682, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "1183:10:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1177:29:27", + "typeName": { + "id": 7683, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1198:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 7687, + "libraryName": { + "contractScope": null, + "id": 7685, + "name": "Address", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12081, + "src": "1217:7:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + }, + "nodeType": "UsingForDirective", + "src": "1211:34:27", + "typeName": { + "id": 7686, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1229:15:27", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + }, + { + "constant": false, + "id": 7689, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 8254, + "src": "1251:53:27", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 7688, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1251:28:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": false, + "id": 7691, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 8254, + "src": "1310:20:27", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 7690, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "1310:15:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7693, + "name": "dataProvider", + "nodeType": "VariableDeclaration", + "scope": 8254, + "src": "1336:36:27", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + }, + "typeName": { + "contractScope": null, + "id": 7692, + "name": "LendingPoolDataProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 7660, + "src": "1336:23:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7695, + "name": "parametersProvider", + "nodeType": "VariableDeclaration", + "scope": 8254, + "src": "1378:48:27", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + }, + "typeName": { + "contractScope": null, + "id": 7694, + "name": "LendingPoolParametersProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1418, + "src": "1378:29:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": true, + "id": 7698, + "name": "LIQUIDATION_CLOSE_FACTOR_PERCENT", + "nodeType": "VariableDeclaration", + "scope": 8254, + "src": "1434:54:27", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7696, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1434:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3530", + "id": 7697, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1486:2:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_50_by_1", + "typeString": "int_const 50" + }, + "value": "50" + }, + "visibility": "internal" + }, + { + "canonicalName": "LendingPoolLiquidationManager.LiquidationErrors", + "id": 7705, + "members": [ + { + "id": 7699, + "name": "NO_ERROR", + "nodeType": "EnumValue", + "src": "1527:8:27" + }, + { + "id": 7700, + "name": "NO_COLLATERAL_AVAILABLE", + "nodeType": "EnumValue", + "src": "1545:23:27" + }, + { + "id": 7701, + "name": "COLLATERAL_CANNOT_BE_LIQUIDATED", + "nodeType": "EnumValue", + "src": "1578:31:27" + }, + { + "id": 7702, + "name": "CURRRENCY_NOT_BORROWED", + "nodeType": "EnumValue", + "src": "1619:22:27" + }, + { + "id": 7703, + "name": "HEALTH_FACTOR_ABOVE_THRESHOLD", + "nodeType": "EnumValue", + "src": "1651:29:27" + }, + { + "id": 7704, + "name": "NOT_ENOUGH_LIQUIDITY", + "nodeType": "EnumValue", + "src": "1690:20:27" + } + ], + "name": "LiquidationErrors", + "nodeType": "EnumDefinition", + "src": "1494:222:27" + }, + { + "anonymous": false, + "documentation": null, + "id": 7707, + "name": "LiquidationCompleted", + "nodeType": "EventDefinition", + "parameters": { + "id": 7706, + "nodeType": "ParameterList", + "parameters": [], + "src": "1748:2:27" + }, + "src": "1722:29:27" + }, + { + "canonicalName": "LendingPoolLiquidationManager.LiquidationCallLocalVars", + "id": 7730, + "members": [ + { + "constant": false, + "id": 7709, + "name": "healthFactor", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1798:20:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7708, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1798:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7711, + "name": "userCollateralBalance", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1828:29:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7710, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1828:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7713, + "name": "userCompoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1867:35:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7712, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1867:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7715, + "name": "borrowBalanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1912:29:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7714, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1912:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7717, + "name": "maxPrincipalAmountToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1951:37:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7716, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1951:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7719, + "name": "actualAmountToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1998:31:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7718, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1998:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7721, + "name": "liquidationRatio", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "2039:24:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7720, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2039:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7723, + "name": "collateralPrice", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "2073:23:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7722, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2073:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7725, + "name": "principalCurrencyPrice", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "2106:30:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7724, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2106:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7727, + "name": "maxAmountCollateralToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "2146:38:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7726, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2146:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7729, + "name": "isCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "2194:24:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7728, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2194:4:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "LiquidationCallLocalVars", + "nodeType": "StructDefinition", + "scope": 8254, + "src": "1757:469:27", + "visibility": "public" + }, + { + "body": { + "id": 8115, + "nodeType": "Block", + "src": "2595:5349:27", + "statements": [ + { + "assignments": [ + 7748 + ], + "declarations": [ + { + "constant": false, + "id": 7748, + "name": "vars", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "2605:36:27", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars" + }, + "typeName": { + "contractScope": null, + "id": 7747, + "name": "LiquidationCallLocalVars", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 7730, + "src": "2605:24:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_storage_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7749, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "2605:36:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 7758, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + null, + null, + null, + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7750, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "2658:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7752, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "healthFactor", + "nodeType": "MemberAccess", + "referencedDeclaration": 7709, + "src": "2658:17:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 7753, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "2652:24:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$__$__$__$__$_t_uint256_$", + "typeString": "tuple(,,,,,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7756, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "2716:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7754, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7693, + "src": "2679:12:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 7755, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "calculateUserGlobalData", + "nodeType": "MemberAccess", + "referencedDeclaration": 6984, + "src": "2679:36:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "id": 7757, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2679:43:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "src": "2652:70:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7759, + "nodeType": "ExpressionStatement", + "src": "2652:70:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7765, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7760, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "2736:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7761, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "healthFactor", + "nodeType": "MemberAccess", + "referencedDeclaration": 7709, + "src": "2736:17:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 7762, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7693, + "src": "2757:12:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 7763, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getHealthFactorLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7263, + "src": "2757:48:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_pure$__$returns$_t_uint256_$", + "typeString": "function () pure external returns (uint256)" + } + }, + "id": 7764, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2757:50:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2736:71:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7774, + "nodeType": "IfStatement", + "src": "2733:209:27", + "trueBody": { + "id": 7773, + "nodeType": "Block", + "src": "2808:134:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7767, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "2838:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 7768, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "HEALTH_FACTOR_ABOVE_THRESHOLD", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2838:47:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 7766, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2830:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7769, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2830:56:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "4865616c746820666163746f72206973206e6f742062656c6f7720746865207468726573686f6c64", + "id": 7770, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2888:42:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e7f9afd7c1ffabe0273b3edfe9c5949b99bf84b8a8f1418c24bc0f519353394f", + "typeString": "literal_string \"Health factor is not below the threshold\"" + }, + "value": "Health factor is not below the threshold" + } + ], + "id": 7771, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "2829:102:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_e7f9afd7c1ffabe0273b3edfe9c5949b99bf84b8a8f1418c24bc0f519353394f_$", + "typeString": "tuple(uint256,literal_string \"Health factor is not below the threshold\")" + } + }, + "functionReturnParameters": 7746, + "id": 7772, + "nodeType": "Return", + "src": "2822:109:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7783, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7775, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "2952:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7777, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "userCollateralBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7711, + "src": "2952:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7780, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "3024:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7781, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "3037:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7778, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7693, + "src": "2981:12:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 7779, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserUnderlyingAssetBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7008, + "src": "2981:42:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7782, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2981:62:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2952:91:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7784, + "nodeType": "ExpressionStatement", + "src": "2952:91:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7788, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7785, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3145:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7786, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCollateralBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7711, + "src": "3145:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 7787, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3175:1:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3145:31:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7797, + "nodeType": "IfStatement", + "src": "3142:155:27", + "trueBody": { + "id": 7796, + "nodeType": "Block", + "src": "3178:119:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7790, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "3208:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 7791, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "NO_COLLATERAL_AVAILABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3208:41:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 7789, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3200:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7792, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3200:50:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c696420636f6c6c61746572616c20746f206c6971756964617465", + "id": 7793, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3252:33:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_fd71d007efa0d133789dda79d6d01aa7bd15ca534645487a5a4de2afc95a3de3", + "typeString": "literal_string \"Invalid collateral to liquidate\"" + }, + "value": "Invalid collateral to liquidate" + } + ], + "id": 7794, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "3199:87:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_fd71d007efa0d133789dda79d6d01aa7bd15ca534645487a5a4de2afc95a3de3_$", + "typeString": "tuple(uint256,literal_string \"Invalid collateral to liquidate\")" + } + }, + "functionReturnParameters": 7746, + "id": 7795, + "nodeType": "Return", + "src": "3192:94:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7812, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7798, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3307:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7800, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 7729, + "src": "3307:24:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 7811, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7803, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "3373:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7801, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "3334:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7802, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isReserveUsageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5851, + "src": "3334:38:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 7804, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3334:51:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "id": 7810, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "3401:61:27", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7807, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "3443:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7808, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "3456:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7805, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "3402:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7806, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "3402:40:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 7809, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3402:60:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "3334:128:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "3307:155:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 7813, + "nodeType": "ExpressionStatement", + "src": "3307:155:27" + }, + { + "condition": { + "argumentTypes": null, + "id": 7816, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "3563:25:27", + "subExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7814, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3564:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7815, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "isCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 7729, + "src": "3564:24:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7825, + "nodeType": "IfStatement", + "src": "3560:169:27", + "trueBody": { + "id": 7824, + "nodeType": "Block", + "src": "3590:139:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7818, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "3620:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 7819, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "COLLATERAL_CANNOT_BE_LIQUIDATED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3620:49:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 7817, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3612:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7820, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3612:58:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520636f6c6c61746572616c2063686f73656e2063616e6e6f74206265206c69757175696461746564", + "id": 7821, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3672:45:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_26ed6a3d02ed1500eb16391fd9742ea448dda174e451a7ecf36ef6cd99a1b91e", + "typeString": "literal_string \"The collateral chosen cannot be liuquidated\"" + }, + "value": "The collateral chosen cannot be liuquidated" + } + ], + "id": 7822, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "3611:107:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_26ed6a3d02ed1500eb16391fd9742ea448dda174e451a7ecf36ef6cd99a1b91e_$", + "typeString": "tuple(uint256,literal_string \"The collateral chosen cannot be liuquidated\")" + } + }, + "functionReturnParameters": 7746, + "id": 7823, + "nodeType": "Return", + "src": "3604:114:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7837, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7826, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3846:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7828, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "userCompoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7713, + "src": "3846:32:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7829, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3879:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7830, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "borrowBalanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7715, + "src": "3879:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 7831, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "3844:62:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$_t_uint256_$_t_uint256_$", + "typeString": "tuple(,uint256,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7834, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "3936:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7835, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "3946:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7832, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "3909:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7833, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "3909:26:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 7836, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3909:43:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "src": "3844:108:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7838, + "nodeType": "ExpressionStatement", + "src": "3844:108:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7842, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7839, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3966:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7840, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCompoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7713, + "src": "3966:32:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 7841, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4002:1:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3966:37:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7851, + "nodeType": "IfStatement", + "src": "3963:170:27", + "trueBody": { + "id": 7850, + "nodeType": "Block", + "src": "4004:129:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7844, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "4034:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 7845, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "CURRRENCY_NOT_BORROWED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4034:40:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 7843, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "4026:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7846, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4026:49:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220646964206e6f7420626f72726f7720746865207370656369666965642063757272656e6379", + "id": 7847, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4077:44:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_f180dd83a62112e452b337e2b6b4afb2399867f2230bc3004770c378708cbda8", + "typeString": "literal_string \"User did not borrow the specified currency\"" + }, + "value": "User did not borrow the specified currency" + } + ], + "id": 7848, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "4025:97:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_f180dd83a62112e452b337e2b6b4afb2399867f2230bc3004770c378708cbda8_$", + "typeString": "tuple(uint256,literal_string \"User did not borrow the specified currency\")" + } + }, + "functionReturnParameters": 7746, + "id": 7849, + "nodeType": "Return", + "src": "4018:104:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7863, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7852, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4223:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7854, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "maxPrincipalAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7717, + "src": "4223:34:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 7861, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4335:3:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7858, + "name": "LIQUIDATION_CLOSE_FACTOR_PERCENT", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7698, + "src": "4297:32:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7855, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4260:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7856, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCompoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7713, + "src": "4260:32:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7857, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "4260:36:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7859, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4260:70:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7860, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "4260:74:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7862, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4260:79:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4223:116:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7864, + "nodeType": "ExpressionStatement", + "src": "4223:116:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 7876, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7865, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4350:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7867, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "4350:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7871, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7868, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7738, + "src": "4381:15:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7869, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4399:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7870, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "maxPrincipalAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7717, + "src": "4399:34:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4381:52:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "id": 7874, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7738, + "src": "4521:15:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7875, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "4381:155:27", + "trueExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7872, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4460:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7873, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "maxPrincipalAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7717, + "src": "4460:34:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4350:186:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7877, + "nodeType": "ExpressionStatement", + "src": "4350:186:27" + }, + { + "assignments": [ + 7879, + 7881 + ], + "declarations": [ + { + "constant": false, + "id": 7879, + "name": "maxCollateralToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "4548:32:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7878, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4548:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7881, + "name": "principalAmountNeeded", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "4590:29:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7880, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4590:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7890, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7883, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "4663:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7884, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "4676:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7885, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4686:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7886, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "4686:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7887, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4716:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7888, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCollateralBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7711, + "src": "4716:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 7882, + "name": "calculateAvailableCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8253, + "src": "4623:39:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$_t_uint256_$_t_uint256_$returns$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address,uint256,uint256) view returns (uint256,uint256)" + } + }, + "id": 7889, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4623:120:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4547:196:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7894, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7891, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7881, + "src": "4968:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7892, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4992:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7893, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "4992:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4968:52:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7902, + "nodeType": "IfStatement", + "src": "4965:133:27", + "trueBody": { + "id": 7901, + "nodeType": "Block", + "src": "5021:77:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7899, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7895, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "5035:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7897, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "5035:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 7898, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7881, + "src": "5066:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5035:52:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7900, + "nodeType": "ExpressionStatement", + "src": "5035:52:27" + } + ] + } + }, + { + "condition": { + "argumentTypes": null, + "id": 7904, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "5231:15:27", + "subExpression": { + "argumentTypes": null, + "id": 7903, + "name": "_receiveAToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7740, + "src": "5232:14:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7925, + "nodeType": "IfStatement", + "src": "5228:342:27", + "trueBody": { + "id": 7924, + "nodeType": "Block", + "src": "5247:323:27", + "statements": [ + { + "assignments": [ + 7906 + ], + "declarations": [ + { + "constant": false, + "id": 7906, + "name": "currentAvailableCollateral", + "nodeType": "VariableDeclaration", + "scope": 7924, + "src": "5261:34:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7905, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5261:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7911, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7909, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "5332:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7907, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "5298:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7908, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveAvailableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5482, + "src": "5298:33:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7910, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5298:46:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5261:83:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7914, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7912, + "name": "currentAvailableCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7906, + "src": "5361:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 7913, + "name": "maxCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7879, + "src": "5391:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5361:54:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7923, + "nodeType": "IfStatement", + "src": "5358:202:27", + "trueBody": { + "id": 7922, + "nodeType": "Block", + "src": "5416:144:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7916, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "5450:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 7917, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "NOT_ENOUGH_LIQUIDITY", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "5450:38:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 7915, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "5442:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7918, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5442:47:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "54686572652069736e277420656e6f756768206c697175696469747920617661696c61626c6520746f206c6971756964617465", + "id": 7919, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5491:53:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a79516f30c9ace6d12f24050fedd804d8cca1187d4e48e1452d78340e8165699", + "typeString": "literal_string \"There isn't enough liquidity available to liquidate\"" + }, + "value": "There isn't enough liquidity available to liquidate" + } + ], + "id": 7920, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "5441:104:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_a79516f30c9ace6d12f24050fedd804d8cca1187d4e48e1452d78340e8165699_$", + "typeString": "tuple(uint256,literal_string \"There isn't enough liquidity available to liquidate\")" + } + }, + "functionReturnParameters": 7746, + "id": 7921, + "nodeType": "Return", + "src": "5434:111:27" + } + ] + } + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7929, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "5656:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7926, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "5620:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7928, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "5620:35:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 7930, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5620:45:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7931, + "nodeType": "ExpressionStatement", + "src": "5620:45:27" + }, + { + "assignments": [ + 7935 + ], + "declarations": [ + { + "constant": false, + "id": 7935, + "name": "borrowRateMode", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "5676:43:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 7934, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "5676:28:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7941, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7938, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "5756:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7939, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "5765:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7936, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "5722:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7937, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentBorrowRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5988, + "src": "5722:33:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view external returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 7940, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5722:49:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5676:95:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7945, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "5817:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7946, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "5827:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7947, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7715, + "src": "5827:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7942, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "5782:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7944, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "5782:34:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 7948, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5782:72:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7949, + "nodeType": "ExpressionStatement", + "src": "5782:72:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 7954, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7950, + "name": "borrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7935, + "src": "5869:14:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7951, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "5887:11:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 7952, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "5887:28:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 7953, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "5887:34:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "5869:52:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 7989, + "nodeType": "Block", + "src": "6193:137:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7980, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6248:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7984, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6291:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7985, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7715, + "src": "6291:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7981, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6258:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7982, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "6258:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7983, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "6258:32:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7986, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6258:60:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7977, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6207:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7979, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 4991, + "src": "6207:40:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 7987, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6207:112:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7988, + "nodeType": "ExpressionStatement", + "src": "6207:112:27" + } + ] + }, + "id": 7990, + "nodeType": "IfStatement", + "src": "5865:465:27", + "trueBody": { + "id": 7976, + "nodeType": "Block", + "src": "5923:264:27", + "statements": [ + { + "assignments": [ + 7956 + ], + "declarations": [ + { + "constant": false, + "id": 7956, + "name": "currentFixedRate", + "nodeType": "VariableDeclaration", + "scope": 7976, + "src": "5937:24:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7955, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5937:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7962, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7959, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "5999:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7960, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "6009:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7957, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "5964:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7958, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6011, + "src": "5964:34:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7961, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5964:51:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5937:78:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7966, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6087:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7970, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6130:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7971, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7715, + "src": "6130:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7967, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6097:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7968, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "6097:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7969, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "6097:32:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7972, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6097:60:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7973, + "name": "currentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7956, + "src": "6159:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7963, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6029:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7965, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 4954, + "src": "6029:57:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 7974, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6029:147:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7975, + "nodeType": "ExpressionStatement", + "src": "6029:147:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7994, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6372:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7991, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6340:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7993, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "6340:31:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 7995, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6340:41:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7996, + "nodeType": "ExpressionStatement", + "src": "6340:41:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8000, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6417:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7997, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6391:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7999, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "6391:25:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 8001, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6391:35:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8002, + "nodeType": "ExpressionStatement", + "src": "6391:35:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8006, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6518:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 8007, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "6528:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8011, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6568:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 8012, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7715, + "src": "6568:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8008, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6535:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 8009, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "6535:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8010, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "6535:32:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8013, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6535:60:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8003, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6478:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8005, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseUserPrincipalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 5309, + "src": "6478:39:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 8014, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6478:118:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8015, + "nodeType": "ExpressionStatement", + "src": "6478:118:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8019, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6629:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 8020, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "6638:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8016, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6606:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8018, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5366, + "src": "6606:22:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 8021, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6606:38:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8022, + "nodeType": "ExpressionStatement", + "src": "6606:38:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8026, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "6727:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8023, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6691:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8025, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "6691:35:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 8027, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6691:48:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8028, + "nodeType": "ExpressionStatement", + "src": "6691:48:27" + }, + { + "assignments": [ + 8030 + ], + "declarations": [ + { + "constant": false, + "id": 8030, + "name": "collateralAtoken", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "6749:23:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + }, + "typeName": { + "contractScope": null, + "id": 8029, + "name": "AToken", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10327, + "src": "6749:6:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8037, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8034, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "6811:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8032, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6782:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8033, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "6782:28:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 8035, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6782:41:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 8031, + "name": "AToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10327, + "src": "6775:6:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_AToken_$10327_$", + "typeString": "type(contract AToken)" + } + }, + "id": 8036, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6775:49:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6749:75:27" + }, + { + "assignments": [ + 8039 + ], + "declarations": [ + { + "constant": false, + "id": 8039, + "name": "aTokenCollateralToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "6893:35:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8038, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6893:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8044, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8042, + "name": "maxCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7879, + "src": "6979:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8040, + "name": "collateralAtoken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8030, + "src": "6931:16:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 8041, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "underlyingAmountToATokenAmount", + "nodeType": "MemberAccess", + "referencedDeclaration": 10313, + "src": "6931:47:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view external returns (uint256)" + } + }, + "id": 8043, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6931:73:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6893:111:27" + }, + { + "condition": { + "argumentTypes": null, + "id": 8045, + "name": "_receiveAToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7740, + "src": "7104:14:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 8085, + "nodeType": "Block", + "src": "7245:418:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8059, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "7387:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 8060, + "name": "aTokenCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8039, + "src": "7394:27:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8056, + "name": "collateralAtoken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8030, + "src": "7352:16:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 8058, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "burnOnLiquidation", + "nodeType": "MemberAccess", + "referencedDeclaration": 10145, + "src": "7352:34:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 8061, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7352:70:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8062, + "nodeType": "ExpressionStatement", + "src": "7352:70:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8066, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "7471:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 8067, + "name": "maxCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7879, + "src": "7484:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8063, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "7436:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4911, + "src": "7436:34:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 8068, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7436:73:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8069, + "nodeType": "ExpressionStatement", + "src": "7436:73:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8073, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "7555:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8070, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "7523:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8072, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "7523:31:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 8074, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7523:44:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8075, + "nodeType": "ExpressionStatement", + "src": "7523:44:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8079, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "7601:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8080, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "7614:3:27", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 8081, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7614:10:27", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 8082, + "name": "maxCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7879, + "src": "7626:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8076, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "7581:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8078, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToUser", + "nodeType": "MemberAccess", + "referencedDeclaration": 6486, + "src": "7581:19:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) external" + } + }, + "id": 8083, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7581:70:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8084, + "nodeType": "ExpressionStatement", + "src": "7581:70:27" + } + ] + }, + "id": 8086, + "nodeType": "IfStatement", + "src": "7101:562:27", + "trueBody": { + "id": 8055, + "nodeType": "Block", + "src": "7120:111:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8049, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "7173:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8050, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "7180:3:27", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 8051, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7180:10:27", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 8052, + "name": "aTokenCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8039, + "src": "7192:27:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8046, + "name": "collateralAtoken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8030, + "src": "7134:16:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 8048, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferOnLiquidation", + "nodeType": "MemberAccess", + "referencedDeclaration": 10180, + "src": "7134:38:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 8053, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7134:86:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8054, + "nodeType": "ExpressionStatement", + "src": "7134:86:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8090, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "7699:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8087, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "7673:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8089, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "7673:25:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 8091, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7673:38:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8092, + "nodeType": "ExpressionStatement", + "src": "7673:38:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8101, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "7818:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8102, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "7828:3:27", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 8103, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7828:10:27", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8104, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "7840:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 8105, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "7840:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8098, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "7807:3:27", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 8099, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7807:9:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8093, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "7778:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8096, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6619, + "src": "7778:22:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 8097, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7778:28:27", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value_$", + "typeString": "function (uint256) returns (function (address,address payable,uint256) payable external)" + } + }, + "id": 8100, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7778:39:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 8106, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7778:91:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8107, + "nodeType": "ExpressionStatement", + "src": "7778:91:27" + }, + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8109, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "7896:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 8110, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "NO_ERROR", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7896:26:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 8108, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "7888:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 8111, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7888:35:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "4e6f206572726f7273", + "id": 8112, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7925:11:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ca44fe728f23c758e348e2d287cc8febf43f0dace4b6a486a276b60c3218ecac", + "typeString": "literal_string \"No errors\"" + }, + "value": "No errors" + } + ], + "id": 8113, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "7887:50:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_ca44fe728f23c758e348e2d287cc8febf43f0dace4b6a486a276b60c3218ecac_$", + "typeString": "tuple(uint256,literal_string \"No errors\")" + } + }, + "functionReturnParameters": 7746, + "id": 8114, + "nodeType": "Return", + "src": "7880:57:27" + } + ] + }, + "documentation": "@notice implements loan liquidation\n@dev _receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset.", + "id": 8116, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "liquidationCall", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7741, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7732, + "name": "_collateral", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2419:19:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7731, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2419:7:27", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7734, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2440:16:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7733, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2440:7:27", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7736, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2458:13:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7735, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2458:7:27", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7738, + "name": "_purchaseAmount", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2473:23:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7737, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2473:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7740, + "name": "_receiveAToken", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2498:19:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7739, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2498:4:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2418:100:27" + }, + "returnParameters": { + "id": 7746, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7743, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2567:7:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7742, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2567:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7745, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2576:13:27", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 7744, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "2576:6:27", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2566:24:27" + }, + "scope": 8254, + "src": "2394:5550:27", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "canonicalName": "LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars", + "id": 8127, + "members": [ + { + "constant": false, + "id": 8118, + "name": "userCompoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 8127, + "src": "8008:35:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8117, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8008:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8120, + "name": "liquidationDiscount", + "nodeType": "VariableDeclaration", + "scope": 8127, + "src": "8053:27:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8119, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8053:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8122, + "name": "collateralPrice", + "nodeType": "VariableDeclaration", + "scope": 8127, + "src": "8090:23:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8121, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8090:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8124, + "name": "principalCurrencyPrice", + "nodeType": "VariableDeclaration", + "scope": 8127, + "src": "8123:30:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8123, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8123:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8126, + "name": "maxAmountCollateralToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 8127, + "src": "8163:38:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8125, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8163:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "AvailableCollateralToLiquidateLocalVars", + "nodeType": "StructDefinition", + "scope": 8254, + "src": "7952:256:27", + "visibility": "public" + }, + { + "body": { + "id": 8252, + "nodeType": "Block", + "src": "8764:1389:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8144, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8142, + "name": "collateralAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8138, + "src": "8775:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "30", + "id": 8143, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8794:1:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "8775:20:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8145, + "nodeType": "ExpressionStatement", + "src": "8775:20:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8148, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8146, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8140, + "src": "8805:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "30", + "id": 8147, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8829:1:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "8805:25:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8149, + "nodeType": "ExpressionStatement", + "src": "8805:25:27" + }, + { + "assignments": [ + 8151 + ], + "declarations": [ + { + "constant": false, + "id": 8151, + "name": "oracle", + "nodeType": "VariableDeclaration", + "scope": 8252, + "src": "8840:19:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + }, + "typeName": { + "contractScope": null, + "id": 8150, + "name": "IPriceOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1959, + "src": "8840:12:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8157, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8153, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7689, + "src": "8875:17:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 8154, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getPriceOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1266, + "src": "8875:32:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 8155, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8875:34:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 8152, + "name": "IPriceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1959, + "src": "8862:12:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IPriceOracle_$1959_$", + "typeString": "type(contract IPriceOracle)" + } + }, + "id": 8156, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8862:48:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8840:70:27" + }, + { + "assignments": [ + 8159 + ], + "declarations": [ + { + "constant": false, + "id": 8159, + "name": "vars", + "nodeType": "VariableDeclaration", + "scope": 8252, + "src": "8921:51:27", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars" + }, + "typeName": { + "contractScope": null, + "id": 8158, + "name": "AvailableCollateralToLiquidateLocalVars", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8127, + "src": "8921:39:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_storage_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8160, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "8921:51:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8168, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8161, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "8983:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8163, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "collateralPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8122, + "src": "8983:20:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8166, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8129, + "src": "9027:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8164, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8151, + "src": "9006:6:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 8165, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getAssetPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 1941, + "src": "9006:20:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 8167, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9006:33:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8983:56:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8169, + "nodeType": "ExpressionStatement", + "src": "8983:56:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8177, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8170, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9049:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8172, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "principalCurrencyPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8124, + "src": "9049:27:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8175, + "name": "_principal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8131, + "src": "9100:10:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8173, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8151, + "src": "9079:6:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 8174, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getAssetPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 1941, + "src": "9079:20:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 8176, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9079:32:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9049:62:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8178, + "nodeType": "ExpressionStatement", + "src": "9049:62:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8186, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8179, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9121:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8181, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 8120, + "src": "9121:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8184, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8129, + "src": "9183:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8182, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "9148:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8183, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveLiquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 5611, + "src": "9148:34:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 8185, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9148:47:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9121:74:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8187, + "nodeType": "ExpressionStatement", + "src": "9121:74:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8207, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8188, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9391:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8190, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "maxAmountCollateralToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8126, + "src": "9391:35:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 8205, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9577:3:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8201, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9534:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8202, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 8120, + "src": "9534:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8197, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9495:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8198, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8122, + "src": "9495:20:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8194, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8133, + "src": "9461:15:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8191, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9429:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8192, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalCurrencyPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8124, + "src": "9429:27:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8193, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "9429:31:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8195, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9429:48:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8196, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "9429:65:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8199, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9429:87:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8200, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "9429:104:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8203, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9429:130:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8204, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "9429:147:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8206, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9429:152:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9391:190:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8208, + "nodeType": "ExpressionStatement", + "src": "9391:190:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8212, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8209, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9595:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8210, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "maxAmountCollateralToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8126, + "src": "9595:35:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 8211, + "name": "_userCollateralBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8135, + "src": "9633:22:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9595:60:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 8246, + "nodeType": "Block", + "src": "9956:132:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8240, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8237, + "name": "collateralAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8138, + "src": "9970:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8238, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9989:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8239, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "maxAmountCollateralToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8126, + "src": "9989:35:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9970:54:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8241, + "nodeType": "ExpressionStatement", + "src": "9970:54:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8244, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8242, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8140, + "src": "10038:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8243, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8133, + "src": "10062:15:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10038:39:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8245, + "nodeType": "ExpressionStatement", + "src": "10038:39:27" + } + ] + }, + "id": 8247, + "nodeType": "IfStatement", + "src": "9592:496:27", + "trueBody": { + "id": 8236, + "nodeType": "Block", + "src": "9657:286:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8215, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8213, + "name": "collateralAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8138, + "src": "9671:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8214, + "name": "_userCollateralBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8135, + "src": "9690:22:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9671:41:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8216, + "nodeType": "ExpressionStatement", + "src": "9671:41:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8234, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8217, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8140, + "src": "9726:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8231, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9907:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8232, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 8120, + "src": "9907:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 8228, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9881:3:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8224, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9831:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8225, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalCurrencyPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8124, + "src": "9831:27:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8221, + "name": "collateralAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8138, + "src": "9792:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8218, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9750:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8219, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8122, + "src": "9750:20:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8220, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "9750:41:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8222, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9750:59:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8223, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "9750:80:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8226, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9750:109:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8227, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "9750:130:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8229, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9750:135:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8230, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "9750:156:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8233, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9750:182:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9726:206:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8235, + "nodeType": "ExpressionStatement", + "src": "9726:206:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 8248, + "name": "collateralAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8138, + "src": "10106:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 8249, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8140, + "src": "10124:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 8250, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "10105:41:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256)" + } + }, + "functionReturnParameters": 8141, + "id": 8251, + "nodeType": "Return", + "src": "10098:48:27" + } + ] + }, + "documentation": "@notice calculates how much of a specific collateral can be liquidated, given\na certain amount of principal currency.\n@dev this function needs to be called after all the checks to validate the liquidation\nhave been performed, otherwise it might fail.", + "id": 8253, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateAvailableCollateralToLiquidate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8136, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8129, + "name": "_collateral", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8563:19:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8128, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "8563:7:27", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8131, + "name": "_principal", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8592:18:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8130, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "8592:7:27", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8133, + "name": "_purchaseAmount", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8620:23:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8132, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8620:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8135, + "name": "_userCollateralBalance", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8653:30:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8134, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8653:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8553:131:27" + }, + "returnParameters": { + "id": 8141, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8138, + "name": "collateralAmount", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8707:24:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8137, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8707:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8140, + "name": "principalAmountNeeded", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8733:29:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8139, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8733:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8706:57:27" + }, + "scope": 8254, + "src": "8505:1648:27", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 8255, + "src": "1080:9075:27" + } + ], + "src": "0:10155:27" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolLiquidationManager.sol", + "exportedSymbols": { + "LendingPoolLiquidationManager": [ + 8254 + ] + }, + "id": 8255, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 7662, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:27" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 7663, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 11141, + "src": "26:59:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "file": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "id": 7664, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 12114, + "src": "86:67:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "file": "openzeppelin-solidity/contracts/utils/Address.sol", + "id": 7665, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 12082, + "src": "154:59:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "id": 7666, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 11787, + "src": "214:64:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 7667, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 1358, + "src": "280:59:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol", + "file": "../configuration/LendingPoolParametersProvider.sol", + "id": 7668, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 1419, + "src": "340:60:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "file": "../configuration/NetworkMetadataProvider.sol", + "id": 7669, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 1479, + "src": "401:54:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/tokenization/AToken.sol", + "file": "../tokenization/AToken.sol", + "id": 7670, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 10328, + "src": "456:36:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol", + "file": "../libraries/CoreLibrary.sol", + "id": 7671, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 8995, + "src": "493:38:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "file": "../libraries/WadRayMath.sol", + "id": 7672, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 9175, + "src": "532:37:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IFeeProvider.sol", + "file": "../interfaces/IFeeProvider.sol", + "id": 7673, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 1766, + "src": "570:40:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol", + "file": "../flashloan/interfaces/IFlashLoanReceiver.sol", + "id": 7674, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 1734, + "src": "611:56:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "./LendingPoolCore.sol", + "id": 7675, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 6683, + "src": "668:31:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolDataProvider.sol", + "file": "./LendingPoolDataProvider.sol", + "id": 7676, + "nodeType": "ImportDirective", + "scope": 8255, + "sourceUnit": 7661, + "src": "700:39:27", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 7677, + "name": "ReentrancyGuard", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12113, + "src": "1122:15:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ReentrancyGuard_$12113", + "typeString": "contract ReentrancyGuard" + } + }, + "id": 7678, + "nodeType": "InheritanceSpecifier", + "src": "1122:15:27" + } + ], + "contractDependencies": [ + 12113 + ], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title LiquidationManager contract\n@author Aave\n@notice Implements the actions of the LendingPool, and exposes accessory methods to access the core information************************************************************************************", + "fullyImplemented": true, + "id": 8254, + "linearizedBaseContracts": [ + 8254, + 12113 + ], + "name": "LendingPoolLiquidationManager", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 7681, + "libraryName": { + "contractScope": null, + "id": 7679, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "1151:8:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1145:27:27", + "typeName": { + "id": 7680, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1164:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 7684, + "libraryName": { + "contractScope": null, + "id": 7682, + "name": "WadRayMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9174, + "src": "1183:10:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_WadRayMath_$9174", + "typeString": "library WadRayMath" + } + }, + "nodeType": "UsingForDirective", + "src": "1177:29:27", + "typeName": { + "id": 7683, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1198:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 7687, + "libraryName": { + "contractScope": null, + "id": 7685, + "name": "Address", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12081, + "src": "1217:7:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + }, + "nodeType": "UsingForDirective", + "src": "1211:34:27", + "typeName": { + "id": 7686, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1229:15:27", + "stateMutability": "payable", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + }, + { + "constant": false, + "id": 7689, + "name": "addressesProvider", + "nodeType": "VariableDeclaration", + "scope": 8254, + "src": "1251:53:27", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 7688, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1251:28:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "public" + }, + { + "constant": false, + "id": 7691, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 8254, + "src": "1310:20:27", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 7690, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "1310:15:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7693, + "name": "dataProvider", + "nodeType": "VariableDeclaration", + "scope": 8254, + "src": "1336:36:27", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + }, + "typeName": { + "contractScope": null, + "id": 7692, + "name": "LendingPoolDataProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 7660, + "src": "1336:23:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7695, + "name": "parametersProvider", + "nodeType": "VariableDeclaration", + "scope": 8254, + "src": "1378:48:27", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + }, + "typeName": { + "contractScope": null, + "id": 7694, + "name": "LendingPoolParametersProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1418, + "src": "1378:29:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolParametersProvider_$1418", + "typeString": "contract LendingPoolParametersProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": true, + "id": 7698, + "name": "LIQUIDATION_CLOSE_FACTOR_PERCENT", + "nodeType": "VariableDeclaration", + "scope": 8254, + "src": "1434:54:27", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7696, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1434:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3530", + "id": 7697, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1486:2:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_50_by_1", + "typeString": "int_const 50" + }, + "value": "50" + }, + "visibility": "internal" + }, + { + "canonicalName": "LendingPoolLiquidationManager.LiquidationErrors", + "id": 7705, + "members": [ + { + "id": 7699, + "name": "NO_ERROR", + "nodeType": "EnumValue", + "src": "1527:8:27" + }, + { + "id": 7700, + "name": "NO_COLLATERAL_AVAILABLE", + "nodeType": "EnumValue", + "src": "1545:23:27" + }, + { + "id": 7701, + "name": "COLLATERAL_CANNOT_BE_LIQUIDATED", + "nodeType": "EnumValue", + "src": "1578:31:27" + }, + { + "id": 7702, + "name": "CURRRENCY_NOT_BORROWED", + "nodeType": "EnumValue", + "src": "1619:22:27" + }, + { + "id": 7703, + "name": "HEALTH_FACTOR_ABOVE_THRESHOLD", + "nodeType": "EnumValue", + "src": "1651:29:27" + }, + { + "id": 7704, + "name": "NOT_ENOUGH_LIQUIDITY", + "nodeType": "EnumValue", + "src": "1690:20:27" + } + ], + "name": "LiquidationErrors", + "nodeType": "EnumDefinition", + "src": "1494:222:27" + }, + { + "anonymous": false, + "documentation": null, + "id": 7707, + "name": "LiquidationCompleted", + "nodeType": "EventDefinition", + "parameters": { + "id": 7706, + "nodeType": "ParameterList", + "parameters": [], + "src": "1748:2:27" + }, + "src": "1722:29:27" + }, + { + "canonicalName": "LendingPoolLiquidationManager.LiquidationCallLocalVars", + "id": 7730, + "members": [ + { + "constant": false, + "id": 7709, + "name": "healthFactor", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1798:20:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7708, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1798:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7711, + "name": "userCollateralBalance", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1828:29:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7710, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1828:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7713, + "name": "userCompoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1867:35:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7712, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1867:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7715, + "name": "borrowBalanceIncrease", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1912:29:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7714, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1912:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7717, + "name": "maxPrincipalAmountToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1951:37:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7716, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1951:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7719, + "name": "actualAmountToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "1998:31:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7718, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1998:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7721, + "name": "liquidationRatio", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "2039:24:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7720, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2039:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7723, + "name": "collateralPrice", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "2073:23:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7722, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2073:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7725, + "name": "principalCurrencyPrice", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "2106:30:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7724, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2106:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7727, + "name": "maxAmountCollateralToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "2146:38:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7726, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2146:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7729, + "name": "isCollateralEnabled", + "nodeType": "VariableDeclaration", + "scope": 7730, + "src": "2194:24:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7728, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2194:4:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "LiquidationCallLocalVars", + "nodeType": "StructDefinition", + "scope": 8254, + "src": "1757:469:27", + "visibility": "public" + }, + { + "body": { + "id": 8115, + "nodeType": "Block", + "src": "2595:5349:27", + "statements": [ + { + "assignments": [ + 7748 + ], + "declarations": [ + { + "constant": false, + "id": 7748, + "name": "vars", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "2605:36:27", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars" + }, + "typeName": { + "contractScope": null, + "id": 7747, + "name": "LiquidationCallLocalVars", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 7730, + "src": "2605:24:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_storage_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7749, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "2605:36:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 7758, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + null, + null, + null, + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7750, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "2658:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7752, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "healthFactor", + "nodeType": "MemberAccess", + "referencedDeclaration": 7709, + "src": "2658:17:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 7753, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "2652:24:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$__$__$__$__$_t_uint256_$", + "typeString": "tuple(,,,,,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7756, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "2716:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7754, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7693, + "src": "2679:12:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 7755, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "calculateUserGlobalData", + "nodeType": "MemberAccess", + "referencedDeclaration": 6984, + "src": "2679:36:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address) view external returns (uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "id": 7757, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2679:43:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256,uint256,uint256,uint256)" + } + }, + "src": "2652:70:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7759, + "nodeType": "ExpressionStatement", + "src": "2652:70:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7765, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7760, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "2736:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7761, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "healthFactor", + "nodeType": "MemberAccess", + "referencedDeclaration": 7709, + "src": "2736:17:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 7762, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7693, + "src": "2757:12:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 7763, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getHealthFactorLiquidationThreshold", + "nodeType": "MemberAccess", + "referencedDeclaration": 7263, + "src": "2757:48:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_pure$__$returns$_t_uint256_$", + "typeString": "function () pure external returns (uint256)" + } + }, + "id": 7764, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2757:50:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2736:71:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7774, + "nodeType": "IfStatement", + "src": "2733:209:27", + "trueBody": { + "id": 7773, + "nodeType": "Block", + "src": "2808:134:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7767, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "2838:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 7768, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "HEALTH_FACTOR_ABOVE_THRESHOLD", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2838:47:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 7766, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2830:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7769, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2830:56:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "4865616c746820666163746f72206973206e6f742062656c6f7720746865207468726573686f6c64", + "id": 7770, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2888:42:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e7f9afd7c1ffabe0273b3edfe9c5949b99bf84b8a8f1418c24bc0f519353394f", + "typeString": "literal_string \"Health factor is not below the threshold\"" + }, + "value": "Health factor is not below the threshold" + } + ], + "id": 7771, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "2829:102:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_e7f9afd7c1ffabe0273b3edfe9c5949b99bf84b8a8f1418c24bc0f519353394f_$", + "typeString": "tuple(uint256,literal_string \"Health factor is not below the threshold\")" + } + }, + "functionReturnParameters": 7746, + "id": 7772, + "nodeType": "Return", + "src": "2822:109:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7783, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7775, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "2952:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7777, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "userCollateralBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7711, + "src": "2952:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7780, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "3024:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7781, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "3037:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7778, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7693, + "src": "2981:12:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolDataProvider_$7660", + "typeString": "contract LendingPoolDataProvider" + } + }, + "id": 7779, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserUnderlyingAssetBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7008, + "src": "2981:42:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7782, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2981:62:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2952:91:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7784, + "nodeType": "ExpressionStatement", + "src": "2952:91:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7788, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7785, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3145:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7786, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCollateralBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7711, + "src": "3145:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 7787, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3175:1:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3145:31:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7797, + "nodeType": "IfStatement", + "src": "3142:155:27", + "trueBody": { + "id": 7796, + "nodeType": "Block", + "src": "3178:119:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7790, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "3208:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 7791, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "NO_COLLATERAL_AVAILABLE", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3208:41:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 7789, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3200:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7792, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3200:50:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c696420636f6c6c61746572616c20746f206c6971756964617465", + "id": 7793, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3252:33:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_fd71d007efa0d133789dda79d6d01aa7bd15ca534645487a5a4de2afc95a3de3", + "typeString": "literal_string \"Invalid collateral to liquidate\"" + }, + "value": "Invalid collateral to liquidate" + } + ], + "id": 7794, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "3199:87:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_fd71d007efa0d133789dda79d6d01aa7bd15ca534645487a5a4de2afc95a3de3_$", + "typeString": "tuple(uint256,literal_string \"Invalid collateral to liquidate\")" + } + }, + "functionReturnParameters": 7746, + "id": 7795, + "nodeType": "Return", + "src": "3192:94:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7812, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7798, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3307:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7800, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "isCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 7729, + "src": "3307:24:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 7811, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7803, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "3373:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7801, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "3334:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7802, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isReserveUsageAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5851, + "src": "3334:38:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_bool_$", + "typeString": "function (address) view external returns (bool)" + } + }, + "id": 7804, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3334:51:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "id": 7810, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "3401:61:27", + "subExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7807, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "3443:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7808, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "3456:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7805, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "3402:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7806, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isUserUseReserveAsCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 5933, + "src": "3402:40:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_bool_$", + "typeString": "function (address,address) view external returns (bool)" + } + }, + "id": 7809, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3402:60:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "3334:128:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "3307:155:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 7813, + "nodeType": "ExpressionStatement", + "src": "3307:155:27" + }, + { + "condition": { + "argumentTypes": null, + "id": 7816, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "3563:25:27", + "subExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7814, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3564:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7815, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "isCollateralEnabled", + "nodeType": "MemberAccess", + "referencedDeclaration": 7729, + "src": "3564:24:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7825, + "nodeType": "IfStatement", + "src": "3560:169:27", + "trueBody": { + "id": 7824, + "nodeType": "Block", + "src": "3590:139:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7818, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "3620:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 7819, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "COLLATERAL_CANNOT_BE_LIQUIDATED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3620:49:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 7817, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3612:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7820, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3612:58:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "54686520636f6c6c61746572616c2063686f73656e2063616e6e6f74206265206c69757175696461746564", + "id": 7821, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3672:45:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_26ed6a3d02ed1500eb16391fd9742ea448dda174e451a7ecf36ef6cd99a1b91e", + "typeString": "literal_string \"The collateral chosen cannot be liuquidated\"" + }, + "value": "The collateral chosen cannot be liuquidated" + } + ], + "id": 7822, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "3611:107:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_26ed6a3d02ed1500eb16391fd9742ea448dda174e451a7ecf36ef6cd99a1b91e_$", + "typeString": "tuple(uint256,literal_string \"The collateral chosen cannot be liuquidated\")" + } + }, + "functionReturnParameters": 7746, + "id": 7823, + "nodeType": "Return", + "src": "3604:114:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7837, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "components": [ + null, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7826, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3846:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7828, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "userCompoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7713, + "src": "3846:32:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7829, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3879:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7830, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "borrowBalanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7715, + "src": "3879:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 7831, + "isConstant": false, + "isInlineArray": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "TupleExpression", + "src": "3844:62:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$_t_uint256_$_t_uint256_$", + "typeString": "tuple(,uint256,uint256)" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7834, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "3936:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7835, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "3946:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7832, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "3909:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7833, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserBorrowBalances", + "nodeType": "MemberAccess", + "referencedDeclaration": 6063, + "src": "3909:26:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256,uint256,uint256)" + } + }, + "id": 7836, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3909:43:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256,uint256)" + } + }, + "src": "3844:108:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7838, + "nodeType": "ExpressionStatement", + "src": "3844:108:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7842, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7839, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "3966:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7840, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCompoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7713, + "src": "3966:32:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 7841, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4002:1:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3966:37:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7851, + "nodeType": "IfStatement", + "src": "3963:170:27", + "trueBody": { + "id": 7850, + "nodeType": "Block", + "src": "4004:129:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7844, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "4034:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 7845, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "CURRRENCY_NOT_BORROWED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "4034:40:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 7843, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "4026:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7846, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4026:49:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "5573657220646964206e6f7420626f72726f7720746865207370656369666965642063757272656e6379", + "id": 7847, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4077:44:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_f180dd83a62112e452b337e2b6b4afb2399867f2230bc3004770c378708cbda8", + "typeString": "literal_string \"User did not borrow the specified currency\"" + }, + "value": "User did not borrow the specified currency" + } + ], + "id": 7848, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "4025:97:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_f180dd83a62112e452b337e2b6b4afb2399867f2230bc3004770c378708cbda8_$", + "typeString": "tuple(uint256,literal_string \"User did not borrow the specified currency\")" + } + }, + "functionReturnParameters": 7746, + "id": 7849, + "nodeType": "Return", + "src": "4018:104:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "id": 7863, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7852, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4223:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7854, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "maxPrincipalAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7717, + "src": "4223:34:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 7861, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4335:3:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7858, + "name": "LIQUIDATION_CLOSE_FACTOR_PERCENT", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7698, + "src": "4297:32:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7855, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4260:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7856, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCompoundedBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7713, + "src": "4260:32:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7857, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "4260:36:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7859, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4260:70:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7860, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "4260:74:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7862, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4260:79:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4223:116:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7864, + "nodeType": "ExpressionStatement", + "src": "4223:116:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 7876, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7865, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4350:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7867, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "4350:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7871, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7868, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7738, + "src": "4381:15:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7869, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4399:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7870, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "maxPrincipalAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7717, + "src": "4399:34:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4381:52:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseExpression": { + "argumentTypes": null, + "id": 7874, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7738, + "src": "4521:15:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7875, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "Conditional", + "src": "4381:155:27", + "trueExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7872, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4460:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7873, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "maxPrincipalAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7717, + "src": "4460:34:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4350:186:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7877, + "nodeType": "ExpressionStatement", + "src": "4350:186:27" + }, + { + "assignments": [ + 7879, + 7881 + ], + "declarations": [ + { + "constant": false, + "id": 7879, + "name": "maxCollateralToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "4548:32:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7878, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4548:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7881, + "name": "principalAmountNeeded", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "4590:29:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7880, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "4590:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7890, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7883, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "4663:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7884, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "4676:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7885, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4686:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7886, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "4686:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7887, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4716:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7888, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "userCollateralBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 7711, + "src": "4716:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 7882, + "name": "calculateAvailableCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8253, + "src": "4623:39:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$_t_uint256_$_t_uint256_$returns$_t_uint256_$_t_uint256_$", + "typeString": "function (address,address,uint256,uint256) view returns (uint256,uint256)" + } + }, + "id": 7889, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4623:120:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "4547:196:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7894, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7891, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7881, + "src": "4968:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7892, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "4992:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7893, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "4992:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "4968:52:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7902, + "nodeType": "IfStatement", + "src": "4965:133:27", + "trueBody": { + "id": 7901, + "nodeType": "Block", + "src": "5021:77:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 7899, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7895, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "5035:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7897, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "5035:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 7898, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7881, + "src": "5066:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5035:52:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7900, + "nodeType": "ExpressionStatement", + "src": "5035:52:27" + } + ] + } + }, + { + "condition": { + "argumentTypes": null, + "id": 7904, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "!", + "prefix": true, + "src": "5231:15:27", + "subExpression": { + "argumentTypes": null, + "id": 7903, + "name": "_receiveAToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7740, + "src": "5232:14:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7925, + "nodeType": "IfStatement", + "src": "5228:342:27", + "trueBody": { + "id": 7924, + "nodeType": "Block", + "src": "5247:323:27", + "statements": [ + { + "assignments": [ + 7906 + ], + "declarations": [ + { + "constant": false, + "id": 7906, + "name": "currentAvailableCollateral", + "nodeType": "VariableDeclaration", + "scope": 7924, + "src": "5261:34:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7905, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5261:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7911, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7909, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "5332:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7907, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "5298:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7908, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveAvailableLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 5482, + "src": "5298:33:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 7910, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5298:46:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5261:83:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 7914, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7912, + "name": "currentAvailableCollateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7906, + "src": "5361:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">=", + "rightExpression": { + "argumentTypes": null, + "id": 7913, + "name": "maxCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7879, + "src": "5391:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "5361:54:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 7923, + "nodeType": "IfStatement", + "src": "5358:202:27", + "trueBody": { + "id": 7922, + "nodeType": "Block", + "src": "5416:144:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7916, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "5450:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 7917, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "NOT_ENOUGH_LIQUIDITY", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "5450:38:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 7915, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "5442:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 7918, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5442:47:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "54686572652069736e277420656e6f756768206c697175696469747920617661696c61626c6520746f206c6971756964617465", + "id": 7919, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "5491:53:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a79516f30c9ace6d12f24050fedd804d8cca1187d4e48e1452d78340e8165699", + "typeString": "literal_string \"There isn't enough liquidity available to liquidate\"" + }, + "value": "There isn't enough liquidity available to liquidate" + } + ], + "id": 7920, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "5441:104:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_a79516f30c9ace6d12f24050fedd804d8cca1187d4e48e1452d78340e8165699_$", + "typeString": "tuple(uint256,literal_string \"There isn't enough liquidity available to liquidate\")" + } + }, + "functionReturnParameters": 7746, + "id": 7921, + "nodeType": "Return", + "src": "5434:111:27" + } + ] + } + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7929, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "5656:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7926, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "5620:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7928, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "5620:35:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 7930, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5620:45:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7931, + "nodeType": "ExpressionStatement", + "src": "5620:45:27" + }, + { + "assignments": [ + 7935 + ], + "declarations": [ + { + "constant": false, + "id": 7935, + "name": "borrowRateMode", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "5676:43:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "typeName": { + "contractScope": null, + "id": 7934, + "name": "CoreLibrary.InterestRateMode", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8267, + "src": "5676:28:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7941, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7938, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "5756:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7939, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "5765:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7936, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "5722:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7937, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentBorrowRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 5988, + "src": "5722:33:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_enum$_InterestRateMode_$8267_$", + "typeString": "function (address,address) view external returns (enum CoreLibrary.InterestRateMode)" + } + }, + "id": 7940, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5722:49:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5676:95:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7945, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "5817:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7946, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "5827:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7947, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7715, + "src": "5827:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7942, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "5782:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7944, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "increaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4883, + "src": "5782:34:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 7948, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5782:72:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7949, + "nodeType": "ExpressionStatement", + "src": "5782:72:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + }, + "id": 7954, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 7950, + "name": "borrowRateMode", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7935, + "src": "5869:14:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7951, + "name": "CoreLibrary", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8994, + "src": "5887:11:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_CoreLibrary_$8994_$", + "typeString": "type(library CoreLibrary)" + } + }, + "id": 7952, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "InterestRateMode", + "nodeType": "MemberAccess", + "referencedDeclaration": 8267, + "src": "5887:28:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_InterestRateMode_$8267_$", + "typeString": "type(enum CoreLibrary.InterestRateMode)" + } + }, + "id": 7953, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "FIXED", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "5887:34:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_InterestRateMode_$8267", + "typeString": "enum CoreLibrary.InterestRateMode" + } + }, + "src": "5869:52:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 7989, + "nodeType": "Block", + "src": "6193:137:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7980, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6248:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7984, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6291:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7985, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7715, + "src": "6291:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7981, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6258:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7982, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "6258:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7983, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "6258:32:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7986, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6258:60:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7977, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6207:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7979, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsVariable", + "nodeType": "MemberAccess", + "referencedDeclaration": 4991, + "src": "6207:40:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 7987, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6207:112:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7988, + "nodeType": "ExpressionStatement", + "src": "6207:112:27" + } + ] + }, + "id": 7990, + "nodeType": "IfStatement", + "src": "5865:465:27", + "trueBody": { + "id": 7976, + "nodeType": "Block", + "src": "5923:264:27", + "statements": [ + { + "assignments": [ + 7956 + ], + "declarations": [ + { + "constant": false, + "id": 7956, + "name": "currentFixedRate", + "nodeType": "VariableDeclaration", + "scope": 7976, + "src": "5937:24:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7955, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "5937:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 7962, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7959, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "5999:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 7960, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "6009:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7957, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "5964:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7958, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getUserCurrentFixedBorrowRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 6011, + "src": "5964:34:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 7961, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "5964:51:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "5937:78:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7966, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6087:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7970, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6130:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7971, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7715, + "src": "6130:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 7967, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6097:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 7968, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "6097:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 7969, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "6097:32:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 7972, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6097:60:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 7973, + "name": "currentFixedRate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7956, + "src": "6159:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 7963, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6029:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7965, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalBorrowsFixedAndUpdateAverageRate", + "nodeType": "MemberAccess", + "referencedDeclaration": 4954, + "src": "6029:57:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256) external" + } + }, + "id": 7974, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6029:147:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7975, + "nodeType": "ExpressionStatement", + "src": "6029:147:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 7994, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6372:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7991, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6340:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7993, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "6340:31:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 7995, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6340:41:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 7996, + "nodeType": "ExpressionStatement", + "src": "6340:41:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8000, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6417:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 7997, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6391:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 7999, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "6391:25:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 8001, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6391:35:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8002, + "nodeType": "ExpressionStatement", + "src": "6391:35:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8006, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6518:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 8007, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "6528:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8011, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6568:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 8012, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "borrowBalanceIncrease", + "nodeType": "MemberAccess", + "referencedDeclaration": 7715, + "src": "6568:26:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8008, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "6535:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 8009, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "6535:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8010, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 10996, + "src": "6535:32:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8013, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6535:60:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8003, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6478:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8005, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseUserPrincipalBorrowBalance", + "nodeType": "MemberAccess", + "referencedDeclaration": 5309, + "src": "6478:39:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 8014, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6478:118:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8015, + "nodeType": "ExpressionStatement", + "src": "6478:118:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8019, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "6629:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 8020, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "6638:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8016, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6606:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8018, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setUserLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5366, + "src": "6606:22:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address) external" + } + }, + "id": 8021, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6606:38:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8022, + "nodeType": "ExpressionStatement", + "src": "6606:38:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8026, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "6727:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8023, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6691:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8025, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveCumulativeIndexes", + "nodeType": "MemberAccess", + "referencedDeclaration": 4793, + "src": "6691:35:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 8027, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6691:48:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8028, + "nodeType": "ExpressionStatement", + "src": "6691:48:27" + }, + { + "assignments": [ + 8030 + ], + "declarations": [ + { + "constant": false, + "id": 8030, + "name": "collateralAtoken", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "6749:23:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + }, + "typeName": { + "contractScope": null, + "id": 8029, + "name": "AToken", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10327, + "src": "6749:6:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8037, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8034, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "6811:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8032, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "6782:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8033, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveATokenAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 5458, + "src": "6782:28:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_address_$", + "typeString": "function (address) view external returns (address)" + } + }, + "id": 8035, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6782:41:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 8031, + "name": "AToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10327, + "src": "6775:6:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_AToken_$10327_$", + "typeString": "type(contract AToken)" + } + }, + "id": 8036, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6775:49:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6749:75:27" + }, + { + "assignments": [ + 8039 + ], + "declarations": [ + { + "constant": false, + "id": 8039, + "name": "aTokenCollateralToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 8115, + "src": "6893:35:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8038, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "6893:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8044, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8042, + "name": "maxCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7879, + "src": "6979:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8040, + "name": "collateralAtoken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8030, + "src": "6931:16:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 8041, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "underlyingAmountToATokenAmount", + "nodeType": "MemberAccess", + "referencedDeclaration": 10313, + "src": "6931:47:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_uint256_$returns$_t_uint256_$", + "typeString": "function (uint256) view external returns (uint256)" + } + }, + "id": 8043, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "6931:73:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "6893:111:27" + }, + { + "condition": { + "argumentTypes": null, + "id": 8045, + "name": "_receiveAToken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7740, + "src": "7104:14:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 8085, + "nodeType": "Block", + "src": "7245:418:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8059, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "7387:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 8060, + "name": "aTokenCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8039, + "src": "7394:27:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8056, + "name": "collateralAtoken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8030, + "src": "7352:16:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 8058, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "burnOnLiquidation", + "nodeType": "MemberAccess", + "referencedDeclaration": 10145, + "src": "7352:34:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 8061, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7352:70:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8062, + "nodeType": "ExpressionStatement", + "src": "7352:70:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8066, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "7471:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 8067, + "name": "maxCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7879, + "src": "7484:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8063, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "7436:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "decreaseReserveTotalLiquidity", + "nodeType": "MemberAccess", + "referencedDeclaration": 4911, + "src": "7436:34:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256) external" + } + }, + "id": 8068, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7436:73:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8069, + "nodeType": "ExpressionStatement", + "src": "7436:73:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8073, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "7555:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8070, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "7523:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8072, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "updateReserveInterestRates", + "nodeType": "MemberAccess", + "referencedDeclaration": 4852, + "src": "7523:31:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 8074, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7523:44:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8075, + "nodeType": "ExpressionStatement", + "src": "7523:44:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8079, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "7601:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8080, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "7614:3:27", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 8081, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7614:10:27", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 8082, + "name": "maxCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7879, + "src": "7626:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8076, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "7581:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8078, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToUser", + "nodeType": "MemberAccess", + "referencedDeclaration": 6486, + "src": "7581:19:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) external" + } + }, + "id": 8083, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7581:70:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8084, + "nodeType": "ExpressionStatement", + "src": "7581:70:27" + } + ] + }, + "id": 8086, + "nodeType": "IfStatement", + "src": "7101:562:27", + "trueBody": { + "id": 8055, + "nodeType": "Block", + "src": "7120:111:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8049, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7736, + "src": "7173:5:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8050, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "7180:3:27", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 8051, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7180:10:27", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 8052, + "name": "aTokenCollateralToLiquidate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8039, + "src": "7192:27:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 8046, + "name": "collateralAtoken", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8030, + "src": "7134:16:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AToken_$10327", + "typeString": "contract AToken" + } + }, + "id": 8048, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferOnLiquidation", + "nodeType": "MemberAccess", + "referencedDeclaration": 10180, + "src": "7134:38:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,address,uint256) external" + } + }, + "id": 8053, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7134:86:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8054, + "nodeType": "ExpressionStatement", + "src": "7134:86:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8090, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7732, + "src": "7699:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8087, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "7673:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8089, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "setReserveLastUpdate", + "nodeType": "MemberAccess", + "referencedDeclaration": 5135, + "src": "7673:25:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$returns$__$", + "typeString": "function (address) external" + } + }, + "id": 8091, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7673:38:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8092, + "nodeType": "ExpressionStatement", + "src": "7673:38:27" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8101, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7734, + "src": "7818:8:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8102, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "7828:3:27", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 8103, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7828:10:27", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8104, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7748, + "src": "7840:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_LiquidationCallLocalVars_$7730_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.LiquidationCallLocalVars memory" + } + }, + "id": 8105, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "actualAmountToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 7719, + "src": "7840:28:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8098, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "7807:3:27", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 8099, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7807:9:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8093, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "7778:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8096, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferToReserve", + "nodeType": "MemberAccess", + "referencedDeclaration": 6619, + "src": "7778:22:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 8097, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "value", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7778:28:27", + "typeDescriptions": { + "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value_$", + "typeString": "function (uint256) returns (function (address,address payable,uint256) payable external)" + } + }, + "id": 8100, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7778:39:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_payable$_t_address_$_t_address_payable_$_t_uint256_$returns$__$value", + "typeString": "function (address,address payable,uint256) payable external" + } + }, + "id": 8106, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7778:91:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 8107, + "nodeType": "ExpressionStatement", + "src": "7778:91:27" + }, + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8109, + "name": "LiquidationErrors", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7705, + "src": "7896:17:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_enum$_LiquidationErrors_$7705_$", + "typeString": "type(enum LendingPoolLiquidationManager.LiquidationErrors)" + } + }, + "id": 8110, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "NO_ERROR", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "7896:26:27", + "typeDescriptions": { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_enum$_LiquidationErrors_$7705", + "typeString": "enum LendingPoolLiquidationManager.LiquidationErrors" + } + ], + "id": 8108, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "7888:7:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_uint256_$", + "typeString": "type(uint256)" + }, + "typeName": "uint256" + }, + "id": 8111, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "7888:35:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "4e6f206572726f7273", + "id": 8112, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "7925:11:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ca44fe728f23c758e348e2d287cc8febf43f0dace4b6a486a276b60c3218ecac", + "typeString": "literal_string \"No errors\"" + }, + "value": "No errors" + } + ], + "id": 8113, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "7887:50:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_stringliteral_ca44fe728f23c758e348e2d287cc8febf43f0dace4b6a486a276b60c3218ecac_$", + "typeString": "tuple(uint256,literal_string \"No errors\")" + } + }, + "functionReturnParameters": 7746, + "id": 8114, + "nodeType": "Return", + "src": "7880:57:27" + } + ] + }, + "documentation": "@notice implements loan liquidation\n@dev _receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset.", + "id": 8116, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "liquidationCall", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 7741, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7732, + "name": "_collateral", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2419:19:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7731, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2419:7:27", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7734, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2440:16:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7733, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2440:7:27", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7736, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2458:13:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 7735, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2458:7:27", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7738, + "name": "_purchaseAmount", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2473:23:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7737, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2473:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7740, + "name": "_receiveAToken", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2498:19:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 7739, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "2498:4:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2418:100:27" + }, + "returnParameters": { + "id": 7746, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 7743, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2567:7:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 7742, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2567:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 7745, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 8116, + "src": "2576:13:27", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 7744, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "2576:6:27", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2566:24:27" + }, + "scope": 8254, + "src": "2394:5550:27", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "canonicalName": "LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars", + "id": 8127, + "members": [ + { + "constant": false, + "id": 8118, + "name": "userCompoundedBorrowBalance", + "nodeType": "VariableDeclaration", + "scope": 8127, + "src": "8008:35:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8117, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8008:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8120, + "name": "liquidationDiscount", + "nodeType": "VariableDeclaration", + "scope": 8127, + "src": "8053:27:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8119, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8053:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8122, + "name": "collateralPrice", + "nodeType": "VariableDeclaration", + "scope": 8127, + "src": "8090:23:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8121, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8090:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8124, + "name": "principalCurrencyPrice", + "nodeType": "VariableDeclaration", + "scope": 8127, + "src": "8123:30:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8123, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8123:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8126, + "name": "maxAmountCollateralToLiquidate", + "nodeType": "VariableDeclaration", + "scope": 8127, + "src": "8163:38:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8125, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8163:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "name": "AvailableCollateralToLiquidateLocalVars", + "nodeType": "StructDefinition", + "scope": 8254, + "src": "7952:256:27", + "visibility": "public" + }, + { + "body": { + "id": 8252, + "nodeType": "Block", + "src": "8764:1389:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8144, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8142, + "name": "collateralAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8138, + "src": "8775:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "30", + "id": 8143, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8794:1:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "8775:20:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8145, + "nodeType": "ExpressionStatement", + "src": "8775:20:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8148, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8146, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8140, + "src": "8805:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "30", + "id": 8147, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "8829:1:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "8805:25:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8149, + "nodeType": "ExpressionStatement", + "src": "8805:25:27" + }, + { + "assignments": [ + 8151 + ], + "declarations": [ + { + "constant": false, + "id": 8151, + "name": "oracle", + "nodeType": "VariableDeclaration", + "scope": 8252, + "src": "8840:19:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + }, + "typeName": { + "contractScope": null, + "id": 8150, + "name": "IPriceOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1959, + "src": "8840:12:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8157, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 8153, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7689, + "src": "8875:17:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 8154, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getPriceOracle", + "nodeType": "MemberAccess", + "referencedDeclaration": 1266, + "src": "8875:32:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 8155, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8875:34:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 8152, + "name": "IPriceOracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1959, + "src": "8862:12:27", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IPriceOracle_$1959_$", + "typeString": "type(contract IPriceOracle)" + } + }, + "id": 8156, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "8862:48:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "8840:70:27" + }, + { + "assignments": [ + 8159 + ], + "declarations": [ + { + "constant": false, + "id": 8159, + "name": "vars", + "nodeType": "VariableDeclaration", + "scope": 8252, + "src": "8921:51:27", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars" + }, + "typeName": { + "contractScope": null, + "id": 8158, + "name": "AvailableCollateralToLiquidateLocalVars", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 8127, + "src": "8921:39:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_storage_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 8160, + "initialValue": null, + "nodeType": "VariableDeclarationStatement", + "src": "8921:51:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8168, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8161, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "8983:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8163, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "collateralPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8122, + "src": "8983:20:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8166, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8129, + "src": "9027:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8164, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8151, + "src": "9006:6:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 8165, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getAssetPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 1941, + "src": "9006:20:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 8167, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9006:33:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "8983:56:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8169, + "nodeType": "ExpressionStatement", + "src": "8983:56:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8177, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8170, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9049:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8172, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "principalCurrencyPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8124, + "src": "9049:27:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8175, + "name": "_principal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8131, + "src": "9100:10:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8173, + "name": "oracle", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8151, + "src": "9079:6:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 8174, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getAssetPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 1941, + "src": "9079:20:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 8176, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9079:32:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9049:62:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8178, + "nodeType": "ExpressionStatement", + "src": "9049:62:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8186, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8179, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9121:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8181, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "liquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 8120, + "src": "9121:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8184, + "name": "_collateral", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8129, + "src": "9183:11:27", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 8182, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 7691, + "src": "9148:4:27", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 8183, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserveLiquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 5611, + "src": "9148:34:27", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 8185, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9148:47:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9121:74:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8187, + "nodeType": "ExpressionStatement", + "src": "9121:74:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8207, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8188, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9391:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8190, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "memberName": "maxAmountCollateralToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8126, + "src": "9391:35:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 8205, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9577:3:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8201, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9534:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8202, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 8120, + "src": "9534:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8197, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9495:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8198, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8122, + "src": "9495:20:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8194, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8133, + "src": "9461:15:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8191, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9429:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8192, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalCurrencyPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8124, + "src": "9429:27:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8193, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "9429:31:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8195, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9429:48:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8196, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "9429:65:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8199, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9429:87:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8200, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "9429:104:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8203, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9429:130:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8204, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "9429:147:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8206, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9429:152:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9391:190:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8208, + "nodeType": "ExpressionStatement", + "src": "9391:190:27" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 8212, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8209, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9595:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8210, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "maxAmountCollateralToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8126, + "src": "9595:35:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "id": 8211, + "name": "_userCollateralBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8135, + "src": "9633:22:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9595:60:27", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 8246, + "nodeType": "Block", + "src": "9956:132:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8240, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8237, + "name": "collateralAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8138, + "src": "9970:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8238, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9989:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8239, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "maxAmountCollateralToLiquidate", + "nodeType": "MemberAccess", + "referencedDeclaration": 8126, + "src": "9989:35:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9970:54:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8241, + "nodeType": "ExpressionStatement", + "src": "9970:54:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8244, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8242, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8140, + "src": "10038:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8243, + "name": "_purchaseAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8133, + "src": "10062:15:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "10038:39:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8245, + "nodeType": "ExpressionStatement", + "src": "10038:39:27" + } + ] + }, + "id": 8247, + "nodeType": "IfStatement", + "src": "9592:496:27", + "trueBody": { + "id": 8236, + "nodeType": "Block", + "src": "9657:286:27", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 8215, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8213, + "name": "collateralAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8138, + "src": "9671:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 8214, + "name": "_userCollateralBalance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8135, + "src": "9690:22:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9671:41:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8216, + "nodeType": "ExpressionStatement", + "src": "9671:41:27" + }, + { + "expression": { + "argumentTypes": null, + "id": 8234, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 8217, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8140, + "src": "9726:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8231, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9907:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8232, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "liquidationDiscount", + "nodeType": "MemberAccess", + "referencedDeclaration": 8120, + "src": "9907:24:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "313030", + "id": 8228, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "9881:3:27", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + }, + "value": "100" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_rational_100_by_1", + "typeString": "int_const 100" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8224, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9831:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8225, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "principalCurrencyPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8124, + "src": "9831:27:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 8221, + "name": "collateralAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8138, + "src": "9792:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 8218, + "name": "vars", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8159, + "src": "9750:4:27", + "typeDescriptions": { + "typeIdentifier": "t_struct$_AvailableCollateralToLiquidateLocalVars_$8127_memory_ptr", + "typeString": "struct LendingPoolLiquidationManager.AvailableCollateralToLiquidateLocalVars memory" + } + }, + "id": 8219, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "memberName": "collateralPrice", + "nodeType": "MemberAccess", + "referencedDeclaration": 8122, + "src": "9750:20:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8220, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "9750:41:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8222, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9750:59:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8223, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "9750:80:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8226, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9750:109:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8227, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "9750:130:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8229, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9750:135:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8230, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "9750:156:27", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 8233, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "9750:182:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "9726:206:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 8235, + "nodeType": "ExpressionStatement", + "src": "9726:206:27" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 8248, + "name": "collateralAmount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8138, + "src": "10106:16:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 8249, + "name": "principalAmountNeeded", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 8140, + "src": "10124:21:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "id": 8250, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "10105:41:27", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_uint256_$_t_uint256_$", + "typeString": "tuple(uint256,uint256)" + } + }, + "functionReturnParameters": 8141, + "id": 8251, + "nodeType": "Return", + "src": "10098:48:27" + } + ] + }, + "documentation": "@notice calculates how much of a specific collateral can be liquidated, given\na certain amount of principal currency.\n@dev this function needs to be called after all the checks to validate the liquidation\nhave been performed, otherwise it might fail.", + "id": 8253, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "calculateAvailableCollateralToLiquidate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 8136, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8129, + "name": "_collateral", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8563:19:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8128, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "8563:7:27", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8131, + "name": "_principal", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8592:18:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 8130, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "8592:7:27", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8133, + "name": "_purchaseAmount", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8620:23:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8132, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8620:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8135, + "name": "_userCollateralBalance", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8653:30:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8134, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8653:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8553:131:27" + }, + "returnParameters": { + "id": 8141, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 8138, + "name": "collateralAmount", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8707:24:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8137, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8707:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 8140, + "name": "principalAmountNeeded", + "nodeType": "VariableDeclaration", + "scope": 8253, + "src": "8733:29:27", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 8139, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "8733:7:27", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "8706:57:27" + }, + "scope": 8254, + "src": "8505:1648:27", + "stateMutability": "view", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 8255, + "src": "1080:9075:27" + } + ], + "src": "0:10155:27" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.787Z", + "devdoc": { + "author": "Aave", + "methods": { + "liquidationCall(address,address,address,uint256,bool)": { + "details": "_receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset." + } + }, + "title": "LiquidationManager contract" + }, + "userdoc": { + "methods": { + "liquidationCall(address,address,address,uint256,bool)": { + "notice": "implements loan liquidation" + } + }, + "notice": "***********************************************************************************Implements the actions of the LendingPool, and exposes accessory methods to access the core information************************************************************************************" + } +} \ No newline at end of file diff --git a/client/src/contracts/LendingPoolParametersProvider.json b/client/src/contracts/LendingPoolParametersProvider.json new file mode 100644 index 0000000..7badf34 --- /dev/null +++ b/client/src/contracts/LendingPoolParametersProvider.json @@ -0,0 +1,1644 @@ +{ + "contractName": "LendingPoolParametersProvider", + "abi": [ + { + "constant": false, + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isOwner", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_key", + "type": "bytes32" + } + ], + "name": "getUint", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "getMaxFixedRateBorrowSizePercent", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_borrowSizePercent", + "type": "uint256" + } + ], + "name": "setMaxFixedRateBorrowSizePercent", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getRebalanceDownRateDelta", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_delta", + "type": "uint256" + } + ], + "name": "setRebalanceDownRateDelta", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"getRebalanceDownRateDelta\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isOwner\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_delta\",\"type\":\"uint256\"}],\"name\":\"setRebalanceDownRateDelta\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_key\",\"type\":\"bytes32\"}],\"name\":\"getUint\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_borrowSizePercent\",\"type\":\"uint256\"}],\"name\":\"setMaxFixedRateBorrowSizePercent\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getMaxFixedRateBorrowSizePercent\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"}],\"devdoc\":{\"author\":\"Aave\",\"methods\":{\"getMaxFixedRateBorrowSizePercent()\":{\"details\":\"returns the maximum fixed rate borrow size, in percentage of the available liquidity.\"},\"getRebalanceDownRateDelta()\":{\"details\":\"returns the delta between the current fixed rate and the user fixed rate at which the borrow position of the user will be rebalanced (scaled down)\"},\"isOwner()\":{\"details\":\"Returns true if the caller is the current owner.\"},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}},\"title\":\"LendingPoolParametersProvider\"},\"userdoc\":{\"methods\":{},\"notice\":\"stores the configuration parameters of the Lending Pool contract\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol\":\"LendingPoolParametersProvider\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol\":{\"keccak256\":\"0xcd8c22e8b9f5c5c4bdb5b5262beafa93486c3b15262283c053afd423eca6e16b\",\"urls\":[\"bzzr://a9a5076a121f51ea42d9ebddc2684f299a0b57c0321837b5776c3a9eb26be97e\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol\":{\"keccak256\":\"0x3f74e899243a66d556c0fa81875ab95ed1e3af1909b0281d03fe89590b95121f\",\"urls\":[\"bzzr://ef6ed6edeb1ec124bf1749991346f0708214f7e12c353175d36b491bce45d7a4\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]}},\"version\":1}", + "bytecode": "0x60806040526100126100d460201b60201c565b600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a36100dc565b600033905090565b6107fb806100eb6000396000f3fe608060405234801561001057600080fd5b50600436106100935760003560e01c8063b383cc2211610066578063b383cc221461012c578063bd02d0f51461015a578063be671bb81461019c578063dd2d8c79146101ca578063f2fde38b146101e857610093565b806346f4f8d114610098578063715018a6146100b65780638da5cb5b146100c05780638f32d59b1461010a575b600080fd5b6100a061022c565b6040518082815260200191505060405180910390f35b6100be61025c565b005b6100c8610397565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6101126103c1565b604051808215151515815260200191505060405180910390f35b6101586004803603602081101561014257600080fd5b8101908080359060200190929190505050610420565b005b6101866004803603602081101561017057600080fd5b81019080803590602001909291905050506104c7565b6040518082815260200191505060405180910390f35b6101c8600480360360208110156101b257600080fd5b81019080803590602001909291905050506104e3565b005b6101d261058a565b6040518082815260200191505060405180910390f35b61022a600480360360208110156101fe57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506105ba565b005b60006102577f524542414c414e43455f444f574e5f524154455f44454c5441000000000000006104c7565b905090565b6102646103c1565b6102d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a36000600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610404610640565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b6104286103c1565b61049a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b6104c47f524542414c414e43455f444f574e5f524154455f44454c54410000000000000082610648565b50565b6000806000838152602001908152602001600020549050919050565b6104eb6103c1565b61055d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b6105877f4d41585f524154455f424f52524f575f53495a455f50455243454e540000000082610648565b50565b60006105b57f4d41585f524154455f424f52524f575f53495a455f50455243454e54000000006104c7565b905090565b6105c26103c1565b610634576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b61063d81610663565b50565b600033905090565b80600080848152602001908152602001600020819055505050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614156106e9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806107aa6026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373a165627a7a72305820b10125edc2fad82fe285d36874b29e2085e9b22d96f1a33580fe857efe1ea1190029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100935760003560e01c8063b383cc2211610066578063b383cc221461012c578063bd02d0f51461015a578063be671bb81461019c578063dd2d8c79146101ca578063f2fde38b146101e857610093565b806346f4f8d114610098578063715018a6146100b65780638da5cb5b146100c05780638f32d59b1461010a575b600080fd5b6100a061022c565b6040518082815260200191505060405180910390f35b6100be61025c565b005b6100c8610397565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6101126103c1565b604051808215151515815260200191505060405180910390f35b6101586004803603602081101561014257600080fd5b8101908080359060200190929190505050610420565b005b6101866004803603602081101561017057600080fd5b81019080803590602001909291905050506104c7565b6040518082815260200191505060405180910390f35b6101c8600480360360208110156101b257600080fd5b81019080803590602001909291905050506104e3565b005b6101d261058a565b6040518082815260200191505060405180910390f35b61022a600480360360208110156101fe57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506105ba565b005b60006102577f524542414c414e43455f444f574e5f524154455f44454c5441000000000000006104c7565b905090565b6102646103c1565b6102d6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a36000600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16905090565b6000600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16610404610640565b73ffffffffffffffffffffffffffffffffffffffff1614905090565b6104286103c1565b61049a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b6104c47f524542414c414e43455f444f574e5f524154455f44454c54410000000000000082610648565b50565b6000806000838152602001908152602001600020549050919050565b6104eb6103c1565b61055d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b6105877f4d41585f524154455f424f52524f575f53495a455f50455243454e540000000082610648565b50565b60006105b57f4d41585f524154455f424f52524f575f53495a455f50455243454e54000000006104c7565b905090565b6105c26103c1565b610634576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e657281525060200191505060405180910390fd5b61063d81610663565b50565b600033905090565b80600080848152602001908152602001600020819055505050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614156106e9576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260268152602001806107aa6026913960400191505060405180910390fd5b8073ffffffffffffffffffffffffffffffffffffffff16600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a380600160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373a165627a7a72305820b10125edc2fad82fe285d36874b29e2085e9b22d96f1a33580fe857efe1ea1190029", + "sourceMap": "251:1248:10:-;;;707:12:57;:10;;;:12;;:::i;:::-;698:6;;:21;;;;;;;;;;;;;;;;;;767:6;;;;;;;;;;;734:40;;763:1;734:40;;;;;;;;;;;;251:1248:10;;788:96:55;833:15;867:10;860:17;;788:96;:::o;251:1248:10:-;;;;;;;", + "deployedSourceMap": "251:1248:10:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;251:1248:10;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1178:127;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1642:137:57;;;:::i;:::-;;857:77;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1208:92;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1359:137:10;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1359:137:10;;;;;;;;;;;;;;;;;:::i;:::-;;100:96:12;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;100:96:12;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;814:177:10;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;814:177:10;;;;;;;;;;;;;;;;;:::i;:::-;;616:144;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1928:107:57;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1928:107:57;;;;;;;;;;;;;;;;;;;:::i;:::-;;1178:127:10;1238:7;1264:34;1272:25;1264:7;:34::i;:::-;1257:41;;1178:127;:::o;1642:137:57:-;1061:9;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1740:1;1703:40;;1724:6;;;;;;;;;;;1703:40;;;;;;;;;;;;1770:1;1753:6;;:19;;;;;;;;;;;;;;;;;;1642:137::o;857:77::-;895:7;921:6;;;;;;;;;;;914:13;;857:77;:::o;1208:92::-;1248:4;1287:6;;;;;;;;;;;1271:22;;:12;:10;:12::i;:::-;:22;;;1264:29;;1208:92;:::o;1359:137:10:-;1061:9:57;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1446:43:10;1455:25;1482:6;1446:8;:43::i;:::-;1359:137;:::o;100:96:12:-;152:7;178:5;:11;184:4;178:11;;;;;;;;;;;;171:18;;100:96;;;:::o;814:177:10:-;1061:9:57;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;920:64:10;929:34;965:18;920:8;:64::i;:::-;814:177;:::o;616:144::-;683:7;710:43;718:34;710:7;:43::i;:::-;703:50;;616:144;:::o;1928:107:57:-;1061:9;:7;:9::i;:::-;1053:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2000:28;2019:8;2000:18;:28::i;:::-;1928:107;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;202:94:12:-;283:6;269:5;:11;275:4;269:11;;;;;;;;;;;:20;;;;202:94;;:::o;2136:225:57:-;2229:1;2209:22;;:8;:22;;;;2201:73;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2318:8;2289:38;;2310:6;;;;;;;;;;;2289:38;;;;;;;;;;;;2346:8;2337:6;;:17;;;;;;;;;;;;;;;;;;2136:225;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"openzeppelin-solidity/contracts/ownership/Ownable.sol\";\nimport \"./UintStorage.sol\";\n\n/**\n@title LendingPoolParametersProvider\n@author Aave\n@notice stores the configuration parameters of the Lending Pool contract\n\n */\ncontract LendingPoolParametersProvider is UintStorage, Ownable {\n bytes32 private constant MAX_FIXED_RATE_BORROW_SIZE_PERCENT = \"MAX_RATE_BORROW_SIZE_PERCENT\";\n bytes32 private constant REBALANCE_DOWN_RATE_DELTA = \"REBALANCE_DOWN_RATE_DELTA\";\n\n /**\n @dev returns the maximum fixed rate borrow size, in percentage of the available liquidity.\n */\n function getMaxFixedRateBorrowSizePercent() external view returns (uint256) {\n return getUint(MAX_FIXED_RATE_BORROW_SIZE_PERCENT);\n }\n\n // TODO: add access control rules under DAO\n function setMaxFixedRateBorrowSizePercent(uint256 _borrowSizePercent) external onlyOwner {\n return _setUint(MAX_FIXED_RATE_BORROW_SIZE_PERCENT, _borrowSizePercent);\n }\n\n /**\n @dev returns the delta between the current fixed rate and the user fixed rate at\n which the borrow position of the user will be rebalanced (scaled down)\n */\n function getRebalanceDownRateDelta() external view returns (uint256) {\n return getUint(REBALANCE_DOWN_RATE_DELTA);\n }\n\n // TODO: add access control rules under DAO\n function setRebalanceDownRateDelta(uint256 _delta) external onlyOwner {\n return _setUint(REBALANCE_DOWN_RATE_DELTA, _delta);\n }\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol", + "exportedSymbols": { + "LendingPoolParametersProvider": [ + 1418 + ] + }, + "id": 1419, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1359, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:10" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "id": 1360, + "nodeType": "ImportDirective", + "scope": 1419, + "sourceUnit": 11255, + "src": "26:63:10", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol", + "file": "./UintStorage.sol", + "id": 1361, + "nodeType": "ImportDirective", + "scope": 1419, + "sourceUnit": 1512, + "src": "90:27:10", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1362, + "name": "UintStorage", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1511, + "src": "293:11:10", + "typeDescriptions": { + "typeIdentifier": "t_contract$_UintStorage_$1511", + "typeString": "contract UintStorage" + } + }, + "id": 1363, + "nodeType": "InheritanceSpecifier", + "src": "293:11:10" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1364, + "name": "Ownable", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11254, + "src": "306:7:10", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Ownable_$11254", + "typeString": "contract Ownable" + } + }, + "id": 1365, + "nodeType": "InheritanceSpecifier", + "src": "306:7:10" + } + ], + "contractDependencies": [ + 1511, + 10953, + 11254 + ], + "contractKind": "contract", + "documentation": "@title LendingPoolParametersProvider\n@author Aave\n@notice stores the configuration parameters of the Lending Pool contract", + "fullyImplemented": true, + "id": 1418, + "linearizedBaseContracts": [ + 1418, + 11254, + 10953, + 1511 + ], + "name": "LendingPoolParametersProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": true, + "id": 1368, + "name": "MAX_FIXED_RATE_BORROW_SIZE_PERCENT", + "nodeType": "VariableDeclaration", + "scope": 1418, + "src": "320:92:10", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1366, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "320:7:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4d41585f524154455f424f52524f575f53495a455f50455243454e54", + "id": 1367, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "382:30:10", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ba4b9e7ee597651932642f8a08ef73dd0794210b0ab5eae294c6782c61c09344", + "typeString": "literal_string \"MAX_RATE_BORROW_SIZE_PERCENT\"" + }, + "value": "MAX_RATE_BORROW_SIZE_PERCENT" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1371, + "name": "REBALANCE_DOWN_RATE_DELTA", + "nodeType": "VariableDeclaration", + "scope": 1418, + "src": "418:80:10", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1369, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "418:7:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "524542414c414e43455f444f574e5f524154455f44454c5441", + "id": 1370, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "471:27:10", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ed357075eeefda3bdf24e71ab10a77c75fb9d7a2c32ed51adbe1f958ba662e79", + "typeString": "literal_string \"REBALANCE_DOWN_RATE_DELTA\"" + }, + "value": "REBALANCE_DOWN_RATE_DELTA" + }, + "visibility": "private" + }, + { + "body": { + "id": 1380, + "nodeType": "Block", + "src": "693:67:10", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1377, + "name": "MAX_FIXED_RATE_BORROW_SIZE_PERCENT", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1368, + "src": "718:34:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1376, + "name": "getUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1496, + "src": "710:7:10", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_uint256_$", + "typeString": "function (bytes32) view returns (uint256)" + } + }, + "id": 1378, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "710:43:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1375, + "id": 1379, + "nodeType": "Return", + "src": "703:50:10" + } + ] + }, + "documentation": "@dev returns the maximum fixed rate borrow size, in percentage of the available liquidity.", + "id": 1381, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getMaxFixedRateBorrowSizePercent", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1372, + "nodeType": "ParameterList", + "parameters": [], + "src": "657:2:10" + }, + "returnParameters": { + "id": 1375, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1374, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1381, + "src": "683:7:10", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1373, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "683:7:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "682:9:10" + }, + "scope": 1418, + "src": "616:144:10", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 1393, + "nodeType": "Block", + "src": "903:88:10", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1389, + "name": "MAX_FIXED_RATE_BORROW_SIZE_PERCENT", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1368, + "src": "929:34:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1390, + "name": "_borrowSizePercent", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1383, + "src": "965:18:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 1388, + "name": "_setUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1510, + "src": "920:8:10", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_uint256_$returns$__$", + "typeString": "function (bytes32,uint256)" + } + }, + "id": 1391, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "920:64:10", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "functionReturnParameters": 1387, + "id": 1392, + "nodeType": "Return", + "src": "913:71:10" + } + ] + }, + "documentation": null, + "id": 1394, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 1386, + "modifierName": { + "argumentTypes": null, + "id": 1385, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "893:9:10", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "893:9:10" + } + ], + "name": "setMaxFixedRateBorrowSizePercent", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1384, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1383, + "name": "_borrowSizePercent", + "nodeType": "VariableDeclaration", + "scope": 1394, + "src": "856:26:10", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1382, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "856:7:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "855:28:10" + }, + "returnParameters": { + "id": 1387, + "nodeType": "ParameterList", + "parameters": [], + "src": "903:0:10" + }, + "scope": 1418, + "src": "814:177:10", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 1403, + "nodeType": "Block", + "src": "1247:58:10", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1400, + "name": "REBALANCE_DOWN_RATE_DELTA", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1371, + "src": "1272:25:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1399, + "name": "getUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1496, + "src": "1264:7:10", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_uint256_$", + "typeString": "function (bytes32) view returns (uint256)" + } + }, + "id": 1401, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1264:34:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1398, + "id": 1402, + "nodeType": "Return", + "src": "1257:41:10" + } + ] + }, + "documentation": "@dev returns the delta between the current fixed rate and the user fixed rate at\nwhich the borrow position of the user will be rebalanced (scaled down)", + "id": 1404, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getRebalanceDownRateDelta", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1395, + "nodeType": "ParameterList", + "parameters": [], + "src": "1212:2:10" + }, + "returnParameters": { + "id": 1398, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1397, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1404, + "src": "1238:7:10", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1396, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1238:7:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1237:9:10" + }, + "scope": 1418, + "src": "1178:127:10", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 1416, + "nodeType": "Block", + "src": "1429:67:10", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1412, + "name": "REBALANCE_DOWN_RATE_DELTA", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1371, + "src": "1455:25:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1413, + "name": "_delta", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1406, + "src": "1482:6:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 1411, + "name": "_setUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1510, + "src": "1446:8:10", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_uint256_$returns$__$", + "typeString": "function (bytes32,uint256)" + } + }, + "id": 1414, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1446:43:10", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "functionReturnParameters": 1410, + "id": 1415, + "nodeType": "Return", + "src": "1439:50:10" + } + ] + }, + "documentation": null, + "id": 1417, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 1409, + "modifierName": { + "argumentTypes": null, + "id": 1408, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "1419:9:10", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "1419:9:10" + } + ], + "name": "setRebalanceDownRateDelta", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1407, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1406, + "name": "_delta", + "nodeType": "VariableDeclaration", + "scope": 1417, + "src": "1394:14:10", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1405, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1394:7:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1393:16:10" + }, + "returnParameters": { + "id": 1410, + "nodeType": "ParameterList", + "parameters": [], + "src": "1429:0:10" + }, + "scope": 1418, + "src": "1359:137:10", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1419, + "src": "251:1248:10" + } + ], + "src": "0:1500:10" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolParametersProvider.sol", + "exportedSymbols": { + "LendingPoolParametersProvider": [ + 1418 + ] + }, + "id": 1419, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1359, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:10" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "file": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "id": 1360, + "nodeType": "ImportDirective", + "scope": 1419, + "sourceUnit": 11255, + "src": "26:63:10", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol", + "file": "./UintStorage.sol", + "id": 1361, + "nodeType": "ImportDirective", + "scope": 1419, + "sourceUnit": 1512, + "src": "90:27:10", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1362, + "name": "UintStorage", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1511, + "src": "293:11:10", + "typeDescriptions": { + "typeIdentifier": "t_contract$_UintStorage_$1511", + "typeString": "contract UintStorage" + } + }, + "id": 1363, + "nodeType": "InheritanceSpecifier", + "src": "293:11:10" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1364, + "name": "Ownable", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11254, + "src": "306:7:10", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Ownable_$11254", + "typeString": "contract Ownable" + } + }, + "id": 1365, + "nodeType": "InheritanceSpecifier", + "src": "306:7:10" + } + ], + "contractDependencies": [ + 1511, + 10953, + 11254 + ], + "contractKind": "contract", + "documentation": "@title LendingPoolParametersProvider\n@author Aave\n@notice stores the configuration parameters of the Lending Pool contract", + "fullyImplemented": true, + "id": 1418, + "linearizedBaseContracts": [ + 1418, + 11254, + 10953, + 1511 + ], + "name": "LendingPoolParametersProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": true, + "id": 1368, + "name": "MAX_FIXED_RATE_BORROW_SIZE_PERCENT", + "nodeType": "VariableDeclaration", + "scope": 1418, + "src": "320:92:10", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1366, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "320:7:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4d41585f524154455f424f52524f575f53495a455f50455243454e54", + "id": 1367, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "382:30:10", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ba4b9e7ee597651932642f8a08ef73dd0794210b0ab5eae294c6782c61c09344", + "typeString": "literal_string \"MAX_RATE_BORROW_SIZE_PERCENT\"" + }, + "value": "MAX_RATE_BORROW_SIZE_PERCENT" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1371, + "name": "REBALANCE_DOWN_RATE_DELTA", + "nodeType": "VariableDeclaration", + "scope": 1418, + "src": "418:80:10", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1369, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "418:7:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "524542414c414e43455f444f574e5f524154455f44454c5441", + "id": 1370, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "471:27:10", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ed357075eeefda3bdf24e71ab10a77c75fb9d7a2c32ed51adbe1f958ba662e79", + "typeString": "literal_string \"REBALANCE_DOWN_RATE_DELTA\"" + }, + "value": "REBALANCE_DOWN_RATE_DELTA" + }, + "visibility": "private" + }, + { + "body": { + "id": 1380, + "nodeType": "Block", + "src": "693:67:10", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1377, + "name": "MAX_FIXED_RATE_BORROW_SIZE_PERCENT", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1368, + "src": "718:34:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1376, + "name": "getUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1496, + "src": "710:7:10", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_uint256_$", + "typeString": "function (bytes32) view returns (uint256)" + } + }, + "id": 1378, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "710:43:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1375, + "id": 1379, + "nodeType": "Return", + "src": "703:50:10" + } + ] + }, + "documentation": "@dev returns the maximum fixed rate borrow size, in percentage of the available liquidity.", + "id": 1381, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getMaxFixedRateBorrowSizePercent", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1372, + "nodeType": "ParameterList", + "parameters": [], + "src": "657:2:10" + }, + "returnParameters": { + "id": 1375, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1374, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1381, + "src": "683:7:10", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1373, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "683:7:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "682:9:10" + }, + "scope": 1418, + "src": "616:144:10", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 1393, + "nodeType": "Block", + "src": "903:88:10", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1389, + "name": "MAX_FIXED_RATE_BORROW_SIZE_PERCENT", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1368, + "src": "929:34:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1390, + "name": "_borrowSizePercent", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1383, + "src": "965:18:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 1388, + "name": "_setUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1510, + "src": "920:8:10", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_uint256_$returns$__$", + "typeString": "function (bytes32,uint256)" + } + }, + "id": 1391, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "920:64:10", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "functionReturnParameters": 1387, + "id": 1392, + "nodeType": "Return", + "src": "913:71:10" + } + ] + }, + "documentation": null, + "id": 1394, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 1386, + "modifierName": { + "argumentTypes": null, + "id": 1385, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "893:9:10", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "893:9:10" + } + ], + "name": "setMaxFixedRateBorrowSizePercent", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1384, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1383, + "name": "_borrowSizePercent", + "nodeType": "VariableDeclaration", + "scope": 1394, + "src": "856:26:10", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1382, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "856:7:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "855:28:10" + }, + "returnParameters": { + "id": 1387, + "nodeType": "ParameterList", + "parameters": [], + "src": "903:0:10" + }, + "scope": 1418, + "src": "814:177:10", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 1403, + "nodeType": "Block", + "src": "1247:58:10", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1400, + "name": "REBALANCE_DOWN_RATE_DELTA", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1371, + "src": "1272:25:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1399, + "name": "getUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1496, + "src": "1264:7:10", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_uint256_$", + "typeString": "function (bytes32) view returns (uint256)" + } + }, + "id": 1401, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1264:34:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1398, + "id": 1402, + "nodeType": "Return", + "src": "1257:41:10" + } + ] + }, + "documentation": "@dev returns the delta between the current fixed rate and the user fixed rate at\nwhich the borrow position of the user will be rebalanced (scaled down)", + "id": 1404, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getRebalanceDownRateDelta", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1395, + "nodeType": "ParameterList", + "parameters": [], + "src": "1212:2:10" + }, + "returnParameters": { + "id": 1398, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1397, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1404, + "src": "1238:7:10", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1396, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1238:7:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1237:9:10" + }, + "scope": 1418, + "src": "1178:127:10", + "stateMutability": "view", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 1416, + "nodeType": "Block", + "src": "1429:67:10", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1412, + "name": "REBALANCE_DOWN_RATE_DELTA", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1371, + "src": "1455:25:10", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1413, + "name": "_delta", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1406, + "src": "1482:6:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 1411, + "name": "_setUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1510, + "src": "1446:8:10", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_uint256_$returns$__$", + "typeString": "function (bytes32,uint256)" + } + }, + "id": 1414, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1446:43:10", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "functionReturnParameters": 1410, + "id": 1415, + "nodeType": "Return", + "src": "1439:50:10" + } + ] + }, + "documentation": null, + "id": 1417, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 1409, + "modifierName": { + "argumentTypes": null, + "id": 1408, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "1419:9:10", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "1419:9:10" + } + ], + "name": "setRebalanceDownRateDelta", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1407, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1406, + "name": "_delta", + "nodeType": "VariableDeclaration", + "scope": 1417, + "src": "1394:14:10", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1405, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1394:7:10", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1393:16:10" + }, + "returnParameters": { + "id": 1410, + "nodeType": "ParameterList", + "parameters": [], + "src": "1429:0:10" + }, + "scope": 1418, + "src": "1359:137:10", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "external" + } + ], + "scope": 1419, + "src": "251:1248:10" + } + ], + "src": "0:1500:10" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.583Z", + "devdoc": { + "author": "Aave", + "methods": { + "getMaxFixedRateBorrowSizePercent()": { + "details": "returns the maximum fixed rate borrow size, in percentage of the available liquidity." + }, + "getRebalanceDownRateDelta()": { + "details": "returns the delta between the current fixed rate and the user fixed rate at which the borrow position of the user will be rebalanced (scaled down)" + }, + "isOwner()": { + "details": "Returns true if the caller is the current owner." + }, + "owner()": { + "details": "Returns the address of the current owner." + }, + "renounceOwnership()": { + "details": "Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner." + }, + "transferOwnership(address)": { + "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner." + } + }, + "title": "LendingPoolParametersProvider" + }, + "userdoc": { + "methods": {}, + "notice": "stores the configuration parameters of the Lending Pool contract" + } +} \ No newline at end of file diff --git a/client/src/contracts/LendingRateOracle.json b/client/src/contracts/LendingRateOracle.json new file mode 100644 index 0000000..c25bc81 --- /dev/null +++ b/client/src/contracts/LendingRateOracle.json @@ -0,0 +1,1603 @@ +{ + "contractName": "LendingRateOracle", + "abi": [ + { + "constant": true, + "inputs": [ + { + "name": "_asset", + "type": "address" + } + ], + "name": "getMarketBorrowRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_asset", + "type": "address" + }, + { + "name": "_rate", + "type": "uint256" + } + ], + "name": "setMarketBorrowRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_asset", + "type": "address" + } + ], + "name": "getMarketLiquidityRate", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_asset", + "type": "address" + }, + { + "name": "_rate", + "type": "uint256" + } + ], + "name": "setMarketLiquidityRate", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"},{\"name\":\"_rate\",\"type\":\"uint256\"}],\"name\":\"setMarketBorrowRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"},{\"name\":\"_rate\",\"type\":\"uint256\"}],\"name\":\"setMarketLiquidityRate\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"}],\"name\":\"getMarketBorrowRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"}],\"name\":\"getMarketLiquidityRate\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/Oracle/LendingRateOracle.sol\":\"LendingRateOracle\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":{\"keccak256\":\"0xeeae2b67fa36103fe1c3a4e346b9c04171f9065949953abd00104c357834b0e3\",\"urls\":[\"bzzr://4e3bd29abfa796726532c3e42dd8039ab0f93388d7bbf358428dbc9b0399664a\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/Oracle/LendingRateOracle.sol\":{\"keccak256\":\"0xb69c8d358db7148465ff44ead9574d240414f7978497ab357fd00a51ced843f5\",\"urls\":[\"bzzr://595c726023382e7fbacdafa00dd5589d68cab82a3045f95ca384aa01e05bdfc8\"]}},\"version\":1}", + "bytecode": "0x608060405234801561001057600080fd5b506102e9806100206000396000f3fe608060405234801561001057600080fd5b506004361061004c5760003560e01c806372eb293d146100515780639f86a0ee1461009f578063bb85c0bb146100ed578063fbe5ba1e14610145575b600080fd5b61009d6004803603604081101561006757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061019d565b005b6100eb600480360360408110156100b557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506101e4565b005b61012f6004803603602081101561010357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061022c565b6040518082815260200191505060405180910390f35b6101876004803603602081101561015b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610274565b6040518082815260200191505060405180910390f35b806000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505050565b80600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b6000600160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905091905056fea165627a7a72305820f72f45c6e7589a487040b277c8a7aac1ac792c7e99baadd1404044f3d9983d320029", + "deployedBytecode": "0x608060405234801561001057600080fd5b506004361061004c5760003560e01c806372eb293d146100515780639f86a0ee1461009f578063bb85c0bb146100ed578063fbe5ba1e14610145575b600080fd5b61009d6004803603604081101561006757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061019d565b005b6100eb600480360360408110156100b557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506101e4565b005b61012f6004803603602081101561010357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061022c565b6040518082815260200191505060405180910390f35b6101876004803603602081101561015b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610274565b6040518082815260200191505060405180910390f35b806000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505050565b80600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b6000600160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905091905056fea165627a7a72305820f72f45c6e7589a487040b277c8a7aac1ac792c7e99baadd1404044f3d9983d320029", + "sourceMap": "77:629:32:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;77:629:32;;;;;;;", + "deployedSourceMap": "77:629:32:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;77:629:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;344:110;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;344:110:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;588:116;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;588:116:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;222;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;222:116:32;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;460:122;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;460:122:32;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;344:110;442:5;420:11;:19;432:6;420:19;;;;;;;;;;;;;;;:27;;;;344:110;;:::o;588:116::-;692:5;667:14;:22;682:6;667:22;;;;;;;;;;;;;;;:30;;;;588:116;;:::o;222:::-;289:4;312:11;:19;324:6;312:19;;;;;;;;;;;;;;;;305:26;;222:116;;;:::o;460:122::-;530:4;553:14;:22;568:6;553:22;;;;;;;;;;;;;;;;546:29;;460:122;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"../../interfaces/ILendingRateOracle.sol\";\n\n\ncontract LendingRateOracle is ILendingRateOracle {\n\n mapping(address => uint) borrowRates;\n mapping(address => uint) liquidityRates;\n\n\n function getMarketBorrowRate(address _asset) external view returns(uint) {\n return borrowRates[_asset];\n }\n\n function setMarketBorrowRate(address _asset, uint _rate) external {\n borrowRates[_asset] = _rate;\n }\n\n function getMarketLiquidityRate(address _asset) external view returns(uint) {\n return liquidityRates[_asset];\n }\n\n function setMarketLiquidityRate(address _asset, uint _rate) external {\n liquidityRates[_asset] = _rate;\n }\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/Oracle/LendingRateOracle.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/Oracle/LendingRateOracle.sol", + "exportedSymbols": { + "LendingRateOracle": [ + 9521 + ] + }, + "id": 9522, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9457, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:32" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol", + "file": "../../interfaces/ILendingRateOracle.sol", + "id": 9458, + "nodeType": "ImportDirective", + "scope": 9522, + "sourceUnit": 1910, + "src": "25:49:32", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9459, + "name": "ILendingRateOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1909, + "src": "107:18:32", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "id": 9460, + "nodeType": "InheritanceSpecifier", + "src": "107:18:32" + } + ], + "contractDependencies": [ + 1909 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9521, + "linearizedBaseContracts": [ + 9521, + 1909 + ], + "name": "LendingRateOracle", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9464, + "name": "borrowRates", + "nodeType": "VariableDeclaration", + "scope": 9521, + "src": "133:36:32", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "typeName": { + "id": 9463, + "keyType": { + "id": 9461, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "141:7:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "133:24:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "valueType": { + "id": 9462, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "152:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9468, + "name": "liquidityRates", + "nodeType": "VariableDeclaration", + "scope": 9521, + "src": "175:39:32", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "typeName": { + "id": 9467, + "keyType": { + "id": 9465, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "183:7:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "175:24:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "valueType": { + "id": 9466, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "194:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 9479, + "nodeType": "Block", + "src": "295:43:32", + "statements": [ + { + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9475, + "name": "borrowRates", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9464, + "src": "312:11:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9477, + "indexExpression": { + "argumentTypes": null, + "id": 9476, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9470, + "src": "324:6:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "312:19:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9474, + "id": 9478, + "nodeType": "Return", + "src": "305:26:32" + } + ] + }, + "documentation": null, + "id": 9480, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getMarketBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9471, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9470, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9480, + "src": "251:14:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9469, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "251:7:32", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "250:16:32" + }, + "returnParameters": { + "id": 9474, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9473, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9480, + "src": "289:4:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9472, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "289:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "288:6:32" + }, + "scope": 9521, + "src": "222:116:32", + "stateMutability": "view", + "superFunction": 1887, + "visibility": "external" + }, + { + "body": { + "id": 9493, + "nodeType": "Block", + "src": "410:44:32", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9491, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9487, + "name": "borrowRates", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9464, + "src": "420:11:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9489, + "indexExpression": { + "argumentTypes": null, + "id": 9488, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9482, + "src": "432:6:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "420:19:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9490, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9484, + "src": "442:5:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "420:27:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9492, + "nodeType": "ExpressionStatement", + "src": "420:27:32" + } + ] + }, + "documentation": null, + "id": 9494, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setMarketBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9485, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9482, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9494, + "src": "373:14:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9481, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "373:7:32", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9484, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 9494, + "src": "389:10:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9483, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "389:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "372:28:32" + }, + "returnParameters": { + "id": 9486, + "nodeType": "ParameterList", + "parameters": [], + "src": "410:0:32" + }, + "scope": 9521, + "src": "344:110:32", + "stateMutability": "nonpayable", + "superFunction": 1894, + "visibility": "external" + }, + { + "body": { + "id": 9505, + "nodeType": "Block", + "src": "536:46:32", + "statements": [ + { + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9501, + "name": "liquidityRates", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9468, + "src": "553:14:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9503, + "indexExpression": { + "argumentTypes": null, + "id": 9502, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9496, + "src": "568:6:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "553:22:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9500, + "id": 9504, + "nodeType": "Return", + "src": "546:29:32" + } + ] + }, + "documentation": null, + "id": 9506, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getMarketLiquidityRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9497, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9496, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9506, + "src": "492:14:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9495, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "492:7:32", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "491:16:32" + }, + "returnParameters": { + "id": 9500, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9499, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9506, + "src": "530:4:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9498, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "530:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "529:6:32" + }, + "scope": 9521, + "src": "460:122:32", + "stateMutability": "view", + "superFunction": 1901, + "visibility": "external" + }, + { + "body": { + "id": 9519, + "nodeType": "Block", + "src": "657:47:32", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9517, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9513, + "name": "liquidityRates", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9468, + "src": "667:14:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9515, + "indexExpression": { + "argumentTypes": null, + "id": 9514, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9508, + "src": "682:6:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "667:22:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9516, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9510, + "src": "692:5:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "667:30:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9518, + "nodeType": "ExpressionStatement", + "src": "667:30:32" + } + ] + }, + "documentation": null, + "id": 9520, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setMarketLiquidityRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9511, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9508, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9520, + "src": "620:14:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9507, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "620:7:32", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9510, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 9520, + "src": "636:10:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9509, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "636:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "619:28:32" + }, + "returnParameters": { + "id": 9512, + "nodeType": "ParameterList", + "parameters": [], + "src": "657:0:32" + }, + "scope": 9521, + "src": "588:116:32", + "stateMutability": "nonpayable", + "superFunction": 1908, + "visibility": "external" + } + ], + "scope": 9522, + "src": "77:629:32" + } + ], + "src": "0:706:32" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/Oracle/LendingRateOracle.sol", + "exportedSymbols": { + "LendingRateOracle": [ + 9521 + ] + }, + "id": 9522, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9457, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:32" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol", + "file": "../../interfaces/ILendingRateOracle.sol", + "id": 9458, + "nodeType": "ImportDirective", + "scope": 9522, + "sourceUnit": 1910, + "src": "25:49:32", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9459, + "name": "ILendingRateOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1909, + "src": "107:18:32", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingRateOracle_$1909", + "typeString": "contract ILendingRateOracle" + } + }, + "id": 9460, + "nodeType": "InheritanceSpecifier", + "src": "107:18:32" + } + ], + "contractDependencies": [ + 1909 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9521, + "linearizedBaseContracts": [ + 9521, + 1909 + ], + "name": "LendingRateOracle", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9464, + "name": "borrowRates", + "nodeType": "VariableDeclaration", + "scope": 9521, + "src": "133:36:32", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "typeName": { + "id": 9463, + "keyType": { + "id": 9461, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "141:7:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "133:24:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "valueType": { + "id": 9462, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "152:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9468, + "name": "liquidityRates", + "nodeType": "VariableDeclaration", + "scope": 9521, + "src": "175:39:32", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "typeName": { + "id": 9467, + "keyType": { + "id": 9465, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "183:7:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "175:24:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "valueType": { + "id": 9466, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "194:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 9479, + "nodeType": "Block", + "src": "295:43:32", + "statements": [ + { + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9475, + "name": "borrowRates", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9464, + "src": "312:11:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9477, + "indexExpression": { + "argumentTypes": null, + "id": 9476, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9470, + "src": "324:6:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "312:19:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9474, + "id": 9478, + "nodeType": "Return", + "src": "305:26:32" + } + ] + }, + "documentation": null, + "id": 9480, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getMarketBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9471, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9470, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9480, + "src": "251:14:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9469, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "251:7:32", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "250:16:32" + }, + "returnParameters": { + "id": 9474, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9473, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9480, + "src": "289:4:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9472, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "289:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "288:6:32" + }, + "scope": 9521, + "src": "222:116:32", + "stateMutability": "view", + "superFunction": 1887, + "visibility": "external" + }, + { + "body": { + "id": 9493, + "nodeType": "Block", + "src": "410:44:32", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9491, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9487, + "name": "borrowRates", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9464, + "src": "420:11:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9489, + "indexExpression": { + "argumentTypes": null, + "id": 9488, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9482, + "src": "432:6:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "420:19:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9490, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9484, + "src": "442:5:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "420:27:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9492, + "nodeType": "ExpressionStatement", + "src": "420:27:32" + } + ] + }, + "documentation": null, + "id": 9494, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setMarketBorrowRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9485, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9482, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9494, + "src": "373:14:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9481, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "373:7:32", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9484, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 9494, + "src": "389:10:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9483, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "389:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "372:28:32" + }, + "returnParameters": { + "id": 9486, + "nodeType": "ParameterList", + "parameters": [], + "src": "410:0:32" + }, + "scope": 9521, + "src": "344:110:32", + "stateMutability": "nonpayable", + "superFunction": 1894, + "visibility": "external" + }, + { + "body": { + "id": 9505, + "nodeType": "Block", + "src": "536:46:32", + "statements": [ + { + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9501, + "name": "liquidityRates", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9468, + "src": "553:14:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9503, + "indexExpression": { + "argumentTypes": null, + "id": 9502, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9496, + "src": "568:6:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "553:22:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9500, + "id": 9504, + "nodeType": "Return", + "src": "546:29:32" + } + ] + }, + "documentation": null, + "id": 9506, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getMarketLiquidityRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9497, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9496, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9506, + "src": "492:14:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9495, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "492:7:32", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "491:16:32" + }, + "returnParameters": { + "id": 9500, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9499, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9506, + "src": "530:4:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9498, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "530:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "529:6:32" + }, + "scope": 9521, + "src": "460:122:32", + "stateMutability": "view", + "superFunction": 1901, + "visibility": "external" + }, + { + "body": { + "id": 9519, + "nodeType": "Block", + "src": "657:47:32", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9517, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9513, + "name": "liquidityRates", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9468, + "src": "667:14:32", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9515, + "indexExpression": { + "argumentTypes": null, + "id": 9514, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9508, + "src": "682:6:32", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "667:22:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9516, + "name": "_rate", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9510, + "src": "692:5:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "667:30:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9518, + "nodeType": "ExpressionStatement", + "src": "667:30:32" + } + ] + }, + "documentation": null, + "id": 9520, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setMarketLiquidityRate", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9511, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9508, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9520, + "src": "620:14:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9507, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "620:7:32", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9510, + "name": "_rate", + "nodeType": "VariableDeclaration", + "scope": 9520, + "src": "636:10:32", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9509, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "636:4:32", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "619:28:32" + }, + "returnParameters": { + "id": 9512, + "nodeType": "ParameterList", + "parameters": [], + "src": "657:0:32" + }, + "scope": 9521, + "src": "588:116:32", + "stateMutability": "nonpayable", + "superFunction": 1908, + "visibility": "external" + } + ], + "scope": 9522, + "src": "77:629:32" + } + ], + "src": "0:706:32" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.857Z", + "devdoc": { + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/Migrations.json b/client/src/contracts/Migrations.json index 0393d31..97ee4a4 100644 --- a/client/src/contracts/Migrations.json +++ b/client/src/contracts/Migrations.json @@ -67,22 +67,22 @@ "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"new_address\",\"type\":\"address\"}],\"name\":\"upgrade\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"last_completed_migration\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"completed\",\"type\":\"uint256\"}],\"name\":\"setCompleted\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/Migrations.sol\":\"Migrations\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/Migrations.sol\":{\"keccak256\":\"0xf65fcb01f4b8ef6909f55bccf7f05ab483d953e671e205d9ce8ea6a9adc3c653\",\"urls\":[\"bzzr://ea0687984a75ca6b8aa89a3ba439fa3123a53421a5b5474320c74ad1174583fc\"]}},\"version\":1}", "bytecode": "0x608060405234801561001057600080fd5b50336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506102ae806100606000396000f3fe608060405234801561001057600080fd5b506004361061004c5760003560e01c80630900f01014610051578063445df0ac146100955780638da5cb5b146100b3578063fdacd576146100fd575b600080fd5b6100936004803603602081101561006757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061012b565b005b61009d6101f7565b6040518082815260200191505060405180910390f35b6100bb6101fd565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6101296004803603602081101561011357600080fd5b8101908080359060200190929190505050610222565b005b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614156101f45760008190508073ffffffffffffffffffffffffffffffffffffffff1663fdacd5766001546040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b1580156101da57600080fd5b505af11580156101ee573d6000803e3d6000fd5b50505050505b50565b60015481565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141561027f57806001819055505b5056fea165627a7a72305820a504a0de14f4e39cc2c6b0b2068a52ba7d1164e58b5cdc82318b62df3457865d0029", "deployedBytecode": "0x608060405234801561001057600080fd5b506004361061004c5760003560e01c80630900f01014610051578063445df0ac146100955780638da5cb5b146100b3578063fdacd576146100fd575b600080fd5b6100936004803603602081101561006757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061012b565b005b61009d6101f7565b6040518082815260200191505060405180910390f35b6100bb6101fd565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6101296004803603602081101561011357600080fd5b8101908080359060200190929190505050610222565b005b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614156101f45760008190508073ffffffffffffffffffffffffffffffffffffffff1663fdacd5766001546040518263ffffffff1660e01b815260040180828152602001915050600060405180830381600087803b1580156101da57600080fd5b505af11580156101ee573d6000803e3d6000fd5b50505050505b50565b60015481565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16141561027f57806001819055505b5056fea165627a7a72305820a504a0de14f4e39cc2c6b0b2068a52ba7d1164e58b5cdc82318b62df3457865d0029", - "sourceMap": "25:480:4:-;;;177:50;8:9:-1;5:2;;;30:1;27;20:12;5:2;177:50:4;212:10;204:5;;:18;;;;;;;;;;;;;;;;;;25:480;;;;;;", - "deployedSourceMap": "25:480:4:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;25:480:4;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;338:165;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;338:165:4;;;;;;;;;;;;;;;;;;;:::i;:::-;;73:36;;;:::i;:::-;;;;;;;;;;;;;;;;;;;49:20;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;231:103;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;231:103:4;;;;;;;;;;;;;;;;;:::i;:::-;;338:165;160:5;;;;;;;;;;;146:19;;:10;:19;;;142:26;;;400:19;433:11;400:45;;451:8;:21;;;473:24;;451:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;451:47:4;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;451:47:4;;;;167:1;142:26;338:165;:::o;73:36::-;;;;:::o;49:20::-;;;;;;;;;;;;;:::o;231:103::-;160:5;;;;;;;;;;;146:19;;:10;:19;;;142:26;;;320:9;293:24;:36;;;;142:26;231:103;:::o", + "sourceMap": "25:480:5:-;;;177:50;8:9:-1;5:2;;;30:1;27;20:12;5:2;177:50:5;212:10;204:5;;:18;;;;;;;;;;;;;;;;;;25:480;;;;;;", + "deployedSourceMap": "25:480:5:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;25:480:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;338:165;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;338:165:5;;;;;;;;;;;;;;;;;;;:::i;:::-;;73:36;;;:::i;:::-;;;;;;;;;;;;;;;;;;;49:20;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;231:103;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;231:103:5;;;;;;;;;;;;;;;;;:::i;:::-;;338:165;160:5;;;;;;;;;;;146:19;;:10;:19;;;142:26;;;400:19;433:11;400:45;;451:8;:21;;;473:24;;451:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;451:47:5;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;451:47:5;;;;167:1;142:26;338:165;:::o;73:36::-;;;;:::o;49:20::-;;;;;;;;;;;;;:::o;231:103::-;160:5;;;;;;;;;;;146:19;;:10;:19;;;142:26;;;320:9;293:24;:36;;;;142:26;231:103;:::o", "source": "pragma solidity ^0.5.0;\n\ncontract Migrations {\n address public owner;\n uint public last_completed_migration;\n\n modifier restricted() {\n if (msg.sender == owner) _;\n }\n\n constructor() public {\n owner = msg.sender;\n }\n\n function setCompleted(uint completed) public restricted {\n last_completed_migration = completed;\n }\n\n function upgrade(address new_address) public restricted {\n Migrations upgraded = Migrations(new_address);\n upgraded.setCompleted(last_completed_migration);\n }\n}\n", "sourcePath": "/Users/jg/Documents/aaveBot/contracts/Migrations.sol", "ast": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/Migrations.sol", "exportedSymbols": { "Migrations": [ - 538 + 614 ] }, - "id": 539, + "id": 615, "nodeType": "SourceUnit", "nodes": [ { - "id": 483, + "id": 559, "literals": [ "solidity", "^", @@ -90,7 +90,7 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:4" + "src": "0:23:5" }, { "baseContracts": [], @@ -98,20 +98,20 @@ "contractKind": "contract", "documentation": null, "fullyImplemented": true, - "id": 538, + "id": 614, "linearizedBaseContracts": [ - 538 + 614 ], "name": "Migrations", "nodeType": "ContractDefinition", "nodes": [ { "constant": false, - "id": 485, + "id": 561, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 538, - "src": "49:20:4", + "scope": 614, + "src": "49:20:5", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -119,10 +119,10 @@ "typeString": "address" }, "typeName": { - "id": 484, + "id": 560, "name": "address", "nodeType": "ElementaryTypeName", - "src": "49:7:4", + "src": "49:7:5", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -134,11 +134,11 @@ }, { "constant": false, - "id": 487, + "id": 563, "name": "last_completed_migration", "nodeType": "VariableDeclaration", - "scope": 538, - "src": "73:36:4", + "scope": 614, + "src": "73:36:5", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -146,10 +146,10 @@ "typeString": "uint256" }, "typeName": { - "id": 486, + "id": 562, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "73:4:4", + "src": "73:4:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -160,9 +160,9 @@ }, { "body": { - "id": 495, + "id": 571, "nodeType": "Block", - "src": "136:37:4", + "src": "136:37:5", "statements": [ { "condition": { @@ -171,7 +171,7 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 492, + "id": 568, "isConstant": false, "isLValue": false, "isPure": false, @@ -180,18 +180,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 489, + "id": 565, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "146:3:4", + "referencedDeclaration": 12128, + "src": "146:3:5", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 490, + "id": 566, "isConstant": false, "isLValue": false, "isPure": false, @@ -199,7 +199,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "146:10:4", + "src": "146:10:5", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -209,70 +209,70 @@ "operator": "==", "rightExpression": { "argumentTypes": null, - "id": 491, + "id": 567, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 485, - "src": "160:5:4", + "referencedDeclaration": 561, + "src": "160:5:5", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "src": "146:19:4", + "src": "146:19:5", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "falseBody": null, - "id": 494, + "id": 570, "nodeType": "IfStatement", - "src": "142:26:4", + "src": "142:26:5", "trueBody": { - "id": 493, + "id": 569, "nodeType": "PlaceholderStatement", - "src": "167:1:4" + "src": "167:1:5" } } ] }, "documentation": null, - "id": 496, + "id": 572, "name": "restricted", "nodeType": "ModifierDefinition", "parameters": { - "id": 488, + "id": 564, "nodeType": "ParameterList", "parameters": [], - "src": "133:2:4" + "src": "133:2:5" }, - "src": "114:59:4", + "src": "114:59:5", "visibility": "internal" }, { "body": { - "id": 504, + "id": 580, "nodeType": "Block", - "src": "198:29:4", + "src": "198:29:5", "statements": [ { "expression": { "argumentTypes": null, - "id": 502, + "id": 578, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 499, + "id": 575, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 485, - "src": "204:5:4", + "referencedDeclaration": 561, + "src": "204:5:5", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -284,18 +284,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 500, + "id": 576, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "212:3:4", + "referencedDeclaration": 12128, + "src": "212:3:5", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 501, + "id": 577, "isConstant": false, "isLValue": false, "isPure": false, @@ -303,71 +303,71 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "212:10:4", + "src": "212:10:5", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "204:18:4", + "src": "204:18:5", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 503, + "id": 579, "nodeType": "ExpressionStatement", - "src": "204:18:4" + "src": "204:18:5" } ] }, "documentation": null, - "id": 505, + "id": 581, "implemented": true, "kind": "constructor", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "parameters": { - "id": 497, + "id": 573, "nodeType": "ParameterList", "parameters": [], - "src": "188:2:4" + "src": "188:2:5" }, "returnParameters": { - "id": 498, + "id": 574, "nodeType": "ParameterList", "parameters": [], - "src": "198:0:4" + "src": "198:0:5" }, - "scope": 538, - "src": "177:50:4", + "scope": 614, + "src": "177:50:5", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 516, + "id": 592, "nodeType": "Block", - "src": "287:47:4", + "src": "287:47:5", "statements": [ { "expression": { "argumentTypes": null, - "id": 514, + "id": 590, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 512, + "id": 588, "name": "last_completed_migration", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 487, - "src": "293:24:4", + "referencedDeclaration": 563, + "src": "293:24:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -377,67 +377,67 @@ "operator": "=", "rightHandSide": { "argumentTypes": null, - "id": 513, + "id": 589, "name": "completed", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 507, - "src": "320:9:4", + "referencedDeclaration": 583, + "src": "320:9:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "293:36:4", + "src": "293:36:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 515, + "id": 591, "nodeType": "ExpressionStatement", - "src": "293:36:4" + "src": "293:36:5" } ] }, "documentation": null, - "id": 517, + "id": 593, "implemented": true, "kind": "function", "modifiers": [ { "arguments": null, - "id": 510, + "id": 586, "modifierName": { "argumentTypes": null, - "id": 509, + "id": 585, "name": "restricted", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 496, - "src": "276:10:4", + "referencedDeclaration": 572, + "src": "276:10:5", "typeDescriptions": { "typeIdentifier": "t_modifier$__$", "typeString": "modifier ()" } }, "nodeType": "ModifierInvocation", - "src": "276:10:4" + "src": "276:10:5" } ], "name": "setCompleted", "nodeType": "FunctionDefinition", "parameters": { - "id": 508, + "id": 584, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 507, + "id": 583, "name": "completed", "nodeType": "VariableDeclaration", - "scope": 517, - "src": "253:14:4", + "scope": 593, + "src": "253:14:5", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -445,10 +445,10 @@ "typeString": "uint256" }, "typeName": { - "id": 506, + "id": 582, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "253:4:4", + "src": "253:4:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -458,53 +458,53 @@ "visibility": "internal" } ], - "src": "252:16:4" + "src": "252:16:5" }, "returnParameters": { - "id": 511, + "id": 587, "nodeType": "ParameterList", "parameters": [], - "src": "287:0:4" + "src": "287:0:5" }, - "scope": 538, - "src": "231:103:4", + "scope": 614, + "src": "231:103:5", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 536, + "id": 612, "nodeType": "Block", - "src": "394:109:4", + "src": "394:109:5", "statements": [ { "assignments": [ - 525 + 601 ], "declarations": [ { "constant": false, - "id": 525, + "id": 601, "name": "upgraded", "nodeType": "VariableDeclaration", - "scope": 536, - "src": "400:19:4", + "scope": 612, + "src": "400:19:5", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_Migrations_$538", + "typeIdentifier": "t_contract$_Migrations_$614", "typeString": "contract Migrations" }, "typeName": { "contractScope": null, - "id": 524, + "id": 600, "name": "Migrations", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 538, - "src": "400:10:4", + "referencedDeclaration": 614, + "src": "400:10:5", "typeDescriptions": { - "typeIdentifier": "t_contract$_Migrations_$538", + "typeIdentifier": "t_contract$_Migrations_$614", "typeString": "contract Migrations" } }, @@ -512,18 +512,18 @@ "visibility": "internal" } ], - "id": 529, + "id": 605, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 527, + "id": 603, "name": "new_address", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 519, - "src": "433:11:4", + "referencedDeclaration": 595, + "src": "433:11:5", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -537,18 +537,18 @@ "typeString": "address" } ], - "id": 526, + "id": 602, "name": "Migrations", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 538, - "src": "422:10:4", + "referencedDeclaration": 614, + "src": "422:10:5", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_Migrations_$538_$", + "typeIdentifier": "t_type$_t_contract$_Migrations_$614_$", "typeString": "type(contract Migrations)" } }, - "id": 528, + "id": 604, "isConstant": false, "isLValue": false, "isPure": false, @@ -556,14 +556,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "422:23:4", + "src": "422:23:5", "typeDescriptions": { - "typeIdentifier": "t_contract$_Migrations_$538", + "typeIdentifier": "t_contract$_Migrations_$614", "typeString": "contract Migrations" } }, "nodeType": "VariableDeclarationStatement", - "src": "400:45:4" + "src": "400:45:5" }, { "expression": { @@ -571,12 +571,12 @@ "arguments": [ { "argumentTypes": null, - "id": 533, + "id": 609, "name": "last_completed_migration", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 487, - "src": "473:24:4", + "referencedDeclaration": 563, + "src": "473:24:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -592,32 +592,32 @@ ], "expression": { "argumentTypes": null, - "id": 530, + "id": 606, "name": "upgraded", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 525, - "src": "451:8:4", + "referencedDeclaration": 601, + "src": "451:8:5", "typeDescriptions": { - "typeIdentifier": "t_contract$_Migrations_$538", + "typeIdentifier": "t_contract$_Migrations_$614", "typeString": "contract Migrations" } }, - "id": 532, + "id": 608, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "setCompleted", "nodeType": "MemberAccess", - "referencedDeclaration": 517, - "src": "451:21:4", + "referencedDeclaration": 593, + "src": "451:21:5", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$returns$__$", "typeString": "function (uint256) external" } }, - "id": 534, + "id": 610, "isConstant": false, "isLValue": false, "isPure": false, @@ -625,56 +625,56 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "451:47:4", + "src": "451:47:5", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 535, + "id": 611, "nodeType": "ExpressionStatement", - "src": "451:47:4" + "src": "451:47:5" } ] }, "documentation": null, - "id": 537, + "id": 613, "implemented": true, "kind": "function", "modifiers": [ { "arguments": null, - "id": 522, + "id": 598, "modifierName": { "argumentTypes": null, - "id": 521, + "id": 597, "name": "restricted", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 496, - "src": "383:10:4", + "referencedDeclaration": 572, + "src": "383:10:5", "typeDescriptions": { "typeIdentifier": "t_modifier$__$", "typeString": "modifier ()" } }, "nodeType": "ModifierInvocation", - "src": "383:10:4" + "src": "383:10:5" } ], "name": "upgrade", "nodeType": "FunctionDefinition", "parameters": { - "id": 520, + "id": 596, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 519, + "id": 595, "name": "new_address", "nodeType": "VariableDeclaration", - "scope": 537, - "src": "355:19:4", + "scope": 613, + "src": "355:19:5", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -682,10 +682,10 @@ "typeString": "address" }, "typeName": { - "id": 518, + "id": 594, "name": "address", "nodeType": "ElementaryTypeName", - "src": "355:7:4", + "src": "355:7:5", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -696,39 +696,39 @@ "visibility": "internal" } ], - "src": "354:21:4" + "src": "354:21:5" }, "returnParameters": { - "id": 523, + "id": 599, "nodeType": "ParameterList", "parameters": [], - "src": "394:0:4" + "src": "394:0:5" }, - "scope": 538, - "src": "338:165:4", + "scope": 614, + "src": "338:165:5", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" } ], - "scope": 539, - "src": "25:480:4" + "scope": 615, + "src": "25:480:5" } ], - "src": "0:506:4" + "src": "0:506:5" }, "legacyAST": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/Migrations.sol", "exportedSymbols": { "Migrations": [ - 538 + 614 ] }, - "id": 539, + "id": 615, "nodeType": "SourceUnit", "nodes": [ { - "id": 483, + "id": 559, "literals": [ "solidity", "^", @@ -736,7 +736,7 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:4" + "src": "0:23:5" }, { "baseContracts": [], @@ -744,20 +744,20 @@ "contractKind": "contract", "documentation": null, "fullyImplemented": true, - "id": 538, + "id": 614, "linearizedBaseContracts": [ - 538 + 614 ], "name": "Migrations", "nodeType": "ContractDefinition", "nodes": [ { "constant": false, - "id": 485, + "id": 561, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 538, - "src": "49:20:4", + "scope": 614, + "src": "49:20:5", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -765,10 +765,10 @@ "typeString": "address" }, "typeName": { - "id": 484, + "id": 560, "name": "address", "nodeType": "ElementaryTypeName", - "src": "49:7:4", + "src": "49:7:5", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -780,11 +780,11 @@ }, { "constant": false, - "id": 487, + "id": 563, "name": "last_completed_migration", "nodeType": "VariableDeclaration", - "scope": 538, - "src": "73:36:4", + "scope": 614, + "src": "73:36:5", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -792,10 +792,10 @@ "typeString": "uint256" }, "typeName": { - "id": 486, + "id": 562, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "73:4:4", + "src": "73:4:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -806,9 +806,9 @@ }, { "body": { - "id": 495, + "id": 571, "nodeType": "Block", - "src": "136:37:4", + "src": "136:37:5", "statements": [ { "condition": { @@ -817,7 +817,7 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 492, + "id": 568, "isConstant": false, "isLValue": false, "isPure": false, @@ -826,18 +826,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 489, + "id": 565, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "146:3:4", + "referencedDeclaration": 12128, + "src": "146:3:5", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 490, + "id": 566, "isConstant": false, "isLValue": false, "isPure": false, @@ -845,7 +845,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "146:10:4", + "src": "146:10:5", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -855,70 +855,70 @@ "operator": "==", "rightExpression": { "argumentTypes": null, - "id": 491, + "id": 567, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 485, - "src": "160:5:4", + "referencedDeclaration": 561, + "src": "160:5:5", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "src": "146:19:4", + "src": "146:19:5", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "falseBody": null, - "id": 494, + "id": 570, "nodeType": "IfStatement", - "src": "142:26:4", + "src": "142:26:5", "trueBody": { - "id": 493, + "id": 569, "nodeType": "PlaceholderStatement", - "src": "167:1:4" + "src": "167:1:5" } } ] }, "documentation": null, - "id": 496, + "id": 572, "name": "restricted", "nodeType": "ModifierDefinition", "parameters": { - "id": 488, + "id": 564, "nodeType": "ParameterList", "parameters": [], - "src": "133:2:4" + "src": "133:2:5" }, - "src": "114:59:4", + "src": "114:59:5", "visibility": "internal" }, { "body": { - "id": 504, + "id": 580, "nodeType": "Block", - "src": "198:29:4", + "src": "198:29:5", "statements": [ { "expression": { "argumentTypes": null, - "id": 502, + "id": 578, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 499, + "id": 575, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 485, - "src": "204:5:4", + "referencedDeclaration": 561, + "src": "204:5:5", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -930,18 +930,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 500, + "id": 576, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "212:3:4", + "referencedDeclaration": 12128, + "src": "212:3:5", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 501, + "id": 577, "isConstant": false, "isLValue": false, "isPure": false, @@ -949,71 +949,71 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "212:10:4", + "src": "212:10:5", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "204:18:4", + "src": "204:18:5", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 503, + "id": 579, "nodeType": "ExpressionStatement", - "src": "204:18:4" + "src": "204:18:5" } ] }, "documentation": null, - "id": 505, + "id": 581, "implemented": true, "kind": "constructor", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "parameters": { - "id": 497, + "id": 573, "nodeType": "ParameterList", "parameters": [], - "src": "188:2:4" + "src": "188:2:5" }, "returnParameters": { - "id": 498, + "id": 574, "nodeType": "ParameterList", "parameters": [], - "src": "198:0:4" + "src": "198:0:5" }, - "scope": 538, - "src": "177:50:4", + "scope": 614, + "src": "177:50:5", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 516, + "id": 592, "nodeType": "Block", - "src": "287:47:4", + "src": "287:47:5", "statements": [ { "expression": { "argumentTypes": null, - "id": 514, + "id": 590, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 512, + "id": 588, "name": "last_completed_migration", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 487, - "src": "293:24:4", + "referencedDeclaration": 563, + "src": "293:24:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1023,67 +1023,67 @@ "operator": "=", "rightHandSide": { "argumentTypes": null, - "id": 513, + "id": 589, "name": "completed", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 507, - "src": "320:9:4", + "referencedDeclaration": 583, + "src": "320:9:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "293:36:4", + "src": "293:36:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "id": 515, + "id": 591, "nodeType": "ExpressionStatement", - "src": "293:36:4" + "src": "293:36:5" } ] }, "documentation": null, - "id": 517, + "id": 593, "implemented": true, "kind": "function", "modifiers": [ { "arguments": null, - "id": 510, + "id": 586, "modifierName": { "argumentTypes": null, - "id": 509, + "id": 585, "name": "restricted", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 496, - "src": "276:10:4", + "referencedDeclaration": 572, + "src": "276:10:5", "typeDescriptions": { "typeIdentifier": "t_modifier$__$", "typeString": "modifier ()" } }, "nodeType": "ModifierInvocation", - "src": "276:10:4" + "src": "276:10:5" } ], "name": "setCompleted", "nodeType": "FunctionDefinition", "parameters": { - "id": 508, + "id": 584, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 507, + "id": 583, "name": "completed", "nodeType": "VariableDeclaration", - "scope": 517, - "src": "253:14:4", + "scope": 593, + "src": "253:14:5", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1091,10 +1091,10 @@ "typeString": "uint256" }, "typeName": { - "id": 506, + "id": 582, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "253:4:4", + "src": "253:4:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1104,53 +1104,53 @@ "visibility": "internal" } ], - "src": "252:16:4" + "src": "252:16:5" }, "returnParameters": { - "id": 511, + "id": 587, "nodeType": "ParameterList", "parameters": [], - "src": "287:0:4" + "src": "287:0:5" }, - "scope": 538, - "src": "231:103:4", + "scope": 614, + "src": "231:103:5", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 536, + "id": 612, "nodeType": "Block", - "src": "394:109:4", + "src": "394:109:5", "statements": [ { "assignments": [ - 525 + 601 ], "declarations": [ { "constant": false, - "id": 525, + "id": 601, "name": "upgraded", "nodeType": "VariableDeclaration", - "scope": 536, - "src": "400:19:4", + "scope": 612, + "src": "400:19:5", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_Migrations_$538", + "typeIdentifier": "t_contract$_Migrations_$614", "typeString": "contract Migrations" }, "typeName": { "contractScope": null, - "id": 524, + "id": 600, "name": "Migrations", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 538, - "src": "400:10:4", + "referencedDeclaration": 614, + "src": "400:10:5", "typeDescriptions": { - "typeIdentifier": "t_contract$_Migrations_$538", + "typeIdentifier": "t_contract$_Migrations_$614", "typeString": "contract Migrations" } }, @@ -1158,18 +1158,18 @@ "visibility": "internal" } ], - "id": 529, + "id": 605, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 527, + "id": 603, "name": "new_address", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 519, - "src": "433:11:4", + "referencedDeclaration": 595, + "src": "433:11:5", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1183,18 +1183,18 @@ "typeString": "address" } ], - "id": 526, + "id": 602, "name": "Migrations", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 538, - "src": "422:10:4", + "referencedDeclaration": 614, + "src": "422:10:5", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_Migrations_$538_$", + "typeIdentifier": "t_type$_t_contract$_Migrations_$614_$", "typeString": "type(contract Migrations)" } }, - "id": 528, + "id": 604, "isConstant": false, "isLValue": false, "isPure": false, @@ -1202,14 +1202,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "422:23:4", + "src": "422:23:5", "typeDescriptions": { - "typeIdentifier": "t_contract$_Migrations_$538", + "typeIdentifier": "t_contract$_Migrations_$614", "typeString": "contract Migrations" } }, "nodeType": "VariableDeclarationStatement", - "src": "400:45:4" + "src": "400:45:5" }, { "expression": { @@ -1217,12 +1217,12 @@ "arguments": [ { "argumentTypes": null, - "id": 533, + "id": 609, "name": "last_completed_migration", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 487, - "src": "473:24:4", + "referencedDeclaration": 563, + "src": "473:24:5", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1238,32 +1238,32 @@ ], "expression": { "argumentTypes": null, - "id": 530, + "id": 606, "name": "upgraded", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 525, - "src": "451:8:4", + "referencedDeclaration": 601, + "src": "451:8:5", "typeDescriptions": { - "typeIdentifier": "t_contract$_Migrations_$538", + "typeIdentifier": "t_contract$_Migrations_$614", "typeString": "contract Migrations" } }, - "id": 532, + "id": 608, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "setCompleted", "nodeType": "MemberAccess", - "referencedDeclaration": 517, - "src": "451:21:4", + "referencedDeclaration": 593, + "src": "451:21:5", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$returns$__$", "typeString": "function (uint256) external" } }, - "id": 534, + "id": 610, "isConstant": false, "isLValue": false, "isPure": false, @@ -1271,56 +1271,56 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "451:47:4", + "src": "451:47:5", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 535, + "id": 611, "nodeType": "ExpressionStatement", - "src": "451:47:4" + "src": "451:47:5" } ] }, "documentation": null, - "id": 537, + "id": 613, "implemented": true, "kind": "function", "modifiers": [ { "arguments": null, - "id": 522, + "id": 598, "modifierName": { "argumentTypes": null, - "id": 521, + "id": 597, "name": "restricted", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 496, - "src": "383:10:4", + "referencedDeclaration": 572, + "src": "383:10:5", "typeDescriptions": { "typeIdentifier": "t_modifier$__$", "typeString": "modifier ()" } }, "nodeType": "ModifierInvocation", - "src": "383:10:4" + "src": "383:10:5" } ], "name": "upgrade", "nodeType": "FunctionDefinition", "parameters": { - "id": 520, + "id": 596, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 519, + "id": 595, "name": "new_address", "nodeType": "VariableDeclaration", - "scope": 537, - "src": "355:19:4", + "scope": 613, + "src": "355:19:5", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1328,10 +1328,10 @@ "typeString": "address" }, "typeName": { - "id": 518, + "id": 594, "name": "address", "nodeType": "ElementaryTypeName", - "src": "355:7:4", + "src": "355:7:5", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1342,34 +1342,41 @@ "visibility": "internal" } ], - "src": "354:21:4" + "src": "354:21:5" }, "returnParameters": { - "id": 523, + "id": 599, "nodeType": "ParameterList", "parameters": [], - "src": "394:0:4" + "src": "394:0:5" }, - "scope": 538, - "src": "338:165:4", + "scope": 614, + "src": "338:165:5", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" } ], - "scope": 539, - "src": "25:480:4" + "scope": 615, + "src": "25:480:5" } ], - "src": "0:506:4" + "src": "0:506:5" }, "compiler": { "name": "solc", "version": "0.5.8+commit.23d335f2.Emscripten.clang" }, - "networks": {}, + "networks": { + "42": { + "events": {}, + "links": {}, + "address": "0x184e638520CEC14E3deb0381D91F9188EBa23A0D", + "transactionHash": "0xfc37d86c87dd53e0e7cd9609d956a74d0f03507d48445c4cc6203cccdb9527cd" + } + }, "schemaVersion": "3.0.16", - "updatedAt": "2019-11-04T18:56:07.478Z", + "updatedAt": "2019-11-07T15:21:05.391Z", "devdoc": { "methods": {} }, diff --git a/client/src/contracts/MintableERC20.json b/client/src/contracts/MintableERC20.json new file mode 100644 index 0000000..025d66c --- /dev/null +++ b/client/src/contracts/MintableERC20.json @@ -0,0 +1,849 @@ +{ + "contractName": "MintableERC20", + "abi": [ + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"details\":\"ERC20 minting logic\",\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}},\"title\":\"ERC20Mintable\"},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":\"MintableERC20\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x6080604052611052806100136000396000f3fe608060405234801561001057600080fd5b50600436106100935760003560e01c806370a082311161006657806370a0823114610208578063a0712d6814610260578063a457c2d7146102a6578063a9059cbb1461030c578063dd62ed3e1461037257610093565b8063095ea7b31461009857806318160ddd146100fe57806323b872dd1461011c57806339509351146101a2575b600080fd5b6100e4600480360360408110156100ae57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506103ea565b604051808215151515815260200191505060405180910390f35b610106610408565b6040518082815260200191505060405180910390f35b6101886004803603606081101561013257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610412565b604051808215151515815260200191505060405180910390f35b6101ee600480360360408110156101b857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506104eb565b604051808215151515815260200191505060405180910390f35b61024a6004803603602081101561021e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061059e565b6040518082815260200191505060405180910390f35b61028c6004803603602081101561027657600080fd5b81019080803590602001909291905050506105e6565b604051808215151515815260200191505060405180910390f35b6102f2600480360360408110156102bc57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105fb565b604051808215151515815260200191505060405180910390f35b6103586004803603604081101561032257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106c8565b604051808215151515815260200191505060405180910390f35b6103d46004803603604081101561038857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506106e6565b6040518082815260200191505060405180910390f35b60006103fe6103f761076d565b8484610775565b6001905092915050565b6000600254905090565b600061041f84848461096c565b6104e08461042b61076d565b6104db85604051806060016040528060288152602001610f9160289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600061049161076d565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610c229092919063ffffffff16565b610775565b600190509392505050565b60006105946104f861076d565b8461058f856001600061050961076d565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ce290919063ffffffff16565b610775565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60006105f23383610d6a565b60019050919050565b60006106be61060861076d565b846106b985604051806060016040528060258152602001611002602591396001600061063261076d565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610c229092919063ffffffff16565b610775565b6001905092915050565b60006106dc6106d561076d565b848461096c565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156107fb576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526024815260200180610fde6024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610881576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180610f496022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156109f2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526025815260200180610fb96025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610a78576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180610f266023913960400191505060405180910390fd5b610ae381604051806060016040528060268152602001610f6b602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610c229092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610b76816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ce290919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610ccf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610c94578082015181840152602081019050610c79565b50505050905090810190601f168015610cc15780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610d60576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610e0d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b610e2281600254610ce290919063ffffffff16565b600281905550610e79816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ce290919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058200d32491fb3a2ddaeabe583ba8459dd0a28309a893329678d040f5bdec4cd15c00029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100935760003560e01c806370a082311161006657806370a0823114610208578063a0712d6814610260578063a457c2d7146102a6578063a9059cbb1461030c578063dd62ed3e1461037257610093565b8063095ea7b31461009857806318160ddd146100fe57806323b872dd1461011c57806339509351146101a2575b600080fd5b6100e4600480360360408110156100ae57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506103ea565b604051808215151515815260200191505060405180910390f35b610106610408565b6040518082815260200191505060405180910390f35b6101886004803603606081101561013257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610412565b604051808215151515815260200191505060405180910390f35b6101ee600480360360408110156101b857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506104eb565b604051808215151515815260200191505060405180910390f35b61024a6004803603602081101561021e57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061059e565b6040518082815260200191505060405180910390f35b61028c6004803603602081101561027657600080fd5b81019080803590602001909291905050506105e6565b604051808215151515815260200191505060405180910390f35b6102f2600480360360408110156102bc57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105fb565b604051808215151515815260200191505060405180910390f35b6103586004803603604081101561032257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106c8565b604051808215151515815260200191505060405180910390f35b6103d46004803603604081101561038857600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506106e6565b6040518082815260200191505060405180910390f35b60006103fe6103f761076d565b8484610775565b6001905092915050565b6000600254905090565b600061041f84848461096c565b6104e08461042b61076d565b6104db85604051806060016040528060288152602001610f9160289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600061049161076d565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610c229092919063ffffffff16565b610775565b600190509392505050565b60006105946104f861076d565b8461058f856001600061050961076d565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ce290919063ffffffff16565b610775565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60006105f23383610d6a565b60019050919050565b60006106be61060861076d565b846106b985604051806060016040528060258152602001611002602591396001600061063261076d565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610c229092919063ffffffff16565b610775565b6001905092915050565b60006106dc6106d561076d565b848461096c565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156107fb576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526024815260200180610fde6024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610881576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526022815260200180610f496022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff1614156109f2576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526025815260200180610fb96025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610a78576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401808060200182810382526023815260200180610f266023913960400191505060405180910390fd5b610ae381604051806060016040528060268152602001610f6b602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610c229092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610b76816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ce290919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610ccf576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610c94578082015181840152602081019050610c79565b50505050905090810190601f168015610cc15780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610d60576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610e0d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b610e2281600254610ce290919063ffffffff16565b600281905550610e79816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ce290919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058200d32491fb3a2ddaeabe583ba8459dd0a28309a893329678d040f5bdec4cd15c00029", + "sourceMap": "150:328:34:-;;;;;;;;;", + "deployedSourceMap": "150:328:34:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;150:328:34;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;3802:207;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;2500:149;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;3802:207::-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\";\n\n/**\n * @title ERC20Mintable\n * @dev ERC20 minting logic\n */\ncontract MintableERC20 is ERC20 {\n /**\n * @dev Function to mint tokens\n * @param value The amount of tokens to mint.\n * @return A boolean that indicates if the operation was successful.\n */\n function mint(uint256 value) public returns (bool) {\n _mint(msg.sender, value);\n return true;\n }\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "exportedSymbols": { + "MintableERC20": [ + 9599 + ] + }, + "id": 9600, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9579, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:34" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "id": 9580, + "nodeType": "ImportDirective", + "scope": 9600, + "sourceUnit": 11660, + "src": "25:63:34", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9581, + "name": "ERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11659, + "src": "176:5:34", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + }, + "id": 9582, + "nodeType": "InheritanceSpecifier", + "src": "176:5:34" + } + ], + "contractDependencies": [ + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": "@title ERC20Mintable\n@dev ERC20 minting logic", + "fullyImplemented": true, + "id": 9599, + "linearizedBaseContracts": [ + 9599, + 11659, + 11786, + 10953 + ], + "name": "MintableERC20", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": { + "id": 9597, + "nodeType": "Block", + "src": "414:62:34", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 9590, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "430:3:34", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 9591, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "430:10:34", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 9592, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9584, + "src": "442:5:34", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9589, + "name": "_mint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11543, + "src": "424:5:34", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 9593, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "424:24:34", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9594, + "nodeType": "ExpressionStatement", + "src": "424:24:34" + }, + { + "expression": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 9595, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "465:4:34", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "functionReturnParameters": 9588, + "id": 9596, + "nodeType": "Return", + "src": "458:11:34" + } + ] + }, + "documentation": "@dev Function to mint tokens\n@param value The amount of tokens to mint.\n@return A boolean that indicates if the operation was successful.", + "id": 9598, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "mint", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9585, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9584, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 9598, + "src": "377:13:34", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9583, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "377:7:34", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "376:15:34" + }, + "returnParameters": { + "id": 9588, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9587, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9598, + "src": "408:4:34", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 9586, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "408:4:34", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "407:6:34" + }, + "scope": 9599, + "src": "363:113:34", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + } + ], + "scope": 9600, + "src": "150:328:34" + } + ], + "src": "0:479:34" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "exportedSymbols": { + "MintableERC20": [ + 9599 + ] + }, + "id": 9600, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9579, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:34" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol", + "id": 9580, + "nodeType": "ImportDirective", + "scope": 9600, + "sourceUnit": 11660, + "src": "25:63:34", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9581, + "name": "ERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11659, + "src": "176:5:34", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ERC20_$11659", + "typeString": "contract ERC20" + } + }, + "id": 9582, + "nodeType": "InheritanceSpecifier", + "src": "176:5:34" + } + ], + "contractDependencies": [ + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": "@title ERC20Mintable\n@dev ERC20 minting logic", + "fullyImplemented": true, + "id": 9599, + "linearizedBaseContracts": [ + 9599, + 11659, + 11786, + 10953 + ], + "name": "MintableERC20", + "nodeType": "ContractDefinition", + "nodes": [ + { + "body": { + "id": 9597, + "nodeType": "Block", + "src": "414:62:34", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 9590, + "name": "msg", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12128, + "src": "430:3:34", + "typeDescriptions": { + "typeIdentifier": "t_magic_message", + "typeString": "msg" + } + }, + "id": 9591, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sender", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "430:10:34", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 9592, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9584, + "src": "442:5:34", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9589, + "name": "_mint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11543, + "src": "424:5:34", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 9593, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "424:24:34", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9594, + "nodeType": "ExpressionStatement", + "src": "424:24:34" + }, + { + "expression": { + "argumentTypes": null, + "hexValue": "74727565", + "id": 9595, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "465:4:34", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "true" + }, + "functionReturnParameters": 9588, + "id": 9596, + "nodeType": "Return", + "src": "458:11:34" + } + ] + }, + "documentation": "@dev Function to mint tokens\n@param value The amount of tokens to mint.\n@return A boolean that indicates if the operation was successful.", + "id": 9598, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "mint", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9585, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9584, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 9598, + "src": "377:13:34", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9583, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "377:7:34", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "376:15:34" + }, + "returnParameters": { + "id": 9588, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9587, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9598, + "src": "408:4:34", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 9586, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "408:4:34", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "407:6:34" + }, + "scope": 9599, + "src": "363:113:34", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + } + ], + "scope": 9600, + "src": "150:328:34" + } + ], + "src": "0:479:34" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.862Z", + "devdoc": { + "details": "ERC20 minting logic", + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + }, + "title": "ERC20Mintable" + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockAMPL.json b/client/src/contracts/MockAMPL.json new file mode 100644 index 0000000..9ab1f3d --- /dev/null +++ b/client/src/contracts/MockAMPL.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockAMPL", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockAMPL.sol\":\"MockAMPL\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockAMPL.sol\":{\"keccak256\":\"0x996df110a10e60db296dae4a9529a7dd17eeb0c8be21976296163debf53f86e8\",\"urls\":[\"bzzr://3a73fe2af64cf8877d230ff791e56f9aec6d0b206aa0ca5960832f31e80bbb15\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600481526020017f414d504c000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600a81526020017f416d706c65666f7274680000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820eaf8bdd33ce3154dec99bc8034a537222235eab688b44913550fc2b599e7ee0f0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820eaf8bdd33ce3154dec99bc8034a537222235eab688b44913550fc2b599e7ee0f0029", + "sourceMap": "58:144:35:-;;;123:2;100:25;;131:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;166:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:144;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:144:35:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:144:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;166:33;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;166:33:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:25:35;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;131:29:35;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;131:29:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;166:33:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:25:35:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;131:29:35:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockAMPL is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"AMPL\";\n string public name = \"Ampleforth\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockAMPL.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockAMPL.sol", + "exportedSymbols": { + "MockAMPL": [ + 9614 + ] + }, + "id": 9615, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9601, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:35" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9602, + "nodeType": "ImportDirective", + "scope": 9615, + "sourceUnit": 9600, + "src": "26:29:35", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9603, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:35", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9604, + "nodeType": "InheritanceSpecifier", + "src": "79:13:35" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9614, + "linearizedBaseContracts": [ + 9614, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockAMPL", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9607, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9614, + "src": "100:25:35", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9605, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:35", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9606, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:35", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9610, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9614, + "src": "131:29:35", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9608, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:35", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "414d504c", + "id": 9609, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:6:35", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_7b2f8ec7be07c08bedd19c401070629924e1c3b56007786b9dee6ec59f08adda", + "typeString": "literal_string \"AMPL\"" + }, + "value": "AMPL" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9613, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9614, + "src": "166:33:35", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9611, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "166:6:35", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "416d706c65666f727468", + "id": 9612, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "187:12:35", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_6c3a3270030614ed3dd113d0ada726ee3211c390bba817ae6608e704c659e11f", + "typeString": "literal_string \"Ampleforth\"" + }, + "value": "Ampleforth" + }, + "visibility": "public" + } + ], + "scope": 9615, + "src": "58:144:35" + } + ], + "src": "0:202:35" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockAMPL.sol", + "exportedSymbols": { + "MockAMPL": [ + 9614 + ] + }, + "id": 9615, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9601, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:35" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9602, + "nodeType": "ImportDirective", + "scope": 9615, + "sourceUnit": 9600, + "src": "26:29:35", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9603, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:35", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9604, + "nodeType": "InheritanceSpecifier", + "src": "79:13:35" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9614, + "linearizedBaseContracts": [ + 9614, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockAMPL", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9607, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9614, + "src": "100:25:35", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9605, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:35", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9606, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:35", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9610, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9614, + "src": "131:29:35", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9608, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:35", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "414d504c", + "id": 9609, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:6:35", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_7b2f8ec7be07c08bedd19c401070629924e1c3b56007786b9dee6ec59f08adda", + "typeString": "literal_string \"AMPL\"" + }, + "value": "AMPL" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9613, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9614, + "src": "166:33:35", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9611, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "166:6:35", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "416d706c65666f727468", + "id": 9612, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "187:12:35", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_6c3a3270030614ed3dd113d0ada726ee3211c390bba817ae6608e704c659e11f", + "typeString": "literal_string \"Ampleforth\"" + }, + "value": "Ampleforth" + }, + "visibility": "public" + } + ], + "scope": 9615, + "src": "58:144:35" + } + ], + "src": "0:202:35" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.865Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockBAT.json b/client/src/contracts/MockBAT.json new file mode 100644 index 0000000..2e1b036 --- /dev/null +++ b/client/src/contracts/MockBAT.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockBAT", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockBAT.sol\":\"MockBAT\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockBAT.sol\":{\"keccak256\":\"0xfeeb9889a795d9eac0e4c7555b00dce30cf254083b029be30e6acb493f843ff6\",\"urls\":[\"bzzr://3ab6e69d3634f25f4c21475245fad6d747be0c62123fe8fec7692294ceae97b4\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600381526020017f42415400000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280601581526020017f426173696320417474656e74696f6e20546f6b656e000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820c655ad7b153463dda8b26837ad22a4bd0aca5605e9a1599f954ea3a8aedb6fd20029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820c655ad7b153463dda8b26837ad22a4bd0aca5605e9a1599f954ea3a8aedb6fd20029", + "sourceMap": "59:153:36:-;;;123:2;100:25;;131:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;165:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;59:153;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "59:153:36:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;59:153:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;165:44;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;165:44:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:25:36;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;131:28:36;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;131:28:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;165:44:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:25:36:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;131:28:36:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\n\ncontract MockBAT is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"BAT\";\n string public name = \"Basic Attention Token\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockBAT.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockBAT.sol", + "exportedSymbols": { + "MockBAT": [ + 9629 + ] + }, + "id": 9630, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9616, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:36" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9617, + "nodeType": "ImportDirective", + "scope": 9630, + "sourceUnit": 9600, + "src": "26:29:36", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9618, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:36", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9619, + "nodeType": "InheritanceSpecifier", + "src": "79:13:36" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9629, + "linearizedBaseContracts": [ + 9629, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockBAT", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9622, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9629, + "src": "100:25:36", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9620, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:36", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9621, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:36", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9625, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9629, + "src": "131:28:36", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9623, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:36", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "424154", + "id": 9624, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:5:36", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3ec6762bdf44eb044276fec7d12c1bb640cb139cfd533f93eeebba5414f5db55", + "typeString": "literal_string \"BAT\"" + }, + "value": "BAT" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9628, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9629, + "src": "165:44:36", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9626, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:36", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "426173696320417474656e74696f6e20546f6b656e", + "id": 9627, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:23:36", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_cb876cf8ff8a932e02982aa05871800ef51c4198c3c1115d0a5d8bb79e06afe4", + "typeString": "literal_string \"Basic Attention Token\"" + }, + "value": "Basic Attention Token" + }, + "visibility": "public" + } + ], + "scope": 9630, + "src": "59:153:36" + } + ], + "src": "0:212:36" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockBAT.sol", + "exportedSymbols": { + "MockBAT": [ + 9629 + ] + }, + "id": 9630, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9616, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:36" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9617, + "nodeType": "ImportDirective", + "scope": 9630, + "sourceUnit": 9600, + "src": "26:29:36", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9618, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:36", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9619, + "nodeType": "InheritanceSpecifier", + "src": "79:13:36" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9629, + "linearizedBaseContracts": [ + 9629, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockBAT", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9622, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9629, + "src": "100:25:36", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9620, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:36", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9621, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:36", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9625, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9629, + "src": "131:28:36", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9623, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:36", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "424154", + "id": 9624, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:5:36", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_3ec6762bdf44eb044276fec7d12c1bb640cb139cfd533f93eeebba5414f5db55", + "typeString": "literal_string \"BAT\"" + }, + "value": "BAT" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9628, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9629, + "src": "165:44:36", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9626, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:36", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "426173696320417474656e74696f6e20546f6b656e", + "id": 9627, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:23:36", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_cb876cf8ff8a932e02982aa05871800ef51c4198c3c1115d0a5d8bb79e06afe4", + "typeString": "literal_string \"Basic Attention Token\"" + }, + "value": "Basic Attention Token" + }, + "visibility": "public" + } + ], + "scope": 9630, + "src": "59:153:36" + } + ], + "src": "0:212:36" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.867Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockDAI.json b/client/src/contracts/MockDAI.json new file mode 100644 index 0000000..60bef1e --- /dev/null +++ b/client/src/contracts/MockDAI.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockDAI", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockDAI.sol\":\"MockDAI\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockDAI.sol\":{\"keccak256\":\"0xd9774b40245a896825ddb0effb577fc0b0598d424e83187239f8e9727957e31a\",\"urls\":[\"bzzr://723182f9921ab12f9119650022e3cad281ddd9bd98eb7c92c5536e05aaa7617e\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600381526020017f44414900000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600381526020017f444149000000000000000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058208257b5448bd9134af24f8da11b96a3c49ce6d95c5cea7ceceb6b2210a4c6ccae0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058208257b5448bd9134af24f8da11b96a3c49ce6d95c5cea7ceceb6b2210a4c6ccae0029", + "sourceMap": "59:135:37:-;;;123:2;100:25;;131:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;165:26;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;59:135;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "59:135:37:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;59:135:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;165:26;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;165:26:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:25:37;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;131:28:37;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;131:28:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;165:26:37;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:25:37:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;131:28:37:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\n\ncontract MockDAI is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"DAI\";\n string public name = \"DAI\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockDAI.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockDAI.sol", + "exportedSymbols": { + "MockDAI": [ + 9644 + ] + }, + "id": 9645, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9631, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:37" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9632, + "nodeType": "ImportDirective", + "scope": 9645, + "sourceUnit": 9600, + "src": "26:29:37", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9633, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:37", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9634, + "nodeType": "InheritanceSpecifier", + "src": "79:13:37" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9644, + "linearizedBaseContracts": [ + 9644, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockDAI", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9637, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9644, + "src": "100:25:37", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9635, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:37", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9636, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:37", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9640, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9644, + "src": "131:28:37", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9638, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:37", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "444149", + "id": 9639, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:5:37", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a5e92f3efb6826155f1f728e162af9d7cda33a574a1153b58f03ea01cc37e568", + "typeString": "literal_string \"DAI\"" + }, + "value": "DAI" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9643, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9644, + "src": "165:26:37", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9641, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:37", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "444149", + "id": 9642, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:5:37", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a5e92f3efb6826155f1f728e162af9d7cda33a574a1153b58f03ea01cc37e568", + "typeString": "literal_string \"DAI\"" + }, + "value": "DAI" + }, + "visibility": "public" + } + ], + "scope": 9645, + "src": "59:135:37" + } + ], + "src": "0:194:37" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockDAI.sol", + "exportedSymbols": { + "MockDAI": [ + 9644 + ] + }, + "id": 9645, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9631, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:37" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9632, + "nodeType": "ImportDirective", + "scope": 9645, + "sourceUnit": 9600, + "src": "26:29:37", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9633, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:37", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9634, + "nodeType": "InheritanceSpecifier", + "src": "79:13:37" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9644, + "linearizedBaseContracts": [ + 9644, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockDAI", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9637, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9644, + "src": "100:25:37", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9635, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:37", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9636, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:37", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9640, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9644, + "src": "131:28:37", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9638, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:37", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "444149", + "id": 9639, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:5:37", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a5e92f3efb6826155f1f728e162af9d7cda33a574a1153b58f03ea01cc37e568", + "typeString": "literal_string \"DAI\"" + }, + "value": "DAI" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9643, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9644, + "src": "165:26:37", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9641, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:37", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "444149", + "id": 9642, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:5:37", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a5e92f3efb6826155f1f728e162af9d7cda33a574a1153b58f03ea01cc37e568", + "typeString": "literal_string \"DAI\"" + }, + "value": "DAI" + }, + "visibility": "public" + } + ], + "scope": 9645, + "src": "59:135:37" + } + ], + "src": "0:194:37" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.869Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockETH.json b/client/src/contracts/MockETH.json new file mode 100644 index 0000000..982db93 --- /dev/null +++ b/client/src/contracts/MockETH.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockETH", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockETH.sol\":\"MockETH\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockETH.sol\":{\"keccak256\":\"0x3baa39f3d58e0767480a54a487ace577bb66dbce08c56f63c4ed33dcf46aa5d7\",\"urls\":[\"bzzr://bcf9f665ce122aada1bede7d87a5750c6cec58eb0508a72ef2010573a1fea899\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600381526020017f45544800000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600881526020017f457468657265756d00000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820cab1ddd6ba42314e341311fed2276d92ae34fc2ceaa92c96ed2d8b734448a63f0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820cab1ddd6ba42314e341311fed2276d92ae34fc2ceaa92c96ed2d8b734448a63f0029", + "sourceMap": "59:140:38:-;;;123:2;100:25;;131:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;165:31;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;59:140;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "59:140:38:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;59:140:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;165:31;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;165:31:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:25:38;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;131:28:38;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;131:28:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;165:31:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:25:38:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;131:28:38:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockETH is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"ETH\";\n string public name = \"Ethereum\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockETH.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockETH.sol", + "exportedSymbols": { + "MockETH": [ + 9659 + ] + }, + "id": 9660, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9646, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:38" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9647, + "nodeType": "ImportDirective", + "scope": 9660, + "sourceUnit": 9600, + "src": "27:29:38", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9648, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:38", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9649, + "nodeType": "InheritanceSpecifier", + "src": "79:13:38" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9659, + "linearizedBaseContracts": [ + 9659, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockETH", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9652, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9659, + "src": "100:25:38", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9650, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:38", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9651, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:38", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9655, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9659, + "src": "131:28:38", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9653, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:38", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "455448", + "id": 9654, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:5:38", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_aaaebeba3810b1e6b70781f14b2d72c1cb89c0b2b320c43bb67ff79f562f5ff4", + "typeString": "literal_string \"ETH\"" + }, + "value": "ETH" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9658, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9659, + "src": "165:31:38", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9656, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:38", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "457468657265756d", + "id": 9657, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:10:38", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_564ccaf7594d66b1eaaea24fe01f0585bf52ee70852af4eac0cc4b04711cd0e2", + "typeString": "literal_string \"Ethereum\"" + }, + "value": "Ethereum" + }, + "visibility": "public" + } + ], + "scope": 9660, + "src": "59:140:38" + } + ], + "src": "0:199:38" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockETH.sol", + "exportedSymbols": { + "MockETH": [ + 9659 + ] + }, + "id": 9660, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9646, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:38" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9647, + "nodeType": "ImportDirective", + "scope": 9660, + "sourceUnit": 9600, + "src": "27:29:38", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9648, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:38", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9649, + "nodeType": "InheritanceSpecifier", + "src": "79:13:38" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9659, + "linearizedBaseContracts": [ + 9659, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockETH", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9652, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9659, + "src": "100:25:38", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9650, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:38", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9651, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:38", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9655, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9659, + "src": "131:28:38", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9653, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:38", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "455448", + "id": 9654, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:5:38", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_aaaebeba3810b1e6b70781f14b2d72c1cb89c0b2b320c43bb67ff79f562f5ff4", + "typeString": "literal_string \"ETH\"" + }, + "value": "ETH" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9658, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9659, + "src": "165:31:38", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9656, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:38", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "457468657265756d", + "id": 9657, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:10:38", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_564ccaf7594d66b1eaaea24fe01f0585bf52ee70852af4eac0cc4b04711cd0e2", + "typeString": "literal_string \"Ethereum\"" + }, + "value": "Ethereum" + }, + "visibility": "public" + } + ], + "scope": 9660, + "src": "59:140:38" + } + ], + "src": "0:199:38" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.871Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockFlashLoanReceiver.json b/client/src/contracts/MockFlashLoanReceiver.json new file mode 100644 index 0000000..cf951c3 --- /dev/null +++ b/client/src/contracts/MockFlashLoanReceiver.json @@ -0,0 +1,3606 @@ +{ + "contractName": "MockFlashLoanReceiver", + "abi": [ + { + "inputs": [ + { + "name": "_provider", + "type": "address" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "name": "_reserve", + "type": "address" + }, + { + "indexed": false, + "name": "_amount", + "type": "uint256" + }, + { + "indexed": false, + "name": "_fee", + "type": "uint256" + } + ], + "name": "ExecutedWithFail", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "name": "_reserve", + "type": "address" + }, + { + "indexed": false, + "name": "_amount", + "type": "uint256" + }, + { + "indexed": false, + "name": "_fee", + "type": "uint256" + } + ], + "name": "ExecutedWithSuccess", + "type": "event" + }, + { + "constant": false, + "inputs": [ + { + "name": "_fail", + "type": "bool" + } + ], + "name": "setFailExecutionTransfer", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_reserve", + "type": "address" + }, + { + "name": "_amount", + "type": "uint256" + }, + { + "name": "_fee", + "type": "uint256" + } + ], + "name": "executeOperation", + "outputs": [ + { + "name": "returnedAmount", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_fail\",\"type\":\"bool\"}],\"name\":\"setFailExecutionTransfer\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_reserve\",\"type\":\"address\"},{\"name\":\"_amount\",\"type\":\"uint256\"},{\"name\":\"_fee\",\"type\":\"uint256\"}],\"name\":\"executeOperation\",\"outputs\":[{\"name\":\"returnedAmount\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_provider\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"fallback\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_fee\",\"type\":\"uint256\"}],\"name\":\"ExecutedWithFail\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"_reserve\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"_amount\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"_fee\",\"type\":\"uint256\"}],\"name\":\"ExecutedWithSuccess\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/FlashLoan/MockFlashLoanReceiver.sol\":\"MockFlashLoanReceiver\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol\":{\"keccak256\":\"0xa05bc60cdbae1ae13832a9e45726487f20de2ef8f2cdf7ccbbdab69e782b867d\",\"urls\":[\"bzzr://31b41cf73f764af450fdb49b224012e1100302b84ba7ec0596f97417361b6f24\"]},\"/Users/jg/Documents/aaveBot/contracts/flashloan/interfaces/IFlashLoanReceiver.sol\":{\"keccak256\":\"0x3b825dc98b6a7aa21e9c9b05e1951bec7b5d7c84b7a0e8de0750069ccb31ebac\",\"urls\":[\"bzzr://8a616caca158d63de8db6037a2162c1effaaa71f6d7095a11516e03f7ea391d0\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/FlashLoan/MockFlashLoanReceiver.sol\":{\"keccak256\":\"0x062a6d92c465453ee0404bdb6552fed42fb2e66b3082a1ac4c30ad44c9a37282\",\"urls\":[\"bzzr://0808ae44763cf91b26e1c9f03cebc82280725be0d3819d0e9d9af2a8b4a8f7f3\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]}},\"version\":1}", + "bytecode": "0x608060405260008060146101000a81548160ff02191690831515021790555034801561002a57600080fd5b50604051602080610e6e8339810180604052602081101561004a57600080fd5b810190808051906020019092919050505080806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505050610dc1806100ad6000396000f3fe6080604052600436106100295760003560e01c8063388f70f11461002b5780638b514f8c14610068575b005b34801561003757600080fd5b506100666004803603602081101561004e57600080fd5b810190808035151590602001909291905050506100e1565b005b34801561007457600080fd5b506100cb6004803603606081101561008b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291905050506100fe565b6040518082815260200191505060405180910390f35b80600060146101000a81548160ff02191690831515021790555050565b60008084905061010e30866104bd565b841115610183576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f496e76616c69642062616c616e636520666f722074686520636f6e747261637481525060200191505060405180910390fd5b600060149054906101000a900460ff1615610226577f816f6a6bc084e1996be1a831afa1af30763d0501b6b43b9e1922a11f347366d7858585604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a161021e83856106f490919063ffffffff16565b9150506104b6565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b15801561028f57600080fd5b505afa1580156102a3573d6000803e3d6000fd5b505050506040513d60208110156102b957600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b15801561031257600080fd5b505afa158015610326573d6000803e3d6000fd5b505050506040513d602081101561033c57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff161461040f578173ffffffffffffffffffffffffffffffffffffffff1663a0712d68856040518263ffffffff1660e01b815260040180828152602001915050602060405180830381600087803b1580156103d257600080fd5b505af11580156103e6573d6000803e3d6000fd5b505050506040513d60208110156103fc57600080fd5b8101908080519060200190929190505050505b61042b8661042686886106f490919063ffffffff16565b61077c565b7f7d94e9d0c906b8d7b2b52a581b9e9ba728aa6f8cd8532bd87243d193f47401be868686604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a16104b184866106f490919063ffffffff16565b925050505b9392505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b15801561052657600080fd5b505afa15801561053a573d6000803e3d6000fd5b505050506040513d602081101561055057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b1580156105a657600080fd5b505afa1580156105ba573d6000803e3d6000fd5b505050506040513d60208110156105d057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610633578273ffffffffffffffffffffffffffffffffffffffff163190506106ee565b8173ffffffffffffffffffffffffffffffffffffffff166370a08231846040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156106b057600080fd5b505afa1580156106c4573d6000803e3d6000fd5b505050506040513d60208110156106da57600080fd5b810190808051906020019092919050505090505b92915050565b600080828401905083811015610772576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156107e557600080fd5b505afa1580156107f9573d6000803e3d6000fd5b505050506040513d602081101561080f57600080fd5b8101908080519060200190929190505050905061082d818484610832565b505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b15801561089957600080fd5b505afa1580156108ad573d6000803e3d6000fd5b505050506040513d60208110156108c357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b15801561091957600080fd5b505afa15801561092d573d6000803e3d6000fd5b505050506040513d602081101561094357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156109d3578273ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f193505050501580156109cd573d6000803e3d6000fd5b506109ff565b6109fe83828473ffffffffffffffffffffffffffffffffffffffff16610a049092919063ffffffff16565b5b505050565b610ad0838473ffffffffffffffffffffffffffffffffffffffff1663a9059cbb905060e01b8484604051602401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610ad5565b505050565b610af48273ffffffffffffffffffffffffffffffffffffffff16610d20565b610b66576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e74726163740081525060200191505060405180910390fd5b600060608373ffffffffffffffffffffffffffffffffffffffff16836040518082805190602001908083835b60208310610bb55780518252602082019150602081019050602083039250610b92565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114610c17576040519150601f19603f3d011682016040523d82523d6000602084013e610c1c565b606091505b509150915081610c94576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656481525060200191505060405180910390fd5b600081511115610d1a57808060200190516020811015610cb357600080fd5b8101908080519060200190929190505050610d19576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180610d6c602a913960400191505060405180910390fd5b5b50505050565b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f91506000801b8214158015610d625750808214155b9250505091905056fe5361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a165627a7a723058206aa0d161371145ae3889df7546145e2cb1b6462c6030e5611e9f074c7779bce20029", + "deployedBytecode": "0x6080604052600436106100295760003560e01c8063388f70f11461002b5780638b514f8c14610068575b005b34801561003757600080fd5b506100666004803603602081101561004e57600080fd5b810190808035151590602001909291905050506100e1565b005b34801561007457600080fd5b506100cb6004803603606081101561008b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291905050506100fe565b6040518082815260200191505060405180910390f35b80600060146101000a81548160ff02191690831515021790555050565b60008084905061010e30866104bd565b841115610183576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f496e76616c69642062616c616e636520666f722074686520636f6e747261637481525060200191505060405180910390fd5b600060149054906101000a900460ff1615610226577f816f6a6bc084e1996be1a831afa1af30763d0501b6b43b9e1922a11f347366d7858585604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a161021e83856106f490919063ffffffff16565b9150506104b6565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b15801561028f57600080fd5b505afa1580156102a3573d6000803e3d6000fd5b505050506040513d60208110156102b957600080fd5b810190808051906020019092919050505090508073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b15801561031257600080fd5b505afa158015610326573d6000803e3d6000fd5b505050506040513d602081101561033c57600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff168673ffffffffffffffffffffffffffffffffffffffff161461040f578173ffffffffffffffffffffffffffffffffffffffff1663a0712d68856040518263ffffffff1660e01b815260040180828152602001915050602060405180830381600087803b1580156103d257600080fd5b505af11580156103e6573d6000803e3d6000fd5b505050506040513d60208110156103fc57600080fd5b8101908080519060200190929190505050505b61042b8661042686886106f490919063ffffffff16565b61077c565b7f7d94e9d0c906b8d7b2b52a581b9e9ba728aa6f8cd8532bd87243d193f47401be868686604051808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001838152602001828152602001935050505060405180910390a16104b184866106f490919063ffffffff16565b925050505b9392505050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b15801561052657600080fd5b505afa15801561053a573d6000803e3d6000fd5b505050506040513d602081101561055057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b1580156105a657600080fd5b505afa1580156105ba573d6000803e3d6000fd5b505050506040513d60208110156105d057600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610633578273ffffffffffffffffffffffffffffffffffffffff163190506106ee565b8173ffffffffffffffffffffffffffffffffffffffff166370a08231846040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b1580156106b057600080fd5b505afa1580156106c4573d6000803e3d6000fd5b505050506040513d60208110156106da57600080fd5b810190808051906020019092919050505090505b92915050565b600080828401905083811015610772576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b60008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b1580156107e557600080fd5b505afa1580156107f9573d6000803e3d6000fd5b505050506040513d602081101561080f57600080fd5b8101908080519060200190929190505050905061082d818484610832565b505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b15801561089957600080fd5b505afa1580156108ad573d6000803e3d6000fd5b505050506040513d60208110156108c357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b15801561091957600080fd5b505afa15801561092d573d6000803e3d6000fd5b505050506040513d602081101561094357600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614156109d3578273ffffffffffffffffffffffffffffffffffffffff166108fc829081150290604051600060405180830381858888f193505050501580156109cd573d6000803e3d6000fd5b506109ff565b6109fe83828473ffffffffffffffffffffffffffffffffffffffff16610a049092919063ffffffff16565b5b505050565b610ad0838473ffffffffffffffffffffffffffffffffffffffff1663a9059cbb905060e01b8484604051602401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050604051602081830303815290604052907bffffffffffffffffffffffffffffffffffffffffffffffffffffffff19166020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8381831617835250505050610ad5565b505050565b610af48273ffffffffffffffffffffffffffffffffffffffff16610d20565b610b66576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f5361666545524332303a2063616c6c20746f206e6f6e2d636f6e74726163740081525060200191505060405180910390fd5b600060608373ffffffffffffffffffffffffffffffffffffffff16836040518082805190602001908083835b60208310610bb55780518252602082019150602081019050602083039250610b92565b6001836020036101000a0380198251168184511680821785525050505050509050019150506000604051808303816000865af19150503d8060008114610c17576040519150601f19603f3d011682016040523d82523d6000602084013e610c1c565b606091505b509150915081610c94576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260208152602001807f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c656481525060200191505060405180910390fd5b600081511115610d1a57808060200190516020811015610cb357600080fd5b8101908080519060200190929190505050610d19576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602a815260200180610d6c602a913960400191505060405180910390fd5b5b50505050565b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f91506000801b8214158015610d625750808214155b9250505091905056fe5361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564a165627a7a723058206aa0d161371145ae3889df7546145e2cb1b6462c6030e5611e9f074c7779bce20029", + "sourceMap": "181:1764:31:-;;;456:5;435:26;;;;;;;;;;;;;;;;;;;;468:101;8:9:-1;5:2;;;30:1;27;20:12;5:2;468:101:31;;;;;;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;468:101:31;;;;;;;;;;;;;;;;543:9;652::14;632:17;;:29;;;;;;;;;;;;;;;;;;562:106;468:101:31;181:1764;;;;;;", + "deployedSourceMap": "181:1764:31:-;;;;;;;;;;;;;;;;;;;;;;;;575:91;;8:9:-1;5:2;;;30:1;27;20:12;5:2;575:91:31;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;575:91:31;;;;;;;;;;;;;;;;;;;:::i;:::-;;672:1271;;8:9:-1;5:2;;;30:1;27;20:12;5:2;672:1271:31;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;672:1271:31;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;575:91;654:5;638:13;;:21;;;;;;;;;;;;;;;;;;575:91;:::o;672:1271::-;789:22;875:19;911:8;875:45;;1006:43;1033:4;1040:8;1006:18;:43::i;:::-;995:7;:54;;987:99;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1100:13;;;;;;;;;;;1097:196;;;1134:41;1151:8;1161:7;1170:4;1134:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1265:17;1277:4;1265:7;:11;;:17;;;;:::i;:::-;1258:24;;;;;1097:196;1507:37;1572:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1572:46:31;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1572:46:31;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1572:46:31;;;;;;;;;;;;;;;;1507:112;;1645:12;:31;;;:33;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1645:33:31;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1645:33:31;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1645:33:31;;;;;;;;;;;;;;;;1633:45;;:8;:45;;;1630:91;;1694:5;:10;;;1705:4;1694:16;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1694:16:31;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1694:16:31;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1694:16:31;;;;;;;;;;;;;;;;;1630:91;1782:60;1814:8;1824:17;1836:4;1824:7;:11;;:17;;;;:::i;:::-;1782:31;:60::i;:::-;1857:44;1877:8;1887:7;1896:4;1857:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1918:17;1930:4;1918:7;:11;;:17;;;;:::i;:::-;1911:24;;;;672:1271;;;;;;:::o;1304:322:14:-;1389:7;1448:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1448:46:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1448:46:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1448:46:14;;;;;;;;;;;;;;;;1423:91;;;:93;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1423:93:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1423:93:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1423:93:14;;;;;;;;;;;;;;;;1411:105;;:8;:105;;;1408:158;;;1540:7;:15;;;1533:22;;;;1408:158;1590:8;1583:26;;;1610:7;1583:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1583:35:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1583:35:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1583:35:14;;;;;;;;;;;;;;;;1576:42;;1304:322;;;;;:::o;834:176:56:-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;716:212:14:-;809:20;832:17;;;;;;;;;;;:36;;;:38;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;832:38:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;832:38:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;832:38:14;;;;;;;;;;;;;;;;809:61;;881:40;898:4;903:8;913:7;881:16;:40::i;:::-;716:212;;;:::o;934:364::-;1082:17;;;;;;;;;;;:44;;;:46;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1082:46:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1082:46:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1082:46:14;;;;;;;;;;;;;;;;1057:91;;;:93;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1057:93:14;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1057:93:14;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1057:93:14;;;;;;;;;;;;;;;;1045:105;;:8;:105;;;1042:185;;;1166:12;:21;;:30;1188:7;1166:30;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1166:30:14;1210:7;;1042:185;1237:52;1267:12;1281:7;1244:8;1237:29;;;;:52;;;;;:::i;:::-;934:364;;;;:::o;662:174:61:-;744:85;763:5;793;:14;;;:23;;;;818:2;822:5;770:58;;;;;;;;;;;;;;;;;;;;;;;;;49:4:-1;39:7;30;26:21;22:32;13:7;6:49;770:58:61;;;;;;;38:4:-1;29:7;25:18;67:10;61:17;96:58;199:8;192:4;186;182:15;179:29;167:10;160:49;0:215;;;770:58:61;744:18;:85::i;:::-;662:174;;;:::o;2666:1095::-;3261:27;3269:5;3261:25;;;:27::i;:::-;3253:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3395:12;3409:23;3444:5;3436:19;;3456:4;3436:25;;;;;;;;;;;;;36:153:-1;66:2;61:3;58:11;36:153;;182:3;176:10;171:3;164:23;98:2;93:3;89:12;82:19;;123:2;118:3;114:12;107:19;;148:2;143:3;139:12;132:19;;36:153;;;274:1;267:3;263:2;259:12;254:3;250:22;246:30;315:4;311:9;305:3;299:10;295:26;356:4;350:3;344:10;340:21;389:7;380;377:20;372:3;365:33;3:399;;;3436:25:61;;;;;;;;;;;;;;;;;;;;;;;;14:1:-1;21;16:31;;;;75:4;69:11;64:16;;144:4;140:9;133:4;115:16;111:27;107:43;104:1;100:51;94:4;87:65;169:16;166:1;159:27;225:16;222:1;215:4;212:1;208:12;193:49;7:242;;16:31;36:4;31:9;;7:242;;3394:67:61;;;;3479:7;3471:52;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3558:1;3538:10;:17;:21;3534:221;;;3678:10;3667:30;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3667:30:61;;;;;;;;;;;;;;;;3659:85;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;3534:221;2666:1095;;;;:::o;557:797:62:-;617:4;1062:16;1088:19;1110:66;1088:88;;;;1277:7;1265:20;1253:32;;1316:3;1304:15;;:8;:15;;:42;;;;;1335:11;1323:8;:23;;1304:42;1296:51;;;;557:797;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\nimport \"../../flashloan/base/FlashLoanReceiverBase.sol\";\nimport \"../tokens/MintableERC20.sol\";\n\ncontract MockFlashLoanReceiver is FlashLoanReceiverBase {\n\n using SafeMath for uint256;\n event ExecutedWithFail(address _reserve, uint256 _amount, uint256 _fee);\n event ExecutedWithSuccess(address _reserve, uint256 _amount, uint256 _fee);\n\n\n bool failExecution = false;\n\n constructor(ILendingPoolAddressesProvider _provider) FlashLoanReceiverBase(_provider) public {\n }\n\n function setFailExecutionTransfer(bool _fail) public {\n failExecution = _fail;\n }\n\n function executeOperation(\n address _reserve,\n uint256 _amount,\n uint256 _fee) external returns(uint256 returnedAmount) {\n //mint to this contract the specific amount\n MintableERC20 token = MintableERC20(_reserve);\n\n\n //check the contract has the specified balance\n require(_amount <= getBalanceInternal(address(this), _reserve), \"Invalid balance for the contract\");\n\n if(failExecution) {\n emit ExecutedWithFail(_reserve, _amount, _fee);\n //returns amount + fee, but does not transfer back funds\n return _amount.add(_fee);\n }\n\n //execution does not fail - mint tokens and return them to the _destination\n //note: if the reserve is eth, the mock contract must receive at least _fee ETH before calling executeOperation\n INetworkMetadataProvider dataProvider = INetworkMetadataProvider(addressesProvider.getNetworkMetadataProvider());\n\n if(_reserve != dataProvider.getEthereumAddress()) {\n token.mint(_fee);\n }\n //returning amount + fee to the destination\n transferFundsBackToPoolInternal(_reserve, _amount.add(_fee));\n emit ExecutedWithSuccess(_reserve, _amount, _fee);\n return _amount.add(_fee);\n\n }\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/FlashLoan/MockFlashLoanReceiver.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/FlashLoan/MockFlashLoanReceiver.sol", + "exportedSymbols": { + "MockFlashLoanReceiver": [ + 9455 + ] + }, + "id": 9456, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9324, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:31" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 9325, + "nodeType": "ImportDirective", + "scope": 9456, + "sourceUnit": 11141, + "src": "25:59:31", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol", + "file": "../../flashloan/base/FlashLoanReceiverBase.sol", + "id": 9326, + "nodeType": "ImportDirective", + "scope": 9456, + "sourceUnit": 1720, + "src": "85:56:31", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "../tokens/MintableERC20.sol", + "id": 9327, + "nodeType": "ImportDirective", + "scope": 9456, + "sourceUnit": 9600, + "src": "142:37:31", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9328, + "name": "FlashLoanReceiverBase", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1719, + "src": "215:21:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_FlashLoanReceiverBase_$1719", + "typeString": "contract FlashLoanReceiverBase" + } + }, + "id": 9329, + "nodeType": "InheritanceSpecifier", + "src": "215:21:31" + } + ], + "contractDependencies": [ + 1719, + 1733 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9455, + "linearizedBaseContracts": [ + 9455, + 1719, + 1733 + ], + "name": "MockFlashLoanReceiver", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 9332, + "libraryName": { + "contractScope": null, + "id": 9330, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "250:8:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "244:27:31", + "typeName": { + "id": 9331, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "263:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "anonymous": false, + "documentation": null, + "id": 9340, + "name": "ExecutedWithFail", + "nodeType": "EventDefinition", + "parameters": { + "id": 9339, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9334, + "indexed": false, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 9340, + "src": "299:16:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9333, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "299:7:31", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9336, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 9340, + "src": "317:15:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9335, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "317:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9338, + "indexed": false, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 9340, + "src": "334:12:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9337, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "334:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "298:49:31" + }, + "src": "276:72:31" + }, + { + "anonymous": false, + "documentation": null, + "id": 9348, + "name": "ExecutedWithSuccess", + "nodeType": "EventDefinition", + "parameters": { + "id": 9347, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9342, + "indexed": false, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 9348, + "src": "379:16:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9341, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "379:7:31", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9344, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 9348, + "src": "397:15:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9343, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "397:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9346, + "indexed": false, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 9348, + "src": "414:12:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9345, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "414:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "378:49:31" + }, + "src": "353:75:31" + }, + { + "constant": false, + "id": 9351, + "name": "failExecution", + "nodeType": "VariableDeclaration", + "scope": 9455, + "src": "435:26:31", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 9349, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "435:4:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 9350, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "456:5:31", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "visibility": "internal" + }, + { + "body": { + "id": 9359, + "nodeType": "Block", + "src": "562:7:31", + "statements": [] + }, + "documentation": null, + "id": 9360, + "implemented": true, + "kind": "constructor", + "modifiers": [ + { + "arguments": [ + { + "argumentTypes": null, + "id": 9356, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9353, + "src": "543:9:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + } + ], + "id": 9357, + "modifierName": { + "argumentTypes": null, + "id": 9355, + "name": "FlashLoanReceiverBase", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1719, + "src": "521:21:31", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_FlashLoanReceiverBase_$1719_$", + "typeString": "type(contract FlashLoanReceiverBase)" + } + }, + "nodeType": "ModifierInvocation", + "src": "521:32:31" + } + ], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9354, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9353, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 9360, + "src": "480:39:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 9352, + "name": "ILendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1878, + "src": "480:29:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "479:41:31" + }, + "returnParameters": { + "id": 9358, + "nodeType": "ParameterList", + "parameters": [], + "src": "562:0:31" + }, + "scope": 9455, + "src": "468:101:31", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 9369, + "nodeType": "Block", + "src": "628:38:31", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9367, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9365, + "name": "failExecution", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9351, + "src": "638:13:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9366, + "name": "_fail", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9362, + "src": "654:5:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "638:21:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 9368, + "nodeType": "ExpressionStatement", + "src": "638:21:31" + } + ] + }, + "documentation": null, + "id": 9370, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setFailExecutionTransfer", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9363, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9362, + "name": "_fail", + "nodeType": "VariableDeclaration", + "scope": 9370, + "src": "609:10:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 9361, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "609:4:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "608:12:31" + }, + "returnParameters": { + "id": 9364, + "nodeType": "ParameterList", + "parameters": [], + "src": "628:0:31" + }, + "scope": 9455, + "src": "575:91:31", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 9453, + "nodeType": "Block", + "src": "813:1130:31", + "statements": [ + { + "assignments": [ + 9382 + ], + "declarations": [ + { + "constant": false, + "id": 9382, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 9453, + "src": "875:19:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + }, + "typeName": { + "contractScope": null, + "id": 9381, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "875:13:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9386, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9384, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "911:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9383, + "name": "MintableERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9599, + "src": "897:13:31", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_MintableERC20_$9599_$", + "typeString": "type(contract MintableERC20)" + } + }, + "id": 9385, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "897:23:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "875:45:31" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9395, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9388, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "995:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<=", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9391, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12232, + "src": "1033:4:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MockFlashLoanReceiver_$9455", + "typeString": "contract MockFlashLoanReceiver" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_MockFlashLoanReceiver_$9455", + "typeString": "contract MockFlashLoanReceiver" + } + ], + "id": 9390, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1025:7:31", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 9392, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1025:13:31", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 9393, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "1040:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9389, + "name": "getBalanceInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1718, + "src": "1006:18:31", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view returns (uint256)" + } + }, + "id": 9394, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1006:43:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "995:54:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c69642062616c616e636520666f722074686520636f6e7472616374", + "id": 9396, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1051:34:31", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_b7eb1acc2a916521532d41db798e862e3bc634b536ffa4062c39b663132b6869", + "typeString": "literal_string \"Invalid balance for the contract\"" + }, + "value": "Invalid balance for the contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_b7eb1acc2a916521532d41db798e862e3bc634b536ffa4062c39b663132b6869", + "typeString": "literal_string \"Invalid balance for the contract\"" + } + ], + "id": 9387, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "987:7:31", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 9397, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "987:99:31", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9398, + "nodeType": "ExpressionStatement", + "src": "987:99:31" + }, + { + "condition": { + "argumentTypes": null, + "id": 9399, + "name": "failExecution", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9351, + "src": "1100:13:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 9412, + "nodeType": "IfStatement", + "src": "1097:196:31", + "trueBody": { + "id": 9411, + "nodeType": "Block", + "src": "1115:178:31", + "statements": [ + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9401, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "1151:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 9402, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "1161:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 9403, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1170:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9400, + "name": "ExecutedWithFail", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9340, + "src": "1134:16:31", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256)" + } + }, + "id": 9404, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1134:41:31", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9405, + "nodeType": "EmitStatement", + "src": "1129:46:31" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9408, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1277:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9406, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "1265:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9407, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1265:11:31", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9409, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1265:17:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9380, + "id": 9410, + "nodeType": "Return", + "src": "1258:24:31" + } + ] + } + }, + { + "assignments": [ + 9414 + ], + "declarations": [ + { + "constant": false, + "id": 9414, + "name": "dataProvider", + "nodeType": "VariableDeclaration", + "scope": 9453, + "src": "1507:37:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + }, + "typeName": { + "contractScope": null, + "id": 9413, + "name": "INetworkMetadataProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1932, + "src": "1507:24:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9420, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9416, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1617, + "src": "1572:17:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 9417, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1822, + "src": "1572:44:31", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 9418, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1572:46:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9415, + "name": "INetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1932, + "src": "1547:24:31", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_INetworkMetadataProvider_$1932_$", + "typeString": "type(contract INetworkMetadataProvider)" + } + }, + "id": 9419, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1547:72:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1507:112:31" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 9425, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9421, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "1633:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9422, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9414, + "src": "1645:12:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 9423, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1926, + "src": "1645:31:31", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 9424, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1645:33:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1633:45:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 9433, + "nodeType": "IfStatement", + "src": "1630:91:31", + "trueBody": { + "id": 9432, + "nodeType": "Block", + "src": "1680:41:31", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9429, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1705:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9426, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9382, + "src": "1694:5:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9428, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mint", + "nodeType": "MemberAccess", + "referencedDeclaration": 9598, + "src": "1694:10:31", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$returns$_t_bool_$", + "typeString": "function (uint256) external returns (bool)" + } + }, + "id": 9430, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1694:16:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 9431, + "nodeType": "ExpressionStatement", + "src": "1694:16:31" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9435, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "1814:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9438, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1836:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9436, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "1824:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9437, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1824:11:31", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9439, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1824:17:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9434, + "name": "transferFundsBackToPoolInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1651, + "src": "1782:31:31", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 9440, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1782:60:31", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9441, + "nodeType": "ExpressionStatement", + "src": "1782:60:31" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9443, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "1877:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 9444, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "1887:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 9445, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1896:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9442, + "name": "ExecutedWithSuccess", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9348, + "src": "1857:19:31", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256)" + } + }, + "id": 9446, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1857:44:31", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9447, + "nodeType": "EmitStatement", + "src": "1852:49:31" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9450, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1930:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9448, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "1918:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9449, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1918:11:31", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9451, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1918:17:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9380, + "id": 9452, + "nodeType": "Return", + "src": "1911:24:31" + } + ] + }, + "documentation": null, + "id": 9454, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "executeOperation", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9377, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9372, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 9454, + "src": "707:16:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9371, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "707:7:31", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9374, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 9454, + "src": "733:15:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9373, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "733:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9376, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 9454, + "src": "758:12:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9375, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "758:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "697:74:31" + }, + "returnParameters": { + "id": 9380, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9379, + "name": "returnedAmount", + "nodeType": "VariableDeclaration", + "scope": 9454, + "src": "789:22:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9378, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "789:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "788:24:31" + }, + "scope": 9455, + "src": "672:1271:31", + "stateMutability": "nonpayable", + "superFunction": 1732, + "visibility": "external" + } + ], + "scope": 9456, + "src": "181:1764:31" + } + ], + "src": "0:1945:31" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/FlashLoan/MockFlashLoanReceiver.sol", + "exportedSymbols": { + "MockFlashLoanReceiver": [ + 9455 + ] + }, + "id": 9456, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9324, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:31" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 9325, + "nodeType": "ImportDirective", + "scope": 9456, + "sourceUnit": 11141, + "src": "25:59:31", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/flashloan/base/FlashLoanReceiverBase.sol", + "file": "../../flashloan/base/FlashLoanReceiverBase.sol", + "id": 9326, + "nodeType": "ImportDirective", + "scope": 9456, + "sourceUnit": 1720, + "src": "85:56:31", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "../tokens/MintableERC20.sol", + "id": 9327, + "nodeType": "ImportDirective", + "scope": 9456, + "sourceUnit": 9600, + "src": "142:37:31", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9328, + "name": "FlashLoanReceiverBase", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1719, + "src": "215:21:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_FlashLoanReceiverBase_$1719", + "typeString": "contract FlashLoanReceiverBase" + } + }, + "id": 9329, + "nodeType": "InheritanceSpecifier", + "src": "215:21:31" + } + ], + "contractDependencies": [ + 1719, + 1733 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9455, + "linearizedBaseContracts": [ + 9455, + 1719, + 1733 + ], + "name": "MockFlashLoanReceiver", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 9332, + "libraryName": { + "contractScope": null, + "id": 9330, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "250:8:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "244:27:31", + "typeName": { + "id": 9331, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "263:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "anonymous": false, + "documentation": null, + "id": 9340, + "name": "ExecutedWithFail", + "nodeType": "EventDefinition", + "parameters": { + "id": 9339, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9334, + "indexed": false, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 9340, + "src": "299:16:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9333, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "299:7:31", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9336, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 9340, + "src": "317:15:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9335, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "317:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9338, + "indexed": false, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 9340, + "src": "334:12:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9337, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "334:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "298:49:31" + }, + "src": "276:72:31" + }, + { + "anonymous": false, + "documentation": null, + "id": 9348, + "name": "ExecutedWithSuccess", + "nodeType": "EventDefinition", + "parameters": { + "id": 9347, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9342, + "indexed": false, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 9348, + "src": "379:16:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9341, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "379:7:31", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9344, + "indexed": false, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 9348, + "src": "397:15:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9343, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "397:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9346, + "indexed": false, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 9348, + "src": "414:12:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9345, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "414:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "378:49:31" + }, + "src": "353:75:31" + }, + { + "constant": false, + "id": 9351, + "name": "failExecution", + "nodeType": "VariableDeclaration", + "scope": 9455, + "src": "435:26:31", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 9349, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "435:4:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "66616c7365", + "id": 9350, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "bool", + "lValueRequested": false, + "nodeType": "Literal", + "src": "456:5:31", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "value": "false" + }, + "visibility": "internal" + }, + { + "body": { + "id": 9359, + "nodeType": "Block", + "src": "562:7:31", + "statements": [] + }, + "documentation": null, + "id": 9360, + "implemented": true, + "kind": "constructor", + "modifiers": [ + { + "arguments": [ + { + "argumentTypes": null, + "id": 9356, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9353, + "src": "543:9:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + } + ], + "id": 9357, + "modifierName": { + "argumentTypes": null, + "id": 9355, + "name": "FlashLoanReceiverBase", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1719, + "src": "521:21:31", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_FlashLoanReceiverBase_$1719_$", + "typeString": "type(contract FlashLoanReceiverBase)" + } + }, + "nodeType": "ModifierInvocation", + "src": "521:32:31" + } + ], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9354, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9353, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 9360, + "src": "480:39:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 9352, + "name": "ILendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1878, + "src": "480:29:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "479:41:31" + }, + "returnParameters": { + "id": 9358, + "nodeType": "ParameterList", + "parameters": [], + "src": "562:0:31" + }, + "scope": 9455, + "src": "468:101:31", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 9369, + "nodeType": "Block", + "src": "628:38:31", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9367, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9365, + "name": "failExecution", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9351, + "src": "638:13:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9366, + "name": "_fail", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9362, + "src": "654:5:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "638:21:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 9368, + "nodeType": "ExpressionStatement", + "src": "638:21:31" + } + ] + }, + "documentation": null, + "id": 9370, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setFailExecutionTransfer", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9363, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9362, + "name": "_fail", + "nodeType": "VariableDeclaration", + "scope": 9370, + "src": "609:10:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 9361, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "609:4:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "608:12:31" + }, + "returnParameters": { + "id": 9364, + "nodeType": "ParameterList", + "parameters": [], + "src": "628:0:31" + }, + "scope": 9455, + "src": "575:91:31", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 9453, + "nodeType": "Block", + "src": "813:1130:31", + "statements": [ + { + "assignments": [ + 9382 + ], + "declarations": [ + { + "constant": false, + "id": 9382, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 9453, + "src": "875:19:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + }, + "typeName": { + "contractScope": null, + "id": 9381, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "875:13:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9386, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9384, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "911:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9383, + "name": "MintableERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9599, + "src": "897:13:31", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_MintableERC20_$9599_$", + "typeString": "type(contract MintableERC20)" + } + }, + "id": 9385, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "897:23:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "875:45:31" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9395, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9388, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "995:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<=", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9391, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12232, + "src": "1033:4:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MockFlashLoanReceiver_$9455", + "typeString": "contract MockFlashLoanReceiver" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_MockFlashLoanReceiver_$9455", + "typeString": "contract MockFlashLoanReceiver" + } + ], + "id": 9390, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1025:7:31", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 9392, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1025:13:31", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 9393, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "1040:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9389, + "name": "getBalanceInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1718, + "src": "1006:18:31", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view returns (uint256)" + } + }, + "id": 9394, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1006:43:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "995:54:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "496e76616c69642062616c616e636520666f722074686520636f6e7472616374", + "id": 9396, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1051:34:31", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_b7eb1acc2a916521532d41db798e862e3bc634b536ffa4062c39b663132b6869", + "typeString": "literal_string \"Invalid balance for the contract\"" + }, + "value": "Invalid balance for the contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_b7eb1acc2a916521532d41db798e862e3bc634b536ffa4062c39b663132b6869", + "typeString": "literal_string \"Invalid balance for the contract\"" + } + ], + "id": 9387, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "987:7:31", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 9397, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "987:99:31", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9398, + "nodeType": "ExpressionStatement", + "src": "987:99:31" + }, + { + "condition": { + "argumentTypes": null, + "id": 9399, + "name": "failExecution", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9351, + "src": "1100:13:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 9412, + "nodeType": "IfStatement", + "src": "1097:196:31", + "trueBody": { + "id": 9411, + "nodeType": "Block", + "src": "1115:178:31", + "statements": [ + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9401, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "1151:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 9402, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "1161:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 9403, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1170:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9400, + "name": "ExecutedWithFail", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9340, + "src": "1134:16:31", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256)" + } + }, + "id": 9404, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1134:41:31", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9405, + "nodeType": "EmitStatement", + "src": "1129:46:31" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9408, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1277:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9406, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "1265:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9407, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1265:11:31", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9409, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1265:17:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9380, + "id": 9410, + "nodeType": "Return", + "src": "1258:24:31" + } + ] + } + }, + { + "assignments": [ + 9414 + ], + "declarations": [ + { + "constant": false, + "id": 9414, + "name": "dataProvider", + "nodeType": "VariableDeclaration", + "scope": 9453, + "src": "1507:37:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + }, + "typeName": { + "contractScope": null, + "id": 9413, + "name": "INetworkMetadataProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1932, + "src": "1507:24:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9420, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9416, + "name": "addressesProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1617, + "src": "1572:17:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_ILendingPoolAddressesProvider_$1878", + "typeString": "contract ILendingPoolAddressesProvider" + } + }, + "id": 9417, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1822, + "src": "1572:44:31", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 9418, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1572:46:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9415, + "name": "INetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1932, + "src": "1547:24:31", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_INetworkMetadataProvider_$1932_$", + "typeString": "type(contract INetworkMetadataProvider)" + } + }, + "id": 9419, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1547:72:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1507:112:31" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 9425, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9421, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "1633:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9422, + "name": "dataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9414, + "src": "1645:12:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 9423, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1926, + "src": "1645:31:31", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 9424, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1645:33:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1633:45:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 9433, + "nodeType": "IfStatement", + "src": "1630:91:31", + "trueBody": { + "id": 9432, + "nodeType": "Block", + "src": "1680:41:31", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9429, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1705:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9426, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9382, + "src": "1694:5:31", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9428, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mint", + "nodeType": "MemberAccess", + "referencedDeclaration": 9598, + "src": "1694:10:31", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$returns$_t_bool_$", + "typeString": "function (uint256) external returns (bool)" + } + }, + "id": 9430, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1694:16:31", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 9431, + "nodeType": "ExpressionStatement", + "src": "1694:16:31" + } + ] + } + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9435, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "1814:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9438, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1836:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9436, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "1824:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9437, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1824:11:31", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9439, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1824:17:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9434, + "name": "transferFundsBackToPoolInternal", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1651, + "src": "1782:31:31", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256)" + } + }, + "id": 9440, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1782:60:31", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9441, + "nodeType": "ExpressionStatement", + "src": "1782:60:31" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9443, + "name": "_reserve", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9372, + "src": "1877:8:31", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 9444, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "1887:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 9445, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1896:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9442, + "name": "ExecutedWithSuccess", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9348, + "src": "1857:19:31", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$", + "typeString": "function (address,uint256,uint256)" + } + }, + "id": 9446, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1857:44:31", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9447, + "nodeType": "EmitStatement", + "src": "1852:49:31" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9450, + "name": "_fee", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9376, + "src": "1930:4:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9448, + "name": "_amount", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9374, + "src": "1918:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9449, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1918:11:31", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9451, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1918:17:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9380, + "id": 9452, + "nodeType": "Return", + "src": "1911:24:31" + } + ] + }, + "documentation": null, + "id": 9454, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "executeOperation", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9377, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9372, + "name": "_reserve", + "nodeType": "VariableDeclaration", + "scope": 9454, + "src": "707:16:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9371, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "707:7:31", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9374, + "name": "_amount", + "nodeType": "VariableDeclaration", + "scope": 9454, + "src": "733:15:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9373, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "733:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9376, + "name": "_fee", + "nodeType": "VariableDeclaration", + "scope": 9454, + "src": "758:12:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9375, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "758:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "697:74:31" + }, + "returnParameters": { + "id": 9380, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9379, + "name": "returnedAmount", + "nodeType": "VariableDeclaration", + "scope": 9454, + "src": "789:22:31", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9378, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "789:7:31", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "788:24:31" + }, + "scope": 9455, + "src": "672:1271:31", + "stateMutability": "nonpayable", + "superFunction": 1732, + "visibility": "external" + } + ], + "scope": 9456, + "src": "181:1764:31" + } + ], + "src": "0:1945:31" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.851Z", + "devdoc": { + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockKNC.json b/client/src/contracts/MockKNC.json new file mode 100644 index 0000000..8c2d977 --- /dev/null +++ b/client/src/contracts/MockKNC.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockKNC", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockKNC.sol\":\"MockKNC\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockKNC.sol\":{\"keccak256\":\"0x1a8ef5da0b4ee28d851b85fbc682029297bdab077a75274f9b8dd7ad43bc4af0\",\"urls\":[\"bzzr://b8f8f995d81006a054477930d305f110eefe1ecff651afdfe28b73955ffa4f95\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600381526020017f4b4e4300000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600d81526020017f4b79626572204e6574776f726b0000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058208502063d99451c9d357cf1ee25a8f560f9e194f7cc4bd684b99a5ea616a8aee90029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058208502063d99451c9d357cf1ee25a8f560f9e194f7cc4bd684b99a5ea616a8aee90029", + "sourceMap": "58:145:39:-;;;122:2;99:25;;130:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;164:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:145;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:145:39:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:145:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;164:36;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;164:36:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;99:25:39;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;130:28:39;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;130:28:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;164:36:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;99:25:39:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;130:28:39:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockKNC is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"KNC\";\n string public name = \"Kyber Network\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockKNC.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockKNC.sol", + "exportedSymbols": { + "MockKNC": [ + 9674 + ] + }, + "id": 9675, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9661, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:39" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9662, + "nodeType": "ImportDirective", + "scope": 9675, + "sourceUnit": 9600, + "src": "26:29:39", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9663, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "78:13:39", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9664, + "nodeType": "InheritanceSpecifier", + "src": "78:13:39" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9674, + "linearizedBaseContracts": [ + 9674, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockKNC", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9667, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9674, + "src": "99:25:39", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9665, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "99:4:39", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9666, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "122:2:39", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9670, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9674, + "src": "130:28:39", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9668, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:39", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4b4e43", + "id": 9669, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:5:39", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e44e7f628ff17b7c7961d3f0150b75ab99038e99c1bfc32d5721c1ca23747cbc", + "typeString": "literal_string \"KNC\"" + }, + "value": "KNC" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9673, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9674, + "src": "164:36:39", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9671, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "164:6:39", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4b79626572204e6574776f726b", + "id": 9672, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "185:15:39", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_897a455cbe1df7ae3bf206d6cb237a297a3293ec5590ffe24c37c476bd9317f7", + "typeString": "literal_string \"Kyber Network\"" + }, + "value": "Kyber Network" + }, + "visibility": "public" + } + ], + "scope": 9675, + "src": "58:145:39" + } + ], + "src": "0:203:39" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockKNC.sol", + "exportedSymbols": { + "MockKNC": [ + 9674 + ] + }, + "id": 9675, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9661, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:39" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9662, + "nodeType": "ImportDirective", + "scope": 9675, + "sourceUnit": 9600, + "src": "26:29:39", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9663, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "78:13:39", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9664, + "nodeType": "InheritanceSpecifier", + "src": "78:13:39" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9674, + "linearizedBaseContracts": [ + 9674, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockKNC", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9667, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9674, + "src": "99:25:39", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9665, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "99:4:39", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9666, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "122:2:39", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9670, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9674, + "src": "130:28:39", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9668, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:39", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4b4e43", + "id": 9669, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:5:39", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e44e7f628ff17b7c7961d3f0150b75ab99038e99c1bfc32d5721c1ca23747cbc", + "typeString": "literal_string \"KNC\"" + }, + "value": "KNC" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9673, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9674, + "src": "164:36:39", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9671, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "164:6:39", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4b79626572204e6574776f726b", + "id": 9672, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "185:15:39", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_897a455cbe1df7ae3bf206d6cb237a297a3293ec5590ffe24c37c476bd9317f7", + "typeString": "literal_string \"Kyber Network\"" + }, + "value": "Kyber Network" + }, + "visibility": "public" + } + ], + "scope": 9675, + "src": "58:145:39" + } + ], + "src": "0:203:39" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.873Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockLEND.json b/client/src/contracts/MockLEND.json new file mode 100644 index 0000000..80ae49e --- /dev/null +++ b/client/src/contracts/MockLEND.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockLEND", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockLEND.sol\":\"MockLEND\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockLEND.sol\":{\"keccak256\":\"0xe1bb84fd6127a8a1404876c5446c9587972792a35d5acc504f63fcdcf22f6807\",\"urls\":[\"bzzr://2d9a073fb4562ee4aa599004ea6297c9f100924a57b07d656ef983f4ca2ff01c\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600481526020017f4c454e44000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600481526020017f4c454e440000000000000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820aabd0371d274681d58b7dfc5123f92ebcf44bea4c752037d70763dad655524ed0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820aabd0371d274681d58b7dfc5123f92ebcf44bea4c752037d70763dad655524ed0029", + "sourceMap": "59:138:40:-;;;124:2;101:25;;132:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;167:27;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;59:138;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "59:138:40:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;59:138:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;167:27;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;167:27:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;101:25:40;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;132:29:40;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;132:29:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;167:27:40;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;101:25:40:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;132:29:40:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\n\ncontract MockLEND is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"LEND\";\n string public name = \"LEND\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockLEND.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockLEND.sol", + "exportedSymbols": { + "MockLEND": [ + 9689 + ] + }, + "id": 9690, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9676, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:40" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9677, + "nodeType": "ImportDirective", + "scope": 9690, + "sourceUnit": 9600, + "src": "26:29:40", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9678, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "80:13:40", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9679, + "nodeType": "InheritanceSpecifier", + "src": "80:13:40" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9689, + "linearizedBaseContracts": [ + 9689, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockLEND", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9682, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9689, + "src": "101:25:40", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9680, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "101:4:40", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9681, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "124:2:40", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9685, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9689, + "src": "132:29:40", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9683, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "132:6:40", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44", + "id": 9684, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "155:6:40", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a31b9172bf52fb401baa1b37639dead5129410f84554091342ccc948c25c7622", + "typeString": "literal_string \"LEND\"" + }, + "value": "LEND" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9688, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9689, + "src": "167:27:40", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9686, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "167:6:40", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44", + "id": 9687, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "188:6:40", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a31b9172bf52fb401baa1b37639dead5129410f84554091342ccc948c25c7622", + "typeString": "literal_string \"LEND\"" + }, + "value": "LEND" + }, + "visibility": "public" + } + ], + "scope": 9690, + "src": "59:138:40" + } + ], + "src": "0:197:40" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockLEND.sol", + "exportedSymbols": { + "MockLEND": [ + 9689 + ] + }, + "id": 9690, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9676, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:40" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9677, + "nodeType": "ImportDirective", + "scope": 9690, + "sourceUnit": 9600, + "src": "26:29:40", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9678, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "80:13:40", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9679, + "nodeType": "InheritanceSpecifier", + "src": "80:13:40" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9689, + "linearizedBaseContracts": [ + 9689, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockLEND", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9682, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9689, + "src": "101:25:40", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9680, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "101:4:40", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9681, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "124:2:40", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9685, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9689, + "src": "132:29:40", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9683, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "132:6:40", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44", + "id": 9684, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "155:6:40", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a31b9172bf52fb401baa1b37639dead5129410f84554091342ccc948c25c7622", + "typeString": "literal_string \"LEND\"" + }, + "value": "LEND" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9688, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9689, + "src": "167:27:40", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9686, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "167:6:40", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c454e44", + "id": 9687, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "188:6:40", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a31b9172bf52fb401baa1b37639dead5129410f84554091342ccc948c25c7622", + "typeString": "literal_string \"LEND\"" + }, + "value": "LEND" + }, + "visibility": "public" + } + ], + "scope": 9690, + "src": "59:138:40" + } + ], + "src": "0:197:40" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.874Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockLINK.json b/client/src/contracts/MockLINK.json new file mode 100644 index 0000000..5c2efe3 --- /dev/null +++ b/client/src/contracts/MockLINK.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockLINK", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockLINK.sol\":\"MockLINK\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockLINK.sol\":{\"keccak256\":\"0x062e30d48e6b96d213783b8dde5b1b760892ff3d910b195257e28ec525098a40\",\"urls\":[\"bzzr://0175a264c677b986e784dd71b577e94e0f7ee9c397474dd51c11435b52a01834\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600481526020017f4c494e4b000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600981526020017f436861696e4c696e6b000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a7230582042375606aad997a6c9ef22a72d58aaf8c551ec9c8d90cacba00b455849c066b60029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a7230582042375606aad997a6c9ef22a72d58aaf8c551ec9c8d90cacba00b455849c066b60029", + "sourceMap": "58:143:41:-;;;123:2;100:25;;131:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;166:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:143;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:143:41:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:143:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;166:32;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;166:32:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:25:41;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;131:29:41;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;131:29:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;166:32:41;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:25:41:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;131:29:41:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockLINK is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"LINK\";\n string public name = \"ChainLink\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockLINK.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockLINK.sol", + "exportedSymbols": { + "MockLINK": [ + 9704 + ] + }, + "id": 9705, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9691, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:41" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9692, + "nodeType": "ImportDirective", + "scope": 9705, + "sourceUnit": 9600, + "src": "26:29:41", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9693, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:41", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9694, + "nodeType": "InheritanceSpecifier", + "src": "79:13:41" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9704, + "linearizedBaseContracts": [ + 9704, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockLINK", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9697, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9704, + "src": "100:25:41", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9695, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:41", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9696, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:41", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9700, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9704, + "src": "131:29:41", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9698, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:41", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c494e4b", + "id": 9699, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:6:41", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_921a3539bcb764c889432630877414523e7fbca00c211bc787aeae69e2e3a779", + "typeString": "literal_string \"LINK\"" + }, + "value": "LINK" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9703, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9704, + "src": "166:32:41", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9701, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "166:6:41", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "436861696e4c696e6b", + "id": 9702, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "187:11:41", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8feb024ad3f128a1fb42d0ed4fd6bc43b6d9cb6030c182e63c2249b93783dc8c", + "typeString": "literal_string \"ChainLink\"" + }, + "value": "ChainLink" + }, + "visibility": "public" + } + ], + "scope": 9705, + "src": "58:143:41" + } + ], + "src": "0:201:41" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockLINK.sol", + "exportedSymbols": { + "MockLINK": [ + 9704 + ] + }, + "id": 9705, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9691, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:41" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9692, + "nodeType": "ImportDirective", + "scope": 9705, + "sourceUnit": 9600, + "src": "26:29:41", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9693, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:41", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9694, + "nodeType": "InheritanceSpecifier", + "src": "79:13:41" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9704, + "linearizedBaseContracts": [ + 9704, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockLINK", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9697, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9704, + "src": "100:25:41", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9695, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:41", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9696, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:41", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9700, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9704, + "src": "131:29:41", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9698, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:41", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4c494e4b", + "id": 9699, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:6:41", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_921a3539bcb764c889432630877414523e7fbca00c211bc787aeae69e2e3a779", + "typeString": "literal_string \"LINK\"" + }, + "value": "LINK" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9703, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9704, + "src": "166:32:41", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9701, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "166:6:41", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "436861696e4c696e6b", + "id": 9702, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "187:11:41", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8feb024ad3f128a1fb42d0ed4fd6bc43b6d9cb6030c182e63c2249b93783dc8c", + "typeString": "literal_string \"ChainLink\"" + }, + "value": "ChainLink" + }, + "visibility": "public" + } + ], + "scope": 9705, + "src": "58:143:41" + } + ], + "src": "0:201:41" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.892Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockMANA.json b/client/src/contracts/MockMANA.json new file mode 100644 index 0000000..36149ee --- /dev/null +++ b/client/src/contracts/MockMANA.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockMANA", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockMANA.sol\":\"MockMANA\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockMANA.sol\":{\"keccak256\":\"0x3bb010fd61c8c12ec08fd893330eac6ae85bcf823f7be87253dc87fdda627cec\",\"urls\":[\"bzzr://6da0cca65b2d1d000918d30cda1ed62f4dd01504bcc4e69e12f599d7def79751\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600481526020017f4d414e41000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600c81526020017f446563656e7472616c616e64000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058200ca6ec7c87764d2de010b684e29c92ae49112a1551814a2f48650568d875f9860029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058200ca6ec7c87764d2de010b684e29c92ae49112a1551814a2f48650568d875f9860029", + "sourceMap": "58:146:42:-;;;123:2;100:25;;131:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;166:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:146;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:146:42:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:146:42;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;166:35;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;166:35:42;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:25:42;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;131:29:42;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;131:29:42;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;166:35:42;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:25:42:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;131:29:42:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockMANA is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"MANA\";\n string public name = \"Decentraland\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockMANA.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockMANA.sol", + "exportedSymbols": { + "MockMANA": [ + 9719 + ] + }, + "id": 9720, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9706, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:42" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9707, + "nodeType": "ImportDirective", + "scope": 9720, + "sourceUnit": 9600, + "src": "26:29:42", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9708, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:42", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9709, + "nodeType": "InheritanceSpecifier", + "src": "79:13:42" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9719, + "linearizedBaseContracts": [ + 9719, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockMANA", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9712, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9719, + "src": "100:25:42", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9710, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:42", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9711, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:42", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9715, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9719, + "src": "131:29:42", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9713, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:42", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4d414e41", + "id": 9714, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:6:42", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_4605d046b0132734b6fc45e75049e1422f8ec9d9cdeec93f928bdb57662cecdc", + "typeString": "literal_string \"MANA\"" + }, + "value": "MANA" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9718, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9719, + "src": "166:35:42", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9716, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "166:6:42", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "446563656e7472616c616e64", + "id": 9717, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "187:14:42", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c5d99c299e753836d0331431d76226e44a3d02048556e6b3ae889db0887b2127", + "typeString": "literal_string \"Decentraland\"" + }, + "value": "Decentraland" + }, + "visibility": "public" + } + ], + "scope": 9720, + "src": "58:146:42" + } + ], + "src": "0:204:42" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockMANA.sol", + "exportedSymbols": { + "MockMANA": [ + 9719 + ] + }, + "id": 9720, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9706, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:42" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9707, + "nodeType": "ImportDirective", + "scope": 9720, + "sourceUnit": 9600, + "src": "26:29:42", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9708, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:42", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9709, + "nodeType": "InheritanceSpecifier", + "src": "79:13:42" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9719, + "linearizedBaseContracts": [ + 9719, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockMANA", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9712, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9719, + "src": "100:25:42", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9710, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:42", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9711, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:42", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9715, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9719, + "src": "131:29:42", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9713, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:42", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4d414e41", + "id": 9714, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:6:42", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_4605d046b0132734b6fc45e75049e1422f8ec9d9cdeec93f928bdb57662cecdc", + "typeString": "literal_string \"MANA\"" + }, + "value": "MANA" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9718, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9719, + "src": "166:35:42", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9716, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "166:6:42", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "446563656e7472616c616e64", + "id": 9717, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "187:14:42", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_c5d99c299e753836d0331431d76226e44a3d02048556e6b3ae889db0887b2127", + "typeString": "literal_string \"Decentraland\"" + }, + "value": "Decentraland" + }, + "visibility": "public" + } + ], + "scope": 9720, + "src": "58:146:42" + } + ], + "src": "0:204:42" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.895Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockMKR.json b/client/src/contracts/MockMKR.json new file mode 100644 index 0000000..5613e4b --- /dev/null +++ b/client/src/contracts/MockMKR.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockMKR", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockMKR.sol\":\"MockMKR\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockMKR.sol\":{\"keccak256\":\"0x45cf2bdda107477a01be73e89e8b64836df1a1974345e94cd3ebed1627f950d2\",\"urls\":[\"bzzr://4a297fce1a49f68f91e61e18cd2b38c91e39e3ed3a2c5cb6895b2ffd81c80c77\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600381526020017f4d4b5200000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600581526020017f4d616b657200000000000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820792ddb223ca7ab6e1c648a4a0a0ec98a6f807b75a9adb8138aac8135c3a8fc980029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820792ddb223ca7ab6e1c648a4a0a0ec98a6f807b75a9adb8138aac8135c3a8fc980029", + "sourceMap": "58:137:43:-;;;122:2;99:25;;130:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;164;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:137;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:137:43:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:137:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;164:28;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;164:28:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;99:25:43;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;130:28:43;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;130:28:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;164:28:43;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;99:25:43:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;130:28:43:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockMKR is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"MKR\";\n string public name = \"Maker\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockMKR.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockMKR.sol", + "exportedSymbols": { + "MockMKR": [ + 9734 + ] + }, + "id": 9735, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9721, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:43" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9722, + "nodeType": "ImportDirective", + "scope": 9735, + "sourceUnit": 9600, + "src": "26:29:43", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9723, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "78:13:43", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9724, + "nodeType": "InheritanceSpecifier", + "src": "78:13:43" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9734, + "linearizedBaseContracts": [ + 9734, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockMKR", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9727, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9734, + "src": "99:25:43", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9725, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "99:4:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9726, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "122:2:43", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9730, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9734, + "src": "130:28:43", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9728, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:43", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4d4b52", + "id": 9729, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:5:43", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ec76ec3a7e5f010a9229e69fa1945af6f0c6cc5b0a625bf03bd6381222192020", + "typeString": "literal_string \"MKR\"" + }, + "value": "MKR" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9733, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9734, + "src": "164:28:43", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9731, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "164:6:43", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4d616b6572", + "id": 9732, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "185:7:43", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_2f64d77ec048ee1c358d6f9699755fbc440c335b22ebfe4a2656cb8eedd12b22", + "typeString": "literal_string \"Maker\"" + }, + "value": "Maker" + }, + "visibility": "public" + } + ], + "scope": 9735, + "src": "58:137:43" + } + ], + "src": "0:195:43" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockMKR.sol", + "exportedSymbols": { + "MockMKR": [ + 9734 + ] + }, + "id": 9735, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9721, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:43" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9722, + "nodeType": "ImportDirective", + "scope": 9735, + "sourceUnit": 9600, + "src": "26:29:43", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9723, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "78:13:43", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9724, + "nodeType": "InheritanceSpecifier", + "src": "78:13:43" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9734, + "linearizedBaseContracts": [ + 9734, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockMKR", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9727, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9734, + "src": "99:25:43", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9725, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "99:4:43", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9726, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "122:2:43", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9730, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9734, + "src": "130:28:43", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9728, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:43", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4d4b52", + "id": 9729, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:5:43", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ec76ec3a7e5f010a9229e69fa1945af6f0c6cc5b0a625bf03bd6381222192020", + "typeString": "literal_string \"MKR\"" + }, + "value": "MKR" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9733, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9734, + "src": "164:28:43", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9731, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "164:6:43", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4d616b6572", + "id": 9732, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "185:7:43", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_2f64d77ec048ee1c358d6f9699755fbc440c335b22ebfe4a2656cb8eedd12b22", + "typeString": "literal_string \"Maker\"" + }, + "value": "Maker" + }, + "visibility": "public" + } + ], + "scope": 9735, + "src": "58:137:43" + } + ], + "src": "0:195:43" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.896Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockREP.json b/client/src/contracts/MockREP.json new file mode 100644 index 0000000..e35b6fe --- /dev/null +++ b/client/src/contracts/MockREP.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockREP", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockREP.sol\":\"MockREP\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockREP.sol\":{\"keccak256\":\"0x2a70e03c8d0abe07cabdea10fbeac91267bfd19e1a89d698333b202fbc8d4342\",\"urls\":[\"bzzr://3853fbca191d79cf547f233280d1f10a7a7a4cc11e8535253f989cdbe3586c5c\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600381526020017f52455000000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600581526020017f417567757200000000000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a7230582087da6eb8560302156c375293c5e993c690229c388b3e0eb92f088c100780d0250029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a7230582087da6eb8560302156c375293c5e993c690229c388b3e0eb92f088c100780d0250029", + "sourceMap": "58:137:44:-;;;122:2;99:25;;130:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;164;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:137;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:137:44:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:137:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;164:28;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;164:28:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;99:25:44;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;130:28:44;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;130:28:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;164:28:44;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;99:25:44:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;130:28:44:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockREP is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"REP\";\n string public name = \"Augur\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockREP.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockREP.sol", + "exportedSymbols": { + "MockREP": [ + 9749 + ] + }, + "id": 9750, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9736, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:44" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9737, + "nodeType": "ImportDirective", + "scope": 9750, + "sourceUnit": 9600, + "src": "26:29:44", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9738, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "78:13:44", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9739, + "nodeType": "InheritanceSpecifier", + "src": "78:13:44" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9749, + "linearizedBaseContracts": [ + 9749, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockREP", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9742, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9749, + "src": "99:25:44", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9740, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "99:4:44", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9741, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "122:2:44", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9745, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9749, + "src": "130:28:44", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9743, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:44", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "524550", + "id": 9744, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:5:44", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_91a08135082b0a28b4ad8ecc7749a009e0408743a9d1cdf34dd6a58d60ee9504", + "typeString": "literal_string \"REP\"" + }, + "value": "REP" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9748, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9749, + "src": "164:28:44", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9746, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "164:6:44", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4175677572", + "id": 9747, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "185:7:44", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_4a1edde91be4c7c07976b3cb58aa57f7c46fdb07bb683281ad3a06bee2b90950", + "typeString": "literal_string \"Augur\"" + }, + "value": "Augur" + }, + "visibility": "public" + } + ], + "scope": 9750, + "src": "58:137:44" + } + ], + "src": "0:195:44" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockREP.sol", + "exportedSymbols": { + "MockREP": [ + 9749 + ] + }, + "id": 9750, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9736, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:44" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9737, + "nodeType": "ImportDirective", + "scope": 9750, + "sourceUnit": 9600, + "src": "26:29:44", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9738, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "78:13:44", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9739, + "nodeType": "InheritanceSpecifier", + "src": "78:13:44" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9749, + "linearizedBaseContracts": [ + 9749, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockREP", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9742, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9749, + "src": "99:25:44", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9740, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "99:4:44", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9741, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "122:2:44", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9745, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9749, + "src": "130:28:44", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9743, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:44", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "524550", + "id": 9744, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:5:44", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_91a08135082b0a28b4ad8ecc7749a009e0408743a9d1cdf34dd6a58d60ee9504", + "typeString": "literal_string \"REP\"" + }, + "value": "REP" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9748, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9749, + "src": "164:28:44", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9746, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "164:6:44", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "4175677572", + "id": 9747, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "185:7:44", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_4a1edde91be4c7c07976b3cb58aa57f7c46fdb07bb683281ad3a06bee2b90950", + "typeString": "literal_string \"Augur\"" + }, + "value": "Augur" + }, + "visibility": "public" + } + ], + "scope": 9750, + "src": "58:137:44" + } + ], + "src": "0:195:44" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.898Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockSUSD.json b/client/src/contracts/MockSUSD.json new file mode 100644 index 0000000..7bee143 --- /dev/null +++ b/client/src/contracts/MockSUSD.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockSUSD", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockSUSD.sol\":\"MockSUSD\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockSUSD.sol\":{\"keccak256\":\"0x667463651f24715c64ce3da34b051598e3b9af56322d7a09130fb25a5d47ea34\",\"urls\":[\"bzzr://e08fe4f0f8d23c6a3f983a91de2f91b032454b955db3befbe8da7beefbc9acb8\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260066003556040518060400160405280600481526020017f53555344000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600d81526020017f53796e746865746978205553440000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058203fdfba630f0cb5a4e74cb97bf65e787a069097d3e691eba05b36adbc8dce7dac0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058203fdfba630f0cb5a4e74cb97bf65e787a069097d3e691eba05b36adbc8dce7dac0029", + "sourceMap": "58:146:45:-;;;123:1;100:24;;130:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;165:36;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:146;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:146:45:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:146:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;165:36;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;165:36:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:24:45;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;130:29:45;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;130:29:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;165:36:45;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:24:45:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;130:29:45:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockSUSD is MintableERC20 {\n\n uint public decimals = 6;\n string public symbol = \"SUSD\";\n string public name = \"Synthetix USD\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockSUSD.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockSUSD.sol", + "exportedSymbols": { + "MockSUSD": [ + 9764 + ] + }, + "id": 9765, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9751, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:45" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9752, + "nodeType": "ImportDirective", + "scope": 9765, + "sourceUnit": 9600, + "src": "26:29:45", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9753, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:45", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9754, + "nodeType": "InheritanceSpecifier", + "src": "79:13:45" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9764, + "linearizedBaseContracts": [ + 9764, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockSUSD", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9757, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9764, + "src": "100:24:45", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9755, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:45", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "36", + "id": 9756, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:1:45", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_6_by_1", + "typeString": "int_const 6" + }, + "value": "6" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9760, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9764, + "src": "130:29:45", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9758, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:45", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "53555344", + "id": 9759, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:6:45", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e18df262d6d0bec60a8d935280235a1a1ee38eabbe83ca3eb9a1ed48b31ac8cb", + "typeString": "literal_string \"SUSD\"" + }, + "value": "SUSD" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9763, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9764, + "src": "165:36:45", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9761, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:45", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "53796e74686574697820555344", + "id": 9762, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:15:45", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_be4ba71ebf8aedacec3d2b9bb90f58aa436ac52a23591df2bd516cf59f84c4a2", + "typeString": "literal_string \"Synthetix USD\"" + }, + "value": "Synthetix USD" + }, + "visibility": "public" + } + ], + "scope": 9765, + "src": "58:146:45" + } + ], + "src": "0:204:45" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockSUSD.sol", + "exportedSymbols": { + "MockSUSD": [ + 9764 + ] + }, + "id": 9765, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9751, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:45" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9752, + "nodeType": "ImportDirective", + "scope": 9765, + "sourceUnit": 9600, + "src": "26:29:45", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9753, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:45", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9754, + "nodeType": "InheritanceSpecifier", + "src": "79:13:45" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9764, + "linearizedBaseContracts": [ + 9764, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockSUSD", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9757, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9764, + "src": "100:24:45", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9755, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:45", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "36", + "id": 9756, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:1:45", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_6_by_1", + "typeString": "int_const 6" + }, + "value": "6" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9760, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9764, + "src": "130:29:45", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9758, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:45", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "53555344", + "id": 9759, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:6:45", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e18df262d6d0bec60a8d935280235a1a1ee38eabbe83ca3eb9a1ed48b31ac8cb", + "typeString": "literal_string \"SUSD\"" + }, + "value": "SUSD" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9763, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9764, + "src": "165:36:45", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9761, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:45", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "53796e74686574697820555344", + "id": 9762, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:15:45", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_be4ba71ebf8aedacec3d2b9bb90f58aa436ac52a23591df2bd516cf59f84c4a2", + "typeString": "literal_string \"Synthetix USD\"" + }, + "value": "Synthetix USD" + }, + "visibility": "public" + } + ], + "scope": 9765, + "src": "58:146:45" + } + ], + "src": "0:204:45" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.902Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockTUSD.json b/client/src/contracts/MockTUSD.json new file mode 100644 index 0000000..d76574e --- /dev/null +++ b/client/src/contracts/MockTUSD.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockTUSD", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockTUSD.sol\":\"MockTUSD\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockTUSD.sol\":{\"keccak256\":\"0x813ecd5791e1c5b0ed400c9387ee7e72964afe26514c26765a4326649ea51ce5\",\"urls\":[\"bzzr://411364224abe7ef5ab57f2b161a4f4bf292b8235137a011b81f0fd00d4962dd3\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600481526020017f54555344000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600781526020017f547275655553440000000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058204b6bde6a800fce2e3023396e8d7e46b69c326def3317072f5618ba5759bcca3d0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058204b6bde6a800fce2e3023396e8d7e46b69c326def3317072f5618ba5759bcca3d0029", + "sourceMap": "58:141:46:-;;;123:2;100:25;;131:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;166:30;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:141;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:141:46:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:141:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;166:30;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;166:30:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:25:46;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;131:29:46;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;131:29:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;166:30:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:25:46:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;131:29:46:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockTUSD is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"TUSD\";\n string public name = \"TrueUSD\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockTUSD.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockTUSD.sol", + "exportedSymbols": { + "MockTUSD": [ + 9779 + ] + }, + "id": 9780, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9766, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:46" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9767, + "nodeType": "ImportDirective", + "scope": 9780, + "sourceUnit": 9600, + "src": "26:29:46", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9768, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:46", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9769, + "nodeType": "InheritanceSpecifier", + "src": "79:13:46" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9779, + "linearizedBaseContracts": [ + 9779, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockTUSD", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9772, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9779, + "src": "100:25:46", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9770, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:46", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9771, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:46", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9775, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9779, + "src": "131:29:46", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9773, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:46", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "54555344", + "id": 9774, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:6:46", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a1b8d8f7e538bb573797c963eeeed40d0bcb9f28c56104417d0da1b372ae3051", + "typeString": "literal_string \"TUSD\"" + }, + "value": "TUSD" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9778, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9779, + "src": "166:30:46", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9776, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "166:6:46", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "54727565555344", + "id": 9777, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "187:9:46", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_89992b47f986f2d0d755771e8d10cdf016d4c2e9e1a8c10c5e4ddfae9e8c076a", + "typeString": "literal_string \"TrueUSD\"" + }, + "value": "TrueUSD" + }, + "visibility": "public" + } + ], + "scope": 9780, + "src": "58:141:46" + } + ], + "src": "0:199:46" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockTUSD.sol", + "exportedSymbols": { + "MockTUSD": [ + 9779 + ] + }, + "id": 9780, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9766, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:46" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9767, + "nodeType": "ImportDirective", + "scope": 9780, + "sourceUnit": 9600, + "src": "26:29:46", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9768, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:46", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9769, + "nodeType": "InheritanceSpecifier", + "src": "79:13:46" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9779, + "linearizedBaseContracts": [ + 9779, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockTUSD", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9772, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9779, + "src": "100:25:46", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9770, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:46", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9771, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:46", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9775, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9779, + "src": "131:29:46", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9773, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:46", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "54555344", + "id": 9774, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:6:46", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_a1b8d8f7e538bb573797c963eeeed40d0bcb9f28c56104417d0da1b372ae3051", + "typeString": "literal_string \"TUSD\"" + }, + "value": "TUSD" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9778, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9779, + "src": "166:30:46", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9776, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "166:6:46", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "54727565555344", + "id": 9777, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "187:9:46", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_89992b47f986f2d0d755771e8d10cdf016d4c2e9e1a8c10c5e4ddfae9e8c076a", + "typeString": "literal_string \"TrueUSD\"" + }, + "value": "TrueUSD" + }, + "visibility": "public" + } + ], + "scope": 9780, + "src": "58:141:46" + } + ], + "src": "0:199:46" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.904Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockUSDC.json b/client/src/contracts/MockUSDC.json new file mode 100644 index 0000000..b90bab6 --- /dev/null +++ b/client/src/contracts/MockUSDC.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockUSDC", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockUSDC.sol\":\"MockUSDC\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockUSDC.sol\":{\"keccak256\":\"0x8ebcf327f072204792c86c54135d3fe8bf56bc934fd49e2680311c32a152bd13\",\"urls\":[\"bzzr://ec5d6e6c0fc6820852e0257cdb1696c341f617dabd5a9e5d8510047c1357263d\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260066003556040518060400160405280600481526020017f55534443000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600881526020017f55534420436f696e00000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058205961a68cf9bcd258662ce01477f2632e147772b25f8015dc8767fe04a44a6f810029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a723058205961a68cf9bcd258662ce01477f2632e147772b25f8015dc8767fe04a44a6f810029", + "sourceMap": "58:141:47:-;;;123:1;100:24;;130:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;165:31;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:141;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:141:47:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:141:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;165:31;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;165:31:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:24:47;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;130:29:47;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;130:29:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;165:31:47;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:24:47:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;130:29:47:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockUSDC is MintableERC20 {\n\n uint public decimals = 6;\n string public symbol = \"USDC\";\n string public name = \"USD Coin\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockUSDC.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockUSDC.sol", + "exportedSymbols": { + "MockUSDC": [ + 9794 + ] + }, + "id": 9795, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9781, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:47" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9782, + "nodeType": "ImportDirective", + "scope": 9795, + "sourceUnit": 9600, + "src": "26:29:47", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9783, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:47", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9784, + "nodeType": "InheritanceSpecifier", + "src": "79:13:47" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9794, + "linearizedBaseContracts": [ + 9794, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockUSDC", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9787, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9794, + "src": "100:24:47", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9785, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:47", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "36", + "id": 9786, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:1:47", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_6_by_1", + "typeString": "int_const 6" + }, + "value": "6" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9790, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9794, + "src": "130:29:47", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9788, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:47", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "55534443", + "id": 9789, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:6:47", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_d6aca1be9729c13d677335161321649cccae6a591554772516700f986f942eaa", + "typeString": "literal_string \"USDC\"" + }, + "value": "USDC" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9793, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9794, + "src": "165:31:47", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9791, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:47", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "55534420436f696e", + "id": 9792, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:10:47", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_52878b207aaddbfc15ea7bebcda681eb8ccd306e2227b61cef68505c8c056341", + "typeString": "literal_string \"USD Coin\"" + }, + "value": "USD Coin" + }, + "visibility": "public" + } + ], + "scope": 9795, + "src": "58:141:47" + } + ], + "src": "0:199:47" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockUSDC.sol", + "exportedSymbols": { + "MockUSDC": [ + 9794 + ] + }, + "id": 9795, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9781, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:47" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9782, + "nodeType": "ImportDirective", + "scope": 9795, + "sourceUnit": 9600, + "src": "26:29:47", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9783, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:47", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9784, + "nodeType": "InheritanceSpecifier", + "src": "79:13:47" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9794, + "linearizedBaseContracts": [ + 9794, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockUSDC", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9787, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9794, + "src": "100:24:47", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9785, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:47", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "36", + "id": 9786, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:1:47", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_6_by_1", + "typeString": "int_const 6" + }, + "value": "6" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9790, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9794, + "src": "130:29:47", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9788, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:47", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "55534443", + "id": 9789, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:6:47", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_d6aca1be9729c13d677335161321649cccae6a591554772516700f986f942eaa", + "typeString": "literal_string \"USDC\"" + }, + "value": "USDC" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9793, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9794, + "src": "165:31:47", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9791, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:47", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "55534420436f696e", + "id": 9792, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:10:47", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_52878b207aaddbfc15ea7bebcda681eb8ccd306e2227b61cef68505c8c056341", + "typeString": "literal_string \"USD Coin\"" + }, + "value": "USD Coin" + }, + "visibility": "public" + } + ], + "scope": 9795, + "src": "58:141:47" + } + ], + "src": "0:199:47" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.907Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockUSDT.json b/client/src/contracts/MockUSDT.json new file mode 100644 index 0000000..dc09dc5 --- /dev/null +++ b/client/src/contracts/MockUSDT.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockUSDT", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockUSDT.sol\":\"MockUSDT\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockUSDT.sol\":{\"keccak256\":\"0xd7ce344df43dbadc6f1af98ceb1dfdb42f41086dc9da8b4a9e81c1bdb7eeed85\",\"urls\":[\"bzzr://083ccb105b2bbaffdf34a2b1edb17dec6b7d6898e75276b1402241553260a85c\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260066003556040518060400160405280600481526020017f55534454000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600981526020017f5553445420436f696e000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820412aa610cf076ef7b3bcbcb63cd4eb515081535bed66cdbb639bd253a620dd730029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820412aa610cf076ef7b3bcbcb63cd4eb515081535bed66cdbb639bd253a620dd730029", + "sourceMap": "58:142:48:-;;;123:1;100:24;;130:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;165:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:142;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:142:48:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:142:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;165:32;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;165:32:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:24:48;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;130:29:48;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;130:29:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;165:32:48;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:24:48:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;130:29:48:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockUSDT is MintableERC20 {\n\n uint public decimals = 6;\n string public symbol = \"USDT\";\n string public name = \"USDT Coin\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockUSDT.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockUSDT.sol", + "exportedSymbols": { + "MockUSDT": [ + 9809 + ] + }, + "id": 9810, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9796, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:48" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9797, + "nodeType": "ImportDirective", + "scope": 9810, + "sourceUnit": 9600, + "src": "26:29:48", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9798, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:48", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9799, + "nodeType": "InheritanceSpecifier", + "src": "79:13:48" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9809, + "linearizedBaseContracts": [ + 9809, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockUSDT", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9802, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9809, + "src": "100:24:48", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9800, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:48", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "36", + "id": 9801, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:1:48", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_6_by_1", + "typeString": "int_const 6" + }, + "value": "6" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9805, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9809, + "src": "130:29:48", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9803, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:48", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "55534454", + "id": 9804, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:6:48", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8b1a1d9c2b109e527c9134b25b1a1833b16b6594f92daa9f6d9b7a6024bce9d0", + "typeString": "literal_string \"USDT\"" + }, + "value": "USDT" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9808, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9809, + "src": "165:32:48", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9806, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:48", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "5553445420436f696e", + "id": 9807, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:11:48", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_0c59e2fbe93f1401b3417411e20543027559096506fd31ddef7c295102a62dfc", + "typeString": "literal_string \"USDT Coin\"" + }, + "value": "USDT Coin" + }, + "visibility": "public" + } + ], + "scope": 9810, + "src": "58:142:48" + } + ], + "src": "0:200:48" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockUSDT.sol", + "exportedSymbols": { + "MockUSDT": [ + 9809 + ] + }, + "id": 9810, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9796, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:48" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9797, + "nodeType": "ImportDirective", + "scope": 9810, + "sourceUnit": 9600, + "src": "26:29:48", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9798, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:48", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9799, + "nodeType": "InheritanceSpecifier", + "src": "79:13:48" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9809, + "linearizedBaseContracts": [ + 9809, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockUSDT", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9802, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9809, + "src": "100:24:48", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9800, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:48", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "36", + "id": 9801, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:1:48", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_6_by_1", + "typeString": "int_const 6" + }, + "value": "6" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9805, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9809, + "src": "130:29:48", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9803, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:48", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "55534454", + "id": 9804, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:6:48", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_8b1a1d9c2b109e527c9134b25b1a1833b16b6594f92daa9f6d9b7a6024bce9d0", + "typeString": "literal_string \"USDT\"" + }, + "value": "USDT" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9808, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9809, + "src": "165:32:48", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9806, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "165:6:48", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "5553445420436f696e", + "id": 9807, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "186:11:48", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_0c59e2fbe93f1401b3417411e20543027559096506fd31ddef7c295102a62dfc", + "typeString": "literal_string \"USDT Coin\"" + }, + "value": "USDT Coin" + }, + "visibility": "public" + } + ], + "scope": 9810, + "src": "58:142:48" + } + ], + "src": "0:200:48" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.909Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockWBTC.json b/client/src/contracts/MockWBTC.json new file mode 100644 index 0000000..d2b856d --- /dev/null +++ b/client/src/contracts/MockWBTC.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockWBTC", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockWBTC.sol\":\"MockWBTC\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockWBTC.sol\":{\"keccak256\":\"0x25d3ac8bee92ba62471396ad211348e5614f60b95916ed510eb17dd1ca7e099c\",\"urls\":[\"bzzr://b8c1f988e5e92d3d11a67f696e5773bb2ab21f1490c192bea22361e5002785d8\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600481526020017f57425443000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600981526020017f5742544320436f696e000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820e7adc6871a220061ec8ed1f5e87595fd88cb349a150e923da6c086ac79915fac0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820e7adc6871a220061ec8ed1f5e87595fd88cb349a150e923da6c086ac79915fac0029", + "sourceMap": "58:143:49:-;;;123:2;100:25;;131:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;166:32;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:143;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:143:49:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:143:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;166:32;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;166:32:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;100:25:49;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;131:29:49;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;131:29:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;166:32:49;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;100:25:49:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;131:29:49:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockWBTC is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"WBTC\";\n string public name = \"WBTC Coin\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockWBTC.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockWBTC.sol", + "exportedSymbols": { + "MockWBTC": [ + 9824 + ] + }, + "id": 9825, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9811, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:49" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9812, + "nodeType": "ImportDirective", + "scope": 9825, + "sourceUnit": 9600, + "src": "26:29:49", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9813, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:49", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9814, + "nodeType": "InheritanceSpecifier", + "src": "79:13:49" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9824, + "linearizedBaseContracts": [ + 9824, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockWBTC", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9817, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9824, + "src": "100:25:49", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9815, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:49", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9816, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:49", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9820, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9824, + "src": "131:29:49", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9818, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:49", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "57425443", + "id": 9819, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:6:49", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_98da2c5e4c6b1db946694570273b859a6e4083ccc8faa155edfc4c54eb3cfd73", + "typeString": "literal_string \"WBTC\"" + }, + "value": "WBTC" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9823, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9824, + "src": "166:32:49", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9821, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "166:6:49", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "5742544320436f696e", + "id": 9822, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "187:11:49", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_d76b0bed4a5bc19b70f01e423934d352006b14ad6285750941a1dc29da78d923", + "typeString": "literal_string \"WBTC Coin\"" + }, + "value": "WBTC Coin" + }, + "visibility": "public" + } + ], + "scope": 9825, + "src": "58:143:49" + } + ], + "src": "0:201:49" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockWBTC.sol", + "exportedSymbols": { + "MockWBTC": [ + 9824 + ] + }, + "id": 9825, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9811, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:49" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9812, + "nodeType": "ImportDirective", + "scope": 9825, + "sourceUnit": 9600, + "src": "26:29:49", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9813, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "79:13:49", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9814, + "nodeType": "InheritanceSpecifier", + "src": "79:13:49" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9824, + "linearizedBaseContracts": [ + 9824, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockWBTC", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9817, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9824, + "src": "100:25:49", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9815, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "100:4:49", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9816, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "123:2:49", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9820, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9824, + "src": "131:29:49", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9818, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "131:6:49", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "57425443", + "id": 9819, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "154:6:49", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_98da2c5e4c6b1db946694570273b859a6e4083ccc8faa155edfc4c54eb3cfd73", + "typeString": "literal_string \"WBTC\"" + }, + "value": "WBTC" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9823, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9824, + "src": "166:32:49", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9821, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "166:6:49", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "5742544320436f696e", + "id": 9822, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "187:11:49", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_d76b0bed4a5bc19b70f01e423934d352006b14ad6285750941a1dc29da78d923", + "typeString": "literal_string \"WBTC Coin\"" + }, + "value": "WBTC Coin" + }, + "visibility": "public" + } + ], + "scope": 9825, + "src": "58:143:49" + } + ], + "src": "0:201:49" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.912Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/MockZRX.json b/client/src/contracts/MockZRX.json new file mode 100644 index 0000000..408d5e5 --- /dev/null +++ b/client/src/contracts/MockZRX.json @@ -0,0 +1,755 @@ +{ + "contractName": "MockZRX", + "abi": [ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "sender", + "type": "address" + }, + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "addedValue", + "type": "uint256" + } + ], + "name": "increaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "value", + "type": "uint256" + } + ], + "name": "mint", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "spender", + "type": "address" + }, + { + "name": "subtractedValue", + "type": "uint256" + } + ], + "name": "decreaseAllowance", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "recipient", + "type": "address" + }, + { + "name": "amount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "owner", + "type": "address" + }, + { + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"sender\",\"type\":\"address\"},{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"name\":\"\",\"type\":\"string\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"spender\",\"type\":\"address\"},{\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"owner\",\"type\":\"address\"},{\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{\"allowance(address,address)\":{\"details\":\"See {IERC20-allowance}.\"},\"approve(address,uint256)\":{\"details\":\"See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address.\"},\"balanceOf(address)\":{\"details\":\"See {IERC20-balanceOf}.\"},\"decreaseAllowance(address,uint256)\":{\"details\":\"Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`.\"},\"increaseAllowance(address,uint256)\":{\"details\":\"Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address.\"},\"mint(uint256)\":{\"details\":\"Function to mint tokens\",\"params\":{\"value\":\"The amount of tokens to mint.\"},\"return\":\"A boolean that indicates if the operation was successful.\"},\"totalSupply()\":{\"details\":\"See {IERC20-totalSupply}.\"},\"transfer(address,uint256)\":{\"details\":\"See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`.\"},\"transferFrom(address,address,uint256)\":{\"details\":\"See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockZRX.sol\":\"MockZRX\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol\":{\"keccak256\":\"0xd464ce8694df56c251043ed03b8b3dfded3e6e9f1f6bc2040c75770a56b21a22\",\"urls\":[\"bzzr://bec7bdac59491a1c4eeb26b5b08a92243e1dae181476d46448a663f6fe35cef2\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockZRX.sol\":{\"keccak256\":\"0x8aa416e301b55a2e69025ccfbb54ca5ecf67a862c7ffbda81ffe72524d4fc4ea\",\"urls\":[\"bzzr://d0bcb91e58feb0ae73b65c01d2f75577b1deb19c948ef496a39505842fd93e97\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]}},\"version\":1}", + "bytecode": "0x608060405260126003556040518060400160405280600381526020017f5a525800000000000000000000000000000000000000000000000000000000008152506004908051906020019062000056929190620000ab565b506040518060400160405280600781526020017f307820436f696e0000000000000000000000000000000000000000000000000081525060059080519060200190620000a4929190620000ab565b506200015a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10620000ee57805160ff19168380011785556200011f565b828001600101855582156200011f579182015b828111156200011e57825182559160200191906001019062000101565b5b5090506200012e919062000132565b5090565b6200015791905b808211156200015357600081600090555060010162000139565b5090565b90565b6112d9806200016a6000396000f3fe608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820106d7fe50a38bc24878bbcfbdb79bd7bba465e12d5cab22c036a452b3f35103c0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100b45760003560e01c806370a082311161007157806370a08231146102ca57806395d89b4114610322578063a0712d68146103a5578063a457c2d7146103eb578063a9059cbb14610451578063dd62ed3e146104b7576100b4565b806306fdde03146100b9578063095ea7b31461013c57806318160ddd146101a257806323b872dd146101c0578063313ce567146102465780633950935114610264575b600080fd5b6100c161052f565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156101015780820151818401526020810190506100e6565b50505050905090810190601f16801561012e5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6101886004803603604081101561015257600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105cd565b604051808215151515815260200191505060405180910390f35b6101aa6105eb565b6040518082815260200191505060405180910390f35b61022c600480360360608110156101d657600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506105f5565b604051808215151515815260200191505060405180910390f35b61024e6106ce565b6040518082815260200191505060405180910390f35b6102b06004803603604081101561027a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506106d4565b604051808215151515815260200191505060405180910390f35b61030c600480360360208110156102e057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610787565b6040518082815260200191505060405180910390f35b61032a6107cf565b6040518080602001828103825283818151815260200191508051906020019080838360005b8381101561036a57808201518184015260208101905061034f565b50505050905090810190601f1680156103975780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b6103d1600480360360208110156103bb57600080fd5b810190808035906020019092919050505061086d565b604051808215151515815260200191505060405180910390f35b6104376004803603604081101561040157600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610882565b604051808215151515815260200191505060405180910390f35b61049d6004803603604081101561046757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919050505061094f565b604051808215151515815260200191505060405180910390f35b610519600480360360408110156104cd57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061096d565b6040518082815260200191505060405180910390f35b60058054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156105c55780601f1061059a576101008083540402835291602001916105c5565b820191906000526020600020905b8154815290600101906020018083116105a857829003601f168201915b505050505081565b60006105e16105da6109f4565b84846109fc565b6001905092915050565b6000600254905090565b6000610602848484610bf3565b6106c38461060e6109f4565b6106be8560405180606001604052806028815260200161121860289139600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006106746109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b600190509392505050565b60035481565b600061077d6106e16109f4565b8461077885600160006106f26109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6109fc565b6001905092915050565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60048054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156108655780601f1061083a57610100808354040283529160200191610865565b820191906000526020600020905b81548152906001019060200180831161084857829003601f168201915b505050505081565b60006108793383610ff1565b60019050919050565b600061094561088f6109f4565b846109408560405180606001604052806025815260200161128960259139600160006108b96109f4565b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6109fc565b6001905092915050565b600061096361095c6109f4565b8484610bf3565b6001905092915050565b6000600160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054905092915050565b600033905090565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610a82576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260248152602001806112656024913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610b08576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260228152602001806111d06022913960400191505060405180910390fd5b80600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925836040518082815260200191505060405180910390a3505050565b600073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff161415610c79576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260258152602001806112406025913960400191505060405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415610cff576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260238152602001806111ad6023913960400191505060405180910390fd5b610d6a816040518060600160405280602681526020016111f2602691396000808773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610ea99092919063ffffffff16565b6000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002081905550610dfd816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505050565b6000838311158290610f56576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825283818151815260200191508051906020019080838360005b83811015610f1b578082015181840152602081019050610f00565b50505050905090810190601f168015610f485780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385039050809150509392505050565b600080828401905083811015610fe7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601b8152602001807f536166654d6174683a206164646974696f6e206f766572666c6f77000000000081525060200191505060405180910390fd5b8091505092915050565b600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415611094576040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252601f8152602001807f45524332303a206d696e7420746f20746865207a65726f20616464726573730081525060200191505060405180910390fd5b6110a981600254610f6990919063ffffffff16565b600281905550611100816000808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054610f6990919063ffffffff16565b6000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055508173ffffffffffffffffffffffffffffffffffffffff16600073ffffffffffffffffffffffffffffffffffffffff167fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef836040518082815260200191505060405180910390a3505056fe45524332303a207472616e7366657220746f20746865207a65726f206164647265737345524332303a20617070726f766520746f20746865207a65726f206164647265737345524332303a207472616e7366657220616d6f756e7420657863656564732062616c616e636545524332303a207472616e7366657220616d6f756e74206578636565647320616c6c6f77616e636545524332303a207472616e736665722066726f6d20746865207a65726f206164647265737345524332303a20617070726f76652066726f6d20746865207a65726f206164647265737345524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726fa165627a7a72305820106d7fe50a38bc24878bbcfbdb79bd7bba465e12d5cab22c036a452b3f35103c0029", + "sourceMap": "58:139:50:-;;;122:2;99:25;;130:28;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;164:30;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;58:139;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;:::o;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;:::-;;;;;;;", + "deployedSourceMap": "58:139:50:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;58:139:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;164:30;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;164:30:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2500:149:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2500:149:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1559:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3107:300;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3107:300:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;99:25:50;;;:::i;:::-;;;;;;;;;;;;;;;;;;;3802:207:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;3802:207:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;1706:108;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1706:108:58;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;130:28:50;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;130:28:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;363:113:34;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;363:113:34;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;4496:258:58;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;4496:258:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2017:155;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2017:155:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;2230:132;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2230:132:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;164:30:50;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;2500:149:58:-;2566:4;2582:39;2591:12;:10;:12::i;:::-;2605:7;2614:6;2582:8;:39::i;:::-;2638:4;2631:11;;2500:149;;;;:::o;1559:89::-;1603:7;1629:12;;1622:19;;1559:89;:::o;3107:300::-;3196:4;3212:36;3222:6;3230:9;3241:6;3212:9;:36::i;:::-;3258:121;3267:6;3275:12;:10;:12::i;:::-;3289:89;3327:6;3289:89;;;;;;;;;;;;;;;;;:11;:19;3301:6;3289:19;;;;;;;;;;;;;;;:33;3309:12;:10;:12::i;:::-;3289:33;;;;;;;;;;;;;;;;:37;;:89;;;;;:::i;:::-;3258:8;:121::i;:::-;3396:4;3389:11;;3107:300;;;;;:::o;99:25:50:-;;;;:::o;3802:207:58:-;3882:4;3898:83;3907:12;:10;:12::i;:::-;3921:7;3930:50;3969:10;3930:11;:25;3942:12;:10;:12::i;:::-;3930:25;;;;;;;;;;;;;;;:34;3956:7;3930:34;;;;;;;;;;;;;;;;:38;;:50;;;;:::i;:::-;3898:8;:83::i;:::-;3998:4;3991:11;;3802:207;;;;:::o;1706:108::-;1763:7;1789:9;:18;1799:7;1789:18;;;;;;;;;;;;;;;;1782:25;;1706:108;;;:::o;130:28:50:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::o;363:113:34:-;408:4;424:24;430:10;442:5;424;:24::i;:::-;465:4;458:11;;363:113;;;:::o;4496:258:58:-;4581:4;4597:129;4606:12;:10;:12::i;:::-;4620:7;4629:96;4668:15;4629:96;;;;;;;;;;;;;;;;;:11;:25;4641:12;:10;:12::i;:::-;4629:25;;;;;;;;;;;;;;;:34;4655:7;4629:34;;;;;;;;;;;;;;;;:38;;:96;;;;;:::i;:::-;4597:8;:129::i;:::-;4743:4;4736:11;;4496:258;;;;:::o;2017:155::-;2086:4;2102:42;2112:12;:10;:12::i;:::-;2126:9;2137:6;2102:9;:42::i;:::-;2161:4;2154:11;;2017:155;;;;:::o;2230:132::-;2302:7;2328:11;:18;2340:5;2328:18;;;;;;;;;;;;;;;:27;2347:7;2328:27;;;;;;;;;;;;;;;;2321:34;;2230:132;;;;:::o;788:96:55:-;833:15;867:10;860:17;;788:96;:::o;7351:332:58:-;7461:1;7444:19;;:5;:19;;;;7436:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7541:1;7522:21;;:7;:21;;;;7514:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;7623:6;7593:11;:18;7605:5;7593:18;;;;;;;;;;;;;;;:27;7612:7;7593:27;;;;;;;;;;;;;;;:36;;;;7660:7;7644:32;;7653:5;7644:32;;;7669:6;7644:32;;;;;;;;;;;;;;;;;;7351:332;;;:::o;5228:464::-;5343:1;5325:20;;:6;:20;;;;5317:70;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5426:1;5405:23;;:9;:23;;;;5397:71;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;5499;5521:6;5499:71;;;;;;;;;;;;;;;;;:9;:17;5509:6;5499:17;;;;;;;;;;;;;;;;:21;;:71;;;;;:::i;:::-;5479:9;:17;5489:6;5479:17;;;;;;;;;;;;;;;:91;;;;5603:32;5628:6;5603:9;:20;5613:9;5603:20;;;;;;;;;;;;;;;;:24;;:32;;;;:::i;:::-;5580:9;:20;5590:9;5580:20;;;;;;;;;;;;;;;:55;;;;5667:9;5650:35;;5659:6;5650:35;;;5678:6;5650:35;;;;;;;;;;;;;;;;;;5228:464;;;:::o;1732:187:56:-;1818:7;1850:1;1845;:6;;1853:12;1837:29;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1837:29:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1876:9;1892:1;1888;:5;1876:17;;1911:1;1904:8;;;1732:187;;;;;:::o;834:176::-;892:7;911:9;927:1;923;:5;911:17;;951:1;946;:6;;938:46;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1002:1;995:8;;;834:176;;;;:::o;5962:302:58:-;6056:1;6037:21;;:7;:21;;;;6029:65;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;6120:24;6137:6;6120:12;;:16;;:24;;;;:::i;:::-;6105:12;:39;;;;6175:30;6198:6;6175:9;:18;6185:7;6175:18;;;;;;;;;;;;;;;;:22;;:30;;;;:::i;:::-;6154:9;:18;6164:7;6154:18;;;;;;;;;;;;;;;:51;;;;6241:7;6220:37;;6237:1;6220:37;;;6250:6;6220:37;;;;;;;;;;;;;;;;;;5962:302;;:::o", + "source": "pragma solidity ^0.5.0;\n\n\nimport \"./MintableERC20.sol\";\n\n\ncontract MockZRX is MintableERC20 {\n\n uint public decimals = 18;\n string public symbol = \"ZRX\";\n string public name = \"0x Coin\";\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockZRX.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockZRX.sol", + "exportedSymbols": { + "MockZRX": [ + 9839 + ] + }, + "id": 9840, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9826, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:50" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9827, + "nodeType": "ImportDirective", + "scope": 9840, + "sourceUnit": 9600, + "src": "26:29:50", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9828, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "78:13:50", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9829, + "nodeType": "InheritanceSpecifier", + "src": "78:13:50" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9839, + "linearizedBaseContracts": [ + 9839, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockZRX", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9832, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9839, + "src": "99:25:50", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9830, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "99:4:50", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9831, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "122:2:50", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9835, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9839, + "src": "130:28:50", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9833, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:50", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "5a5258", + "id": 9834, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:5:50", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_b8612e326dd19fc983e73ae3bc23fa1c78a3e01478574fa7ceb5b57e589dcebd", + "typeString": "literal_string \"ZRX\"" + }, + "value": "ZRX" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9838, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9839, + "src": "164:30:50", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9836, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "164:6:50", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "307820436f696e", + "id": 9837, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "185:9:50", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_6606643ad4cc47865e59436ee002d53a05670639feb5e31c6fc5243e52868279", + "typeString": "literal_string \"0x Coin\"" + }, + "value": "0x Coin" + }, + "visibility": "public" + } + ], + "scope": 9840, + "src": "58:139:50" + } + ], + "src": "0:197:50" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MockZRX.sol", + "exportedSymbols": { + "MockZRX": [ + 9839 + ] + }, + "id": 9840, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9826, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:50" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/tokens/MintableERC20.sol", + "file": "./MintableERC20.sol", + "id": 9827, + "nodeType": "ImportDirective", + "scope": 9840, + "sourceUnit": 9600, + "src": "26:29:50", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9828, + "name": "MintableERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 9599, + "src": "78:13:50", + "typeDescriptions": { + "typeIdentifier": "t_contract$_MintableERC20_$9599", + "typeString": "contract MintableERC20" + } + }, + "id": 9829, + "nodeType": "InheritanceSpecifier", + "src": "78:13:50" + } + ], + "contractDependencies": [ + 9599, + 10953, + 11659, + 11786 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9839, + "linearizedBaseContracts": [ + 9839, + 9599, + 11659, + 11786, + 10953 + ], + "name": "MockZRX", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9832, + "name": "decimals", + "nodeType": "VariableDeclaration", + "scope": 9839, + "src": "99:25:50", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9830, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "99:4:50", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "3138", + "id": 9831, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "122:2:50", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_18_by_1", + "typeString": "int_const 18" + }, + "value": "18" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9835, + "name": "symbol", + "nodeType": "VariableDeclaration", + "scope": 9839, + "src": "130:28:50", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9833, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "130:6:50", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "5a5258", + "id": 9834, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "153:5:50", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_b8612e326dd19fc983e73ae3bc23fa1c78a3e01478574fa7ceb5b57e589dcebd", + "typeString": "literal_string \"ZRX\"" + }, + "value": "ZRX" + }, + "visibility": "public" + }, + { + "constant": false, + "id": 9838, + "name": "name", + "nodeType": "VariableDeclaration", + "scope": 9839, + "src": "164:30:50", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_string_storage", + "typeString": "string" + }, + "typeName": { + "id": 9836, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "164:6:50", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "307820436f696e", + "id": 9837, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "185:9:50", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_6606643ad4cc47865e59436ee002d53a05670639feb5e31c6fc5243e52868279", + "typeString": "literal_string \"0x Coin\"" + }, + "value": "0x Coin" + }, + "visibility": "public" + } + ], + "scope": 9840, + "src": "58:139:50" + } + ], + "src": "0:197:50" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.914Z", + "devdoc": { + "methods": { + "allowance(address,address)": { + "details": "See {IERC20-allowance}." + }, + "approve(address,uint256)": { + "details": "See {IERC20-approve}. * Requirements: * - `spender` cannot be the zero address." + }, + "balanceOf(address)": { + "details": "See {IERC20-balanceOf}." + }, + "decreaseAllowance(address,uint256)": { + "details": "Atomically decreases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address. - `spender` must have allowance for the caller of at least `subtractedValue`." + }, + "increaseAllowance(address,uint256)": { + "details": "Atomically increases the allowance granted to `spender` by the caller. * This is an alternative to {approve} that can be used as a mitigation for problems described in {IERC20-approve}. * Emits an {Approval} event indicating the updated allowance. * Requirements: * - `spender` cannot be the zero address." + }, + "mint(uint256)": { + "details": "Function to mint tokens", + "params": { + "value": "The amount of tokens to mint." + }, + "return": "A boolean that indicates if the operation was successful." + }, + "totalSupply()": { + "details": "See {IERC20-totalSupply}." + }, + "transfer(address,uint256)": { + "details": "See {IERC20-transfer}. * Requirements: * - `recipient` cannot be the zero address. - the caller must have a balance of at least `amount`." + }, + "transferFrom(address,address,uint256)": { + "details": "See {IERC20-transferFrom}. * Emits an {Approval} event indicating the updated allowance. This is not required by the EIP. See the note at the beginning of {ERC20}; * Requirements: - `sender` and `recipient` cannot be the zero address. - `sender` must have a balance of at least `amount`. - the caller must have allowance for `sender`'s tokens of at least `amount`." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/NetworkMetadataProvider.json b/client/src/contracts/NetworkMetadataProvider.json new file mode 100644 index 0000000..726892d --- /dev/null +++ b/client/src/contracts/NetworkMetadataProvider.json @@ -0,0 +1,1555 @@ +{ + "contractName": "NetworkMetadataProvider", + "abi": [ + { + "constant": true, + "inputs": [ + { + "name": "_key", + "type": "bytes32" + } + ], + "name": "getAddress", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_key", + "type": "bytes32" + } + ], + "name": "getUint", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getBlocksPerYear", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_blocksPerYear", + "type": "uint256" + } + ], + "name": "setBlocksPerYear", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getEthereumAddress", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_ethereumAddress", + "type": "address" + } + ], + "name": "setEthereumAddress", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"getEthereumAddress\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_key\",\"type\":\"bytes32\"}],\"name\":\"getAddress\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_ethereumAddress\",\"type\":\"address\"}],\"name\":\"setEthereumAddress\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getBlocksPerYear\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_key\",\"type\":\"bytes32\"}],\"name\":\"getUint\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_blocksPerYear\",\"type\":\"uint256\"}],\"name\":\"setBlocksPerYear\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol\":\"NetworkMetadataProvider\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol\":{\"keccak256\":\"0x479a8627304b58f37a4adbe06a72c7a056ad7ce6793a4ea66deeba04c6e443c8\",\"urls\":[\"bzzr://92bb0ae9b38ab361638c71c81f650ff8115da42cb4f50a0ee7a6fb5e03e5e640\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol\":{\"keccak256\":\"0x3f74e899243a66d556c0fa81875ab95ed1e3af1909b0281d03fe89590b95121f\",\"urls\":[\"bzzr://ef6ed6edeb1ec124bf1749991346f0708214f7e12c353175d36b491bce45d7a4\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]}},\"version\":1}", + "bytecode": "0x608060405234801561001057600080fd5b506103a1806100206000396000f3fe608060405234801561001057600080fd5b50600436106100625760003560e01c806317bfdd571461006757806321f8a721146100b15780635c85fe811461011f578063741de14814610163578063bd02d0f514610181578063e5fa2b70146101c3575b600080fd5b61006f6101f1565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6100dd600480360360208110156100c757600080fd5b8101908080359060200190929190505050610221565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6101616004803603602081101561013557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061025e565b005b61016b61028b565b6040518082815260200191505060405180910390f35b6101ad6004803603602081101561019757600080fd5b81019080803590602001909291905050506102bb565b6040518082815260200191505060405180910390f35b6101ef600480360360208110156101d957600080fd5b81019080803590602001909291905050506102d7565b005b600061021c7f455448455245554d5f4144445245535300000000000000000000000000000000610221565b905090565b60006001600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b6102887f455448455245554d5f414444524553530000000000000000000000000000000082610304565b50565b60006102b67f424c4f434b535f5045525f5945415200000000000000000000000000000000006102bb565b905090565b6000806000838152602001908152602001600020549050919050565b6103017f424c4f434b535f5045525f5945415200000000000000000000000000000000008261035a565b50565b806001600084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505050565b8060008084815260200190815260200160002081905550505056fea165627a7a72305820aa28fddf730f5f349abda1139607da2cb91ca041af1afefb8e27adfff967b40a0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100625760003560e01c806317bfdd571461006757806321f8a721146100b15780635c85fe811461011f578063741de14814610163578063bd02d0f514610181578063e5fa2b70146101c3575b600080fd5b61006f6101f1565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6100dd600480360360208110156100c757600080fd5b8101908080359060200190929190505050610221565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6101616004803603602081101561013557600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919050505061025e565b005b61016b61028b565b6040518082815260200191505060405180910390f35b6101ad6004803603602081101561019757600080fd5b81019080803590602001909291905050506102bb565b6040518082815260200191505060405180910390f35b6101ef600480360360208110156101d957600080fd5b81019080803590602001909291905050506102d7565b005b600061021c7f455448455245554d5f4144445245535300000000000000000000000000000000610221565b905090565b60006001600083815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169050919050565b6102887f455448455245554d5f414444524553530000000000000000000000000000000082610304565b50565b60006102b67f424c4f434b535f5045525f5945415200000000000000000000000000000000006102bb565b905090565b6000806000838152602001908152602001600020549050919050565b6103017f424c4f434b535f5045525f5945415200000000000000000000000000000000008261035a565b50565b806001600084815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505050565b8060008084815260200190815260200160002081905550505056fea165627a7a72305820aa28fddf730f5f349abda1139607da2cb91ca041af1afefb8e27adfff967b40a0029", + "sourceMap": "138:828:11:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;138:828:11;;;;;;;", + "deployedSourceMap": "138:828:11:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;138:828:11;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;661:114;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;107:103:8;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;107:103:8;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;829:134:11;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;829:134:11;;;;;;;;;;;;;;;;;;;:::i;:::-;;369:108;;;:::i;:::-;;;;;;;;;;;;;;;;;;;100:96:12;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;100:96:12;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;531:124:11;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;531:124:11;;;;;;;;;;;;;;;;;:::i;:::-;;661:114;714:7;740:28;751:16;740:10;:28::i;:::-;733:35;;661:114;:::o;107:103:8:-;162:7;188:9;:15;198:4;188:15;;;;;;;;;;;;;;;;;;;;;181:22;;107:103;;;:::o;829:134:11:-;909:47;921:16;939;909:11;:47::i;:::-;829:134;:::o;369:108::-;420:7;446:24;454:15;446:7;:24::i;:::-;439:31;;369:108;:::o;100:96:12:-;152:7;178:5;:11;184:4;178:11;;;;;;;;;;;;171:18;;100:96;;;:::o;531:124:11:-;607:41;616:15;633:14;607:8;:41::i;:::-;531:124;:::o;216:101:8:-;304:6;286:9;:15;296:4;286:15;;;;;;;;;;;;:24;;;;;;;;;;;;;;;;;;216:101;;:::o;202:94:12:-;283:6;269:5;:11;275:4;269:11;;;;;;;;;;;:20;;;;202:94;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"../interfaces/INetworkMetadataProvider.sol\";\nimport \"./UintStorage.sol\";\nimport \"./AddressStorage.sol\";\n\ncontract NetworkMetadataProvider is INetworkMetadataProvider, UintStorage, AddressStorage {\n bytes32 private constant BLOCKS_PER_YEAR = \"BLOCKS_PER_YEAR\";\n bytes32 private constant ETHEREUM_ADDRESS = \"ETHEREUM_ADDRESS\";\n\n function getBlocksPerYear() external view returns (uint256) {\n return getUint(BLOCKS_PER_YEAR);\n }\n\n // TODO: add access control rules under DAO\n function setBlocksPerYear(uint256 _blocksPerYear) external {\n return _setUint(BLOCKS_PER_YEAR, _blocksPerYear);\n }\n\n function getEthereumAddress() external view returns (address) {\n return getAddress(ETHEREUM_ADDRESS);\n }\n\n // TODO: add access control rules under DAO\n function setEthereumAddress(address _ethereumAddress) external {\n return _setAddress(ETHEREUM_ADDRESS, _ethereumAddress);\n }\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "exportedSymbols": { + "NetworkMetadataProvider": [ + 1478 + ] + }, + "id": 1479, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1420, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:11" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "file": "../interfaces/INetworkMetadataProvider.sol", + "id": 1421, + "nodeType": "ImportDirective", + "scope": 1479, + "sourceUnit": 1933, + "src": "25:52:11", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol", + "file": "./UintStorage.sol", + "id": 1422, + "nodeType": "ImportDirective", + "scope": 1479, + "sourceUnit": 1512, + "src": "78:27:11", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol", + "file": "./AddressStorage.sol", + "id": 1423, + "nodeType": "ImportDirective", + "scope": 1479, + "sourceUnit": 954, + "src": "106:30:11", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1424, + "name": "INetworkMetadataProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1932, + "src": "174:24:11", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 1425, + "nodeType": "InheritanceSpecifier", + "src": "174:24:11" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1426, + "name": "UintStorage", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1511, + "src": "200:11:11", + "typeDescriptions": { + "typeIdentifier": "t_contract$_UintStorage_$1511", + "typeString": "contract UintStorage" + } + }, + "id": 1427, + "nodeType": "InheritanceSpecifier", + "src": "200:11:11" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1428, + "name": "AddressStorage", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 953, + "src": "213:14:11", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AddressStorage_$953", + "typeString": "contract AddressStorage" + } + }, + "id": 1429, + "nodeType": "InheritanceSpecifier", + "src": "213:14:11" + } + ], + "contractDependencies": [ + 953, + 1511, + 1932 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 1478, + "linearizedBaseContracts": [ + 1478, + 953, + 1511, + 1932 + ], + "name": "NetworkMetadataProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": true, + "id": 1432, + "name": "BLOCKS_PER_YEAR", + "nodeType": "VariableDeclaration", + "scope": 1478, + "src": "234:60:11", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1430, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "234:7:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "424c4f434b535f5045525f59454152", + "id": 1431, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "277:17:11", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_dd9795cff4312d9fffd0d2b8c06e31c1e80060161f168688c608c7f1d210d2fa", + "typeString": "literal_string \"BLOCKS_PER_YEAR\"" + }, + "value": "BLOCKS_PER_YEAR" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1435, + "name": "ETHEREUM_ADDRESS", + "nodeType": "VariableDeclaration", + "scope": 1478, + "src": "300:62:11", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1433, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "300:7:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "455448455245554d5f41444452455353", + "id": 1434, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "344:18:11", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_f360571fa099fca7e2371ff8715a62086efce0e6eaeaeb308622cdf4ef44b8f2", + "typeString": "literal_string \"ETHEREUM_ADDRESS\"" + }, + "value": "ETHEREUM_ADDRESS" + }, + "visibility": "private" + }, + { + "body": { + "id": 1444, + "nodeType": "Block", + "src": "429:48:11", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1441, + "name": "BLOCKS_PER_YEAR", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1432, + "src": "454:15:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1440, + "name": "getUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1496, + "src": "446:7:11", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_uint256_$", + "typeString": "function (bytes32) view returns (uint256)" + } + }, + "id": 1442, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "446:24:11", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1439, + "id": 1443, + "nodeType": "Return", + "src": "439:31:11" + } + ] + }, + "documentation": null, + "id": 1445, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getBlocksPerYear", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1436, + "nodeType": "ParameterList", + "parameters": [], + "src": "394:2:11" + }, + "returnParameters": { + "id": 1439, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1438, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1445, + "src": "420:7:11", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1437, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "420:7:11", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "419:9:11" + }, + "scope": 1478, + "src": "369:108:11", + "stateMutability": "view", + "superFunction": 1916, + "visibility": "external" + }, + { + "body": { + "id": 1455, + "nodeType": "Block", + "src": "590:65:11", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1451, + "name": "BLOCKS_PER_YEAR", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1432, + "src": "616:15:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1452, + "name": "_blocksPerYear", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1447, + "src": "633:14:11", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 1450, + "name": "_setUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1510, + "src": "607:8:11", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_uint256_$returns$__$", + "typeString": "function (bytes32,uint256)" + } + }, + "id": 1453, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "607:41:11", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "functionReturnParameters": 1449, + "id": 1454, + "nodeType": "Return", + "src": "600:48:11" + } + ] + }, + "documentation": null, + "id": 1456, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setBlocksPerYear", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1448, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1447, + "name": "_blocksPerYear", + "nodeType": "VariableDeclaration", + "scope": 1456, + "src": "557:22:11", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1446, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "557:7:11", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "556:24:11" + }, + "returnParameters": { + "id": 1449, + "nodeType": "ParameterList", + "parameters": [], + "src": "590:0:11" + }, + "scope": 1478, + "src": "531:124:11", + "stateMutability": "nonpayable", + "superFunction": 1921, + "visibility": "external" + }, + { + "body": { + "id": 1465, + "nodeType": "Block", + "src": "723:52:11", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1462, + "name": "ETHEREUM_ADDRESS", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1435, + "src": "751:16:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1461, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "740:10:11", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1463, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "740:28:11", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1460, + "id": 1464, + "nodeType": "Return", + "src": "733:35:11" + } + ] + }, + "documentation": null, + "id": 1466, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getEthereumAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1457, + "nodeType": "ParameterList", + "parameters": [], + "src": "688:2:11" + }, + "returnParameters": { + "id": 1460, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1459, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1466, + "src": "714:7:11", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1458, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "714:7:11", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "713:9:11" + }, + "scope": 1478, + "src": "661:114:11", + "stateMutability": "view", + "superFunction": 1926, + "visibility": "external" + }, + { + "body": { + "id": 1476, + "nodeType": "Block", + "src": "892:71:11", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1472, + "name": "ETHEREUM_ADDRESS", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1435, + "src": "921:16:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1473, + "name": "_ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1468, + "src": "939:16:11", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1471, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "909:11:11", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1474, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "909:47:11", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "functionReturnParameters": 1470, + "id": 1475, + "nodeType": "Return", + "src": "902:54:11" + } + ] + }, + "documentation": null, + "id": 1477, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setEthereumAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1469, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1468, + "name": "_ethereumAddress", + "nodeType": "VariableDeclaration", + "scope": 1477, + "src": "857:24:11", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1467, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "857:7:11", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "856:26:11" + }, + "returnParameters": { + "id": 1470, + "nodeType": "ParameterList", + "parameters": [], + "src": "892:0:11" + }, + "scope": 1478, + "src": "829:134:11", + "stateMutability": "nonpayable", + "superFunction": 1931, + "visibility": "external" + } + ], + "scope": 1479, + "src": "138:828:11" + } + ], + "src": "0:967:11" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/NetworkMetadataProvider.sol", + "exportedSymbols": { + "NetworkMetadataProvider": [ + 1478 + ] + }, + "id": 1479, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1420, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:11" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "file": "../interfaces/INetworkMetadataProvider.sol", + "id": 1421, + "nodeType": "ImportDirective", + "scope": 1479, + "sourceUnit": 1933, + "src": "25:52:11", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol", + "file": "./UintStorage.sol", + "id": 1422, + "nodeType": "ImportDirective", + "scope": 1479, + "sourceUnit": 1512, + "src": "78:27:11", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol", + "file": "./AddressStorage.sol", + "id": 1423, + "nodeType": "ImportDirective", + "scope": 1479, + "sourceUnit": 954, + "src": "106:30:11", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1424, + "name": "INetworkMetadataProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1932, + "src": "174:24:11", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 1425, + "nodeType": "InheritanceSpecifier", + "src": "174:24:11" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1426, + "name": "UintStorage", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1511, + "src": "200:11:11", + "typeDescriptions": { + "typeIdentifier": "t_contract$_UintStorage_$1511", + "typeString": "contract UintStorage" + } + }, + "id": 1427, + "nodeType": "InheritanceSpecifier", + "src": "200:11:11" + }, + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 1428, + "name": "AddressStorage", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 953, + "src": "213:14:11", + "typeDescriptions": { + "typeIdentifier": "t_contract$_AddressStorage_$953", + "typeString": "contract AddressStorage" + } + }, + "id": 1429, + "nodeType": "InheritanceSpecifier", + "src": "213:14:11" + } + ], + "contractDependencies": [ + 953, + 1511, + 1932 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 1478, + "linearizedBaseContracts": [ + 1478, + 953, + 1511, + 1932 + ], + "name": "NetworkMetadataProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": true, + "id": 1432, + "name": "BLOCKS_PER_YEAR", + "nodeType": "VariableDeclaration", + "scope": 1478, + "src": "234:60:11", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1430, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "234:7:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "424c4f434b535f5045525f59454152", + "id": 1431, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "277:17:11", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_dd9795cff4312d9fffd0d2b8c06e31c1e80060161f168688c608c7f1d210d2fa", + "typeString": "literal_string \"BLOCKS_PER_YEAR\"" + }, + "value": "BLOCKS_PER_YEAR" + }, + "visibility": "private" + }, + { + "constant": true, + "id": 1435, + "name": "ETHEREUM_ADDRESS", + "nodeType": "VariableDeclaration", + "scope": 1478, + "src": "300:62:11", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1433, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "300:7:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "455448455245554d5f41444452455353", + "id": 1434, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "344:18:11", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_f360571fa099fca7e2371ff8715a62086efce0e6eaeaeb308622cdf4ef44b8f2", + "typeString": "literal_string \"ETHEREUM_ADDRESS\"" + }, + "value": "ETHEREUM_ADDRESS" + }, + "visibility": "private" + }, + { + "body": { + "id": 1444, + "nodeType": "Block", + "src": "429:48:11", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1441, + "name": "BLOCKS_PER_YEAR", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1432, + "src": "454:15:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1440, + "name": "getUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1496, + "src": "446:7:11", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_uint256_$", + "typeString": "function (bytes32) view returns (uint256)" + } + }, + "id": 1442, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "446:24:11", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1439, + "id": 1443, + "nodeType": "Return", + "src": "439:31:11" + } + ] + }, + "documentation": null, + "id": 1445, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getBlocksPerYear", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1436, + "nodeType": "ParameterList", + "parameters": [], + "src": "394:2:11" + }, + "returnParameters": { + "id": 1439, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1438, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1445, + "src": "420:7:11", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1437, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "420:7:11", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "419:9:11" + }, + "scope": 1478, + "src": "369:108:11", + "stateMutability": "view", + "superFunction": 1916, + "visibility": "external" + }, + { + "body": { + "id": 1455, + "nodeType": "Block", + "src": "590:65:11", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1451, + "name": "BLOCKS_PER_YEAR", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1432, + "src": "616:15:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1452, + "name": "_blocksPerYear", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1447, + "src": "633:14:11", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 1450, + "name": "_setUint", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1510, + "src": "607:8:11", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_uint256_$returns$__$", + "typeString": "function (bytes32,uint256)" + } + }, + "id": 1453, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "607:41:11", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "functionReturnParameters": 1449, + "id": 1454, + "nodeType": "Return", + "src": "600:48:11" + } + ] + }, + "documentation": null, + "id": 1456, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setBlocksPerYear", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1448, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1447, + "name": "_blocksPerYear", + "nodeType": "VariableDeclaration", + "scope": 1456, + "src": "557:22:11", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1446, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "557:7:11", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "556:24:11" + }, + "returnParameters": { + "id": 1449, + "nodeType": "ParameterList", + "parameters": [], + "src": "590:0:11" + }, + "scope": 1478, + "src": "531:124:11", + "stateMutability": "nonpayable", + "superFunction": 1921, + "visibility": "external" + }, + { + "body": { + "id": 1465, + "nodeType": "Block", + "src": "723:52:11", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1462, + "name": "ETHEREUM_ADDRESS", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1435, + "src": "751:16:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + ], + "id": 1461, + "name": "getAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 938, + "src": "740:10:11", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_bytes32_$returns$_t_address_$", + "typeString": "function (bytes32) view returns (address)" + } + }, + "id": 1463, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "740:28:11", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 1460, + "id": 1464, + "nodeType": "Return", + "src": "733:35:11" + } + ] + }, + "documentation": null, + "id": 1466, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getEthereumAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1457, + "nodeType": "ParameterList", + "parameters": [], + "src": "688:2:11" + }, + "returnParameters": { + "id": 1460, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1459, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1466, + "src": "714:7:11", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1458, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "714:7:11", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "713:9:11" + }, + "scope": 1478, + "src": "661:114:11", + "stateMutability": "view", + "superFunction": 1926, + "visibility": "external" + }, + { + "body": { + "id": 1476, + "nodeType": "Block", + "src": "892:71:11", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 1472, + "name": "ETHEREUM_ADDRESS", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1435, + "src": "921:16:11", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + { + "argumentTypes": null, + "id": 1473, + "name": "_ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1468, + "src": "939:16:11", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 1471, + "name": "_setAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 952, + "src": "909:11:11", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_bytes32_$_t_address_$returns$__$", + "typeString": "function (bytes32,address)" + } + }, + "id": 1474, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "909:47:11", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "functionReturnParameters": 1470, + "id": 1475, + "nodeType": "Return", + "src": "902:54:11" + } + ] + }, + "documentation": null, + "id": 1477, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setEthereumAddress", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1469, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1468, + "name": "_ethereumAddress", + "nodeType": "VariableDeclaration", + "scope": 1477, + "src": "857:24:11", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 1467, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "857:7:11", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "856:26:11" + }, + "returnParameters": { + "id": 1470, + "nodeType": "ParameterList", + "parameters": [], + "src": "892:0:11" + }, + "scope": 1478, + "src": "829:134:11", + "stateMutability": "nonpayable", + "superFunction": 1931, + "visibility": "external" + } + ], + "scope": 1479, + "src": "138:828:11" + } + ], + "src": "0:967:11" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.584Z", + "devdoc": { + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/Ownable.json b/client/src/contracts/Ownable.json new file mode 100644 index 0000000..2403a0d --- /dev/null +++ b/client/src/contracts/Ownable.json @@ -0,0 +1,2986 @@ +{ + "contractName": "Ownable", + "abi": [ + { + "inputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "previousOwner", + "type": "address" + }, + { + "indexed": true, + "name": "newOwner", + "type": "address" + } + ], + "name": "OwnershipTransferred", + "type": "event" + }, + { + "constant": true, + "inputs": [], + "name": "owner", + "outputs": [ + { + "name": "", + "type": "address" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "isOwner", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [], + "name": "renounceOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "newOwner", + "type": "address" + } + ], + "name": "transferOwnership", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[],\"name\":\"renounceOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"isOwner\",\"outputs\":[{\"name\":\"\",\"type\":\"bool\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"name\":\"previousOwner\",\"type\":\"address\"},{\"indexed\":true,\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"OwnershipTransferred\",\"type\":\"event\"}],\"devdoc\":{\"details\":\"Contract module which provides a basic access control mechanism, where there is an account (an owner) that can be granted exclusive access to specific functions. * This module is used through inheritance. It will make available the modifier `onlyOwner`, which can be applied to your functions to restrict their use to the owner.\",\"methods\":{\"constructor\":{\"details\":\"Initializes the contract setting the deployer as the initial owner.\"},\"isOwner()\":{\"details\":\"Returns true if the caller is the current owner.\"},\"owner()\":{\"details\":\"Returns the address of the current owner.\"},\"renounceOwnership()\":{\"details\":\"Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner.\"},\"transferOwnership(address)\":{\"details\":\"Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner.\"}}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":\"Ownable\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\nimport \"../GSN/Context.sol\";\n/**\n * @dev Contract module which provides a basic access control mechanism, where\n * there is an account (an owner) that can be granted exclusive access to\n * specific functions.\n *\n * This module is used through inheritance. It will make available the modifier\n * `onlyOwner`, which can be applied to your functions to restrict their use to\n * the owner.\n */\ncontract Ownable is Context {\n address private _owner;\n\n event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);\n\n /**\n * @dev Initializes the contract setting the deployer as the initial owner.\n */\n constructor () internal {\n _owner = _msgSender();\n emit OwnershipTransferred(address(0), _owner);\n }\n\n /**\n * @dev Returns the address of the current owner.\n */\n function owner() public view returns (address) {\n return _owner;\n }\n\n /**\n * @dev Throws if called by any account other than the owner.\n */\n modifier onlyOwner() {\n require(isOwner(), \"Ownable: caller is not the owner\");\n _;\n }\n\n /**\n * @dev Returns true if the caller is the current owner.\n */\n function isOwner() public view returns (bool) {\n return _msgSender() == _owner;\n }\n\n /**\n * @dev Leaves the contract without owner. It will not be possible to call\n * `onlyOwner` functions anymore. Can only be called by the current owner.\n *\n * NOTE: Renouncing ownership will leave the contract without an owner,\n * thereby removing any functionality that is only available to the owner.\n */\n function renounceOwnership() public onlyOwner {\n emit OwnershipTransferred(_owner, address(0));\n _owner = address(0);\n }\n\n /**\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\n * Can only be called by the current owner.\n */\n function transferOwnership(address newOwner) public onlyOwner {\n _transferOwnership(newOwner);\n }\n\n /**\n * @dev Transfers ownership of the contract to a new account (`newOwner`).\n */\n function _transferOwnership(address newOwner) internal {\n require(newOwner != address(0), \"Ownable: new owner is the zero address\");\n emit OwnershipTransferred(_owner, newOwner);\n _owner = newOwner;\n }\n}\n", + "sourcePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "ast": { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "exportedSymbols": { + "Ownable": [ + 11254 + ] + }, + "id": 11255, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 11142, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:57" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/GSN/Context.sol", + "file": "../GSN/Context.sol", + "id": 11143, + "nodeType": "ImportDirective", + "scope": 11255, + "sourceUnit": 10954, + "src": "25:28:57", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 11144, + "name": "Context", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10953, + "src": "435:7:57", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Context_$10953", + "typeString": "contract Context" + } + }, + "id": 11145, + "nodeType": "InheritanceSpecifier", + "src": "435:7:57" + } + ], + "contractDependencies": [ + 10953 + ], + "contractKind": "contract", + "documentation": "@dev Contract module which provides a basic access control mechanism, where\nthere is an account (an owner) that can be granted exclusive access to\nspecific functions.\n * This module is used through inheritance. It will make available the modifier\n`onlyOwner`, which can be applied to your functions to restrict their use to\nthe owner.", + "fullyImplemented": true, + "id": 11254, + "linearizedBaseContracts": [ + 11254, + 10953 + ], + "name": "Ownable", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 11147, + "name": "_owner", + "nodeType": "VariableDeclaration", + "scope": 11254, + "src": "449:22:57", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11146, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "449:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "private" + }, + { + "anonymous": false, + "documentation": null, + "id": 11153, + "name": "OwnershipTransferred", + "nodeType": "EventDefinition", + "parameters": { + "id": 11152, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11149, + "indexed": true, + "name": "previousOwner", + "nodeType": "VariableDeclaration", + "scope": 11153, + "src": "505:29:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11148, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "505:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11151, + "indexed": true, + "name": "newOwner", + "nodeType": "VariableDeclaration", + "scope": 11153, + "src": "536:24:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11150, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "536:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "504:57:57" + }, + "src": "478:84:57" + }, + { + "body": { + "id": 11168, + "nodeType": "Block", + "src": "688:93:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11159, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11156, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "698:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 11157, + "name": "_msgSender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10941, + "src": "707:10:57", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" + } + }, + "id": 11158, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "707:12:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "698:21:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 11160, + "nodeType": "ExpressionStatement", + "src": "698:21:57" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "30", + "id": 11163, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "763:1:57", + "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": 11162, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "755:7:57", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11164, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "755:10:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 11165, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "767:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 11161, + "name": "OwnershipTransferred", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11153, + "src": "734:20:57", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address)" + } + }, + "id": 11166, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "734:40:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11167, + "nodeType": "EmitStatement", + "src": "729:45:57" + } + ] + }, + "documentation": "@dev Initializes the contract setting the deployer as the initial owner.", + "id": 11169, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11154, + "nodeType": "ParameterList", + "parameters": [], + "src": "676:2:57" + }, + "returnParameters": { + "id": 11155, + "nodeType": "ParameterList", + "parameters": [], + "src": "688:0:57" + }, + "scope": 11254, + "src": "664:117:57", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11176, + "nodeType": "Block", + "src": "904:30:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11174, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "921:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 11173, + "id": 11175, + "nodeType": "Return", + "src": "914:13:57" + } + ] + }, + "documentation": "@dev Returns the address of the current owner.", + "id": 11177, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "owner", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11170, + "nodeType": "ParameterList", + "parameters": [], + "src": "871:2:57" + }, + "returnParameters": { + "id": 11173, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11172, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11177, + "src": "895:7:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11171, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "895:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "894:9:57" + }, + "scope": 11254, + "src": "857:77:57", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11186, + "nodeType": "Block", + "src": "1043:82:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 11180, + "name": "isOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11198, + "src": "1061:7:57", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$", + "typeString": "function () view returns (bool)" + } + }, + "id": 11181, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1061:9:57", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572", + "id": 11182, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1072:34:57", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_9924ebdf1add33d25d4ef888e16131f0a5687b0580a36c21b5c301a6c462effe", + "typeString": "literal_string \"Ownable: caller is not the owner\"" + }, + "value": "Ownable: caller is not the owner" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_9924ebdf1add33d25d4ef888e16131f0a5687b0580a36c21b5c301a6c462effe", + "typeString": "literal_string \"Ownable: caller is not the owner\"" + } + ], + "id": 11179, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1053:7:57", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11183, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1053:54:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11184, + "nodeType": "ExpressionStatement", + "src": "1053:54:57" + }, + { + "id": 11185, + "nodeType": "PlaceholderStatement", + "src": "1117:1:57" + } + ] + }, + "documentation": "@dev Throws if called by any account other than the owner.", + "id": 11187, + "name": "onlyOwner", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 11178, + "nodeType": "ParameterList", + "parameters": [], + "src": "1040:2:57" + }, + "src": "1022:103:57", + "visibility": "internal" + }, + { + "body": { + "id": 11197, + "nodeType": "Block", + "src": "1254:46:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 11195, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 11192, + "name": "_msgSender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10941, + "src": "1271:10:57", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" + } + }, + "id": 11193, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1271:12:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 11194, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "1287:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1271:22:57", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 11191, + "id": 11196, + "nodeType": "Return", + "src": "1264:29:57" + } + ] + }, + "documentation": "@dev Returns true if the caller is the current owner.", + "id": 11198, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isOwner", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11188, + "nodeType": "ParameterList", + "parameters": [], + "src": "1224:2:57" + }, + "returnParameters": { + "id": 11191, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11190, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11198, + "src": "1248:4:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 11189, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "1248:4:57", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1247:6:57" + }, + "scope": 11254, + "src": "1208:92:57", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11216, + "nodeType": "Block", + "src": "1688:91:57", + "statements": [ + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11204, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "1724:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "30", + "id": 11206, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1740:1:57", + "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": 11205, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1732:7:57", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11207, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1732:10:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 11203, + "name": "OwnershipTransferred", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11153, + "src": "1703:20:57", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address)" + } + }, + "id": 11208, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1703:40:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11209, + "nodeType": "EmitStatement", + "src": "1698:45:57" + }, + { + "expression": { + "argumentTypes": null, + "id": 11214, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11210, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "1753:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "30", + "id": 11212, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1770:1:57", + "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": 11211, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1762:7:57", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11213, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1762:10:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "1753:19:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 11215, + "nodeType": "ExpressionStatement", + "src": "1753:19:57" + } + ] + }, + "documentation": "@dev Leaves the contract without owner. It will not be possible to call\n`onlyOwner` functions anymore. Can only be called by the current owner.\n * NOTE: Renouncing ownership will leave the contract without an owner,\nthereby removing any functionality that is only available to the owner.", + "id": 11217, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 11201, + "modifierName": { + "argumentTypes": null, + "id": 11200, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "1678:9:57", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "1678:9:57" + } + ], + "name": "renounceOwnership", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11199, + "nodeType": "ParameterList", + "parameters": [], + "src": "1668:2:57" + }, + "returnParameters": { + "id": 11202, + "nodeType": "ParameterList", + "parameters": [], + "src": "1688:0:57" + }, + "scope": 11254, + "src": "1642:137:57", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11228, + "nodeType": "Block", + "src": "1990:45:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11225, + "name": "newOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11219, + "src": "2019:8:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 11224, + "name": "_transferOwnership", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11253, + "src": "2000:18:57", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 11226, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2000:28:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11227, + "nodeType": "ExpressionStatement", + "src": "2000:28:57" + } + ] + }, + "documentation": "@dev Transfers ownership of the contract to a new account (`newOwner`).\nCan only be called by the current owner.", + "id": 11229, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 11222, + "modifierName": { + "argumentTypes": null, + "id": 11221, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "1980:9:57", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "1980:9:57" + } + ], + "name": "transferOwnership", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11220, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11219, + "name": "newOwner", + "nodeType": "VariableDeclaration", + "scope": 11229, + "src": "1955:16:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11218, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1955:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1954:18:57" + }, + "returnParameters": { + "id": 11223, + "nodeType": "ParameterList", + "parameters": [], + "src": "1990:0:57" + }, + "scope": 11254, + "src": "1928:107:57", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11252, + "nodeType": "Block", + "src": "2191:170:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 11239, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 11235, + "name": "newOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11231, + "src": "2209:8:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "30", + "id": 11237, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2229:1:57", + "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": 11236, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2221:7:57", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11238, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2221:10:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "2209:22:57", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373", + "id": 11240, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2233:40:57", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_245f15ff17f551913a7a18385165551503906a406f905ac1c2437281a7cd0cfe", + "typeString": "literal_string \"Ownable: new owner is the zero address\"" + }, + "value": "Ownable: new owner is the zero address" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_245f15ff17f551913a7a18385165551503906a406f905ac1c2437281a7cd0cfe", + "typeString": "literal_string \"Ownable: new owner is the zero address\"" + } + ], + "id": 11234, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2201:7:57", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11241, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2201:73:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11242, + "nodeType": "ExpressionStatement", + "src": "2201:73:57" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11244, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "2310:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11245, + "name": "newOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11231, + "src": "2318:8:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 11243, + "name": "OwnershipTransferred", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11153, + "src": "2289:20:57", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address)" + } + }, + "id": 11246, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2289:38:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11247, + "nodeType": "EmitStatement", + "src": "2284:43:57" + }, + { + "expression": { + "argumentTypes": null, + "id": 11250, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11248, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "2337:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 11249, + "name": "newOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11231, + "src": "2346:8:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "2337:17:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 11251, + "nodeType": "ExpressionStatement", + "src": "2337:17:57" + } + ] + }, + "documentation": "@dev Transfers ownership of the contract to a new account (`newOwner`).", + "id": 11253, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "_transferOwnership", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11232, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11231, + "name": "newOwner", + "nodeType": "VariableDeclaration", + "scope": 11253, + "src": "2164:16:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11230, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2164:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2163:18:57" + }, + "returnParameters": { + "id": 11233, + "nodeType": "ParameterList", + "parameters": [], + "src": "2191:0:57" + }, + "scope": 11254, + "src": "2136:225:57", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 11255, + "src": "415:1948:57" + } + ], + "src": "0:2364:57" + }, + "legacyAST": { + "absolutePath": "openzeppelin-solidity/contracts/ownership/Ownable.sol", + "exportedSymbols": { + "Ownable": [ + 11254 + ] + }, + "id": 11255, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 11142, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:57" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/GSN/Context.sol", + "file": "../GSN/Context.sol", + "id": 11143, + "nodeType": "ImportDirective", + "scope": 11255, + "sourceUnit": 10954, + "src": "25:28:57", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 11144, + "name": "Context", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 10953, + "src": "435:7:57", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Context_$10953", + "typeString": "contract Context" + } + }, + "id": 11145, + "nodeType": "InheritanceSpecifier", + "src": "435:7:57" + } + ], + "contractDependencies": [ + 10953 + ], + "contractKind": "contract", + "documentation": "@dev Contract module which provides a basic access control mechanism, where\nthere is an account (an owner) that can be granted exclusive access to\nspecific functions.\n * This module is used through inheritance. It will make available the modifier\n`onlyOwner`, which can be applied to your functions to restrict their use to\nthe owner.", + "fullyImplemented": true, + "id": 11254, + "linearizedBaseContracts": [ + 11254, + 10953 + ], + "name": "Ownable", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 11147, + "name": "_owner", + "nodeType": "VariableDeclaration", + "scope": 11254, + "src": "449:22:57", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11146, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "449:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "private" + }, + { + "anonymous": false, + "documentation": null, + "id": 11153, + "name": "OwnershipTransferred", + "nodeType": "EventDefinition", + "parameters": { + "id": 11152, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11149, + "indexed": true, + "name": "previousOwner", + "nodeType": "VariableDeclaration", + "scope": 11153, + "src": "505:29:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11148, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "505:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11151, + "indexed": true, + "name": "newOwner", + "nodeType": "VariableDeclaration", + "scope": 11153, + "src": "536:24:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11150, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "536:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "504:57:57" + }, + "src": "478:84:57" + }, + { + "body": { + "id": 11168, + "nodeType": "Block", + "src": "688:93:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11159, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11156, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "698:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 11157, + "name": "_msgSender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10941, + "src": "707:10:57", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" + } + }, + "id": 11158, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "707:12:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "698:21:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 11160, + "nodeType": "ExpressionStatement", + "src": "698:21:57" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "30", + "id": 11163, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "763:1:57", + "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": 11162, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "755:7:57", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11164, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "755:10:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + { + "argumentTypes": null, + "id": 11165, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "767:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 11161, + "name": "OwnershipTransferred", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11153, + "src": "734:20:57", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address)" + } + }, + "id": 11166, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "734:40:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11167, + "nodeType": "EmitStatement", + "src": "729:45:57" + } + ] + }, + "documentation": "@dev Initializes the contract setting the deployer as the initial owner.", + "id": 11169, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11154, + "nodeType": "ParameterList", + "parameters": [], + "src": "676:2:57" + }, + "returnParameters": { + "id": 11155, + "nodeType": "ParameterList", + "parameters": [], + "src": "688:0:57" + }, + "scope": 11254, + "src": "664:117:57", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11176, + "nodeType": "Block", + "src": "904:30:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 11174, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "921:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "functionReturnParameters": 11173, + "id": 11175, + "nodeType": "Return", + "src": "914:13:57" + } + ] + }, + "documentation": "@dev Returns the address of the current owner.", + "id": 11177, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "owner", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11170, + "nodeType": "ParameterList", + "parameters": [], + "src": "871:2:57" + }, + "returnParameters": { + "id": 11173, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11172, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11177, + "src": "895:7:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11171, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "895:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "894:9:57" + }, + "scope": 11254, + "src": "857:77:57", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11186, + "nodeType": "Block", + "src": "1043:82:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 11180, + "name": "isOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11198, + "src": "1061:7:57", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_bool_$", + "typeString": "function () view returns (bool)" + } + }, + "id": 11181, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1061:9:57", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "4f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572", + "id": 11182, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1072:34:57", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_9924ebdf1add33d25d4ef888e16131f0a5687b0580a36c21b5c301a6c462effe", + "typeString": "literal_string \"Ownable: caller is not the owner\"" + }, + "value": "Ownable: caller is not the owner" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_9924ebdf1add33d25d4ef888e16131f0a5687b0580a36c21b5c301a6c462effe", + "typeString": "literal_string \"Ownable: caller is not the owner\"" + } + ], + "id": 11179, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1053:7:57", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11183, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1053:54:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11184, + "nodeType": "ExpressionStatement", + "src": "1053:54:57" + }, + { + "id": 11185, + "nodeType": "PlaceholderStatement", + "src": "1117:1:57" + } + ] + }, + "documentation": "@dev Throws if called by any account other than the owner.", + "id": 11187, + "name": "onlyOwner", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 11178, + "nodeType": "ParameterList", + "parameters": [], + "src": "1040:2:57" + }, + "src": "1022:103:57", + "visibility": "internal" + }, + { + "body": { + "id": 11197, + "nodeType": "Block", + "src": "1254:46:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 11195, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "id": 11192, + "name": "_msgSender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10941, + "src": "1271:10:57", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$__$returns$_t_address_payable_$", + "typeString": "function () view returns (address payable)" + } + }, + "id": 11193, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1271:12:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 11194, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "1287:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "1271:22:57", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "functionReturnParameters": 11191, + "id": 11196, + "nodeType": "Return", + "src": "1264:29:57" + } + ] + }, + "documentation": "@dev Returns true if the caller is the current owner.", + "id": 11198, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "isOwner", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11188, + "nodeType": "ParameterList", + "parameters": [], + "src": "1224:2:57" + }, + "returnParameters": { + "id": 11191, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11190, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11198, + "src": "1248:4:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 11189, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "1248:4:57", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1247:6:57" + }, + "scope": 11254, + "src": "1208:92:57", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11216, + "nodeType": "Block", + "src": "1688:91:57", + "statements": [ + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11204, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "1724:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "30", + "id": 11206, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1740:1:57", + "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": 11205, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1732:7:57", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11207, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1732:10:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 11203, + "name": "OwnershipTransferred", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11153, + "src": "1703:20:57", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address)" + } + }, + "id": 11208, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1703:40:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11209, + "nodeType": "EmitStatement", + "src": "1698:45:57" + }, + { + "expression": { + "argumentTypes": null, + "id": 11214, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11210, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "1753:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "30", + "id": 11212, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1770:1:57", + "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": 11211, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1762:7:57", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11213, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1762:10:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "1753:19:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 11215, + "nodeType": "ExpressionStatement", + "src": "1753:19:57" + } + ] + }, + "documentation": "@dev Leaves the contract without owner. It will not be possible to call\n`onlyOwner` functions anymore. Can only be called by the current owner.\n * NOTE: Renouncing ownership will leave the contract without an owner,\nthereby removing any functionality that is only available to the owner.", + "id": 11217, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 11201, + "modifierName": { + "argumentTypes": null, + "id": 11200, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "1678:9:57", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "1678:9:57" + } + ], + "name": "renounceOwnership", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11199, + "nodeType": "ParameterList", + "parameters": [], + "src": "1668:2:57" + }, + "returnParameters": { + "id": 11202, + "nodeType": "ParameterList", + "parameters": [], + "src": "1688:0:57" + }, + "scope": 11254, + "src": "1642:137:57", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11228, + "nodeType": "Block", + "src": "1990:45:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11225, + "name": "newOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11219, + "src": "2019:8:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 11224, + "name": "_transferOwnership", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11253, + "src": "2000:18:57", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_address_$returns$__$", + "typeString": "function (address)" + } + }, + "id": 11226, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2000:28:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11227, + "nodeType": "ExpressionStatement", + "src": "2000:28:57" + } + ] + }, + "documentation": "@dev Transfers ownership of the contract to a new account (`newOwner`).\nCan only be called by the current owner.", + "id": 11229, + "implemented": true, + "kind": "function", + "modifiers": [ + { + "arguments": null, + "id": 11222, + "modifierName": { + "argumentTypes": null, + "id": 11221, + "name": "onlyOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11187, + "src": "1980:9:57", + "typeDescriptions": { + "typeIdentifier": "t_modifier$__$", + "typeString": "modifier ()" + } + }, + "nodeType": "ModifierInvocation", + "src": "1980:9:57" + } + ], + "name": "transferOwnership", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11220, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11219, + "name": "newOwner", + "nodeType": "VariableDeclaration", + "scope": 11229, + "src": "1955:16:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11218, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1955:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1954:18:57" + }, + "returnParameters": { + "id": 11223, + "nodeType": "ParameterList", + "parameters": [], + "src": "1990:0:57" + }, + "scope": 11254, + "src": "1928:107:57", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 11252, + "nodeType": "Block", + "src": "2191:170:57", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 11239, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 11235, + "name": "newOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11231, + "src": "2209:8:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "30", + "id": 11237, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2229:1:57", + "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": 11236, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2221:7:57", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11238, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2221:10:57", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + }, + "src": "2209:22:57", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "4f776e61626c653a206e6577206f776e657220697320746865207a65726f2061646472657373", + "id": 11240, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2233:40:57", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_245f15ff17f551913a7a18385165551503906a406f905ac1c2437281a7cd0cfe", + "typeString": "literal_string \"Ownable: new owner is the zero address\"" + }, + "value": "Ownable: new owner is the zero address" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_245f15ff17f551913a7a18385165551503906a406f905ac1c2437281a7cd0cfe", + "typeString": "literal_string \"Ownable: new owner is the zero address\"" + } + ], + "id": 11234, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2201:7:57", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11241, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2201:73:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11242, + "nodeType": "ExpressionStatement", + "src": "2201:73:57" + }, + { + "eventCall": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11244, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "2310:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11245, + "name": "newOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11231, + "src": "2318:8:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 11243, + "name": "OwnershipTransferred", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11153, + "src": "2289:20:57", + "typeDescriptions": { + "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_address_$returns$__$", + "typeString": "function (address,address)" + } + }, + "id": 11246, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2289:38:57", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11247, + "nodeType": "EmitStatement", + "src": "2284:43:57" + }, + { + "expression": { + "argumentTypes": null, + "id": 11250, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 11248, + "name": "_owner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11147, + "src": "2337:6:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 11249, + "name": "newOwner", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11231, + "src": "2346:8:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "2337:17:57", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 11251, + "nodeType": "ExpressionStatement", + "src": "2337:17:57" + } + ] + }, + "documentation": "@dev Transfers ownership of the contract to a new account (`newOwner`).", + "id": 11253, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "_transferOwnership", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11232, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11231, + "name": "newOwner", + "nodeType": "VariableDeclaration", + "scope": 11253, + "src": "2164:16:57", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11230, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2164:7:57", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2163:18:57" + }, + "returnParameters": { + "id": 11233, + "nodeType": "ParameterList", + "parameters": [], + "src": "2191:0:57" + }, + "scope": 11254, + "src": "2136:225:57", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 11255, + "src": "415:1948:57" + } + ], + "src": "0:2364:57" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.944Z", + "devdoc": { + "details": "Contract module which provides a basic access control mechanism, where there is an account (an owner) that can be granted exclusive access to specific functions. * This module is used through inheritance. It will make available the modifier `onlyOwner`, which can be applied to your functions to restrict their use to the owner.", + "methods": { + "constructor": { + "details": "Initializes the contract setting the deployer as the initial owner." + }, + "isOwner()": { + "details": "Returns true if the caller is the current owner." + }, + "owner()": { + "details": "Returns the address of the current owner." + }, + "renounceOwnership()": { + "details": "Leaves the contract without owner. It will not be possible to call `onlyOwner` functions anymore. Can only be called by the current owner. * NOTE: Renouncing ownership will leave the contract without an owner, thereby removing any functionality that is only available to the owner." + }, + "transferOwnership(address)": { + "details": "Transfers ownership of the contract to a new account (`newOwner`). Can only be called by the current owner." + } + } + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/PriceOracle.json b/client/src/contracts/PriceOracle.json new file mode 100644 index 0000000..1bb6c7a --- /dev/null +++ b/client/src/contracts/PriceOracle.json @@ -0,0 +1,1338 @@ +{ + "contractName": "PriceOracle", + "abi": [ + { + "constant": true, + "inputs": [ + { + "name": "_asset", + "type": "address" + } + ], + "name": "getAssetPrice", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_asset", + "type": "address" + }, + { + "name": "_price", + "type": "uint256" + } + ], + "name": "setAssetPrice", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "getEthUsdPrice", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_price", + "type": "uint256" + } + ], + "name": "setEthUsdPrice", + "outputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"},{\"name\":\"_price\",\"type\":\"uint256\"}],\"name\":\"setAssetPrice\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"getEthUsdPrice\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_asset\",\"type\":\"address\"}],\"name\":\"getAssetPrice\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"_price\",\"type\":\"uint256\"}],\"name\":\"setEthUsdPrice\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/mocks/Oracle/PriceOracle.sol\":\"PriceOracle\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x0adf744884b9262f507aba565d1c96c82397f58d399a2dc2c60a452953197574\",\"urls\":[\"bzzr://03099f88c041565b5ac13ea7e645a8f9bff0c29bfa584c7969372ce12c5473f5\"]},\"/Users/jg/Documents/aaveBot/contracts/mocks/Oracle/PriceOracle.sol\":{\"keccak256\":\"0xcafd72e3d1f91f33561b891942bf4c5062506242dc2355c7480b761a01a5345b\",\"urls\":[\"bzzr://3d97a8cf708d0c1b6a15f165f45d94dd8ccd022442381abdc6080aac1d08272b\"]}},\"version\":1}", + "bytecode": "0x608060405234801561001057600080fd5b50610212806100206000396000f3fe608060405234801561001057600080fd5b506004361061004c5760003560e01c806351323f7214610051578063a0a8045e1461009f578063b3596f07146100bd578063b951883a14610115575b600080fd5b61009d6004803603604081101561006757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610143565b005b6100a761018a565b6040518082815260200191505060405180910390f35b6100ff600480360360208110156100d357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610194565b6040518082815260200191505060405180910390f35b6101416004803603602081101561012b57600080fd5b81019080803590602001909291905050506101dc565b005b806000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505050565b6000600154905090565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b806001819055505056fea165627a7a72305820834db48efbaf5f23b30b109aab929489665ee414514535528bc272ad18b88f6b0029", + "deployedBytecode": "0x608060405234801561001057600080fd5b506004361061004c5760003560e01c806351323f7214610051578063a0a8045e1461009f578063b3596f07146100bd578063b951883a14610115575b600080fd5b61009d6004803603604081101561006757600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190505050610143565b005b6100a761018a565b6040518082815260200191505060405180910390f35b6100ff600480360360208110156100d357600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610194565b6040518082815260200191505060405180910390f35b6101416004803603602081101561012b57600080fd5b81019080803590602001909291905050506101dc565b005b806000808473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055505050565b6000600154905090565b60008060008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b806001819055505056fea165627a7a72305820834db48efbaf5f23b30b109aab929489665ee414514535528bc272ad18b88f6b0029", + "sourceMap": "71:502:33:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;71:502:33;;;;;;;", + "deployedSourceMap": "71:502:33:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;71:502:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;286:101;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;286:101:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;393:89;;;:::i;:::-;;;;;;;;;;;;;;;;;;;175:105;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;175:105:33;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;488:83;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;488:83:33;;;;;;;;;;;;;;;;;:::i;:::-;;286:101;374:6;357;:14;364:6;357:14;;;;;;;;;;;;;;;:23;;;;286:101;;:::o;393:89::-;441:4;464:11;;457:18;;393:89;:::o;175:105::-;236:4;259:6;:14;266:6;259:14;;;;;;;;;;;;;;;;252:21;;175:105;;;:::o;488:83::-;558:6;544:11;:20;;;;488:83;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"../../interfaces/IPriceOracle.sol\";\n\n\ncontract PriceOracle is IPriceOracle {\n\n mapping(address => uint) prices;\n uint ethPriceUsd;\n\n function getAssetPrice(address _asset) external view returns(uint) {\n return prices[_asset];\n }\n\n function setAssetPrice(address _asset, uint _price) external {\n prices[_asset] = _price;\n }\n\n function getEthUsdPrice() external view returns(uint) {\n return ethPriceUsd;\n }\n\n function setEthUsdPrice(uint _price) external {\n ethPriceUsd = _price;\n }\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/mocks/Oracle/PriceOracle.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/Oracle/PriceOracle.sol", + "exportedSymbols": { + "PriceOracle": [ + 9577 + ] + }, + "id": 9578, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9523, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:33" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol", + "file": "../../interfaces/IPriceOracle.sol", + "id": 9524, + "nodeType": "ImportDirective", + "scope": 9578, + "sourceUnit": 1960, + "src": "25:43:33", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9525, + "name": "IPriceOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1959, + "src": "95:12:33", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 9526, + "nodeType": "InheritanceSpecifier", + "src": "95:12:33" + } + ], + "contractDependencies": [ + 1959 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9577, + "linearizedBaseContracts": [ + 9577, + 1959 + ], + "name": "PriceOracle", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9530, + "name": "prices", + "nodeType": "VariableDeclaration", + "scope": 9577, + "src": "115:31:33", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "typeName": { + "id": 9529, + "keyType": { + "id": 9527, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "123:7:33", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "115:24:33", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "valueType": { + "id": 9528, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "134:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9532, + "name": "ethPriceUsd", + "nodeType": "VariableDeclaration", + "scope": 9577, + "src": "152:16:33", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9531, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "152:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 9543, + "nodeType": "Block", + "src": "242:38:33", + "statements": [ + { + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9539, + "name": "prices", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9530, + "src": "259:6:33", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9541, + "indexExpression": { + "argumentTypes": null, + "id": 9540, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9534, + "src": "266:6:33", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "259:14:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9538, + "id": 9542, + "nodeType": "Return", + "src": "252:21:33" + } + ] + }, + "documentation": null, + "id": 9544, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getAssetPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9535, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9534, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9544, + "src": "198:14:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9533, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "198:7:33", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "197:16:33" + }, + "returnParameters": { + "id": 9538, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9537, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9544, + "src": "236:4:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9536, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "236:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "235:6:33" + }, + "scope": 9577, + "src": "175:105:33", + "stateMutability": "view", + "superFunction": 1941, + "visibility": "external" + }, + { + "body": { + "id": 9557, + "nodeType": "Block", + "src": "347:40:33", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9555, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9551, + "name": "prices", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9530, + "src": "357:6:33", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9553, + "indexExpression": { + "argumentTypes": null, + "id": 9552, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9546, + "src": "364:6:33", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "357:14:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9554, + "name": "_price", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9548, + "src": "374:6:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "357:23:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9556, + "nodeType": "ExpressionStatement", + "src": "357:23:33" + } + ] + }, + "documentation": null, + "id": 9558, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setAssetPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9549, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9546, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9558, + "src": "309:14:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9545, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "309:7:33", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9548, + "name": "_price", + "nodeType": "VariableDeclaration", + "scope": 9558, + "src": "325:11:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9547, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "325:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "308:29:33" + }, + "returnParameters": { + "id": 9550, + "nodeType": "ParameterList", + "parameters": [], + "src": "347:0:33" + }, + "scope": 9577, + "src": "286:101:33", + "stateMutability": "nonpayable", + "superFunction": 1948, + "visibility": "external" + }, + { + "body": { + "id": 9565, + "nodeType": "Block", + "src": "447:35:33", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9563, + "name": "ethPriceUsd", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9532, + "src": "464:11:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9562, + "id": 9564, + "nodeType": "Return", + "src": "457:18:33" + } + ] + }, + "documentation": null, + "id": 9566, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getEthUsdPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9559, + "nodeType": "ParameterList", + "parameters": [], + "src": "416:2:33" + }, + "returnParameters": { + "id": 9562, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9561, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9566, + "src": "441:4:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9560, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "441:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "440:6:33" + }, + "scope": 9577, + "src": "393:89:33", + "stateMutability": "view", + "superFunction": 1953, + "visibility": "external" + }, + { + "body": { + "id": 9575, + "nodeType": "Block", + "src": "534:37:33", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9573, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9571, + "name": "ethPriceUsd", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9532, + "src": "544:11:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9572, + "name": "_price", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9568, + "src": "558:6:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "544:20:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9574, + "nodeType": "ExpressionStatement", + "src": "544:20:33" + } + ] + }, + "documentation": null, + "id": 9576, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setEthUsdPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9569, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9568, + "name": "_price", + "nodeType": "VariableDeclaration", + "scope": 9576, + "src": "512:11:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9567, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "512:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "511:13:33" + }, + "returnParameters": { + "id": 9570, + "nodeType": "ParameterList", + "parameters": [], + "src": "534:0:33" + }, + "scope": 9577, + "src": "488:83:33", + "stateMutability": "nonpayable", + "superFunction": 1958, + "visibility": "external" + } + ], + "scope": 9578, + "src": "71:502:33" + } + ], + "src": "0:573:33" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/mocks/Oracle/PriceOracle.sol", + "exportedSymbols": { + "PriceOracle": [ + 9577 + ] + }, + "id": 9578, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9523, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:33" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol", + "file": "../../interfaces/IPriceOracle.sol", + "id": 9524, + "nodeType": "ImportDirective", + "scope": 9578, + "sourceUnit": 1960, + "src": "25:43:33", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [ + { + "arguments": null, + "baseName": { + "contractScope": null, + "id": 9525, + "name": "IPriceOracle", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1959, + "src": "95:12:33", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IPriceOracle_$1959", + "typeString": "contract IPriceOracle" + } + }, + "id": 9526, + "nodeType": "InheritanceSpecifier", + "src": "95:12:33" + } + ], + "contractDependencies": [ + 1959 + ], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 9577, + "linearizedBaseContracts": [ + 9577, + 1959 + ], + "name": "PriceOracle", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 9530, + "name": "prices", + "nodeType": "VariableDeclaration", + "scope": 9577, + "src": "115:31:33", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "typeName": { + "id": 9529, + "keyType": { + "id": 9527, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "123:7:33", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "Mapping", + "src": "115:24:33", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + }, + "valueType": { + "id": 9528, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "134:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9532, + "name": "ethPriceUsd", + "nodeType": "VariableDeclaration", + "scope": 9577, + "src": "152:16:33", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9531, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "152:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 9543, + "nodeType": "Block", + "src": "242:38:33", + "statements": [ + { + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9539, + "name": "prices", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9530, + "src": "259:6:33", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9541, + "indexExpression": { + "argumentTypes": null, + "id": 9540, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9534, + "src": "266:6:33", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "259:14:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9538, + "id": 9542, + "nodeType": "Return", + "src": "252:21:33" + } + ] + }, + "documentation": null, + "id": 9544, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getAssetPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9535, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9534, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9544, + "src": "198:14:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9533, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "198:7:33", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "197:16:33" + }, + "returnParameters": { + "id": 9538, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9537, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9544, + "src": "236:4:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9536, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "236:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "235:6:33" + }, + "scope": 9577, + "src": "175:105:33", + "stateMutability": "view", + "superFunction": 1941, + "visibility": "external" + }, + { + "body": { + "id": 9557, + "nodeType": "Block", + "src": "347:40:33", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9555, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9551, + "name": "prices", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9530, + "src": "357:6:33", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_address_$_t_uint256_$", + "typeString": "mapping(address => uint256)" + } + }, + "id": 9553, + "indexExpression": { + "argumentTypes": null, + "id": 9552, + "name": "_asset", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9546, + "src": "364:6:33", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "357:14:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9554, + "name": "_price", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9548, + "src": "374:6:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "357:23:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9556, + "nodeType": "ExpressionStatement", + "src": "357:23:33" + } + ] + }, + "documentation": null, + "id": 9558, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setAssetPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9549, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9546, + "name": "_asset", + "nodeType": "VariableDeclaration", + "scope": 9558, + "src": "309:14:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9545, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "309:7:33", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9548, + "name": "_price", + "nodeType": "VariableDeclaration", + "scope": 9558, + "src": "325:11:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9547, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "325:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "308:29:33" + }, + "returnParameters": { + "id": 9550, + "nodeType": "ParameterList", + "parameters": [], + "src": "347:0:33" + }, + "scope": 9577, + "src": "286:101:33", + "stateMutability": "nonpayable", + "superFunction": 1948, + "visibility": "external" + }, + { + "body": { + "id": 9565, + "nodeType": "Block", + "src": "447:35:33", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9563, + "name": "ethPriceUsd", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9532, + "src": "464:11:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9562, + "id": 9564, + "nodeType": "Return", + "src": "457:18:33" + } + ] + }, + "documentation": null, + "id": 9566, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getEthUsdPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9559, + "nodeType": "ParameterList", + "parameters": [], + "src": "416:2:33" + }, + "returnParameters": { + "id": 9562, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9561, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9566, + "src": "441:4:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9560, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "441:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "440:6:33" + }, + "scope": 9577, + "src": "393:89:33", + "stateMutability": "view", + "superFunction": 1953, + "visibility": "external" + }, + { + "body": { + "id": 9575, + "nodeType": "Block", + "src": "534:37:33", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9573, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9571, + "name": "ethPriceUsd", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9532, + "src": "544:11:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9572, + "name": "_price", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9568, + "src": "558:6:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "544:20:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9574, + "nodeType": "ExpressionStatement", + "src": "544:20:33" + } + ] + }, + "documentation": null, + "id": 9576, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "setEthUsdPrice", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9569, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9568, + "name": "_price", + "nodeType": "VariableDeclaration", + "scope": 9576, + "src": "512:11:33", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9567, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "512:4:33", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "511:13:33" + }, + "returnParameters": { + "id": 9570, + "nodeType": "ParameterList", + "parameters": [], + "src": "534:0:33" + }, + "scope": 9577, + "src": "488:83:33", + "stateMutability": "nonpayable", + "superFunction": 1958, + "visibility": "external" + } + ], + "scope": 9578, + "src": "71:502:33" + } + ], + "src": "0:573:33" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.859Z", + "devdoc": { + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/ReentrancyGuard.json b/client/src/contracts/ReentrancyGuard.json new file mode 100644 index 0000000..6d19bef --- /dev/null +++ b/client/src/contracts/ReentrancyGuard.json @@ -0,0 +1,808 @@ +{ + "contractName": "ReentrancyGuard", + "abi": [ + { + "inputs": [], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"inputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"}],\"devdoc\":{\"details\":\"Contract module that helps prevent reentrant calls to a function. * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier available, which can be applied to functions to make sure there are no nested (reentrant) calls to them. * Note that because there is a single `nonReentrant` guard, functions marked as `nonReentrant` may not call one another. This can be worked around by making those functions `private`, and then adding `external` `nonReentrant` entry points to them.\",\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol\":\"ReentrancyGuard\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol\":{\"keccak256\":\"0xe86fdc15fbc379ecf14d6aa4f51b87c0be8476e114e23c171b790a6717230655\",\"urls\":[\"bzzr://364c5847b4ee3ac37a6ad6e54a288889ac3d2a85757b7999c00c719db6cd871d\"]}},\"version\":1}", + "bytecode": "0x", + "deployedBytecode": "0x", + "sourceMap": "", + "deployedSourceMap": "", + "source": "pragma solidity ^0.5.0;\n\n/**\n * @dev Contract module that helps prevent reentrant calls to a function.\n *\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\n * available, which can be applied to functions to make sure there are no nested\n * (reentrant) calls to them.\n *\n * Note that because there is a single `nonReentrant` guard, functions marked as\n * `nonReentrant` may not call one another. This can be worked around by making\n * those functions `private`, and then adding `external` `nonReentrant` entry\n * points to them.\n */\ncontract ReentrancyGuard {\n // counter to allow mutex lock with only one SSTORE operation\n uint256 private _guardCounter;\n\n constructor () internal {\n // The counter starts at one to prevent changing it from zero to a non-zero\n // value, which is a more expensive operation.\n _guardCounter = 1;\n }\n\n /**\n * @dev Prevents a contract from calling itself, directly or indirectly.\n * Calling a `nonReentrant` function from another `nonReentrant`\n * function is not supported. It is possible to prevent this from happening\n * by making the `nonReentrant` function external, and make it call a\n * `private` function that does the actual work.\n */\n modifier nonReentrant() {\n _guardCounter += 1;\n uint256 localCounter = _guardCounter;\n _;\n require(localCounter == _guardCounter, \"ReentrancyGuard: reentrant call\");\n }\n}\n", + "sourcePath": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "ast": { + "absolutePath": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "exportedSymbols": { + "ReentrancyGuard": [ + 12113 + ] + }, + "id": 12114, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 12083, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:63" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": "@dev Contract module that helps prevent reentrant calls to a function.\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\navailable, which can be applied to functions to make sure there are no nested\n(reentrant) calls to them.\n * Note that because there is a single `nonReentrant` guard, functions marked as\n`nonReentrant` may not call one another. This can be worked around by making\nthose functions `private`, and then adding `external` `nonReentrant` entry\npoints to them.", + "fullyImplemented": true, + "id": 12113, + "linearizedBaseContracts": [ + 12113 + ], + "name": "ReentrancyGuard", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 12085, + "name": "_guardCounter", + "nodeType": "VariableDeclaration", + "scope": 12113, + "src": "654:29:63", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 12084, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "654:7:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "private" + }, + { + "body": { + "id": 12092, + "nodeType": "Block", + "src": "714:173:63", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 12090, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 12088, + "name": "_guardCounter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12085, + "src": "863:13:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "31", + "id": 12089, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "879:1:63", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1_by_1", + "typeString": "int_const 1" + }, + "value": "1" + }, + "src": "863:17:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 12091, + "nodeType": "ExpressionStatement", + "src": "863:17:63" + } + ] + }, + "documentation": null, + "id": 12093, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 12086, + "nodeType": "ParameterList", + "parameters": [], + "src": "702:2:63" + }, + "returnParameters": { + "id": 12087, + "nodeType": "ParameterList", + "parameters": [], + "src": "714:0:63" + }, + "scope": 12113, + "src": "690:197:63", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 12111, + "nodeType": "Block", + "src": "1286:175:63", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 12097, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 12095, + "name": "_guardCounter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12085, + "src": "1296:13:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "+=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "31", + "id": 12096, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1313:1:63", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1_by_1", + "typeString": "int_const 1" + }, + "value": "1" + }, + "src": "1296:18:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 12098, + "nodeType": "ExpressionStatement", + "src": "1296:18:63" + }, + { + "assignments": [ + 12100 + ], + "declarations": [ + { + "constant": false, + "id": 12100, + "name": "localCounter", + "nodeType": "VariableDeclaration", + "scope": 12111, + "src": "1324:20:63", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 12099, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1324:7:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 12102, + "initialValue": { + "argumentTypes": null, + "id": 12101, + "name": "_guardCounter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12085, + "src": "1347:13:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1324:36:63" + }, + { + "id": 12103, + "nodeType": "PlaceholderStatement", + "src": "1370:1:63" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 12107, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 12105, + "name": "localCounter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12100, + "src": "1389:12:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 12106, + "name": "_guardCounter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12085, + "src": "1405:13:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1389:29:63", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5265656e7472616e637947756172643a207265656e7472616e742063616c6c", + "id": 12108, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1420:33:63", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ebf73bba305590e4764d5cb53b69bffd6d4d092d1a67551cb346f8cfcdab8619", + "typeString": "literal_string \"ReentrancyGuard: reentrant call\"" + }, + "value": "ReentrancyGuard: reentrant call" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_ebf73bba305590e4764d5cb53b69bffd6d4d092d1a67551cb346f8cfcdab8619", + "typeString": "literal_string \"ReentrancyGuard: reentrant call\"" + } + ], + "id": 12104, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1381:7:63", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 12109, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1381:73:63", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 12110, + "nodeType": "ExpressionStatement", + "src": "1381:73:63" + } + ] + }, + "documentation": "@dev Prevents a contract from calling itself, directly or indirectly.\nCalling a `nonReentrant` function from another `nonReentrant`\nfunction is not supported. It is possible to prevent this from happening\nby making the `nonReentrant` function external, and make it call a\n`private` function that does the actual work.", + "id": 12112, + "name": "nonReentrant", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 12094, + "nodeType": "ParameterList", + "parameters": [], + "src": "1283:2:63" + }, + "src": "1262:199:63", + "visibility": "internal" + } + ], + "scope": 12114, + "src": "557:906:63" + } + ], + "src": "0:1464:63" + }, + "legacyAST": { + "absolutePath": "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol", + "exportedSymbols": { + "ReentrancyGuard": [ + 12113 + ] + }, + "id": 12114, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 12083, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:63" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": "@dev Contract module that helps prevent reentrant calls to a function.\n * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier\navailable, which can be applied to functions to make sure there are no nested\n(reentrant) calls to them.\n * Note that because there is a single `nonReentrant` guard, functions marked as\n`nonReentrant` may not call one another. This can be worked around by making\nthose functions `private`, and then adding `external` `nonReentrant` entry\npoints to them.", + "fullyImplemented": true, + "id": 12113, + "linearizedBaseContracts": [ + 12113 + ], + "name": "ReentrancyGuard", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 12085, + "name": "_guardCounter", + "nodeType": "VariableDeclaration", + "scope": 12113, + "src": "654:29:63", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 12084, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "654:7:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "private" + }, + { + "body": { + "id": 12092, + "nodeType": "Block", + "src": "714:173:63", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 12090, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 12088, + "name": "_guardCounter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12085, + "src": "863:13:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "31", + "id": 12089, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "879:1:63", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1_by_1", + "typeString": "int_const 1" + }, + "value": "1" + }, + "src": "863:17:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 12091, + "nodeType": "ExpressionStatement", + "src": "863:17:63" + } + ] + }, + "documentation": null, + "id": 12093, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 12086, + "nodeType": "ParameterList", + "parameters": [], + "src": "702:2:63" + }, + "returnParameters": { + "id": 12087, + "nodeType": "ParameterList", + "parameters": [], + "src": "714:0:63" + }, + "scope": 12113, + "src": "690:197:63", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 12111, + "nodeType": "Block", + "src": "1286:175:63", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 12097, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 12095, + "name": "_guardCounter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12085, + "src": "1296:13:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "+=", + "rightHandSide": { + "argumentTypes": null, + "hexValue": "31", + "id": 12096, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1313:1:63", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1_by_1", + "typeString": "int_const 1" + }, + "value": "1" + }, + "src": "1296:18:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 12098, + "nodeType": "ExpressionStatement", + "src": "1296:18:63" + }, + { + "assignments": [ + 12100 + ], + "declarations": [ + { + "constant": false, + "id": 12100, + "name": "localCounter", + "nodeType": "VariableDeclaration", + "scope": 12111, + "src": "1324:20:63", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 12099, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1324:7:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 12102, + "initialValue": { + "argumentTypes": null, + "id": 12101, + "name": "_guardCounter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12085, + "src": "1347:13:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1324:36:63" + }, + { + "id": 12103, + "nodeType": "PlaceholderStatement", + "src": "1370:1:63" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 12107, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 12105, + "name": "localCounter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12100, + "src": "1389:12:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "id": 12106, + "name": "_guardCounter", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12085, + "src": "1405:13:63", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "1389:29:63", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5265656e7472616e637947756172643a207265656e7472616e742063616c6c", + "id": 12108, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1420:33:63", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ebf73bba305590e4764d5cb53b69bffd6d4d092d1a67551cb346f8cfcdab8619", + "typeString": "literal_string \"ReentrancyGuard: reentrant call\"" + }, + "value": "ReentrancyGuard: reentrant call" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_ebf73bba305590e4764d5cb53b69bffd6d4d092d1a67551cb346f8cfcdab8619", + "typeString": "literal_string \"ReentrancyGuard: reentrant call\"" + } + ], + "id": 12104, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1381:7:63", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 12109, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1381:73:63", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 12110, + "nodeType": "ExpressionStatement", + "src": "1381:73:63" + } + ] + }, + "documentation": "@dev Prevents a contract from calling itself, directly or indirectly.\nCalling a `nonReentrant` function from another `nonReentrant`\nfunction is not supported. It is possible to prevent this from happening\nby making the `nonReentrant` function external, and make it call a\n`private` function that does the actual work.", + "id": 12112, + "name": "nonReentrant", + "nodeType": "ModifierDefinition", + "parameters": { + "id": 12094, + "nodeType": "ParameterList", + "parameters": [], + "src": "1283:2:63" + }, + "src": "1262:199:63", + "visibility": "internal" + } + ], + "scope": 12114, + "src": "557:906:63" + } + ], + "src": "0:1464:63" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.952Z", + "devdoc": { + "details": "Contract module that helps prevent reentrant calls to a function. * Inheriting from `ReentrancyGuard` will make the {nonReentrant} modifier available, which can be applied to functions to make sure there are no nested (reentrant) calls to them. * Note that because there is a single `nonReentrant` guard, functions marked as `nonReentrant` may not call one another. This can be worked around by making those functions `private`, and then adding `external` `nonReentrant` entry points to them.", + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/RinkebyArbContract.json b/client/src/contracts/RinkebyArbContract.json index 0ae88d0..33918b7 100644 --- a/client/src/contracts/RinkebyArbContract.json +++ b/client/src/contracts/RinkebyArbContract.json @@ -205,22 +205,22 @@ "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[],\"name\":\"getBalance\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"uniSwapExchangeAddr\",\"type\":\"address\"},{\"name\":\"min_buy_tokens\",\"type\":\"uint256\"},{\"name\":\"buy_deadline\",\"type\":\"uint256\"},{\"name\":\"buy_eth_value\",\"type\":\"uint256\"},{\"name\":\"max_sell_tokens\",\"type\":\"uint256\"},{\"name\":\"sell_deadline\",\"type\":\"uint256\"},{\"name\":\"sell_eth_value\",\"type\":\"uint256\"}],\"name\":\"trade\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"uniSwapExchangeAddr\",\"type\":\"address\"},{\"name\":\"min_buy_tokens\",\"type\":\"uint256\"},{\"name\":\"buy_deadline\",\"type\":\"uint256\"},{\"name\":\"buy_eth_value\",\"type\":\"uint256\"}],\"name\":\"tradeEthToToken\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"uniSwapExchangeAddr\",\"type\":\"address\"},{\"name\":\"max_sell_tokens\",\"type\":\"uint256\"},{\"name\":\"sell_deadline\",\"type\":\"uint256\"},{\"name\":\"sell_eth_value\",\"type\":\"uint256\"}],\"name\":\"tradeTokenToEth\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"name\":\"\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"tokenAddress\",\"type\":\"address\"},{\"name\":\"exchangeAddress\",\"type\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approveToken\",\"outputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"trader\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"eth\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"tokens\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"token_bought\",\"type\":\"uint256\"}],\"name\":\"ethToToken\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"name\":\"trader\",\"type\":\"address\"},{\"indexed\":false,\"name\":\"sell_eth_value\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"max_sell_tokens\",\"type\":\"uint256\"},{\"indexed\":false,\"name\":\"tokens_sold\",\"type\":\"uint256\"}],\"name\":\"tokenToEth\",\"type\":\"event\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/RinkebyArbContract.sol\":\"RinkebyArbContract\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/RinkebyArbContract.sol\":{\"keccak256\":\"0x5d23caaccfecd871eaff36f8367f7a9cdd9055d4c8efe0229eac28f7a07b0c98\",\"urls\":[\"bzzr://a12d94d960f8eb724b6f981e38722744e8de30f6bbfc89519cf8d0044c310c6b\"]},\"/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol\":{\"keccak256\":\"0x35ce204d214fb0d5b2e05df0b9e45833a2e8db564c995db36bfc023ff4a3f4f4\",\"urls\":[\"bzzr://5d4c7bc352bb1accf85e754811b6c0acc9bf0be87e852ba011c92b1344cfa463\"]},\"@openzeppelin/contracts/math/SafeMath.sol\":{\"keccak256\":\"0xd1804d04fb39689453f673601429a99a0c68c422a981fc338773df9a59180fe9\",\"urls\":[\"bzzr://a7dfb6fc259d0074da840a848461487567e2a6309105dd5c050a4e025f0fa7cb\"]},\"@openzeppelin/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x852793a3c2f86d336a683b30d688ec3dcfc57451af5a2bf5975cda3b7191a901\",\"urls\":[\"bzzr://07fb42206812a17c1f71e548cfa5cec6f9aa1ae0ca5df870718ca4aa9759d1a5\"]},\"@openzeppelin/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0x90e8c2521653bbb1768b05889c5760031e688d9cd361f167489b89215e201b95\",\"urls\":[\"bzzr://aa8b45b57edafc3d67bc5d916327ea16807fae33f753ca163ae0c4061b789766\"]}},\"version\":1}", "bytecode": "0x608060405234801561001057600080fd5b50336000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550610a8b806100606000396000f3fe6080604052600436106100555760003560e01c806312065fe01461005a578063691c6a051461008557806369ef92be146101055780636efd905c146101675780638da5cb5b146101d6578063da3e33971461022d575b600080fd5b34801561006657600080fd5b5061006f6102a8565b6040518082815260200191505060405180910390f35b610103600480360360e081101561009b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190803590602001909291908035906020019092919080359060200190929190803590602001909291905050506102c7565b005b6101656004803603608081101561011b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190803590602001909291905050506105b4565b005b34801561017357600080fd5b506101d46004803603608081101561018a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291908035906020019092919050505061074c565b005b3480156101e257600080fd5b506101eb6108aa565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561023957600080fd5b506102a66004803603606081101561025057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506108cf565b005b60003073ffffffffffffffffffffffffffffffffffffffff1631905090565b8334101561033d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4e6f7420456e6f756768204574682053656e740000000000000000000000000081525060200191505060405180910390fd5b600087905060008173ffffffffffffffffffffffffffffffffffffffff1663f39b5b9b878a8a6040518463ffffffff1660e01b815260040180838152602001828152602001925050506020604051808303818588803b15801561039f57600080fd5b505af11580156103b3573d6000803e3d6000fd5b50505050506040513d60208110156103ca57600080fd5b810190808051906020019092919050505090507e54db9af6406356fb75e752b513e9bdf734056e92d4e263cb6b7e525773f22333878a84604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a160008273ffffffffffffffffffffffffffffffffffffffff1663d4e4841d858888336040518563ffffffff1660e01b8152600401808581526020018481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b1580156104f057600080fd5b505af1158015610504573d6000803e3d6000fd5b505050506040513d602081101561051a57600080fd5b810190808051906020019092919050505090507fe9c245f1c1a4a7a621218231e7ed679594b1c02c80e4fe05a465ecb46dc37f4733858884604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a150505050505050505050565b8034101561062a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4e6f7420456e6f756768204574682053656e740000000000000000000000000081525060200191505060405180910390fd5b600084905060008173ffffffffffffffffffffffffffffffffffffffff1663f39b5b9b8487876040518463ffffffff1660e01b815260040180838152602001828152602001925050506020604051808303818588803b15801561068c57600080fd5b505af11580156106a0573d6000803e3d6000fd5b50505050506040513d60208110156106b757600080fd5b810190808051906020019092919050505090507e54db9af6406356fb75e752b513e9bdf734056e92d4e263cb6b7e525773f22333848784604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a1505050505050565b600084905060008173ffffffffffffffffffffffffffffffffffffffff1663d4e4841d848787336040518563ffffffff1660e01b8152600401808581526020018481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b1580156107ea57600080fd5b505af11580156107fe573d6000803e3d6000fd5b505050506040513d602081101561081457600080fd5b810190808051906020019092919050505090507fe9c245f1c1a4a7a621218231e7ed679594b1c02c80e4fe05a465ecb46dc37f4733848784604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a1505050505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610991576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260168152602001807f4f6e6c79204f776e65722043616e20417070726f76650000000000000000000081525060200191505060405180910390fd5b60008390508073ffffffffffffffffffffffffffffffffffffffff1663095ea7b384846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b158015610a1d57600080fd5b505af1158015610a31573d6000803e3d6000fd5b505050506040513d6020811015610a4757600080fd5b8101908080519060200190929190505050505050505056fea165627a7a723058203d999f6eec6221d71942d21d914d1a90af71ecd3e486c0348d163c0f5e1c7f750029", "deployedBytecode": "0x6080604052600436106100555760003560e01c806312065fe01461005a578063691c6a051461008557806369ef92be146101055780636efd905c146101675780638da5cb5b146101d6578063da3e33971461022d575b600080fd5b34801561006657600080fd5b5061006f6102a8565b6040518082815260200191505060405180910390f35b610103600480360360e081101561009b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190803590602001909291908035906020019092919080359060200190929190803590602001909291905050506102c7565b005b6101656004803603608081101561011b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291908035906020019092919080359060200190929190803590602001909291905050506105b4565b005b34801561017357600080fd5b506101d46004803603608081101561018a57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff16906020019092919080359060200190929190803590602001909291908035906020019092919050505061074c565b005b3480156101e257600080fd5b506101eb6108aa565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34801561023957600080fd5b506102a66004803603606081101561025057600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803590602001909291905050506108cf565b005b60003073ffffffffffffffffffffffffffffffffffffffff1631905090565b8334101561033d576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4e6f7420456e6f756768204574682053656e740000000000000000000000000081525060200191505060405180910390fd5b600087905060008173ffffffffffffffffffffffffffffffffffffffff1663f39b5b9b878a8a6040518463ffffffff1660e01b815260040180838152602001828152602001925050506020604051808303818588803b15801561039f57600080fd5b505af11580156103b3573d6000803e3d6000fd5b50505050506040513d60208110156103ca57600080fd5b810190808051906020019092919050505090507e54db9af6406356fb75e752b513e9bdf734056e92d4e263cb6b7e525773f22333878a84604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a160008273ffffffffffffffffffffffffffffffffffffffff1663d4e4841d858888336040518563ffffffff1660e01b8152600401808581526020018481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b1580156104f057600080fd5b505af1158015610504573d6000803e3d6000fd5b505050506040513d602081101561051a57600080fd5b810190808051906020019092919050505090507fe9c245f1c1a4a7a621218231e7ed679594b1c02c80e4fe05a465ecb46dc37f4733858884604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a150505050505050505050565b8034101561062a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260138152602001807f4e6f7420456e6f756768204574682053656e740000000000000000000000000081525060200191505060405180910390fd5b600084905060008173ffffffffffffffffffffffffffffffffffffffff1663f39b5b9b8487876040518463ffffffff1660e01b815260040180838152602001828152602001925050506020604051808303818588803b15801561068c57600080fd5b505af11580156106a0573d6000803e3d6000fd5b50505050506040513d60208110156106b757600080fd5b810190808051906020019092919050505090507e54db9af6406356fb75e752b513e9bdf734056e92d4e263cb6b7e525773f22333848784604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a1505050505050565b600084905060008173ffffffffffffffffffffffffffffffffffffffff1663d4e4841d848787336040518563ffffffff1660e01b8152600401808581526020018481526020018381526020018273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001945050505050602060405180830381600087803b1580156107ea57600080fd5b505af11580156107fe573d6000803e3d6000fd5b505050506040513d602081101561081457600080fd5b810190808051906020019092919050505090507fe9c245f1c1a4a7a621218231e7ed679594b1c02c80e4fe05a465ecb46dc37f4733848784604051808573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200184815260200183815260200182815260200194505050505060405180910390a1505050505050565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b6000809054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610991576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260168152602001807f4f6e6c79204f776e65722043616e20417070726f76650000000000000000000081525060200191505060405180910390fd5b60008390508073ffffffffffffffffffffffffffffffffffffffff1663095ea7b384846040518363ffffffff1660e01b8152600401808373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200182815260200192505050602060405180830381600087803b158015610a1d57600080fd5b505af1158015610a31573d6000803e3d6000fd5b505050506040513d6020811015610a4757600080fd5b8101908080519060200190929190505050505050505056fea165627a7a723058203d999f6eec6221d71942d21d914d1a90af71ecd3e486c0348d163c0f5e1c7f750029", - "sourceMap": "114:2539:5:-;;;366:50;8:9:-1;5:2;;;30:1;27;20:12;5:2;366:50:5;401:10;393:5;;:18;;;;;;;;;;;;;;;;;;114:2539;;;;;;", - "deployedSourceMap": "114:2539:5:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2560:91;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2560:91:5;;;:::i;:::-;;;;;;;;;;;;;;;;;;;663:844;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;663:844:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;1511:558;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;1511:558:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;2073:483;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2073:483:5;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;2073:483:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;147:20;;8:9:-1;5:2;;;30:1;27;20:12;5:2;147:20:5;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;420:239;;8:9:-1;5:2;;;30:1;27;20:12;5:2;420:239:5;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;420:239:5;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;2560:91;2603:7;2633:4;2625:21;;;2618:28;;2560:91;:::o;663:844::-;925:13;912:9;:26;;904:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;971:31;1021:19;971:70;;1050:20;1073:15;:35;;;1115:13;1130:14;1146:12;1073:86;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1073:86:5;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1073:86:5;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1073:86:5;;;;;;;;;;;;;;;;1050:109;;1223:67;1234:10;1246:13;1261:14;1277:12;1223:67;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1299:19;1321:15;:40;;;1362:14;1378:15;1395:13;1410:10;1321:100;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1321:100:5;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1321:100:5;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1321:100:5;;;;;;;;;;;;;;;;1299:122;;1434:68;1445:10;1457:14;1473:15;1490:11;1434:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;663:844;;;;;;;;;;:::o;1511:558::-;1699:13;1686:9;:26;;1678:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1745:31;1795:19;1745:70;;1824:20;1847:15;:35;;;1889:13;1904:14;1920:12;1847:86;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1847:86:5;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1847:86:5;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1847:86:5;;;;;;;;;;;;;;;;1824:109;;1997:67;2008:10;2020:13;2035:14;2051:12;1997:67;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1511:558;;;;;;:::o;2073:483::-;2268:31;2318:19;2268:70;;2347:19;2369:15;:40;;;2410:14;2426:15;2443:13;2458:10;2369:100;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2369:100:5;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2369:100:5;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2369:100:5;;;;;;;;;;;;;;;;2347:122;;2483:68;2494:10;2506:14;2522:15;2539:11;2483:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2073:483;;;;;;:::o;147:20::-;;;;;;;;;;;;;:::o;420:239::-;537:5;;;;;;;;;;;523:19;;:10;:19;;;515:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;576:11;596:12;576:33;;616:5;:13;;;630:15;647:6;616:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;616:38:5;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;616:38:5;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;616:38:5;;;;;;;;;;;;;;;;;420:239;;;;:::o", + "sourceMap": "114:2539:6:-;;;366:50;8:9:-1;5:2;;;30:1;27;20:12;5:2;366:50:6;401:10;393:5;;:18;;;;;;;;;;;;;;;;;;114:2539;;;;;;", + "deployedSourceMap": "114:2539:6:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2560:91;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2560:91:6;;;:::i;:::-;;;;;;;;;;;;;;;;;;;663:844;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;663:844:6;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;1511:558;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;1511:558:6;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;2073:483;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2073:483:6;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;2073:483:6;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;147:20;;8:9:-1;5:2;;;30:1;27;20:12;5:2;147:20:6;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;420:239;;8:9:-1;5:2;;;30:1;27;20:12;5:2;420:239:6;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;420:239:6;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;2560:91;2603:7;2633:4;2625:21;;;2618:28;;2560:91;:::o;663:844::-;925:13;912:9;:26;;904:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;971:31;1021:19;971:70;;1050:20;1073:15;:35;;;1115:13;1130:14;1146:12;1073:86;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1073:86:6;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1073:86:6;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1073:86:6;;;;;;;;;;;;;;;;1050:109;;1223:67;1234:10;1246:13;1261:14;1277:12;1223:67;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1299:19;1321:15;:40;;;1362:14;1378:15;1395:13;1410:10;1321:100;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1321:100:6;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1321:100:6;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1321:100:6;;;;;;;;;;;;;;;;1299:122;;1434:68;1445:10;1457:14;1473:15;1490:11;1434:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;663:844;;;;;;;;;;:::o;1511:558::-;1699:13;1686:9;:26;;1678:58;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1745:31;1795:19;1745:70;;1824:20;1847:15;:35;;;1889:13;1904:14;1920:12;1847:86;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1847:86:6;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1847:86:6;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1847:86:6;;;;;;;;;;;;;;;;1824:109;;1997:67;2008:10;2020:13;2035:14;2051:12;1997:67;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1511:558;;;;;;:::o;2073:483::-;2268:31;2318:19;2268:70;;2347:19;2369:15;:40;;;2410:14;2426:15;2443:13;2458:10;2369:100;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2369:100:6;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2369:100:6;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2369:100:6;;;;;;;;;;;;;;;;2347:122;;2483:68;2494:10;2506:14;2522:15;2539:11;2483:68;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2073:483;;;;;;:::o;147:20::-;;;;;;;;;;;;;:::o;420:239::-;537:5;;;;;;;;;;;523:19;;:10;:19;;;515:54;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;576:11;596:12;576:33;;616:5;:13;;;630:15;647:6;616:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;616:38:6;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;616:38:6;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;616:38:6;;;;;;;;;;;;;;;;;420:239;;;;:::o", "source": "pragma solidity ^0.5.0;\n\nimport \"./UniswapExchange.sol\";\nimport \"@openzeppelin/contracts/token/ERC20/ERC20.sol\";\n\ncontract RinkebyArbContract {\n\n address public owner;\n\n event ethToToken(address trader, uint256 eth, uint256 tokens, uint256 token_bought);\n event tokenToEth(address trader, uint256 sell_eth_value, uint256 max_sell_tokens, uint256 tokens_sold);\n\n constructor() public {\n owner = msg.sender;\n }\n\n function approveToken(address tokenAddress, address exchangeAddress, uint amount) public {\n require(msg.sender == owner, \"Only Owner Can Approve\");\n\n ERC20 token = ERC20(tokenAddress);\n\n token.approve(exchangeAddress, amount);\n }\n\n function trade(\n address uniSwapExchangeAddr,\n uint256 min_buy_tokens,\n uint256 buy_deadline,\n uint256 buy_eth_value,\n uint256 max_sell_tokens,\n uint256 sell_deadline,\n uint256 sell_eth_value)\n public payable {\n require(msg.value >= buy_eth_value, \"Not Enough Eth Sent\");\n\n UniswapExchange uniSwapExchange = UniswapExchange(uniSwapExchangeAddr);\n\n uint256 token_bought = uniSwapExchange.ethToTokenSwapInput.value(buy_eth_value)(min_buy_tokens, buy_deadline); // Swap Eth to token in UniSwap\n emit ethToToken(msg.sender, buy_eth_value, min_buy_tokens, token_bought);\n\n uint256 tokens_sold = uniSwapExchange.tokenToEthTransferOutput(sell_eth_value, max_sell_tokens, sell_deadline, msg.sender);\n emit tokenToEth(msg.sender, sell_eth_value, max_sell_tokens, tokens_sold);\n }\n\n function tradeEthToToken(\n address uniSwapExchangeAddr,\n uint256 min_buy_tokens,\n uint256 buy_deadline,\n uint256 buy_eth_value)\n public payable {\n require(msg.value >= buy_eth_value, \"Not Enough Eth Sent\");\n\n UniswapExchange uniSwapExchange = UniswapExchange(uniSwapExchangeAddr);\n\n uint256 token_bought = uniSwapExchange.ethToTokenSwapInput.value(buy_eth_value)(min_buy_tokens, buy_deadline); // Swap Eth to token in UniSwap\n emit ethToToken(msg.sender, buy_eth_value, min_buy_tokens, token_bought);\n }\n\n function tradeTokenToEth(\n address uniSwapExchangeAddr,\n uint256 max_sell_tokens,\n uint256 sell_deadline,\n uint256 sell_eth_value)\n public {\n // Should check approval?\n\n UniswapExchange uniSwapExchange = UniswapExchange(uniSwapExchangeAddr);\n\n uint256 tokens_sold = uniSwapExchange.tokenToEthTransferOutput(sell_eth_value, max_sell_tokens, sell_deadline, msg.sender);\n\n emit tokenToEth(msg.sender, sell_eth_value, max_sell_tokens, tokens_sold);\n }\n\n function getBalance() public view returns (uint256) {\n return address(this).balance;\n }\n}\n", "sourcePath": "/Users/jg/Documents/aaveBot/contracts/RinkebyArbContract.sol", "ast": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/RinkebyArbContract.sol", "exportedSymbols": { "RinkebyArbContract": [ - 768 + 844 ] }, - "id": 769, + "id": 845, "nodeType": "SourceUnit", "nodes": [ { - "id": 540, + "id": 616, "literals": [ "solidity", "^", @@ -228,27 +228,27 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:5" + "src": "0:23:6" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol", "file": "./UniswapExchange.sol", - "id": 541, + "id": 617, "nodeType": "ImportDirective", - "scope": 769, - "sourceUnit": 845, - "src": "25:31:5", + "scope": 845, + "sourceUnit": 921, + "src": "25:31:6", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "@openzeppelin/contracts/token/ERC20/ERC20.sol", "file": "@openzeppelin/contracts/token/ERC20/ERC20.sol", - "id": 542, + "id": 618, "nodeType": "ImportDirective", - "scope": 769, - "sourceUnit": 1375, - "src": "57:55:5", + "scope": 845, + "sourceUnit": 10858, + "src": "57:55:6", "symbolAliases": [], "unitAlias": "" }, @@ -258,20 +258,20 @@ "contractKind": "contract", "documentation": null, "fullyImplemented": true, - "id": 768, + "id": 844, "linearizedBaseContracts": [ - 768 + 844 ], "name": "RinkebyArbContract", "nodeType": "ContractDefinition", "nodes": [ { "constant": false, - "id": 544, + "id": 620, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 768, - "src": "147:20:5", + "scope": 844, + "src": "147:20:6", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -279,10 +279,10 @@ "typeString": "address" }, "typeName": { - "id": 543, + "id": 619, "name": "address", "nodeType": "ElementaryTypeName", - "src": "147:7:5", + "src": "147:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -295,21 +295,21 @@ { "anonymous": false, "documentation": null, - "id": 554, + "id": 630, "name": "ethToToken", "nodeType": "EventDefinition", "parameters": { - "id": 553, + "id": 629, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 546, + "id": 622, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 554, - "src": "189:14:5", + "scope": 630, + "src": "189:14:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -317,10 +317,10 @@ "typeString": "address" }, "typeName": { - "id": 545, + "id": 621, "name": "address", "nodeType": "ElementaryTypeName", - "src": "189:7:5", + "src": "189:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -332,12 +332,12 @@ }, { "constant": false, - "id": 548, + "id": 624, "indexed": false, "name": "eth", "nodeType": "VariableDeclaration", - "scope": 554, - "src": "205:11:5", + "scope": 630, + "src": "205:11:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -345,10 +345,10 @@ "typeString": "uint256" }, "typeName": { - "id": 547, + "id": 623, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "205:7:5", + "src": "205:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -359,12 +359,12 @@ }, { "constant": false, - "id": 550, + "id": 626, "indexed": false, "name": "tokens", "nodeType": "VariableDeclaration", - "scope": 554, - "src": "218:14:5", + "scope": 630, + "src": "218:14:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -372,10 +372,10 @@ "typeString": "uint256" }, "typeName": { - "id": 549, + "id": 625, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "218:7:5", + "src": "218:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -386,12 +386,12 @@ }, { "constant": false, - "id": 552, + "id": 628, "indexed": false, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 554, - "src": "234:20:5", + "scope": 630, + "src": "234:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -399,10 +399,10 @@ "typeString": "uint256" }, "typeName": { - "id": 551, + "id": 627, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "234:7:5", + "src": "234:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -412,28 +412,28 @@ "visibility": "internal" } ], - "src": "188:67:5" + "src": "188:67:6" }, - "src": "172:84:5" + "src": "172:84:6" }, { "anonymous": false, "documentation": null, - "id": 564, + "id": 640, "name": "tokenToEth", "nodeType": "EventDefinition", "parameters": { - "id": 563, + "id": 639, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 556, + "id": 632, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 564, - "src": "276:14:5", + "scope": 640, + "src": "276:14:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -441,10 +441,10 @@ "typeString": "address" }, "typeName": { - "id": 555, + "id": 631, "name": "address", "nodeType": "ElementaryTypeName", - "src": "276:7:5", + "src": "276:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -456,12 +456,12 @@ }, { "constant": false, - "id": 558, + "id": 634, "indexed": false, "name": "sell_eth_value", "nodeType": "VariableDeclaration", - "scope": 564, - "src": "292:22:5", + "scope": 640, + "src": "292:22:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -469,10 +469,10 @@ "typeString": "uint256" }, "typeName": { - "id": 557, + "id": 633, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "292:7:5", + "src": "292:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -483,12 +483,12 @@ }, { "constant": false, - "id": 560, + "id": 636, "indexed": false, "name": "max_sell_tokens", "nodeType": "VariableDeclaration", - "scope": 564, - "src": "316:23:5", + "scope": 640, + "src": "316:23:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -496,10 +496,10 @@ "typeString": "uint256" }, "typeName": { - "id": 559, + "id": 635, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "316:7:5", + "src": "316:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -510,12 +510,12 @@ }, { "constant": false, - "id": 562, + "id": 638, "indexed": false, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 564, - "src": "341:19:5", + "scope": 640, + "src": "341:19:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -523,10 +523,10 @@ "typeString": "uint256" }, "typeName": { - "id": 561, + "id": 637, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "341:7:5", + "src": "341:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -536,32 +536,32 @@ "visibility": "internal" } ], - "src": "275:86:5" + "src": "275:86:6" }, - "src": "259:103:5" + "src": "259:103:6" }, { "body": { - "id": 572, + "id": 648, "nodeType": "Block", - "src": "387:29:5", + "src": "387:29:6", "statements": [ { "expression": { "argumentTypes": null, - "id": 570, + "id": 646, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 567, + "id": 643, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 544, - "src": "393:5:5", + "referencedDeclaration": 620, + "src": "393:5:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -573,18 +573,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 568, + "id": 644, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "401:3:5", + "referencedDeclaration": 12128, + "src": "401:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 569, + "id": 645, "isConstant": false, "isLValue": false, "isPure": false, @@ -592,54 +592,54 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "401:10:5", + "src": "401:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "393:18:5", + "src": "393:18:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 571, + "id": 647, "nodeType": "ExpressionStatement", - "src": "393:18:5" + "src": "393:18:6" } ] }, "documentation": null, - "id": 573, + "id": 649, "implemented": true, "kind": "constructor", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "parameters": { - "id": 565, + "id": 641, "nodeType": "ParameterList", "parameters": [], - "src": "377:2:5" + "src": "377:2:6" }, "returnParameters": { - "id": 566, + "id": 642, "nodeType": "ParameterList", "parameters": [], - "src": "387:0:5" + "src": "387:0:6" }, - "scope": 768, - "src": "366:50:5", + "scope": 844, + "src": "366:50:6", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 603, + "id": 679, "nodeType": "Block", - "src": "509:150:5", + "src": "509:150:6", "statements": [ { "expression": { @@ -651,7 +651,7 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 586, + "id": 662, "isConstant": false, "isLValue": false, "isPure": false, @@ -660,18 +660,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 583, + "id": 659, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "523:3:5", + "referencedDeclaration": 12128, + "src": "523:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 584, + "id": 660, "isConstant": false, "isLValue": false, "isPure": false, @@ -679,7 +679,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "523:10:5", + "src": "523:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -689,18 +689,18 @@ "operator": "==", "rightExpression": { "argumentTypes": null, - "id": 585, + "id": 661, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 544, - "src": "537:5:5", + "referencedDeclaration": 620, + "src": "537:5:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "src": "523:19:5", + "src": "523:19:6", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -709,14 +709,14 @@ { "argumentTypes": null, "hexValue": "4f6e6c79204f776e65722043616e20417070726f7665", - "id": 587, + "id": 663, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "544:24:5", + "src": "544:24:6", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_ec0b1a840a8a6c4384575556c3817abb58aac6b2bc4e7741e1c712be8067937e", @@ -736,21 +736,21 @@ "typeString": "literal_string \"Only Owner Can Approve\"" } ], - "id": 582, + "id": 658, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "515:7:5", + "referencedDeclaration": 12132, + "src": "515:7:6", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 588, + "id": 664, "isConstant": false, "isLValue": false, "isPure": false, @@ -758,43 +758,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "515:54:5", + "src": "515:54:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 589, + "id": 665, "nodeType": "ExpressionStatement", - "src": "515:54:5" + "src": "515:54:6" }, { "assignments": [ - 591 + 667 ], "declarations": [ { "constant": false, - "id": 591, + "id": 667, "name": "token", "nodeType": "VariableDeclaration", - "scope": 603, - "src": "576:11:5", + "scope": 679, + "src": "576:11:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 590, + "id": 666, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "576:5:5", + "referencedDeclaration": 10857, + "src": "576:5:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -802,18 +802,18 @@ "visibility": "internal" } ], - "id": 595, + "id": 671, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 593, + "id": 669, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 575, - "src": "596:12:5", + "referencedDeclaration": 651, + "src": "596:12:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -827,18 +827,18 @@ "typeString": "address" } ], - "id": 592, + "id": 668, "name": "ERC20", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1374, - "src": "590:5:5", + "referencedDeclaration": 10857, + "src": "590:5:6", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_ERC20_$1374_$", + "typeIdentifier": "t_type$_t_contract$_ERC20_$10857_$", "typeString": "type(contract ERC20)" } }, - "id": 594, + "id": 670, "isConstant": false, "isLValue": false, "isPure": false, @@ -846,14 +846,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "590:19:5", + "src": "590:19:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, "nodeType": "VariableDeclarationStatement", - "src": "576:33:5" + "src": "576:33:6" }, { "expression": { @@ -861,12 +861,12 @@ "arguments": [ { "argumentTypes": null, - "id": 599, + "id": 675, "name": "exchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 577, - "src": "630:15:5", + "referencedDeclaration": 653, + "src": "630:15:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -874,12 +874,12 @@ }, { "argumentTypes": null, - "id": 600, + "id": 676, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 579, - "src": "647:6:5", + "referencedDeclaration": 655, + "src": "647:6:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -899,32 +899,32 @@ ], "expression": { "argumentTypes": null, - "id": 596, + "id": 672, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 591, - "src": "616:5:5", + "referencedDeclaration": 667, + "src": "616:5:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, - "id": 598, + "id": 674, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "approve", "nodeType": "MemberAccess", - "referencedDeclaration": 1072, - "src": "616:13:5", + "referencedDeclaration": 10555, + "src": "616:13:6", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,uint256) external returns (bool)" } }, - "id": 601, + "id": 677, "isConstant": false, "isLValue": false, "isPure": false, @@ -932,36 +932,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "616:38:5", + "src": "616:38:6", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, - "id": 602, + "id": 678, "nodeType": "ExpressionStatement", - "src": "616:38:5" + "src": "616:38:6" } ] }, "documentation": null, - "id": 604, + "id": 680, "implemented": true, "kind": "function", "modifiers": [], "name": "approveToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 580, + "id": 656, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 575, + "id": 651, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 604, - "src": "442:20:5", + "scope": 680, + "src": "442:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -969,10 +969,10 @@ "typeString": "address" }, "typeName": { - "id": 574, + "id": 650, "name": "address", "nodeType": "ElementaryTypeName", - "src": "442:7:5", + "src": "442:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -984,11 +984,11 @@ }, { "constant": false, - "id": 577, + "id": 653, "name": "exchangeAddress", "nodeType": "VariableDeclaration", - "scope": 604, - "src": "464:23:5", + "scope": 680, + "src": "464:23:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -996,10 +996,10 @@ "typeString": "address" }, "typeName": { - "id": 576, + "id": 652, "name": "address", "nodeType": "ElementaryTypeName", - "src": "464:7:5", + "src": "464:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1011,11 +1011,11 @@ }, { "constant": false, - "id": 579, + "id": 655, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 604, - "src": "489:11:5", + "scope": 680, + "src": "489:11:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1023,10 +1023,10 @@ "typeString": "uint256" }, "typeName": { - "id": 578, + "id": 654, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "489:4:5", + "src": "489:4:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1036,25 +1036,25 @@ "visibility": "internal" } ], - "src": "441:60:5" + "src": "441:60:6" }, "returnParameters": { - "id": 581, + "id": 657, "nodeType": "ParameterList", "parameters": [], - "src": "509:0:5" + "src": "509:0:6" }, - "scope": 768, - "src": "420:239:5", + "scope": 844, + "src": "420:239:6", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 673, + "id": 749, "nodeType": "Block", - "src": "896:611:5", + "src": "896:611:6", "statements": [ { "expression": { @@ -1066,7 +1066,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 625, + "id": 701, "isConstant": false, "isLValue": false, "isPure": false, @@ -1075,18 +1075,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 622, + "id": 698, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "912:3:5", + "referencedDeclaration": 12128, + "src": "912:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 623, + "id": 699, "isConstant": false, "isLValue": false, "isPure": false, @@ -1094,7 +1094,7 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "912:9:5", + "src": "912:9:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1104,18 +1104,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 624, + "id": 700, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 612, - "src": "925:13:5", + "referencedDeclaration": 688, + "src": "925:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "912:26:5", + "src": "912:26:6", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1124,14 +1124,14 @@ { "argumentTypes": null, "hexValue": "4e6f7420456e6f756768204574682053656e74", - "id": 626, + "id": 702, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "940:21:5", + "src": "940:21:6", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30b29beae4cdbb7acc80a8e1229a071d1d9114e20038f0c713ecf8dbdd0dcc4e", @@ -1151,21 +1151,21 @@ "typeString": "literal_string \"Not Enough Eth Sent\"" } ], - "id": 621, + "id": 697, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "904:7:5", + "referencedDeclaration": 12132, + "src": "904:7:6", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 627, + "id": 703, "isConstant": false, "isLValue": false, "isPure": false, @@ -1173,43 +1173,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "904:58:5", + "src": "904:58:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 628, + "id": 704, "nodeType": "ExpressionStatement", - "src": "904:58:5" + "src": "904:58:6" }, { "assignments": [ - 630 + 706 ], "declarations": [ { "constant": false, - "id": 630, + "id": 706, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 673, - "src": "971:31:5", + "scope": 749, + "src": "971:31:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 629, + "id": 705, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "971:15:5", + "referencedDeclaration": 920, + "src": "971:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -1217,18 +1217,18 @@ "visibility": "internal" } ], - "id": 634, + "id": 710, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 632, + "id": 708, "name": "uniSwapExchangeAddr", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 606, - "src": "1021:19:5", + "referencedDeclaration": 682, + "src": "1021:19:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -1242,18 +1242,18 @@ "typeString": "address" } ], - "id": 631, + "id": 707, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "1005:15:5", + "referencedDeclaration": 920, + "src": "1005:15:6", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 633, + "id": 709, "isConstant": false, "isLValue": false, "isPure": false, @@ -1261,27 +1261,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1005:36:5", + "src": "1005:36:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "971:70:5" + "src": "971:70:6" }, { "assignments": [ - 636 + 712 ], "declarations": [ { "constant": false, - "id": 636, + "id": 712, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 673, - "src": "1050:20:5", + "scope": 749, + "src": "1050:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1289,10 +1289,10 @@ "typeString": "uint256" }, "typeName": { - "id": 635, + "id": 711, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1050:7:5", + "src": "1050:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1302,18 +1302,18 @@ "visibility": "internal" } ], - "id": 645, + "id": 721, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 642, + "id": 718, "name": "min_buy_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 608, - "src": "1130:14:5", + "referencedDeclaration": 684, + "src": "1130:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1321,12 +1321,12 @@ }, { "argumentTypes": null, - "id": 643, + "id": 719, "name": "buy_deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 610, - "src": "1146:12:5", + "referencedDeclaration": 686, + "src": "1146:12:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1347,12 +1347,12 @@ "arguments": [ { "argumentTypes": null, - "id": 640, + "id": 716, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 612, - "src": "1115:13:5", + "referencedDeclaration": 688, + "src": "1115:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1370,32 +1370,32 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 637, + "id": 713, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 630, - "src": "1073:15:5", + "referencedDeclaration": 706, + "src": "1073:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 638, + "id": 714, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "ethToTokenSwapInput", "nodeType": "MemberAccess", - "referencedDeclaration": 789, - "src": "1073:35:5", + "referencedDeclaration": 865, + "src": "1073:35:6", "typeDescriptions": { "typeIdentifier": "t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$", "typeString": "function (uint256,uint256) payable external returns (uint256)" } }, - "id": 639, + "id": 715, "isConstant": false, "isLValue": false, "isPure": false, @@ -1403,13 +1403,13 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1073:41:5", + "src": "1073:41:6", "typeDescriptions": { "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$value_$", "typeString": "function (uint256) returns (function (uint256,uint256) payable external returns (uint256))" } }, - "id": 641, + "id": 717, "isConstant": false, "isLValue": false, "isPure": false, @@ -1417,13 +1417,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1073:56:5", + "src": "1073:56:6", "typeDescriptions": { "typeIdentifier": "t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$value", "typeString": "function (uint256,uint256) payable external returns (uint256)" } }, - "id": 644, + "id": 720, "isConstant": false, "isLValue": false, "isPure": false, @@ -1431,14 +1431,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1073:86:5", + "src": "1073:86:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "1050:109:5" + "src": "1050:109:6" }, { "eventCall": { @@ -1448,18 +1448,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 647, + "id": 723, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1234:3:5", + "referencedDeclaration": 12128, + "src": "1234:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 648, + "id": 724, "isConstant": false, "isLValue": false, "isPure": false, @@ -1467,7 +1467,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1234:10:5", + "src": "1234:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1475,12 +1475,12 @@ }, { "argumentTypes": null, - "id": 649, + "id": 725, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 612, - "src": "1246:13:5", + "referencedDeclaration": 688, + "src": "1246:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1488,12 +1488,12 @@ }, { "argumentTypes": null, - "id": 650, + "id": 726, "name": "min_buy_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 608, - "src": "1261:14:5", + "referencedDeclaration": 684, + "src": "1261:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1501,12 +1501,12 @@ }, { "argumentTypes": null, - "id": 651, + "id": 727, "name": "token_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 636, - "src": "1277:12:5", + "referencedDeclaration": 712, + "src": "1277:12:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1532,18 +1532,18 @@ "typeString": "uint256" } ], - "id": 646, + "id": 722, "name": "ethToToken", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 554, - "src": "1223:10:5", + "referencedDeclaration": 630, + "src": "1223:10:6", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 652, + "id": 728, "isConstant": false, "isLValue": false, "isPure": false, @@ -1551,28 +1551,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1223:67:5", + "src": "1223:67:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 653, + "id": 729, "nodeType": "EmitStatement", - "src": "1218:72:5" + "src": "1218:72:6" }, { "assignments": [ - 655 + 731 ], "declarations": [ { "constant": false, - "id": 655, + "id": 731, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 673, - "src": "1299:19:5", + "scope": 749, + "src": "1299:19:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1580,10 +1580,10 @@ "typeString": "uint256" }, "typeName": { - "id": 654, + "id": 730, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1299:7:5", + "src": "1299:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1593,18 +1593,18 @@ "visibility": "internal" } ], - "id": 664, + "id": 740, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 658, + "id": 734, "name": "sell_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 618, - "src": "1362:14:5", + "referencedDeclaration": 694, + "src": "1362:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1612,12 +1612,12 @@ }, { "argumentTypes": null, - "id": 659, + "id": 735, "name": "max_sell_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 614, - "src": "1378:15:5", + "referencedDeclaration": 690, + "src": "1378:15:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1625,12 +1625,12 @@ }, { "argumentTypes": null, - "id": 660, + "id": 736, "name": "sell_deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 616, - "src": "1395:13:5", + "referencedDeclaration": 692, + "src": "1395:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1640,18 +1640,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 661, + "id": 737, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1410:3:5", + "referencedDeclaration": 12128, + "src": "1410:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 662, + "id": 738, "isConstant": false, "isLValue": false, "isPure": false, @@ -1659,7 +1659,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1410:10:5", + "src": "1410:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1687,32 +1687,32 @@ ], "expression": { "argumentTypes": null, - "id": 656, + "id": 732, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 630, - "src": "1321:15:5", + "referencedDeclaration": 706, + "src": "1321:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 657, + "id": 733, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "tokenToEthTransferOutput", "nodeType": "MemberAccess", - "referencedDeclaration": 839, - "src": "1321:40:5", + "referencedDeclaration": 915, + "src": "1321:40:6", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_payable_$returns$_t_uint256_$", "typeString": "function (uint256,uint256,uint256,address payable) external returns (uint256)" } }, - "id": 663, + "id": 739, "isConstant": false, "isLValue": false, "isPure": false, @@ -1720,14 +1720,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1321:100:5", + "src": "1321:100:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "1299:122:5" + "src": "1299:122:6" }, { "eventCall": { @@ -1737,18 +1737,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 666, + "id": 742, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1445:3:5", + "referencedDeclaration": 12128, + "src": "1445:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 667, + "id": 743, "isConstant": false, "isLValue": false, "isPure": false, @@ -1756,7 +1756,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1445:10:5", + "src": "1445:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -1764,12 +1764,12 @@ }, { "argumentTypes": null, - "id": 668, + "id": 744, "name": "sell_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 618, - "src": "1457:14:5", + "referencedDeclaration": 694, + "src": "1457:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1777,12 +1777,12 @@ }, { "argumentTypes": null, - "id": 669, + "id": 745, "name": "max_sell_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 614, - "src": "1473:15:5", + "referencedDeclaration": 690, + "src": "1473:15:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1790,12 +1790,12 @@ }, { "argumentTypes": null, - "id": 670, + "id": 746, "name": "tokens_sold", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 655, - "src": "1490:11:5", + "referencedDeclaration": 731, + "src": "1490:11:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1821,18 +1821,18 @@ "typeString": "uint256" } ], - "id": 665, + "id": 741, "name": "tokenToEth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 564, - "src": "1434:10:5", + "referencedDeclaration": 640, + "src": "1434:10:6", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 671, + "id": 747, "isConstant": false, "isLValue": false, "isPure": false, @@ -1840,36 +1840,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1434:68:5", + "src": "1434:68:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 672, + "id": 748, "nodeType": "EmitStatement", - "src": "1429:73:5" + "src": "1429:73:6" } ] }, "documentation": null, - "id": 674, + "id": 750, "implemented": true, "kind": "function", "modifiers": [], "name": "trade", "nodeType": "FunctionDefinition", "parameters": { - "id": 619, + "id": 695, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 606, + "id": 682, "name": "uniSwapExchangeAddr", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "683:27:5", + "scope": 750, + "src": "683:27:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1877,10 +1877,10 @@ "typeString": "address" }, "typeName": { - "id": 605, + "id": 681, "name": "address", "nodeType": "ElementaryTypeName", - "src": "683:7:5", + "src": "683:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -1892,11 +1892,11 @@ }, { "constant": false, - "id": 608, + "id": 684, "name": "min_buy_tokens", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "716:22:5", + "scope": 750, + "src": "716:22:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1904,10 +1904,10 @@ "typeString": "uint256" }, "typeName": { - "id": 607, + "id": 683, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "716:7:5", + "src": "716:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1918,11 +1918,11 @@ }, { "constant": false, - "id": 610, + "id": 686, "name": "buy_deadline", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "744:20:5", + "scope": 750, + "src": "744:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1930,10 +1930,10 @@ "typeString": "uint256" }, "typeName": { - "id": 609, + "id": 685, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "744:7:5", + "src": "744:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1944,11 +1944,11 @@ }, { "constant": false, - "id": 612, + "id": 688, "name": "buy_eth_value", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "770:21:5", + "scope": 750, + "src": "770:21:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1956,10 +1956,10 @@ "typeString": "uint256" }, "typeName": { - "id": 611, + "id": 687, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "770:7:5", + "src": "770:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1970,11 +1970,11 @@ }, { "constant": false, - "id": 614, + "id": 690, "name": "max_sell_tokens", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "797:23:5", + "scope": 750, + "src": "797:23:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1982,10 +1982,10 @@ "typeString": "uint256" }, "typeName": { - "id": 613, + "id": 689, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "797:7:5", + "src": "797:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1996,11 +1996,11 @@ }, { "constant": false, - "id": 616, + "id": 692, "name": "sell_deadline", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "826:21:5", + "scope": 750, + "src": "826:21:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2008,10 +2008,10 @@ "typeString": "uint256" }, "typeName": { - "id": 615, + "id": 691, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "826:7:5", + "src": "826:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2022,11 +2022,11 @@ }, { "constant": false, - "id": 618, + "id": 694, "name": "sell_eth_value", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "853:22:5", + "scope": 750, + "src": "853:22:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2034,10 +2034,10 @@ "typeString": "uint256" }, "typeName": { - "id": 617, + "id": 693, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "853:7:5", + "src": "853:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2047,25 +2047,25 @@ "visibility": "internal" } ], - "src": "677:199:5" + "src": "677:199:6" }, "returnParameters": { - "id": 620, + "id": 696, "nodeType": "ParameterList", "parameters": [], - "src": "896:0:5" + "src": "896:0:6" }, - "scope": 768, - "src": "663:844:5", + "scope": 844, + "src": "663:844:6", "stateMutability": "payable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 718, + "id": 794, "nodeType": "Block", - "src": "1670:399:5", + "src": "1670:399:6", "statements": [ { "expression": { @@ -2077,7 +2077,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 689, + "id": 765, "isConstant": false, "isLValue": false, "isPure": false, @@ -2086,18 +2086,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 686, + "id": 762, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1686:3:5", + "referencedDeclaration": 12128, + "src": "1686:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 687, + "id": 763, "isConstant": false, "isLValue": false, "isPure": false, @@ -2105,7 +2105,7 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1686:9:5", + "src": "1686:9:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2115,18 +2115,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 688, + "id": 764, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 682, - "src": "1699:13:5", + "referencedDeclaration": 758, + "src": "1699:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "1686:26:5", + "src": "1686:26:6", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -2135,14 +2135,14 @@ { "argumentTypes": null, "hexValue": "4e6f7420456e6f756768204574682053656e74", - "id": 690, + "id": 766, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "1714:21:5", + "src": "1714:21:6", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30b29beae4cdbb7acc80a8e1229a071d1d9114e20038f0c713ecf8dbdd0dcc4e", @@ -2162,21 +2162,21 @@ "typeString": "literal_string \"Not Enough Eth Sent\"" } ], - "id": 685, + "id": 761, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "1678:7:5", + "referencedDeclaration": 12132, + "src": "1678:7:6", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 691, + "id": 767, "isConstant": false, "isLValue": false, "isPure": false, @@ -2184,43 +2184,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1678:58:5", + "src": "1678:58:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 692, + "id": 768, "nodeType": "ExpressionStatement", - "src": "1678:58:5" + "src": "1678:58:6" }, { "assignments": [ - 694 + 770 ], "declarations": [ { "constant": false, - "id": 694, + "id": 770, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 718, - "src": "1745:31:5", + "scope": 794, + "src": "1745:31:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 693, + "id": 769, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "1745:15:5", + "referencedDeclaration": 920, + "src": "1745:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -2228,18 +2228,18 @@ "visibility": "internal" } ], - "id": 698, + "id": 774, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 696, + "id": 772, "name": "uniSwapExchangeAddr", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 676, - "src": "1795:19:5", + "referencedDeclaration": 752, + "src": "1795:19:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2253,18 +2253,18 @@ "typeString": "address" } ], - "id": 695, + "id": 771, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "1779:15:5", + "referencedDeclaration": 920, + "src": "1779:15:6", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 697, + "id": 773, "isConstant": false, "isLValue": false, "isPure": false, @@ -2272,27 +2272,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1779:36:5", + "src": "1779:36:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "1745:70:5" + "src": "1745:70:6" }, { "assignments": [ - 700 + 776 ], "declarations": [ { "constant": false, - "id": 700, + "id": 776, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 718, - "src": "1824:20:5", + "scope": 794, + "src": "1824:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2300,10 +2300,10 @@ "typeString": "uint256" }, "typeName": { - "id": 699, + "id": 775, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1824:7:5", + "src": "1824:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2313,18 +2313,18 @@ "visibility": "internal" } ], - "id": 709, + "id": 785, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 706, + "id": 782, "name": "min_buy_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 678, - "src": "1904:14:5", + "referencedDeclaration": 754, + "src": "1904:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2332,12 +2332,12 @@ }, { "argumentTypes": null, - "id": 707, + "id": 783, "name": "buy_deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 680, - "src": "1920:12:5", + "referencedDeclaration": 756, + "src": "1920:12:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2358,12 +2358,12 @@ "arguments": [ { "argumentTypes": null, - "id": 704, + "id": 780, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 682, - "src": "1889:13:5", + "referencedDeclaration": 758, + "src": "1889:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2381,32 +2381,32 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 701, + "id": 777, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 694, - "src": "1847:15:5", + "referencedDeclaration": 770, + "src": "1847:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 702, + "id": 778, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "ethToTokenSwapInput", "nodeType": "MemberAccess", - "referencedDeclaration": 789, - "src": "1847:35:5", + "referencedDeclaration": 865, + "src": "1847:35:6", "typeDescriptions": { "typeIdentifier": "t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$", "typeString": "function (uint256,uint256) payable external returns (uint256)" } }, - "id": 703, + "id": 779, "isConstant": false, "isLValue": false, "isPure": false, @@ -2414,13 +2414,13 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1847:41:5", + "src": "1847:41:6", "typeDescriptions": { "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$value_$", "typeString": "function (uint256) returns (function (uint256,uint256) payable external returns (uint256))" } }, - "id": 705, + "id": 781, "isConstant": false, "isLValue": false, "isPure": false, @@ -2428,13 +2428,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1847:56:5", + "src": "1847:56:6", "typeDescriptions": { "typeIdentifier": "t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$value", "typeString": "function (uint256,uint256) payable external returns (uint256)" } }, - "id": 708, + "id": 784, "isConstant": false, "isLValue": false, "isPure": false, @@ -2442,14 +2442,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1847:86:5", + "src": "1847:86:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "1824:109:5" + "src": "1824:109:6" }, { "eventCall": { @@ -2459,18 +2459,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 711, + "id": 787, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2008:3:5", + "referencedDeclaration": 12128, + "src": "2008:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 712, + "id": 788, "isConstant": false, "isLValue": false, "isPure": false, @@ -2478,7 +2478,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2008:10:5", + "src": "2008:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -2486,12 +2486,12 @@ }, { "argumentTypes": null, - "id": 713, + "id": 789, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 682, - "src": "2020:13:5", + "referencedDeclaration": 758, + "src": "2020:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2499,12 +2499,12 @@ }, { "argumentTypes": null, - "id": 714, + "id": 790, "name": "min_buy_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 678, - "src": "2035:14:5", + "referencedDeclaration": 754, + "src": "2035:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2512,12 +2512,12 @@ }, { "argumentTypes": null, - "id": 715, + "id": 791, "name": "token_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 700, - "src": "2051:12:5", + "referencedDeclaration": 776, + "src": "2051:12:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2543,18 +2543,18 @@ "typeString": "uint256" } ], - "id": 710, + "id": 786, "name": "ethToToken", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 554, - "src": "1997:10:5", + "referencedDeclaration": 630, + "src": "1997:10:6", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 716, + "id": 792, "isConstant": false, "isLValue": false, "isPure": false, @@ -2562,36 +2562,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1997:67:5", + "src": "1997:67:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 717, + "id": 793, "nodeType": "EmitStatement", - "src": "1992:72:5" + "src": "1992:72:6" } ] }, "documentation": null, - "id": 719, + "id": 795, "implemented": true, "kind": "function", "modifiers": [], "name": "tradeEthToToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 683, + "id": 759, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 676, + "id": 752, "name": "uniSwapExchangeAddr", "nodeType": "VariableDeclaration", - "scope": 719, - "src": "1541:27:5", + "scope": 795, + "src": "1541:27:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2599,10 +2599,10 @@ "typeString": "address" }, "typeName": { - "id": 675, + "id": 751, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1541:7:5", + "src": "1541:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -2614,11 +2614,11 @@ }, { "constant": false, - "id": 678, + "id": 754, "name": "min_buy_tokens", "nodeType": "VariableDeclaration", - "scope": 719, - "src": "1574:22:5", + "scope": 795, + "src": "1574:22:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2626,10 +2626,10 @@ "typeString": "uint256" }, "typeName": { - "id": 677, + "id": 753, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1574:7:5", + "src": "1574:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2640,11 +2640,11 @@ }, { "constant": false, - "id": 680, + "id": 756, "name": "buy_deadline", "nodeType": "VariableDeclaration", - "scope": 719, - "src": "1602:20:5", + "scope": 795, + "src": "1602:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2652,10 +2652,10 @@ "typeString": "uint256" }, "typeName": { - "id": 679, + "id": 755, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1602:7:5", + "src": "1602:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2666,11 +2666,11 @@ }, { "constant": false, - "id": 682, + "id": 758, "name": "buy_eth_value", "nodeType": "VariableDeclaration", - "scope": 719, - "src": "1628:21:5", + "scope": 795, + "src": "1628:21:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2678,10 +2678,10 @@ "typeString": "uint256" }, "typeName": { - "id": 681, + "id": 757, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1628:7:5", + "src": "1628:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2691,53 +2691,53 @@ "visibility": "internal" } ], - "src": "1535:115:5" + "src": "1535:115:6" }, "returnParameters": { - "id": 684, + "id": 760, "nodeType": "ParameterList", "parameters": [], - "src": "1670:0:5" + "src": "1670:0:6" }, - "scope": 768, - "src": "1511:558:5", + "scope": 844, + "src": "1511:558:6", "stateMutability": "payable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 755, + "id": 831, "nodeType": "Block", - "src": "2227:329:5", + "src": "2227:329:6", "statements": [ { "assignments": [ - 731 + 807 ], "declarations": [ { "constant": false, - "id": 731, + "id": 807, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 755, - "src": "2268:31:5", + "scope": 831, + "src": "2268:31:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 730, + "id": 806, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "2268:15:5", + "referencedDeclaration": 920, + "src": "2268:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -2745,18 +2745,18 @@ "visibility": "internal" } ], - "id": 735, + "id": 811, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 733, + "id": 809, "name": "uniSwapExchangeAddr", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 721, - "src": "2318:19:5", + "referencedDeclaration": 797, + "src": "2318:19:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -2770,18 +2770,18 @@ "typeString": "address" } ], - "id": 732, + "id": 808, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "2302:15:5", + "referencedDeclaration": 920, + "src": "2302:15:6", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 734, + "id": 810, "isConstant": false, "isLValue": false, "isPure": false, @@ -2789,27 +2789,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2302:36:5", + "src": "2302:36:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "2268:70:5" + "src": "2268:70:6" }, { "assignments": [ - 737 + 813 ], "declarations": [ { "constant": false, - "id": 737, + "id": 813, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 755, - "src": "2347:19:5", + "scope": 831, + "src": "2347:19:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2817,10 +2817,10 @@ "typeString": "uint256" }, "typeName": { - "id": 736, + "id": 812, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2347:7:5", + "src": "2347:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2830,18 +2830,18 @@ "visibility": "internal" } ], - "id": 746, + "id": 822, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 740, + "id": 816, "name": "sell_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 727, - "src": "2410:14:5", + "referencedDeclaration": 803, + "src": "2410:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2849,12 +2849,12 @@ }, { "argumentTypes": null, - "id": 741, + "id": 817, "name": "max_sell_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 723, - "src": "2426:15:5", + "referencedDeclaration": 799, + "src": "2426:15:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2862,12 +2862,12 @@ }, { "argumentTypes": null, - "id": 742, + "id": 818, "name": "sell_deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 725, - "src": "2443:13:5", + "referencedDeclaration": 801, + "src": "2443:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2877,18 +2877,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 743, + "id": 819, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2458:3:5", + "referencedDeclaration": 12128, + "src": "2458:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 744, + "id": 820, "isConstant": false, "isLValue": false, "isPure": false, @@ -2896,7 +2896,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2458:10:5", + "src": "2458:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -2924,32 +2924,32 @@ ], "expression": { "argumentTypes": null, - "id": 738, + "id": 814, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 731, - "src": "2369:15:5", + "referencedDeclaration": 807, + "src": "2369:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 739, + "id": 815, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "tokenToEthTransferOutput", "nodeType": "MemberAccess", - "referencedDeclaration": 839, - "src": "2369:40:5", + "referencedDeclaration": 915, + "src": "2369:40:6", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_payable_$returns$_t_uint256_$", "typeString": "function (uint256,uint256,uint256,address payable) external returns (uint256)" } }, - "id": 745, + "id": 821, "isConstant": false, "isLValue": false, "isPure": false, @@ -2957,14 +2957,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2369:100:5", + "src": "2369:100:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2347:122:5" + "src": "2347:122:6" }, { "eventCall": { @@ -2974,18 +2974,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 748, + "id": 824, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2494:3:5", + "referencedDeclaration": 12128, + "src": "2494:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 749, + "id": 825, "isConstant": false, "isLValue": false, "isPure": false, @@ -2993,7 +2993,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2494:10:5", + "src": "2494:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -3001,12 +3001,12 @@ }, { "argumentTypes": null, - "id": 750, + "id": 826, "name": "sell_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 727, - "src": "2506:14:5", + "referencedDeclaration": 803, + "src": "2506:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3014,12 +3014,12 @@ }, { "argumentTypes": null, - "id": 751, + "id": 827, "name": "max_sell_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 723, - "src": "2522:15:5", + "referencedDeclaration": 799, + "src": "2522:15:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3027,12 +3027,12 @@ }, { "argumentTypes": null, - "id": 752, + "id": 828, "name": "tokens_sold", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 737, - "src": "2539:11:5", + "referencedDeclaration": 813, + "src": "2539:11:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3058,18 +3058,18 @@ "typeString": "uint256" } ], - "id": 747, + "id": 823, "name": "tokenToEth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 564, - "src": "2483:10:5", + "referencedDeclaration": 640, + "src": "2483:10:6", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 753, + "id": 829, "isConstant": false, "isLValue": false, "isPure": false, @@ -3077,36 +3077,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2483:68:5", + "src": "2483:68:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 754, + "id": 830, "nodeType": "EmitStatement", - "src": "2478:73:5" + "src": "2478:73:6" } ] }, "documentation": null, - "id": 756, + "id": 832, "implemented": true, "kind": "function", "modifiers": [], "name": "tradeTokenToEth", "nodeType": "FunctionDefinition", "parameters": { - "id": 728, + "id": 804, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 721, + "id": 797, "name": "uniSwapExchangeAddr", "nodeType": "VariableDeclaration", - "scope": 756, - "src": "2103:27:5", + "scope": 832, + "src": "2103:27:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3114,10 +3114,10 @@ "typeString": "address" }, "typeName": { - "id": 720, + "id": 796, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2103:7:5", + "src": "2103:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3129,11 +3129,11 @@ }, { "constant": false, - "id": 723, + "id": 799, "name": "max_sell_tokens", "nodeType": "VariableDeclaration", - "scope": 756, - "src": "2136:23:5", + "scope": 832, + "src": "2136:23:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3141,10 +3141,10 @@ "typeString": "uint256" }, "typeName": { - "id": 722, + "id": 798, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2136:7:5", + "src": "2136:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3155,11 +3155,11 @@ }, { "constant": false, - "id": 725, + "id": 801, "name": "sell_deadline", "nodeType": "VariableDeclaration", - "scope": 756, - "src": "2165:21:5", + "scope": 832, + "src": "2165:21:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3167,10 +3167,10 @@ "typeString": "uint256" }, "typeName": { - "id": 724, + "id": 800, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2165:7:5", + "src": "2165:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3181,11 +3181,11 @@ }, { "constant": false, - "id": 727, + "id": 803, "name": "sell_eth_value", "nodeType": "VariableDeclaration", - "scope": 756, - "src": "2192:22:5", + "scope": 832, + "src": "2192:22:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3193,10 +3193,10 @@ "typeString": "uint256" }, "typeName": { - "id": 726, + "id": 802, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2192:7:5", + "src": "2192:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3206,25 +3206,25 @@ "visibility": "internal" } ], - "src": "2097:118:5" + "src": "2097:118:6" }, "returnParameters": { - "id": 729, + "id": 805, "nodeType": "ParameterList", "parameters": [], - "src": "2227:0:5" + "src": "2227:0:6" }, - "scope": 768, - "src": "2073:483:5", + "scope": 844, + "src": "2073:483:6", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 766, + "id": 842, "nodeType": "Block", - "src": "2612:39:5", + "src": "2612:39:6", "statements": [ { "expression": { @@ -3234,14 +3234,14 @@ "arguments": [ { "argumentTypes": null, - "id": 762, + "id": 838, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1490, - "src": "2633:4:5", + "referencedDeclaration": 12192, + "src": "2633:4:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_RinkebyArbContract_$768", + "typeIdentifier": "t_contract$_RinkebyArbContract_$844", "typeString": "contract RinkebyArbContract" } } @@ -3249,24 +3249,24 @@ "expression": { "argumentTypes": [ { - "typeIdentifier": "t_contract$_RinkebyArbContract_$768", + "typeIdentifier": "t_contract$_RinkebyArbContract_$844", "typeString": "contract RinkebyArbContract" } ], - "id": 761, + "id": 837, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "2625:7:5", + "src": "2625:7:6", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 763, + "id": 839, "isConstant": false, "isLValue": false, "isPure": false, @@ -3274,13 +3274,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2625:13:5", + "src": "2625:13:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 764, + "id": 840, "isConstant": false, "isLValue": false, "isPure": false, @@ -3288,43 +3288,43 @@ "memberName": "balance", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2625:21:5", + "src": "2625:21:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 760, - "id": 765, + "functionReturnParameters": 836, + "id": 841, "nodeType": "Return", - "src": "2618:28:5" + "src": "2618:28:6" } ] }, "documentation": null, - "id": 767, + "id": 843, "implemented": true, "kind": "function", "modifiers": [], "name": "getBalance", "nodeType": "FunctionDefinition", "parameters": { - "id": 757, + "id": 833, "nodeType": "ParameterList", "parameters": [], - "src": "2579:2:5" + "src": "2579:2:6" }, "returnParameters": { - "id": 760, + "id": 836, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 759, + "id": 835, "name": "", "nodeType": "VariableDeclaration", - "scope": 767, - "src": "2603:7:5", + "scope": 843, + "src": "2603:7:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3332,10 +3332,10 @@ "typeString": "uint256" }, "typeName": { - "id": 758, + "id": 834, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2603:7:5", + "src": "2603:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3345,33 +3345,33 @@ "visibility": "internal" } ], - "src": "2602:9:5" + "src": "2602:9:6" }, - "scope": 768, - "src": "2560:91:5", + "scope": 844, + "src": "2560:91:6", "stateMutability": "view", "superFunction": null, "visibility": "public" } ], - "scope": 769, - "src": "114:2539:5" + "scope": 845, + "src": "114:2539:6" } ], - "src": "0:2654:5" + "src": "0:2654:6" }, "legacyAST": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/RinkebyArbContract.sol", "exportedSymbols": { "RinkebyArbContract": [ - 768 + 844 ] }, - "id": 769, + "id": 845, "nodeType": "SourceUnit", "nodes": [ { - "id": 540, + "id": 616, "literals": [ "solidity", "^", @@ -3379,27 +3379,27 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:5" + "src": "0:23:6" }, { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol", "file": "./UniswapExchange.sol", - "id": 541, + "id": 617, "nodeType": "ImportDirective", - "scope": 769, - "sourceUnit": 845, - "src": "25:31:5", + "scope": 845, + "sourceUnit": 921, + "src": "25:31:6", "symbolAliases": [], "unitAlias": "" }, { "absolutePath": "@openzeppelin/contracts/token/ERC20/ERC20.sol", "file": "@openzeppelin/contracts/token/ERC20/ERC20.sol", - "id": 542, + "id": 618, "nodeType": "ImportDirective", - "scope": 769, - "sourceUnit": 1375, - "src": "57:55:5", + "scope": 845, + "sourceUnit": 10858, + "src": "57:55:6", "symbolAliases": [], "unitAlias": "" }, @@ -3409,20 +3409,20 @@ "contractKind": "contract", "documentation": null, "fullyImplemented": true, - "id": 768, + "id": 844, "linearizedBaseContracts": [ - 768 + 844 ], "name": "RinkebyArbContract", "nodeType": "ContractDefinition", "nodes": [ { "constant": false, - "id": 544, + "id": 620, "name": "owner", "nodeType": "VariableDeclaration", - "scope": 768, - "src": "147:20:5", + "scope": 844, + "src": "147:20:6", "stateVariable": true, "storageLocation": "default", "typeDescriptions": { @@ -3430,10 +3430,10 @@ "typeString": "address" }, "typeName": { - "id": 543, + "id": 619, "name": "address", "nodeType": "ElementaryTypeName", - "src": "147:7:5", + "src": "147:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3446,21 +3446,21 @@ { "anonymous": false, "documentation": null, - "id": 554, + "id": 630, "name": "ethToToken", "nodeType": "EventDefinition", "parameters": { - "id": 553, + "id": 629, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 546, + "id": 622, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 554, - "src": "189:14:5", + "scope": 630, + "src": "189:14:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3468,10 +3468,10 @@ "typeString": "address" }, "typeName": { - "id": 545, + "id": 621, "name": "address", "nodeType": "ElementaryTypeName", - "src": "189:7:5", + "src": "189:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3483,12 +3483,12 @@ }, { "constant": false, - "id": 548, + "id": 624, "indexed": false, "name": "eth", "nodeType": "VariableDeclaration", - "scope": 554, - "src": "205:11:5", + "scope": 630, + "src": "205:11:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3496,10 +3496,10 @@ "typeString": "uint256" }, "typeName": { - "id": 547, + "id": 623, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "205:7:5", + "src": "205:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3510,12 +3510,12 @@ }, { "constant": false, - "id": 550, + "id": 626, "indexed": false, "name": "tokens", "nodeType": "VariableDeclaration", - "scope": 554, - "src": "218:14:5", + "scope": 630, + "src": "218:14:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3523,10 +3523,10 @@ "typeString": "uint256" }, "typeName": { - "id": 549, + "id": 625, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "218:7:5", + "src": "218:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3537,12 +3537,12 @@ }, { "constant": false, - "id": 552, + "id": 628, "indexed": false, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 554, - "src": "234:20:5", + "scope": 630, + "src": "234:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3550,10 +3550,10 @@ "typeString": "uint256" }, "typeName": { - "id": 551, + "id": 627, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "234:7:5", + "src": "234:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3563,28 +3563,28 @@ "visibility": "internal" } ], - "src": "188:67:5" + "src": "188:67:6" }, - "src": "172:84:5" + "src": "172:84:6" }, { "anonymous": false, "documentation": null, - "id": 564, + "id": 640, "name": "tokenToEth", "nodeType": "EventDefinition", "parameters": { - "id": 563, + "id": 639, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 556, + "id": 632, "indexed": false, "name": "trader", "nodeType": "VariableDeclaration", - "scope": 564, - "src": "276:14:5", + "scope": 640, + "src": "276:14:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3592,10 +3592,10 @@ "typeString": "address" }, "typeName": { - "id": 555, + "id": 631, "name": "address", "nodeType": "ElementaryTypeName", - "src": "276:7:5", + "src": "276:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -3607,12 +3607,12 @@ }, { "constant": false, - "id": 558, + "id": 634, "indexed": false, "name": "sell_eth_value", "nodeType": "VariableDeclaration", - "scope": 564, - "src": "292:22:5", + "scope": 640, + "src": "292:22:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3620,10 +3620,10 @@ "typeString": "uint256" }, "typeName": { - "id": 557, + "id": 633, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "292:7:5", + "src": "292:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3634,12 +3634,12 @@ }, { "constant": false, - "id": 560, + "id": 636, "indexed": false, "name": "max_sell_tokens", "nodeType": "VariableDeclaration", - "scope": 564, - "src": "316:23:5", + "scope": 640, + "src": "316:23:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3647,10 +3647,10 @@ "typeString": "uint256" }, "typeName": { - "id": 559, + "id": 635, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "316:7:5", + "src": "316:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3661,12 +3661,12 @@ }, { "constant": false, - "id": 562, + "id": 638, "indexed": false, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 564, - "src": "341:19:5", + "scope": 640, + "src": "341:19:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3674,10 +3674,10 @@ "typeString": "uint256" }, "typeName": { - "id": 561, + "id": 637, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "341:7:5", + "src": "341:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3687,32 +3687,32 @@ "visibility": "internal" } ], - "src": "275:86:5" + "src": "275:86:6" }, - "src": "259:103:5" + "src": "259:103:6" }, { "body": { - "id": 572, + "id": 648, "nodeType": "Block", - "src": "387:29:5", + "src": "387:29:6", "statements": [ { "expression": { "argumentTypes": null, - "id": 570, + "id": 646, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftHandSide": { "argumentTypes": null, - "id": 567, + "id": 643, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 544, - "src": "393:5:5", + "referencedDeclaration": 620, + "src": "393:5:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3724,18 +3724,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 568, + "id": 644, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "401:3:5", + "referencedDeclaration": 12128, + "src": "401:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 569, + "id": 645, "isConstant": false, "isLValue": false, "isPure": false, @@ -3743,54 +3743,54 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "401:10:5", + "src": "401:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "src": "393:18:5", + "src": "393:18:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 571, + "id": 647, "nodeType": "ExpressionStatement", - "src": "393:18:5" + "src": "393:18:6" } ] }, "documentation": null, - "id": 573, + "id": 649, "implemented": true, "kind": "constructor", "modifiers": [], "name": "", "nodeType": "FunctionDefinition", "parameters": { - "id": 565, + "id": 641, "nodeType": "ParameterList", "parameters": [], - "src": "377:2:5" + "src": "377:2:6" }, "returnParameters": { - "id": 566, + "id": 642, "nodeType": "ParameterList", "parameters": [], - "src": "387:0:5" + "src": "387:0:6" }, - "scope": 768, - "src": "366:50:5", + "scope": 844, + "src": "366:50:6", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 603, + "id": 679, "nodeType": "Block", - "src": "509:150:5", + "src": "509:150:6", "statements": [ { "expression": { @@ -3802,7 +3802,7 @@ "typeIdentifier": "t_address", "typeString": "address" }, - "id": 586, + "id": 662, "isConstant": false, "isLValue": false, "isPure": false, @@ -3811,18 +3811,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 583, + "id": 659, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "523:3:5", + "referencedDeclaration": 12128, + "src": "523:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 584, + "id": 660, "isConstant": false, "isLValue": false, "isPure": false, @@ -3830,7 +3830,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "523:10:5", + "src": "523:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -3840,18 +3840,18 @@ "operator": "==", "rightExpression": { "argumentTypes": null, - "id": 585, + "id": 661, "name": "owner", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 544, - "src": "537:5:5", + "referencedDeclaration": 620, + "src": "537:5:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "src": "523:19:5", + "src": "523:19:6", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -3860,14 +3860,14 @@ { "argumentTypes": null, "hexValue": "4f6e6c79204f776e65722043616e20417070726f7665", - "id": 587, + "id": 663, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "544:24:5", + "src": "544:24:6", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_ec0b1a840a8a6c4384575556c3817abb58aac6b2bc4e7741e1c712be8067937e", @@ -3887,21 +3887,21 @@ "typeString": "literal_string \"Only Owner Can Approve\"" } ], - "id": 582, + "id": 658, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "515:7:5", + "referencedDeclaration": 12132, + "src": "515:7:6", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 588, + "id": 664, "isConstant": false, "isLValue": false, "isPure": false, @@ -3909,43 +3909,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "515:54:5", + "src": "515:54:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 589, + "id": 665, "nodeType": "ExpressionStatement", - "src": "515:54:5" + "src": "515:54:6" }, { "assignments": [ - 591 + 667 ], "declarations": [ { "constant": false, - "id": 591, + "id": 667, "name": "token", "nodeType": "VariableDeclaration", - "scope": 603, - "src": "576:11:5", + "scope": 679, + "src": "576:11:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" }, "typeName": { "contractScope": null, - "id": 590, + "id": 666, "name": "ERC20", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 1374, - "src": "576:5:5", + "referencedDeclaration": 10857, + "src": "576:5:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, @@ -3953,18 +3953,18 @@ "visibility": "internal" } ], - "id": 595, + "id": 671, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 593, + "id": 669, "name": "tokenAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 575, - "src": "596:12:5", + "referencedDeclaration": 651, + "src": "596:12:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -3978,18 +3978,18 @@ "typeString": "address" } ], - "id": 592, + "id": 668, "name": "ERC20", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1374, - "src": "590:5:5", + "referencedDeclaration": 10857, + "src": "590:5:6", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_ERC20_$1374_$", + "typeIdentifier": "t_type$_t_contract$_ERC20_$10857_$", "typeString": "type(contract ERC20)" } }, - "id": 594, + "id": 670, "isConstant": false, "isLValue": false, "isPure": false, @@ -3997,14 +3997,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "590:19:5", + "src": "590:19:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, "nodeType": "VariableDeclarationStatement", - "src": "576:33:5" + "src": "576:33:6" }, { "expression": { @@ -4012,12 +4012,12 @@ "arguments": [ { "argumentTypes": null, - "id": 599, + "id": 675, "name": "exchangeAddress", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 577, - "src": "630:15:5", + "referencedDeclaration": 653, + "src": "630:15:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4025,12 +4025,12 @@ }, { "argumentTypes": null, - "id": 600, + "id": 676, "name": "amount", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 579, - "src": "647:6:5", + "referencedDeclaration": 655, + "src": "647:6:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4050,32 +4050,32 @@ ], "expression": { "argumentTypes": null, - "id": 596, + "id": 672, "name": "token", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 591, - "src": "616:5:5", + "referencedDeclaration": 667, + "src": "616:5:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_ERC20_$1374", + "typeIdentifier": "t_contract$_ERC20_$10857", "typeString": "contract ERC20" } }, - "id": 598, + "id": 674, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "approve", "nodeType": "MemberAccess", - "referencedDeclaration": 1072, - "src": "616:13:5", + "referencedDeclaration": 10555, + "src": "616:13:6", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", "typeString": "function (address,uint256) external returns (bool)" } }, - "id": 601, + "id": 677, "isConstant": false, "isLValue": false, "isPure": false, @@ -4083,36 +4083,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "616:38:5", + "src": "616:38:6", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, - "id": 602, + "id": 678, "nodeType": "ExpressionStatement", - "src": "616:38:5" + "src": "616:38:6" } ] }, "documentation": null, - "id": 604, + "id": 680, "implemented": true, "kind": "function", "modifiers": [], "name": "approveToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 580, + "id": 656, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 575, + "id": 651, "name": "tokenAddress", "nodeType": "VariableDeclaration", - "scope": 604, - "src": "442:20:5", + "scope": 680, + "src": "442:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4120,10 +4120,10 @@ "typeString": "address" }, "typeName": { - "id": 574, + "id": 650, "name": "address", "nodeType": "ElementaryTypeName", - "src": "442:7:5", + "src": "442:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -4135,11 +4135,11 @@ }, { "constant": false, - "id": 577, + "id": 653, "name": "exchangeAddress", "nodeType": "VariableDeclaration", - "scope": 604, - "src": "464:23:5", + "scope": 680, + "src": "464:23:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4147,10 +4147,10 @@ "typeString": "address" }, "typeName": { - "id": 576, + "id": 652, "name": "address", "nodeType": "ElementaryTypeName", - "src": "464:7:5", + "src": "464:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -4162,11 +4162,11 @@ }, { "constant": false, - "id": 579, + "id": 655, "name": "amount", "nodeType": "VariableDeclaration", - "scope": 604, - "src": "489:11:5", + "scope": 680, + "src": "489:11:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4174,10 +4174,10 @@ "typeString": "uint256" }, "typeName": { - "id": 578, + "id": 654, "name": "uint", "nodeType": "ElementaryTypeName", - "src": "489:4:5", + "src": "489:4:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4187,25 +4187,25 @@ "visibility": "internal" } ], - "src": "441:60:5" + "src": "441:60:6" }, "returnParameters": { - "id": 581, + "id": 657, "nodeType": "ParameterList", "parameters": [], - "src": "509:0:5" + "src": "509:0:6" }, - "scope": 768, - "src": "420:239:5", + "scope": 844, + "src": "420:239:6", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 673, + "id": 749, "nodeType": "Block", - "src": "896:611:5", + "src": "896:611:6", "statements": [ { "expression": { @@ -4217,7 +4217,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 625, + "id": 701, "isConstant": false, "isLValue": false, "isPure": false, @@ -4226,18 +4226,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 622, + "id": 698, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "912:3:5", + "referencedDeclaration": 12128, + "src": "912:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 623, + "id": 699, "isConstant": false, "isLValue": false, "isPure": false, @@ -4245,7 +4245,7 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "912:9:5", + "src": "912:9:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4255,18 +4255,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 624, + "id": 700, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 612, - "src": "925:13:5", + "referencedDeclaration": 688, + "src": "925:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "912:26:5", + "src": "912:26:6", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -4275,14 +4275,14 @@ { "argumentTypes": null, "hexValue": "4e6f7420456e6f756768204574682053656e74", - "id": 626, + "id": 702, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "940:21:5", + "src": "940:21:6", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30b29beae4cdbb7acc80a8e1229a071d1d9114e20038f0c713ecf8dbdd0dcc4e", @@ -4302,21 +4302,21 @@ "typeString": "literal_string \"Not Enough Eth Sent\"" } ], - "id": 621, + "id": 697, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "904:7:5", + "referencedDeclaration": 12132, + "src": "904:7:6", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 627, + "id": 703, "isConstant": false, "isLValue": false, "isPure": false, @@ -4324,43 +4324,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "904:58:5", + "src": "904:58:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 628, + "id": 704, "nodeType": "ExpressionStatement", - "src": "904:58:5" + "src": "904:58:6" }, { "assignments": [ - 630 + 706 ], "declarations": [ { "constant": false, - "id": 630, + "id": 706, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 673, - "src": "971:31:5", + "scope": 749, + "src": "971:31:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 629, + "id": 705, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "971:15:5", + "referencedDeclaration": 920, + "src": "971:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -4368,18 +4368,18 @@ "visibility": "internal" } ], - "id": 634, + "id": 710, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 632, + "id": 708, "name": "uniSwapExchangeAddr", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 606, - "src": "1021:19:5", + "referencedDeclaration": 682, + "src": "1021:19:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -4393,18 +4393,18 @@ "typeString": "address" } ], - "id": 631, + "id": 707, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "1005:15:5", + "referencedDeclaration": 920, + "src": "1005:15:6", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 633, + "id": 709, "isConstant": false, "isLValue": false, "isPure": false, @@ -4412,27 +4412,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1005:36:5", + "src": "1005:36:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "971:70:5" + "src": "971:70:6" }, { "assignments": [ - 636 + 712 ], "declarations": [ { "constant": false, - "id": 636, + "id": 712, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 673, - "src": "1050:20:5", + "scope": 749, + "src": "1050:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4440,10 +4440,10 @@ "typeString": "uint256" }, "typeName": { - "id": 635, + "id": 711, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1050:7:5", + "src": "1050:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4453,18 +4453,18 @@ "visibility": "internal" } ], - "id": 645, + "id": 721, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 642, + "id": 718, "name": "min_buy_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 608, - "src": "1130:14:5", + "referencedDeclaration": 684, + "src": "1130:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4472,12 +4472,12 @@ }, { "argumentTypes": null, - "id": 643, + "id": 719, "name": "buy_deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 610, - "src": "1146:12:5", + "referencedDeclaration": 686, + "src": "1146:12:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4498,12 +4498,12 @@ "arguments": [ { "argumentTypes": null, - "id": 640, + "id": 716, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 612, - "src": "1115:13:5", + "referencedDeclaration": 688, + "src": "1115:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4521,32 +4521,32 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 637, + "id": 713, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 630, - "src": "1073:15:5", + "referencedDeclaration": 706, + "src": "1073:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 638, + "id": 714, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "ethToTokenSwapInput", "nodeType": "MemberAccess", - "referencedDeclaration": 789, - "src": "1073:35:5", + "referencedDeclaration": 865, + "src": "1073:35:6", "typeDescriptions": { "typeIdentifier": "t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$", "typeString": "function (uint256,uint256) payable external returns (uint256)" } }, - "id": 639, + "id": 715, "isConstant": false, "isLValue": false, "isPure": false, @@ -4554,13 +4554,13 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1073:41:5", + "src": "1073:41:6", "typeDescriptions": { "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$value_$", "typeString": "function (uint256) returns (function (uint256,uint256) payable external returns (uint256))" } }, - "id": 641, + "id": 717, "isConstant": false, "isLValue": false, "isPure": false, @@ -4568,13 +4568,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1073:56:5", + "src": "1073:56:6", "typeDescriptions": { "typeIdentifier": "t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$value", "typeString": "function (uint256,uint256) payable external returns (uint256)" } }, - "id": 644, + "id": 720, "isConstant": false, "isLValue": false, "isPure": false, @@ -4582,14 +4582,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1073:86:5", + "src": "1073:86:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "1050:109:5" + "src": "1050:109:6" }, { "eventCall": { @@ -4599,18 +4599,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 647, + "id": 723, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1234:3:5", + "referencedDeclaration": 12128, + "src": "1234:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 648, + "id": 724, "isConstant": false, "isLValue": false, "isPure": false, @@ -4618,7 +4618,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1234:10:5", + "src": "1234:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -4626,12 +4626,12 @@ }, { "argumentTypes": null, - "id": 649, + "id": 725, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 612, - "src": "1246:13:5", + "referencedDeclaration": 688, + "src": "1246:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4639,12 +4639,12 @@ }, { "argumentTypes": null, - "id": 650, + "id": 726, "name": "min_buy_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 608, - "src": "1261:14:5", + "referencedDeclaration": 684, + "src": "1261:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4652,12 +4652,12 @@ }, { "argumentTypes": null, - "id": 651, + "id": 727, "name": "token_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 636, - "src": "1277:12:5", + "referencedDeclaration": 712, + "src": "1277:12:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4683,18 +4683,18 @@ "typeString": "uint256" } ], - "id": 646, + "id": 722, "name": "ethToToken", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 554, - "src": "1223:10:5", + "referencedDeclaration": 630, + "src": "1223:10:6", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 652, + "id": 728, "isConstant": false, "isLValue": false, "isPure": false, @@ -4702,28 +4702,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1223:67:5", + "src": "1223:67:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 653, + "id": 729, "nodeType": "EmitStatement", - "src": "1218:72:5" + "src": "1218:72:6" }, { "assignments": [ - 655 + 731 ], "declarations": [ { "constant": false, - "id": 655, + "id": 731, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 673, - "src": "1299:19:5", + "scope": 749, + "src": "1299:19:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -4731,10 +4731,10 @@ "typeString": "uint256" }, "typeName": { - "id": 654, + "id": 730, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1299:7:5", + "src": "1299:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4744,18 +4744,18 @@ "visibility": "internal" } ], - "id": 664, + "id": 740, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 658, + "id": 734, "name": "sell_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 618, - "src": "1362:14:5", + "referencedDeclaration": 694, + "src": "1362:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4763,12 +4763,12 @@ }, { "argumentTypes": null, - "id": 659, + "id": 735, "name": "max_sell_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 614, - "src": "1378:15:5", + "referencedDeclaration": 690, + "src": "1378:15:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4776,12 +4776,12 @@ }, { "argumentTypes": null, - "id": 660, + "id": 736, "name": "sell_deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 616, - "src": "1395:13:5", + "referencedDeclaration": 692, + "src": "1395:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4791,18 +4791,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 661, + "id": 737, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1410:3:5", + "referencedDeclaration": 12128, + "src": "1410:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 662, + "id": 738, "isConstant": false, "isLValue": false, "isPure": false, @@ -4810,7 +4810,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1410:10:5", + "src": "1410:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -4838,32 +4838,32 @@ ], "expression": { "argumentTypes": null, - "id": 656, + "id": 732, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 630, - "src": "1321:15:5", + "referencedDeclaration": 706, + "src": "1321:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 657, + "id": 733, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "tokenToEthTransferOutput", "nodeType": "MemberAccess", - "referencedDeclaration": 839, - "src": "1321:40:5", + "referencedDeclaration": 915, + "src": "1321:40:6", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_payable_$returns$_t_uint256_$", "typeString": "function (uint256,uint256,uint256,address payable) external returns (uint256)" } }, - "id": 663, + "id": 739, "isConstant": false, "isLValue": false, "isPure": false, @@ -4871,14 +4871,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1321:100:5", + "src": "1321:100:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "1299:122:5" + "src": "1299:122:6" }, { "eventCall": { @@ -4888,18 +4888,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 666, + "id": 742, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1445:3:5", + "referencedDeclaration": 12128, + "src": "1445:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 667, + "id": 743, "isConstant": false, "isLValue": false, "isPure": false, @@ -4907,7 +4907,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1445:10:5", + "src": "1445:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -4915,12 +4915,12 @@ }, { "argumentTypes": null, - "id": 668, + "id": 744, "name": "sell_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 618, - "src": "1457:14:5", + "referencedDeclaration": 694, + "src": "1457:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4928,12 +4928,12 @@ }, { "argumentTypes": null, - "id": 669, + "id": 745, "name": "max_sell_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 614, - "src": "1473:15:5", + "referencedDeclaration": 690, + "src": "1473:15:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4941,12 +4941,12 @@ }, { "argumentTypes": null, - "id": 670, + "id": 746, "name": "tokens_sold", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 655, - "src": "1490:11:5", + "referencedDeclaration": 731, + "src": "1490:11:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -4972,18 +4972,18 @@ "typeString": "uint256" } ], - "id": 665, + "id": 741, "name": "tokenToEth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 564, - "src": "1434:10:5", + "referencedDeclaration": 640, + "src": "1434:10:6", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 671, + "id": 747, "isConstant": false, "isLValue": false, "isPure": false, @@ -4991,36 +4991,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1434:68:5", + "src": "1434:68:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 672, + "id": 748, "nodeType": "EmitStatement", - "src": "1429:73:5" + "src": "1429:73:6" } ] }, "documentation": null, - "id": 674, + "id": 750, "implemented": true, "kind": "function", "modifiers": [], "name": "trade", "nodeType": "FunctionDefinition", "parameters": { - "id": 619, + "id": 695, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 606, + "id": 682, "name": "uniSwapExchangeAddr", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "683:27:5", + "scope": 750, + "src": "683:27:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5028,10 +5028,10 @@ "typeString": "address" }, "typeName": { - "id": 605, + "id": 681, "name": "address", "nodeType": "ElementaryTypeName", - "src": "683:7:5", + "src": "683:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -5043,11 +5043,11 @@ }, { "constant": false, - "id": 608, + "id": 684, "name": "min_buy_tokens", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "716:22:5", + "scope": 750, + "src": "716:22:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5055,10 +5055,10 @@ "typeString": "uint256" }, "typeName": { - "id": 607, + "id": 683, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "716:7:5", + "src": "716:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5069,11 +5069,11 @@ }, { "constant": false, - "id": 610, + "id": 686, "name": "buy_deadline", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "744:20:5", + "scope": 750, + "src": "744:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5081,10 +5081,10 @@ "typeString": "uint256" }, "typeName": { - "id": 609, + "id": 685, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "744:7:5", + "src": "744:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5095,11 +5095,11 @@ }, { "constant": false, - "id": 612, + "id": 688, "name": "buy_eth_value", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "770:21:5", + "scope": 750, + "src": "770:21:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5107,10 +5107,10 @@ "typeString": "uint256" }, "typeName": { - "id": 611, + "id": 687, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "770:7:5", + "src": "770:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5121,11 +5121,11 @@ }, { "constant": false, - "id": 614, + "id": 690, "name": "max_sell_tokens", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "797:23:5", + "scope": 750, + "src": "797:23:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5133,10 +5133,10 @@ "typeString": "uint256" }, "typeName": { - "id": 613, + "id": 689, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "797:7:5", + "src": "797:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5147,11 +5147,11 @@ }, { "constant": false, - "id": 616, + "id": 692, "name": "sell_deadline", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "826:21:5", + "scope": 750, + "src": "826:21:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5159,10 +5159,10 @@ "typeString": "uint256" }, "typeName": { - "id": 615, + "id": 691, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "826:7:5", + "src": "826:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5173,11 +5173,11 @@ }, { "constant": false, - "id": 618, + "id": 694, "name": "sell_eth_value", "nodeType": "VariableDeclaration", - "scope": 674, - "src": "853:22:5", + "scope": 750, + "src": "853:22:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5185,10 +5185,10 @@ "typeString": "uint256" }, "typeName": { - "id": 617, + "id": 693, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "853:7:5", + "src": "853:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5198,25 +5198,25 @@ "visibility": "internal" } ], - "src": "677:199:5" + "src": "677:199:6" }, "returnParameters": { - "id": 620, + "id": 696, "nodeType": "ParameterList", "parameters": [], - "src": "896:0:5" + "src": "896:0:6" }, - "scope": 768, - "src": "663:844:5", + "scope": 844, + "src": "663:844:6", "stateMutability": "payable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 718, + "id": 794, "nodeType": "Block", - "src": "1670:399:5", + "src": "1670:399:6", "statements": [ { "expression": { @@ -5228,7 +5228,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 689, + "id": 765, "isConstant": false, "isLValue": false, "isPure": false, @@ -5237,18 +5237,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 686, + "id": 762, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "1686:3:5", + "referencedDeclaration": 12128, + "src": "1686:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 687, + "id": 763, "isConstant": false, "isLValue": false, "isPure": false, @@ -5256,7 +5256,7 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1686:9:5", + "src": "1686:9:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5266,18 +5266,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 688, + "id": 764, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 682, - "src": "1699:13:5", + "referencedDeclaration": 758, + "src": "1699:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "1686:26:5", + "src": "1686:26:6", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -5286,14 +5286,14 @@ { "argumentTypes": null, "hexValue": "4e6f7420456e6f756768204574682053656e74", - "id": 690, + "id": 766, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "1714:21:5", + "src": "1714:21:6", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30b29beae4cdbb7acc80a8e1229a071d1d9114e20038f0c713ecf8dbdd0dcc4e", @@ -5313,21 +5313,21 @@ "typeString": "literal_string \"Not Enough Eth Sent\"" } ], - "id": 685, + "id": 761, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "1678:7:5", + "referencedDeclaration": 12132, + "src": "1678:7:6", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 691, + "id": 767, "isConstant": false, "isLValue": false, "isPure": false, @@ -5335,43 +5335,43 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1678:58:5", + "src": "1678:58:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 692, + "id": 768, "nodeType": "ExpressionStatement", - "src": "1678:58:5" + "src": "1678:58:6" }, { "assignments": [ - 694 + 770 ], "declarations": [ { "constant": false, - "id": 694, + "id": 770, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 718, - "src": "1745:31:5", + "scope": 794, + "src": "1745:31:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 693, + "id": 769, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "1745:15:5", + "referencedDeclaration": 920, + "src": "1745:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -5379,18 +5379,18 @@ "visibility": "internal" } ], - "id": 698, + "id": 774, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 696, + "id": 772, "name": "uniSwapExchangeAddr", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 676, - "src": "1795:19:5", + "referencedDeclaration": 752, + "src": "1795:19:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5404,18 +5404,18 @@ "typeString": "address" } ], - "id": 695, + "id": 771, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "1779:15:5", + "referencedDeclaration": 920, + "src": "1779:15:6", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 697, + "id": 773, "isConstant": false, "isLValue": false, "isPure": false, @@ -5423,27 +5423,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1779:36:5", + "src": "1779:36:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "1745:70:5" + "src": "1745:70:6" }, { "assignments": [ - 700 + 776 ], "declarations": [ { "constant": false, - "id": 700, + "id": 776, "name": "token_bought", "nodeType": "VariableDeclaration", - "scope": 718, - "src": "1824:20:5", + "scope": 794, + "src": "1824:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5451,10 +5451,10 @@ "typeString": "uint256" }, "typeName": { - "id": 699, + "id": 775, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1824:7:5", + "src": "1824:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5464,18 +5464,18 @@ "visibility": "internal" } ], - "id": 709, + "id": 785, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 706, + "id": 782, "name": "min_buy_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 678, - "src": "1904:14:5", + "referencedDeclaration": 754, + "src": "1904:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5483,12 +5483,12 @@ }, { "argumentTypes": null, - "id": 707, + "id": 783, "name": "buy_deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 680, - "src": "1920:12:5", + "referencedDeclaration": 756, + "src": "1920:12:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5509,12 +5509,12 @@ "arguments": [ { "argumentTypes": null, - "id": 704, + "id": 780, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 682, - "src": "1889:13:5", + "referencedDeclaration": 758, + "src": "1889:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5532,32 +5532,32 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 701, + "id": 777, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 694, - "src": "1847:15:5", + "referencedDeclaration": 770, + "src": "1847:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 702, + "id": 778, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "ethToTokenSwapInput", "nodeType": "MemberAccess", - "referencedDeclaration": 789, - "src": "1847:35:5", + "referencedDeclaration": 865, + "src": "1847:35:6", "typeDescriptions": { "typeIdentifier": "t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$", "typeString": "function (uint256,uint256) payable external returns (uint256)" } }, - "id": 703, + "id": 779, "isConstant": false, "isLValue": false, "isPure": false, @@ -5565,13 +5565,13 @@ "memberName": "value", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1847:41:5", + "src": "1847:41:6", "typeDescriptions": { "typeIdentifier": "t_function_setvalue_nonpayable$_t_uint256_$returns$_t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$value_$", "typeString": "function (uint256) returns (function (uint256,uint256) payable external returns (uint256))" } }, - "id": 705, + "id": 781, "isConstant": false, "isLValue": false, "isPure": false, @@ -5579,13 +5579,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1847:56:5", + "src": "1847:56:6", "typeDescriptions": { "typeIdentifier": "t_function_external_payable$_t_uint256_$_t_uint256_$returns$_t_uint256_$value", "typeString": "function (uint256,uint256) payable external returns (uint256)" } }, - "id": 708, + "id": 784, "isConstant": false, "isLValue": false, "isPure": false, @@ -5593,14 +5593,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1847:86:5", + "src": "1847:86:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "1824:109:5" + "src": "1824:109:6" }, { "eventCall": { @@ -5610,18 +5610,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 711, + "id": 787, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2008:3:5", + "referencedDeclaration": 12128, + "src": "2008:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 712, + "id": 788, "isConstant": false, "isLValue": false, "isPure": false, @@ -5629,7 +5629,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2008:10:5", + "src": "2008:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -5637,12 +5637,12 @@ }, { "argumentTypes": null, - "id": 713, + "id": 789, "name": "buy_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 682, - "src": "2020:13:5", + "referencedDeclaration": 758, + "src": "2020:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5650,12 +5650,12 @@ }, { "argumentTypes": null, - "id": 714, + "id": 790, "name": "min_buy_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 678, - "src": "2035:14:5", + "referencedDeclaration": 754, + "src": "2035:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5663,12 +5663,12 @@ }, { "argumentTypes": null, - "id": 715, + "id": 791, "name": "token_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 700, - "src": "2051:12:5", + "referencedDeclaration": 776, + "src": "2051:12:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5694,18 +5694,18 @@ "typeString": "uint256" } ], - "id": 710, + "id": 786, "name": "ethToToken", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 554, - "src": "1997:10:5", + "referencedDeclaration": 630, + "src": "1997:10:6", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 716, + "id": 792, "isConstant": false, "isLValue": false, "isPure": false, @@ -5713,36 +5713,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1997:67:5", + "src": "1997:67:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 717, + "id": 793, "nodeType": "EmitStatement", - "src": "1992:72:5" + "src": "1992:72:6" } ] }, "documentation": null, - "id": 719, + "id": 795, "implemented": true, "kind": "function", "modifiers": [], "name": "tradeEthToToken", "nodeType": "FunctionDefinition", "parameters": { - "id": 683, + "id": 759, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 676, + "id": 752, "name": "uniSwapExchangeAddr", "nodeType": "VariableDeclaration", - "scope": 719, - "src": "1541:27:5", + "scope": 795, + "src": "1541:27:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5750,10 +5750,10 @@ "typeString": "address" }, "typeName": { - "id": 675, + "id": 751, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1541:7:5", + "src": "1541:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -5765,11 +5765,11 @@ }, { "constant": false, - "id": 678, + "id": 754, "name": "min_buy_tokens", "nodeType": "VariableDeclaration", - "scope": 719, - "src": "1574:22:5", + "scope": 795, + "src": "1574:22:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5777,10 +5777,10 @@ "typeString": "uint256" }, "typeName": { - "id": 677, + "id": 753, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1574:7:5", + "src": "1574:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5791,11 +5791,11 @@ }, { "constant": false, - "id": 680, + "id": 756, "name": "buy_deadline", "nodeType": "VariableDeclaration", - "scope": 719, - "src": "1602:20:5", + "scope": 795, + "src": "1602:20:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5803,10 +5803,10 @@ "typeString": "uint256" }, "typeName": { - "id": 679, + "id": 755, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1602:7:5", + "src": "1602:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5817,11 +5817,11 @@ }, { "constant": false, - "id": 682, + "id": 758, "name": "buy_eth_value", "nodeType": "VariableDeclaration", - "scope": 719, - "src": "1628:21:5", + "scope": 795, + "src": "1628:21:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5829,10 +5829,10 @@ "typeString": "uint256" }, "typeName": { - "id": 681, + "id": 757, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1628:7:5", + "src": "1628:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5842,53 +5842,53 @@ "visibility": "internal" } ], - "src": "1535:115:5" + "src": "1535:115:6" }, "returnParameters": { - "id": 684, + "id": 760, "nodeType": "ParameterList", "parameters": [], - "src": "1670:0:5" + "src": "1670:0:6" }, - "scope": 768, - "src": "1511:558:5", + "scope": 844, + "src": "1511:558:6", "stateMutability": "payable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 755, + "id": 831, "nodeType": "Block", - "src": "2227:329:5", + "src": "2227:329:6", "statements": [ { "assignments": [ - 731 + 807 ], "declarations": [ { "constant": false, - "id": 731, + "id": 807, "name": "uniSwapExchange", "nodeType": "VariableDeclaration", - "scope": 755, - "src": "2268:31:5", + "scope": 831, + "src": "2268:31:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" }, "typeName": { "contractScope": null, - "id": 730, + "id": 806, "name": "UniswapExchange", "nodeType": "UserDefinedTypeName", - "referencedDeclaration": 844, - "src": "2268:15:5", + "referencedDeclaration": 920, + "src": "2268:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, @@ -5896,18 +5896,18 @@ "visibility": "internal" } ], - "id": 735, + "id": 811, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 733, + "id": 809, "name": "uniSwapExchangeAddr", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 721, - "src": "2318:19:5", + "referencedDeclaration": 797, + "src": "2318:19:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" @@ -5921,18 +5921,18 @@ "typeString": "address" } ], - "id": 732, + "id": 808, "name": "UniswapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 844, - "src": "2302:15:5", + "referencedDeclaration": 920, + "src": "2302:15:6", "typeDescriptions": { - "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$844_$", + "typeIdentifier": "t_type$_t_contract$_UniswapExchange_$920_$", "typeString": "type(contract UniswapExchange)" } }, - "id": 734, + "id": 810, "isConstant": false, "isLValue": false, "isPure": false, @@ -5940,27 +5940,27 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2302:36:5", + "src": "2302:36:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, "nodeType": "VariableDeclarationStatement", - "src": "2268:70:5" + "src": "2268:70:6" }, { "assignments": [ - 737 + 813 ], "declarations": [ { "constant": false, - "id": 737, + "id": 813, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 755, - "src": "2347:19:5", + "scope": 831, + "src": "2347:19:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -5968,10 +5968,10 @@ "typeString": "uint256" }, "typeName": { - "id": 736, + "id": 812, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2347:7:5", + "src": "2347:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -5981,18 +5981,18 @@ "visibility": "internal" } ], - "id": 746, + "id": 822, "initialValue": { "argumentTypes": null, "arguments": [ { "argumentTypes": null, - "id": 740, + "id": 816, "name": "sell_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 727, - "src": "2410:14:5", + "referencedDeclaration": 803, + "src": "2410:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6000,12 +6000,12 @@ }, { "argumentTypes": null, - "id": 741, + "id": 817, "name": "max_sell_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 723, - "src": "2426:15:5", + "referencedDeclaration": 799, + "src": "2426:15:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6013,12 +6013,12 @@ }, { "argumentTypes": null, - "id": 742, + "id": 818, "name": "sell_deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 725, - "src": "2443:13:5", + "referencedDeclaration": 801, + "src": "2443:13:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6028,18 +6028,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 743, + "id": 819, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2458:3:5", + "referencedDeclaration": 12128, + "src": "2458:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 744, + "id": 820, "isConstant": false, "isLValue": false, "isPure": false, @@ -6047,7 +6047,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2458:10:5", + "src": "2458:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -6075,32 +6075,32 @@ ], "expression": { "argumentTypes": null, - "id": 738, + "id": 814, "name": "uniSwapExchange", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 731, - "src": "2369:15:5", + "referencedDeclaration": 807, + "src": "2369:15:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_UniswapExchange_$844", + "typeIdentifier": "t_contract$_UniswapExchange_$920", "typeString": "contract UniswapExchange" } }, - "id": 739, + "id": 815, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "memberName": "tokenToEthTransferOutput", "nodeType": "MemberAccess", - "referencedDeclaration": 839, - "src": "2369:40:5", + "referencedDeclaration": 915, + "src": "2369:40:6", "typeDescriptions": { "typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_uint256_$_t_address_payable_$returns$_t_uint256_$", "typeString": "function (uint256,uint256,uint256,address payable) external returns (uint256)" } }, - "id": 745, + "id": 821, "isConstant": false, "isLValue": false, "isPure": false, @@ -6108,14 +6108,14 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2369:100:5", + "src": "2369:100:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2347:122:5" + "src": "2347:122:6" }, { "eventCall": { @@ -6125,18 +6125,18 @@ "argumentTypes": null, "expression": { "argumentTypes": null, - "id": 748, + "id": 824, "name": "msg", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1458, - "src": "2494:3:5", + "referencedDeclaration": 12128, + "src": "2494:3:6", "typeDescriptions": { "typeIdentifier": "t_magic_message", "typeString": "msg" } }, - "id": 749, + "id": 825, "isConstant": false, "isLValue": false, "isPure": false, @@ -6144,7 +6144,7 @@ "memberName": "sender", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2494:10:5", + "src": "2494:10:6", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" @@ -6152,12 +6152,12 @@ }, { "argumentTypes": null, - "id": 750, + "id": 826, "name": "sell_eth_value", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 727, - "src": "2506:14:5", + "referencedDeclaration": 803, + "src": "2506:14:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6165,12 +6165,12 @@ }, { "argumentTypes": null, - "id": 751, + "id": 827, "name": "max_sell_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 723, - "src": "2522:15:5", + "referencedDeclaration": 799, + "src": "2522:15:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6178,12 +6178,12 @@ }, { "argumentTypes": null, - "id": 752, + "id": 828, "name": "tokens_sold", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 737, - "src": "2539:11:5", + "referencedDeclaration": 813, + "src": "2539:11:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6209,18 +6209,18 @@ "typeString": "uint256" } ], - "id": 747, + "id": 823, "name": "tokenToEth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 564, - "src": "2483:10:5", + "referencedDeclaration": 640, + "src": "2483:10:6", "typeDescriptions": { "typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$_t_uint256_$returns$__$", "typeString": "function (address,uint256,uint256,uint256)" } }, - "id": 753, + "id": 829, "isConstant": false, "isLValue": false, "isPure": false, @@ -6228,36 +6228,36 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2483:68:5", + "src": "2483:68:6", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 754, + "id": 830, "nodeType": "EmitStatement", - "src": "2478:73:5" + "src": "2478:73:6" } ] }, "documentation": null, - "id": 756, + "id": 832, "implemented": true, "kind": "function", "modifiers": [], "name": "tradeTokenToEth", "nodeType": "FunctionDefinition", "parameters": { - "id": 728, + "id": 804, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 721, + "id": 797, "name": "uniSwapExchangeAddr", "nodeType": "VariableDeclaration", - "scope": 756, - "src": "2103:27:5", + "scope": 832, + "src": "2103:27:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6265,10 +6265,10 @@ "typeString": "address" }, "typeName": { - "id": 720, + "id": 796, "name": "address", "nodeType": "ElementaryTypeName", - "src": "2103:7:5", + "src": "2103:7:6", "stateMutability": "nonpayable", "typeDescriptions": { "typeIdentifier": "t_address", @@ -6280,11 +6280,11 @@ }, { "constant": false, - "id": 723, + "id": 799, "name": "max_sell_tokens", "nodeType": "VariableDeclaration", - "scope": 756, - "src": "2136:23:5", + "scope": 832, + "src": "2136:23:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6292,10 +6292,10 @@ "typeString": "uint256" }, "typeName": { - "id": 722, + "id": 798, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2136:7:5", + "src": "2136:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6306,11 +6306,11 @@ }, { "constant": false, - "id": 725, + "id": 801, "name": "sell_deadline", "nodeType": "VariableDeclaration", - "scope": 756, - "src": "2165:21:5", + "scope": 832, + "src": "2165:21:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6318,10 +6318,10 @@ "typeString": "uint256" }, "typeName": { - "id": 724, + "id": 800, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2165:7:5", + "src": "2165:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6332,11 +6332,11 @@ }, { "constant": false, - "id": 727, + "id": 803, "name": "sell_eth_value", "nodeType": "VariableDeclaration", - "scope": 756, - "src": "2192:22:5", + "scope": 832, + "src": "2192:22:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6344,10 +6344,10 @@ "typeString": "uint256" }, "typeName": { - "id": 726, + "id": 802, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2192:7:5", + "src": "2192:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6357,25 +6357,25 @@ "visibility": "internal" } ], - "src": "2097:118:5" + "src": "2097:118:6" }, "returnParameters": { - "id": 729, + "id": 805, "nodeType": "ParameterList", "parameters": [], - "src": "2227:0:5" + "src": "2227:0:6" }, - "scope": 768, - "src": "2073:483:5", + "scope": 844, + "src": "2073:483:6", "stateMutability": "nonpayable", "superFunction": null, "visibility": "public" }, { "body": { - "id": 766, + "id": 842, "nodeType": "Block", - "src": "2612:39:5", + "src": "2612:39:6", "statements": [ { "expression": { @@ -6385,14 +6385,14 @@ "arguments": [ { "argumentTypes": null, - "id": 762, + "id": 838, "name": "this", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 1490, - "src": "2633:4:5", + "referencedDeclaration": 12192, + "src": "2633:4:6", "typeDescriptions": { - "typeIdentifier": "t_contract$_RinkebyArbContract_$768", + "typeIdentifier": "t_contract$_RinkebyArbContract_$844", "typeString": "contract RinkebyArbContract" } } @@ -6400,24 +6400,24 @@ "expression": { "argumentTypes": [ { - "typeIdentifier": "t_contract$_RinkebyArbContract_$768", + "typeIdentifier": "t_contract$_RinkebyArbContract_$844", "typeString": "contract RinkebyArbContract" } ], - "id": 761, + "id": 837, "isConstant": false, "isLValue": false, "isPure": true, "lValueRequested": false, "nodeType": "ElementaryTypeNameExpression", - "src": "2625:7:5", + "src": "2625:7:6", "typeDescriptions": { "typeIdentifier": "t_type$_t_address_$", "typeString": "type(address)" }, "typeName": "address" }, - "id": 763, + "id": 839, "isConstant": false, "isLValue": false, "isPure": false, @@ -6425,13 +6425,13 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2625:13:5", + "src": "2625:13:6", "typeDescriptions": { "typeIdentifier": "t_address", "typeString": "address" } }, - "id": 764, + "id": 840, "isConstant": false, "isLValue": false, "isPure": false, @@ -6439,43 +6439,43 @@ "memberName": "balance", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "2625:21:5", + "src": "2625:21:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 760, - "id": 765, + "functionReturnParameters": 836, + "id": 841, "nodeType": "Return", - "src": "2618:28:5" + "src": "2618:28:6" } ] }, "documentation": null, - "id": 767, + "id": 843, "implemented": true, "kind": "function", "modifiers": [], "name": "getBalance", "nodeType": "FunctionDefinition", "parameters": { - "id": 757, + "id": 833, "nodeType": "ParameterList", "parameters": [], - "src": "2579:2:5" + "src": "2579:2:6" }, "returnParameters": { - "id": 760, + "id": 836, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 759, + "id": 835, "name": "", "nodeType": "VariableDeclaration", - "scope": 767, - "src": "2603:7:5", + "scope": 843, + "src": "2603:7:6", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -6483,10 +6483,10 @@ "typeString": "uint256" }, "typeName": { - "id": 758, + "id": 834, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2603:7:5", + "src": "2603:7:6", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -6496,20 +6496,20 @@ "visibility": "internal" } ], - "src": "2602:9:5" + "src": "2602:9:6" }, - "scope": 768, - "src": "2560:91:5", + "scope": 844, + "src": "2560:91:6", "stateMutability": "view", "superFunction": null, "visibility": "public" } ], - "scope": 769, - "src": "114:2539:5" + "scope": 845, + "src": "114:2539:6" } ], - "src": "0:2654:5" + "src": "0:2654:6" }, "compiler": { "name": "solc", @@ -6517,7 +6517,7 @@ }, "networks": {}, "schemaVersion": "3.0.16", - "updatedAt": "2019-11-04T18:56:07.480Z", + "updatedAt": "2019-11-07T15:21:05.367Z", "devdoc": { "methods": {} }, diff --git a/client/src/contracts/SafeERC20.json b/client/src/contracts/SafeERC20.json new file mode 100644 index 0000000..f4e06b5 --- /dev/null +++ b/client/src/contracts/SafeERC20.json @@ -0,0 +1,6398 @@ +{ + "contractName": "SafeERC20", + "abi": [], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"details\":\"Wrappers around ERC20 operations that throw on failure (when the token contract returns false). Tokens that return no value (and instead revert or throw on failure) are also supported, non-reverting calls are assumed to be successful. To use this library you can add a `using SafeERC20 for ERC20;` statement to your contract, which allows you to call the safe operations as `token.safeTransfer(...)`, etc.\",\"methods\":{},\"title\":\"SafeERC20\"},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":\"SafeERC20\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]}},\"version\":1}", + "bytecode": "0x604c6023600b82828239805160001a607314601657fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea165627a7a7230582060a81f0b78b7c40293eaa18d960ab0c84d580f869d43237e839a2b12cd059d8b0029", + "deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600080fdfea165627a7a7230582060a81f0b78b7c40293eaa18d960ab0c84d580f869d43237e839a2b12cd059d8b0029", + "sourceMap": "574:3189:61:-;;132:2:-1;166:7;155:9;146:7;137:37;255:7;249:14;246:1;241:23;235:4;232:33;222:2;;269:9;222:2;293:9;290:1;283:20;323:4;314:7;306:22;347:7;338;331:24", + "deployedSourceMap": "574:3189:61:-;;;;;;;;", + "source": "pragma solidity ^0.5.0;\n\nimport \"./IERC20.sol\";\nimport \"../../math/SafeMath.sol\";\nimport \"../../utils/Address.sol\";\n\n/**\n * @title SafeERC20\n * @dev Wrappers around ERC20 operations that throw on failure (when the token\n * contract returns false). Tokens that return no value (and instead revert or\n * throw on failure) are also supported, non-reverting calls are assumed to be\n * successful.\n * To use this library you can add a `using SafeERC20 for ERC20;` statement to your contract,\n * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.\n */\nlibrary SafeERC20 {\n using SafeMath for uint256;\n using Address for address;\n\n function safeTransfer(IERC20 token, address to, uint256 value) internal {\n callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));\n }\n\n function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal {\n callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));\n }\n\n function safeApprove(IERC20 token, address spender, uint256 value) internal {\n // safeApprove should only be called when setting an initial allowance,\n // or when resetting it to zero. To increase and decrease it, use\n // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'\n // solhint-disable-next-line max-line-length\n require((value == 0) || (token.allowance(address(this), spender) == 0),\n \"SafeERC20: approve from non-zero to non-zero allowance\"\n );\n callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));\n }\n\n function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal {\n uint256 newAllowance = token.allowance(address(this), spender).add(value);\n callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));\n }\n\n function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal {\n uint256 newAllowance = token.allowance(address(this), spender).sub(value, \"SafeERC20: decreased allowance below zero\");\n callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));\n }\n\n /**\n * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement\n * on the return value: the return value is optional (but if data is returned, it must not be false).\n * @param token The token targeted by the call.\n * @param data The call data (encoded using abi.encode or one of its variants).\n */\n function callOptionalReturn(IERC20 token, bytes memory data) private {\n // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since\n // we're implementing it ourselves.\n\n // A Solidity high level call has three parts:\n // 1. The target address is checked to verify it contains contract code\n // 2. The call itself is made, and success asserted\n // 3. The return value is decoded, which in turn checks the size of the returned data.\n // solhint-disable-next-line max-line-length\n require(address(token).isContract(), \"SafeERC20: call to non-contract\");\n\n // solhint-disable-next-line avoid-low-level-calls\n (bool success, bytes memory returndata) = address(token).call(data);\n require(success, \"SafeERC20: low-level call failed\");\n\n if (returndata.length > 0) { // Return data is optional\n // solhint-disable-next-line max-line-length\n require(abi.decode(returndata, (bool)), \"SafeERC20: ERC20 operation did not succeed\");\n }\n }\n}\n", + "sourcePath": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "ast": { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "exportedSymbols": { + "SafeERC20": [ + 12006 + ] + }, + "id": 12007, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 11788, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:61" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "./IERC20.sol", + "id": 11789, + "nodeType": "ImportDirective", + "scope": 12007, + "sourceUnit": 11787, + "src": "25:22:61", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "../../math/SafeMath.sol", + "id": 11790, + "nodeType": "ImportDirective", + "scope": 12007, + "sourceUnit": 11141, + "src": "48:33:61", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "file": "../../utils/Address.sol", + "id": 11791, + "nodeType": "ImportDirective", + "scope": 12007, + "sourceUnit": 12082, + "src": "82:33:61", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "library", + "documentation": "@title SafeERC20\n@dev Wrappers around ERC20 operations that throw on failure (when the token\ncontract returns false). Tokens that return no value (and instead revert or\nthrow on failure) are also supported, non-reverting calls are assumed to be\nsuccessful.\nTo use this library you can add a `using SafeERC20 for ERC20;` statement to your contract,\nwhich allows you to call the safe operations as `token.safeTransfer(...)`, etc.", + "fullyImplemented": true, + "id": 12006, + "linearizedBaseContracts": [ + 12006 + ], + "name": "SafeERC20", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 11794, + "libraryName": { + "contractScope": null, + "id": 11792, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "604:8:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "598:27:61", + "typeName": { + "id": 11793, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "617:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 11797, + "libraryName": { + "contractScope": null, + "id": 11795, + "name": "Address", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12081, + "src": "636:7:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + }, + "nodeType": "UsingForDirective", + "src": "630:26:61", + "typeName": { + "id": 11796, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "648:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + }, + { + "body": { + "id": 11818, + "nodeType": "Block", + "src": "734:102:61", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11807, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11799, + "src": "763:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11810, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11799, + "src": "793:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11811, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": 11740, + "src": "793:14:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,uint256) external returns (bool)" + } + }, + "id": 11812, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "selector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "793:23:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + } + }, + { + "argumentTypes": null, + "id": 11813, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11801, + "src": "818:2:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11814, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11803, + "src": "822:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 11808, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "770:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11809, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSelector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "770:22:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (bytes4) pure returns (bytes memory)" + } + }, + "id": 11815, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "770:58:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 11806, + "name": "callOptionalReturn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12005, + "src": "744:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_bytes_memory_ptr_$returns$__$", + "typeString": "function (contract IERC20,bytes memory)" + } + }, + "id": 11816, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "744:85:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11817, + "nodeType": "ExpressionStatement", + "src": "744:85:61" + } + ] + }, + "documentation": null, + "id": 11819, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "safeTransfer", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11804, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11799, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 11819, + "src": "684:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11798, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "684:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11801, + "name": "to", + "nodeType": "VariableDeclaration", + "scope": 11819, + "src": "698:10:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11800, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "698:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11803, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 11819, + "src": "710:13:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11802, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "710:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "683:41:61" + }, + "returnParameters": { + "id": 11805, + "nodeType": "ParameterList", + "parameters": [], + "src": "734:0:61" + }, + "scope": 12006, + "src": "662:174:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11843, + "nodeType": "Block", + "src": "932:112:61", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11831, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11821, + "src": "961:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11834, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11821, + "src": "991:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11835, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferFrom", + "nodeType": "MemberAccess", + "referencedDeclaration": 11769, + "src": "991:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,address,uint256) external returns (bool)" + } + }, + "id": 11836, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "selector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "991:27:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + } + }, + { + "argumentTypes": null, + "id": 11837, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11823, + "src": "1020:4:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11838, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11825, + "src": "1026:2:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11839, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11827, + "src": "1030:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 11832, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "968:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11833, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSelector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "968:22:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (bytes4) pure returns (bytes memory)" + } + }, + "id": 11840, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "968:68:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 11830, + "name": "callOptionalReturn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12005, + "src": "942:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_bytes_memory_ptr_$returns$__$", + "typeString": "function (contract IERC20,bytes memory)" + } + }, + "id": 11841, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "942:95:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11842, + "nodeType": "ExpressionStatement", + "src": "942:95:61" + } + ] + }, + "documentation": null, + "id": 11844, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "safeTransferFrom", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11828, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11821, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 11844, + "src": "868:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11820, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "868:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11823, + "name": "from", + "nodeType": "VariableDeclaration", + "scope": 11844, + "src": "882:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11822, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "882:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11825, + "name": "to", + "nodeType": "VariableDeclaration", + "scope": 11844, + "src": "896:10:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11824, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "896:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11827, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 11844, + "src": "908:13:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11826, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "908:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "867:55:61" + }, + "returnParameters": { + "id": 11829, + "nodeType": "ParameterList", + "parameters": [], + "src": "932:0:61" + }, + "scope": 12006, + "src": "842:202:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11884, + "nodeType": "Block", + "src": "1126:536:61", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 11868, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 11856, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 11854, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11850, + "src": "1415:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 11855, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1424:1:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "1415:10:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "id": 11857, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "1414:12:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 11866, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11861, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12162, + "src": "1455:4:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + ], + "id": 11860, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1447:7:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11862, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1447:13:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11863, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11848, + "src": "1462:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 11858, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11846, + "src": "1431:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11859, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "allowance", + "nodeType": "MemberAccess", + "referencedDeclaration": 11749, + "src": "1431:15:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 11864, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1431:39:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 11865, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1474:1:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "1431:44:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "id": 11867, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "1430:46:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "1414:62:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f20746f206e6f6e2d7a65726f20616c6c6f77616e6365", + "id": 11869, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1490:56:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ef945ddb1bfdc0da870feb4560d868b047642b4ac7f2fb7f8b7c51cb4a411e25", + "typeString": "literal_string \"SafeERC20: approve from non-zero to non-zero allowance\"" + }, + "value": "SafeERC20: approve from non-zero to non-zero allowance" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_ef945ddb1bfdc0da870feb4560d868b047642b4ac7f2fb7f8b7c51cb4a411e25", + "typeString": "literal_string \"SafeERC20: approve from non-zero to non-zero allowance\"" + } + ], + "id": 11853, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1406:7:61", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11870, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1406:150:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11871, + "nodeType": "ExpressionStatement", + "src": "1406:150:61" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11873, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11846, + "src": "1585:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11876, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11846, + "src": "1615:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11877, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "approve", + "nodeType": "MemberAccess", + "referencedDeclaration": 11758, + "src": "1615:13:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,uint256) external returns (bool)" + } + }, + "id": 11878, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "selector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1615:22:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + } + }, + { + "argumentTypes": null, + "id": 11879, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11848, + "src": "1639:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11880, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11850, + "src": "1648:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 11874, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "1592:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11875, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSelector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1592:22:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (bytes4) pure returns (bytes memory)" + } + }, + "id": 11881, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1592:62:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 11872, + "name": "callOptionalReturn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12005, + "src": "1566:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_bytes_memory_ptr_$returns$__$", + "typeString": "function (contract IERC20,bytes memory)" + } + }, + "id": 11882, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1566:89:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11883, + "nodeType": "ExpressionStatement", + "src": "1566:89:61" + } + ] + }, + "documentation": null, + "id": 11885, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "safeApprove", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11851, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11846, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 11885, + "src": "1071:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11845, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "1071:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11848, + "name": "spender", + "nodeType": "VariableDeclaration", + "scope": 11885, + "src": "1085:15:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11847, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1085:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11850, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 11885, + "src": "1102:13:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11849, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1102:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1070:46:61" + }, + "returnParameters": { + "id": 11852, + "nodeType": "ParameterList", + "parameters": [], + "src": "1126:0:61" + }, + "scope": 12006, + "src": "1050:612:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11919, + "nodeType": "Block", + "src": "1754:196:61", + "statements": [ + { + "assignments": [ + 11895 + ], + "declarations": [ + { + "constant": false, + "id": 11895, + "name": "newAllowance", + "nodeType": "VariableDeclaration", + "scope": 11919, + "src": "1764:20:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11894, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1764:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 11906, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11904, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11891, + "src": "1831:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11899, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12162, + "src": "1811:4:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + ], + "id": 11898, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1803:7:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11900, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1803:13:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11901, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11889, + "src": "1818:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 11896, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11887, + "src": "1787:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11897, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "allowance", + "nodeType": "MemberAccess", + "referencedDeclaration": 11749, + "src": "1787:15:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 11902, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1787:39:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 11903, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1787:43:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 11905, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1787:50:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1764:73:61" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11908, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11887, + "src": "1866:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11911, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11887, + "src": "1896:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11912, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "approve", + "nodeType": "MemberAccess", + "referencedDeclaration": 11758, + "src": "1896:13:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,uint256) external returns (bool)" + } + }, + "id": 11913, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "selector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1896:22:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + } + }, + { + "argumentTypes": null, + "id": 11914, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11889, + "src": "1920:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11915, + "name": "newAllowance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11895, + "src": "1929:12:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 11909, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "1873:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11910, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSelector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1873:22:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (bytes4) pure returns (bytes memory)" + } + }, + "id": 11916, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1873:69:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 11907, + "name": "callOptionalReturn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12005, + "src": "1847:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_bytes_memory_ptr_$returns$__$", + "typeString": "function (contract IERC20,bytes memory)" + } + }, + "id": 11917, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1847:96:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11918, + "nodeType": "ExpressionStatement", + "src": "1847:96:61" + } + ] + }, + "documentation": null, + "id": 11920, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "safeIncreaseAllowance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11892, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11887, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 11920, + "src": "1699:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11886, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "1699:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11889, + "name": "spender", + "nodeType": "VariableDeclaration", + "scope": 11920, + "src": "1713:15:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11888, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1713:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11891, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 11920, + "src": "1730:13:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11890, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1730:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1698:46:61" + }, + "returnParameters": { + "id": 11893, + "nodeType": "ParameterList", + "parameters": [], + "src": "1754:0:61" + }, + "scope": 12006, + "src": "1668:282:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11955, + "nodeType": "Block", + "src": "2042:241:61", + "statements": [ + { + "assignments": [ + 11930 + ], + "declarations": [ + { + "constant": false, + "id": 11930, + "name": "newAllowance", + "nodeType": "VariableDeclaration", + "scope": 11955, + "src": "2052:20:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11929, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2052:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 11942, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11939, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11926, + "src": "2119:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "5361666545524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726f", + "id": 11940, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2126:43:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_2c3af60974a758b7e72e108c9bf0943ecc9e4f2e8af4695da5f52fbf57a63d3a", + "typeString": "literal_string \"SafeERC20: decreased allowance below zero\"" + }, + "value": "SafeERC20: decreased allowance below zero" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_2c3af60974a758b7e72e108c9bf0943ecc9e4f2e8af4695da5f52fbf57a63d3a", + "typeString": "literal_string \"SafeERC20: decreased allowance below zero\"" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11934, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12162, + "src": "2099:4:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + ], + "id": 11933, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2091:7:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11935, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2091:13:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11936, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11924, + "src": "2106:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 11931, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11922, + "src": "2075:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11932, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "allowance", + "nodeType": "MemberAccess", + "referencedDeclaration": 11749, + "src": "2075:15:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 11937, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2075:39:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 11938, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 11023, + "src": "2075:43:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" + } + }, + "id": 11941, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2075:95:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2052:118:61" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11944, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11922, + "src": "2199:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11947, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11922, + "src": "2229:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11948, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "approve", + "nodeType": "MemberAccess", + "referencedDeclaration": 11758, + "src": "2229:13:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,uint256) external returns (bool)" + } + }, + "id": 11949, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "selector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2229:22:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + } + }, + { + "argumentTypes": null, + "id": 11950, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11924, + "src": "2253:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11951, + "name": "newAllowance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11930, + "src": "2262:12:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 11945, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "2206:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11946, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSelector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2206:22:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (bytes4) pure returns (bytes memory)" + } + }, + "id": 11952, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2206:69:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 11943, + "name": "callOptionalReturn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12005, + "src": "2180:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_bytes_memory_ptr_$returns$__$", + "typeString": "function (contract IERC20,bytes memory)" + } + }, + "id": 11953, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2180:96:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11954, + "nodeType": "ExpressionStatement", + "src": "2180:96:61" + } + ] + }, + "documentation": null, + "id": 11956, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "safeDecreaseAllowance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11927, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11922, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 11956, + "src": "1987:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11921, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "1987:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11924, + "name": "spender", + "nodeType": "VariableDeclaration", + "scope": 11956, + "src": "2001:15:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11923, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2001:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11926, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 11956, + "src": "2018:13:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11925, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2018:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1986:46:61" + }, + "returnParameters": { + "id": 11928, + "nodeType": "ParameterList", + "parameters": [], + "src": "2042:0:61" + }, + "scope": 12006, + "src": "1956:327:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 12004, + "nodeType": "Block", + "src": "2735:1026:61", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11965, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11958, + "src": "3269:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + ], + "id": 11964, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3261:7:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11966, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3261:14:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 11967, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isContract", + "nodeType": "MemberAccess", + "referencedDeclaration": 12033, + "src": "3261:25:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$bound_to$_t_address_$", + "typeString": "function (address) view returns (bool)" + } + }, + "id": 11968, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3261:27:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5361666545524332303a2063616c6c20746f206e6f6e2d636f6e7472616374", + "id": 11969, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3290:33:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_f6ce7bfd656f35145dec774d6f7e67f4cba158373d2dd7a0f8273e232f86148d", + "typeString": "literal_string \"SafeERC20: call to non-contract\"" + }, + "value": "SafeERC20: call to non-contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_f6ce7bfd656f35145dec774d6f7e67f4cba158373d2dd7a0f8273e232f86148d", + "typeString": "literal_string \"SafeERC20: call to non-contract\"" + } + ], + "id": 11963, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "3253:7:61", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11970, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3253:71:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11971, + "nodeType": "ExpressionStatement", + "src": "3253:71:61" + }, + { + "assignments": [ + 11973, + 11975 + ], + "declarations": [ + { + "constant": false, + "id": 11973, + "name": "success", + "nodeType": "VariableDeclaration", + "scope": 12004, + "src": "3395:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 11972, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "3395:4:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11975, + "name": "returndata", + "nodeType": "VariableDeclaration", + "scope": 12004, + "src": "3409:23:61", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 11974, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "3409:5:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 11982, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11980, + "name": "data", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11960, + "src": "3456:4:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11977, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11958, + "src": "3444:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + ], + "id": 11976, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3436:7:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11978, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3436:14:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 11979, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "call", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3436:19:61", + "typeDescriptions": { + "typeIdentifier": "t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "function (bytes memory) payable returns (bool,bytes memory)" + } + }, + "id": 11981, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3436:25:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "tuple(bool,bytes memory)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3394:67:61" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11984, + "name": "success", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11973, + "src": "3479:7:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564", + "id": 11985, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3488:34:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_47fb62c2c272651d2f0f342bac006756b8ba07f21cc5cb87e0fbb9d50c0c585b", + "typeString": "literal_string \"SafeERC20: low-level call failed\"" + }, + "value": "SafeERC20: low-level call failed" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_47fb62c2c272651d2f0f342bac006756b8ba07f21cc5cb87e0fbb9d50c0c585b", + "typeString": "literal_string \"SafeERC20: low-level call failed\"" + } + ], + "id": 11983, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "3471:7:61", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11986, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3471:52:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11987, + "nodeType": "ExpressionStatement", + "src": "3471:52:61" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 11991, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11988, + "name": "returndata", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11975, + "src": "3538:10:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + }, + "id": 11989, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "length", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3538:17:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 11990, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3558:1:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3538:21:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 12003, + "nodeType": "IfStatement", + "src": "3534:221:61", + "trueBody": { + "id": 12002, + "nodeType": "Block", + "src": "3561:194:61", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11995, + "name": "returndata", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11975, + "src": "3678:10:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + }, + { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 11996, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3691:4:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_bool_$", + "typeString": "type(bool)" + }, + "typeName": "bool" + } + ], + "id": 11997, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "3690:6:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_bool_$", + "typeString": "type(bool)" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + }, + { + "typeIdentifier": "t_type$_t_bool_$", + "typeString": "type(bool)" + } + ], + "expression": { + "argumentTypes": null, + "id": 11993, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "3667:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11994, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "decode", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3667:10:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abidecode_pure$__$returns$__$", + "typeString": "function () pure" + } + }, + "id": 11998, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3667:30:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564", + "id": 11999, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3699:44:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e11ad79d1e4a7f2e5f376964cb99e8e8f7904e3fc16a109f7a7ecb9aa7956dcd", + "typeString": "literal_string \"SafeERC20: ERC20 operation did not succeed\"" + }, + "value": "SafeERC20: ERC20 operation did not succeed" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_e11ad79d1e4a7f2e5f376964cb99e8e8f7904e3fc16a109f7a7ecb9aa7956dcd", + "typeString": "literal_string \"SafeERC20: ERC20 operation did not succeed\"" + } + ], + "id": 11992, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "3659:7:61", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 12000, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3659:85:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 12001, + "nodeType": "ExpressionStatement", + "src": "3659:85:61" + } + ] + } + } + ] + }, + "documentation": "@dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement\non the return value: the return value is optional (but if data is returned, it must not be false).\n@param token The token targeted by the call.\n@param data The call data (encoded using abi.encode or one of its variants).", + "id": 12005, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "callOptionalReturn", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11961, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11958, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 12005, + "src": "2694:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11957, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "2694:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11960, + "name": "data", + "nodeType": "VariableDeclaration", + "scope": 12005, + "src": "2708:17:61", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 11959, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "2708:5:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2693:33:61" + }, + "returnParameters": { + "id": 11962, + "nodeType": "ParameterList", + "parameters": [], + "src": "2735:0:61" + }, + "scope": 12006, + "src": "2666:1095:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "private" + } + ], + "scope": 12007, + "src": "574:3189:61" + } + ], + "src": "0:3764:61" + }, + "legacyAST": { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol", + "exportedSymbols": { + "SafeERC20": [ + 12006 + ] + }, + "id": 12007, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 11788, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:61" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "./IERC20.sol", + "id": 11789, + "nodeType": "ImportDirective", + "scope": 12007, + "sourceUnit": 11787, + "src": "25:22:61", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "../../math/SafeMath.sol", + "id": 11790, + "nodeType": "ImportDirective", + "scope": 12007, + "sourceUnit": 11141, + "src": "48:33:61", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "file": "../../utils/Address.sol", + "id": 11791, + "nodeType": "ImportDirective", + "scope": 12007, + "sourceUnit": 12082, + "src": "82:33:61", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "library", + "documentation": "@title SafeERC20\n@dev Wrappers around ERC20 operations that throw on failure (when the token\ncontract returns false). Tokens that return no value (and instead revert or\nthrow on failure) are also supported, non-reverting calls are assumed to be\nsuccessful.\nTo use this library you can add a `using SafeERC20 for ERC20;` statement to your contract,\nwhich allows you to call the safe operations as `token.safeTransfer(...)`, etc.", + "fullyImplemented": true, + "id": 12006, + "linearizedBaseContracts": [ + 12006 + ], + "name": "SafeERC20", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 11794, + "libraryName": { + "contractScope": null, + "id": 11792, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "604:8:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "598:27:61", + "typeName": { + "id": 11793, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "617:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "id": 11797, + "libraryName": { + "contractScope": null, + "id": 11795, + "name": "Address", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12081, + "src": "636:7:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + }, + "nodeType": "UsingForDirective", + "src": "630:26:61", + "typeName": { + "id": 11796, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "648:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + }, + { + "body": { + "id": 11818, + "nodeType": "Block", + "src": "734:102:61", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11807, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11799, + "src": "763:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11810, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11799, + "src": "793:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11811, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transfer", + "nodeType": "MemberAccess", + "referencedDeclaration": 11740, + "src": "793:14:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,uint256) external returns (bool)" + } + }, + "id": 11812, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "selector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "793:23:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + } + }, + { + "argumentTypes": null, + "id": 11813, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11801, + "src": "818:2:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11814, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11803, + "src": "822:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 11808, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "770:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11809, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSelector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "770:22:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (bytes4) pure returns (bytes memory)" + } + }, + "id": 11815, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "770:58:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 11806, + "name": "callOptionalReturn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12005, + "src": "744:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_bytes_memory_ptr_$returns$__$", + "typeString": "function (contract IERC20,bytes memory)" + } + }, + "id": 11816, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "744:85:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11817, + "nodeType": "ExpressionStatement", + "src": "744:85:61" + } + ] + }, + "documentation": null, + "id": 11819, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "safeTransfer", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11804, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11799, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 11819, + "src": "684:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11798, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "684:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11801, + "name": "to", + "nodeType": "VariableDeclaration", + "scope": 11819, + "src": "698:10:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11800, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "698:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11803, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 11819, + "src": "710:13:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11802, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "710:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "683:41:61" + }, + "returnParameters": { + "id": 11805, + "nodeType": "ParameterList", + "parameters": [], + "src": "734:0:61" + }, + "scope": 12006, + "src": "662:174:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11843, + "nodeType": "Block", + "src": "932:112:61", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11831, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11821, + "src": "961:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11834, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11821, + "src": "991:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11835, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "transferFrom", + "nodeType": "MemberAccess", + "referencedDeclaration": 11769, + "src": "991:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,address,uint256) external returns (bool)" + } + }, + "id": 11836, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "selector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "991:27:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + } + }, + { + "argumentTypes": null, + "id": 11837, + "name": "from", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11823, + "src": "1020:4:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11838, + "name": "to", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11825, + "src": "1026:2:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11839, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11827, + "src": "1030:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 11832, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "968:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11833, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSelector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "968:22:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (bytes4) pure returns (bytes memory)" + } + }, + "id": 11840, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "968:68:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 11830, + "name": "callOptionalReturn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12005, + "src": "942:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_bytes_memory_ptr_$returns$__$", + "typeString": "function (contract IERC20,bytes memory)" + } + }, + "id": 11841, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "942:95:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11842, + "nodeType": "ExpressionStatement", + "src": "942:95:61" + } + ] + }, + "documentation": null, + "id": 11844, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "safeTransferFrom", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11828, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11821, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 11844, + "src": "868:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11820, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "868:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11823, + "name": "from", + "nodeType": "VariableDeclaration", + "scope": 11844, + "src": "882:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11822, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "882:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11825, + "name": "to", + "nodeType": "VariableDeclaration", + "scope": 11844, + "src": "896:10:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11824, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "896:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11827, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 11844, + "src": "908:13:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11826, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "908:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "867:55:61" + }, + "returnParameters": { + "id": 11829, + "nodeType": "ParameterList", + "parameters": [], + "src": "932:0:61" + }, + "scope": 12006, + "src": "842:202:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11884, + "nodeType": "Block", + "src": "1126:536:61", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "id": 11868, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 11856, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 11854, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11850, + "src": "1415:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 11855, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1424:1:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "1415:10:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "id": 11857, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "1414:12:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "nodeType": "BinaryOperation", + "operator": "||", + "rightExpression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 11866, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11861, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12162, + "src": "1455:4:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + ], + "id": 11860, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1447:7:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11862, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1447:13:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11863, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11848, + "src": "1462:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 11858, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11846, + "src": "1431:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11859, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "allowance", + "nodeType": "MemberAccess", + "referencedDeclaration": 11749, + "src": "1431:15:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 11864, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1431:39:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "==", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 11865, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1474:1:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "1431:44:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + } + ], + "id": 11867, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "1430:46:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "src": "1414:62:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f20746f206e6f6e2d7a65726f20616c6c6f77616e6365", + "id": 11869, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1490:56:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_ef945ddb1bfdc0da870feb4560d868b047642b4ac7f2fb7f8b7c51cb4a411e25", + "typeString": "literal_string \"SafeERC20: approve from non-zero to non-zero allowance\"" + }, + "value": "SafeERC20: approve from non-zero to non-zero allowance" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_ef945ddb1bfdc0da870feb4560d868b047642b4ac7f2fb7f8b7c51cb4a411e25", + "typeString": "literal_string \"SafeERC20: approve from non-zero to non-zero allowance\"" + } + ], + "id": 11853, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "1406:7:61", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11870, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1406:150:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11871, + "nodeType": "ExpressionStatement", + "src": "1406:150:61" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11873, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11846, + "src": "1585:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11876, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11846, + "src": "1615:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11877, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "approve", + "nodeType": "MemberAccess", + "referencedDeclaration": 11758, + "src": "1615:13:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,uint256) external returns (bool)" + } + }, + "id": 11878, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "selector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1615:22:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + } + }, + { + "argumentTypes": null, + "id": 11879, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11848, + "src": "1639:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11880, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11850, + "src": "1648:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 11874, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "1592:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11875, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSelector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1592:22:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (bytes4) pure returns (bytes memory)" + } + }, + "id": 11881, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1592:62:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 11872, + "name": "callOptionalReturn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12005, + "src": "1566:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_bytes_memory_ptr_$returns$__$", + "typeString": "function (contract IERC20,bytes memory)" + } + }, + "id": 11882, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1566:89:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11883, + "nodeType": "ExpressionStatement", + "src": "1566:89:61" + } + ] + }, + "documentation": null, + "id": 11885, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "safeApprove", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11851, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11846, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 11885, + "src": "1071:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11845, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "1071:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11848, + "name": "spender", + "nodeType": "VariableDeclaration", + "scope": 11885, + "src": "1085:15:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11847, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1085:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11850, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 11885, + "src": "1102:13:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11849, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1102:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1070:46:61" + }, + "returnParameters": { + "id": 11852, + "nodeType": "ParameterList", + "parameters": [], + "src": "1126:0:61" + }, + "scope": 12006, + "src": "1050:612:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11919, + "nodeType": "Block", + "src": "1754:196:61", + "statements": [ + { + "assignments": [ + 11895 + ], + "declarations": [ + { + "constant": false, + "id": 11895, + "name": "newAllowance", + "nodeType": "VariableDeclaration", + "scope": 11919, + "src": "1764:20:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11894, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1764:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 11906, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11904, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11891, + "src": "1831:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11899, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12162, + "src": "1811:4:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + ], + "id": 11898, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "1803:7:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11900, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1803:13:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11901, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11889, + "src": "1818:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 11896, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11887, + "src": "1787:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11897, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "allowance", + "nodeType": "MemberAccess", + "referencedDeclaration": 11749, + "src": "1787:15:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 11902, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1787:39:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 11903, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1787:43:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 11905, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1787:50:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1764:73:61" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11908, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11887, + "src": "1866:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11911, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11887, + "src": "1896:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11912, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "approve", + "nodeType": "MemberAccess", + "referencedDeclaration": 11758, + "src": "1896:13:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,uint256) external returns (bool)" + } + }, + "id": 11913, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "selector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1896:22:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + } + }, + { + "argumentTypes": null, + "id": 11914, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11889, + "src": "1920:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11915, + "name": "newAllowance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11895, + "src": "1929:12:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 11909, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "1873:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11910, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSelector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "1873:22:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (bytes4) pure returns (bytes memory)" + } + }, + "id": 11916, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1873:69:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 11907, + "name": "callOptionalReturn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12005, + "src": "1847:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_bytes_memory_ptr_$returns$__$", + "typeString": "function (contract IERC20,bytes memory)" + } + }, + "id": 11917, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1847:96:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11918, + "nodeType": "ExpressionStatement", + "src": "1847:96:61" + } + ] + }, + "documentation": null, + "id": 11920, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "safeIncreaseAllowance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11892, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11887, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 11920, + "src": "1699:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11886, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "1699:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11889, + "name": "spender", + "nodeType": "VariableDeclaration", + "scope": 11920, + "src": "1713:15:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11888, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1713:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11891, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 11920, + "src": "1730:13:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11890, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1730:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1698:46:61" + }, + "returnParameters": { + "id": 11893, + "nodeType": "ParameterList", + "parameters": [], + "src": "1754:0:61" + }, + "scope": 12006, + "src": "1668:282:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11955, + "nodeType": "Block", + "src": "2042:241:61", + "statements": [ + { + "assignments": [ + 11930 + ], + "declarations": [ + { + "constant": false, + "id": 11930, + "name": "newAllowance", + "nodeType": "VariableDeclaration", + "scope": 11955, + "src": "2052:20:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11929, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2052:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 11942, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11939, + "name": "value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11926, + "src": "2119:5:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "5361666545524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726f", + "id": 11940, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2126:43:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_2c3af60974a758b7e72e108c9bf0943ecc9e4f2e8af4695da5f52fbf57a63d3a", + "typeString": "literal_string \"SafeERC20: decreased allowance below zero\"" + }, + "value": "SafeERC20: decreased allowance below zero" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_2c3af60974a758b7e72e108c9bf0943ecc9e4f2e8af4695da5f52fbf57a63d3a", + "typeString": "literal_string \"SafeERC20: decreased allowance below zero\"" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11934, + "name": "this", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12162, + "src": "2099:4:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_SafeERC20_$12006", + "typeString": "library SafeERC20" + } + ], + "id": 11933, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "2091:7:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11935, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2091:13:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11936, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11924, + "src": "2106:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "id": 11931, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11922, + "src": "2075:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11932, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "allowance", + "nodeType": "MemberAccess", + "referencedDeclaration": 11749, + "src": "2075:15:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view external returns (uint256)" + } + }, + "id": 11937, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2075:39:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 11938, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "sub", + "nodeType": "MemberAccess", + "referencedDeclaration": 11023, + "src": "2075:43:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" + } + }, + "id": 11941, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2075:95:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2052:118:61" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11944, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11922, + "src": "2199:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11947, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11922, + "src": "2229:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 11948, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "approve", + "nodeType": "MemberAccess", + "referencedDeclaration": 11758, + "src": "2229:13:61", + "typeDescriptions": { + "typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$", + "typeString": "function (address,uint256) external returns (bool)" + } + }, + "id": 11949, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "selector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2229:22:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + } + }, + { + "argumentTypes": null, + "id": 11950, + "name": "spender", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11924, + "src": "2253:7:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "id": 11951, + "name": "newAllowance", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11930, + "src": "2262:12:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes4", + "typeString": "bytes4" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 11945, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "2206:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11946, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "encodeWithSelector", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2206:22:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$", + "typeString": "function (bytes4) pure returns (bytes memory)" + } + }, + "id": 11952, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2206:69:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "id": 11943, + "name": "callOptionalReturn", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12005, + "src": "2180:18:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$11786_$_t_bytes_memory_ptr_$returns$__$", + "typeString": "function (contract IERC20,bytes memory)" + } + }, + "id": 11953, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2180:96:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11954, + "nodeType": "ExpressionStatement", + "src": "2180:96:61" + } + ] + }, + "documentation": null, + "id": 11956, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "safeDecreaseAllowance", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11927, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11922, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 11956, + "src": "1987:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11921, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "1987:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11924, + "name": "spender", + "nodeType": "VariableDeclaration", + "scope": 11956, + "src": "2001:15:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 11923, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2001:7:61", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11926, + "name": "value", + "nodeType": "VariableDeclaration", + "scope": 11956, + "src": "2018:13:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11925, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2018:7:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1986:46:61" + }, + "returnParameters": { + "id": 11928, + "nodeType": "ParameterList", + "parameters": [], + "src": "2042:0:61" + }, + "scope": 12006, + "src": "1956:327:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 12004, + "nodeType": "Block", + "src": "2735:1026:61", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11965, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11958, + "src": "3269:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + ], + "id": 11964, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3261:7:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11966, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3261:14:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 11967, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isContract", + "nodeType": "MemberAccess", + "referencedDeclaration": 12033, + "src": "3261:25:61", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$bound_to$_t_address_$", + "typeString": "function (address) view returns (bool)" + } + }, + "id": 11968, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3261:27:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5361666545524332303a2063616c6c20746f206e6f6e2d636f6e7472616374", + "id": 11969, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3290:33:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_f6ce7bfd656f35145dec774d6f7e67f4cba158373d2dd7a0f8273e232f86148d", + "typeString": "literal_string \"SafeERC20: call to non-contract\"" + }, + "value": "SafeERC20: call to non-contract" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_f6ce7bfd656f35145dec774d6f7e67f4cba158373d2dd7a0f8273e232f86148d", + "typeString": "literal_string \"SafeERC20: call to non-contract\"" + } + ], + "id": 11963, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "3253:7:61", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11970, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3253:71:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11971, + "nodeType": "ExpressionStatement", + "src": "3253:71:61" + }, + { + "assignments": [ + 11973, + 11975 + ], + "declarations": [ + { + "constant": false, + "id": 11973, + "name": "success", + "nodeType": "VariableDeclaration", + "scope": 12004, + "src": "3395:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + "typeName": { + "id": 11972, + "name": "bool", + "nodeType": "ElementaryTypeName", + "src": "3395:4:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11975, + "name": "returndata", + "nodeType": "VariableDeclaration", + "scope": 12004, + "src": "3409:23:61", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 11974, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "3409:5:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 11982, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11980, + "name": "data", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11960, + "src": "3456:4:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11977, + "name": "token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11958, + "src": "3444:5:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + ], + "id": 11976, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3436:7:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_address_$", + "typeString": "type(address)" + }, + "typeName": "address" + }, + "id": 11978, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3436:14:61", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 11979, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "call", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3436:19:61", + "typeDescriptions": { + "typeIdentifier": "t_function_barecall_payable$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "function (bytes memory) payable returns (bool,bytes memory)" + } + }, + "id": 11981, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3436:25:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$", + "typeString": "tuple(bool,bytes memory)" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3394:67:61" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11984, + "name": "success", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11973, + "src": "3479:7:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564", + "id": 11985, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3488:34:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_47fb62c2c272651d2f0f342bac006756b8ba07f21cc5cb87e0fbb9d50c0c585b", + "typeString": "literal_string \"SafeERC20: low-level call failed\"" + }, + "value": "SafeERC20: low-level call failed" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_47fb62c2c272651d2f0f342bac006756b8ba07f21cc5cb87e0fbb9d50c0c585b", + "typeString": "literal_string \"SafeERC20: low-level call failed\"" + } + ], + "id": 11983, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "3471:7:61", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11986, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3471:52:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11987, + "nodeType": "ExpressionStatement", + "src": "3471:52:61" + }, + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 11991, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 11988, + "name": "returndata", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11975, + "src": "3538:10:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + }, + "id": 11989, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "length", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3538:17:61", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 11990, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3558:1:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3538:21:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": null, + "id": 12003, + "nodeType": "IfStatement", + "src": "3534:221:61", + "trueBody": { + "id": 12002, + "nodeType": "Block", + "src": "3561:194:61", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11995, + "name": "returndata", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11975, + "src": "3678:10:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + } + }, + { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 11996, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "ElementaryTypeNameExpression", + "src": "3691:4:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_bool_$", + "typeString": "type(bool)" + }, + "typeName": "bool" + } + ], + "id": 11997, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "3690:6:61", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_bool_$", + "typeString": "type(bool)" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes memory" + }, + { + "typeIdentifier": "t_type$_t_bool_$", + "typeString": "type(bool)" + } + ], + "expression": { + "argumentTypes": null, + "id": 11993, + "name": "abi", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 12115, + "src": "3667:3:61", + "typeDescriptions": { + "typeIdentifier": "t_magic_abi", + "typeString": "abi" + } + }, + "id": 11994, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "memberName": "decode", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "3667:10:61", + "typeDescriptions": { + "typeIdentifier": "t_function_abidecode_pure$__$returns$__$", + "typeString": "function () pure" + } + }, + "id": 11998, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3667:30:61", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "5361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564", + "id": 11999, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3699:44:61", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_e11ad79d1e4a7f2e5f376964cb99e8e8f7904e3fc16a109f7a7ecb9aa7956dcd", + "typeString": "literal_string \"SafeERC20: ERC20 operation did not succeed\"" + }, + "value": "SafeERC20: ERC20 operation did not succeed" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_e11ad79d1e4a7f2e5f376964cb99e8e8f7904e3fc16a109f7a7ecb9aa7956dcd", + "typeString": "literal_string \"SafeERC20: ERC20 operation did not succeed\"" + } + ], + "id": 11992, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "3659:7:61", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 12000, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3659:85:61", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 12001, + "nodeType": "ExpressionStatement", + "src": "3659:85:61" + } + ] + } + } + ] + }, + "documentation": "@dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement\non the return value: the return value is optional (but if data is returned, it must not be false).\n@param token The token targeted by the call.\n@param data The call data (encoded using abi.encode or one of its variants).", + "id": 12005, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "callOptionalReturn", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11961, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11958, + "name": "token", + "nodeType": "VariableDeclaration", + "scope": 12005, + "src": "2694:12:61", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + }, + "typeName": { + "contractScope": null, + "id": 11957, + "name": "IERC20", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11786, + "src": "2694:6:61", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11960, + "name": "data", + "nodeType": "VariableDeclaration", + "scope": 12005, + "src": "2708:17:61", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_bytes_memory_ptr", + "typeString": "bytes" + }, + "typeName": { + "id": 11959, + "name": "bytes", + "nodeType": "ElementaryTypeName", + "src": "2708:5:61", + "typeDescriptions": { + "typeIdentifier": "t_bytes_storage_ptr", + "typeString": "bytes" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2693:33:61" + }, + "returnParameters": { + "id": 11962, + "nodeType": "ParameterList", + "parameters": [], + "src": "2735:0:61" + }, + "scope": 12006, + "src": "2666:1095:61", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "private" + } + ], + "scope": 12007, + "src": "574:3189:61" + } + ], + "src": "0:3764:61" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.947Z", + "devdoc": { + "details": "Wrappers around ERC20 operations that throw on failure (when the token contract returns false). Tokens that return no value (and instead revert or throw on failure) are also supported, non-reverting calls are assumed to be successful. To use this library you can add a `using SafeERC20 for ERC20;` statement to your contract, which allows you to call the safe operations as `token.safeTransfer(...)`, etc.", + "methods": {}, + "title": "SafeERC20" + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/SafeMath.json b/client/src/contracts/SafeMath.json index 4353f28..9d19dea 100644 --- a/client/src/contracts/SafeMath.json +++ b/client/src/contracts/SafeMath.json @@ -1,25 +1,25 @@ { "contractName": "SafeMath", "abi": [], - "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"details\":\"Wrappers over Solidity's arithmetic operations with added overflow checks. * Arithmetic operations in Solidity wrap on overflow. This can easily result in bugs, because programmers usually assume that an overflow raises an error, which is the standard behavior in high level programming languages. `SafeMath` restores this intuition by reverting the transaction when an operation overflows. * Using this library instead of the unchecked operations eliminates an entire class of bugs, so it's recommended to use it always.\",\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"@openzeppelin/contracts/math/SafeMath.sol\":\"SafeMath\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"@openzeppelin/contracts/math/SafeMath.sol\":{\"keccak256\":\"0xd1804d04fb39689453f673601429a99a0c68c422a981fc338773df9a59180fe9\",\"urls\":[\"bzzr://a7dfb6fc259d0074da840a848461487567e2a6309105dd5c050a4e025f0fa7cb\"]}},\"version\":1}", - "bytecode": "0x604c6023600b82828239805160001a607314601657fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea165627a7a723058205da37f16d5126afe146346cd9baf6392727a9184443fa85e097f6a1e2ed1d4d10029", - "deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600080fdfea165627a7a723058205da37f16d5126afe146346cd9baf6392727a9184443fa85e097f6a1e2ed1d4d10029", - "sourceMap": "589:2939:7:-;;132:2:-1;166:7;155:9;146:7;137:37;255:7;249:14;246:1;241:23;235:4;232:33;222:2;;269:9;222:2;293:9;290:1;283:20;323:4;314:7;306:22;347:7;338;331:24", - "deployedSourceMap": "589:2939:7:-;;;;;;;;", - "source": "pragma solidity ^0.5.0;\n\n/**\n * @dev Wrappers over Solidity's arithmetic operations with added overflow\n * checks.\n *\n * Arithmetic operations in Solidity wrap on overflow. This can easily result\n * in bugs, because programmers usually assume that an overflow raises an\n * error, which is the standard behavior in high level programming languages.\n * `SafeMath` restores this intuition by reverting the transaction when an\n * operation overflows.\n *\n * Using this library instead of the unchecked operations eliminates an entire\n * class of bugs, so it's recommended to use it always.\n */\nlibrary SafeMath {\n /**\n * @dev Returns the addition of two unsigned integers, reverting on\n * overflow.\n *\n * Counterpart to Solidity's `+` operator.\n *\n * Requirements:\n * - Addition cannot overflow.\n */\n function add(uint256 a, uint256 b) internal pure returns (uint256) {\n uint256 c = a + b;\n require(c >= a, \"SafeMath: addition overflow\");\n\n return c;\n }\n\n /**\n * @dev Returns the subtraction of two unsigned integers, reverting on\n * overflow (when the result is negative).\n *\n * Counterpart to Solidity's `-` operator.\n *\n * Requirements:\n * - Subtraction cannot overflow.\n */\n function sub(uint256 a, uint256 b) internal pure returns (uint256) {\n require(b <= a, \"SafeMath: subtraction overflow\");\n uint256 c = a - b;\n\n return c;\n }\n\n /**\n * @dev Returns the multiplication of two unsigned integers, reverting on\n * overflow.\n *\n * Counterpart to Solidity's `*` operator.\n *\n * Requirements:\n * - Multiplication cannot overflow.\n */\n function mul(uint256 a, uint256 b) internal pure returns (uint256) {\n // Gas optimization: this is cheaper than requiring 'a' not being zero, but the\n // benefit is lost if 'b' is also tested.\n // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522\n if (a == 0) {\n return 0;\n }\n\n uint256 c = a * b;\n require(c / a == b, \"SafeMath: multiplication overflow\");\n\n return c;\n }\n\n /**\n * @dev Returns the integer division of two unsigned integers. Reverts on\n * division by zero. The result is rounded towards zero.\n *\n * Counterpart to Solidity's `/` operator. Note: this function uses a\n * `revert` opcode (which leaves remaining gas untouched) while Solidity\n * uses an invalid opcode to revert (consuming all remaining gas).\n *\n * Requirements:\n * - The divisor cannot be zero.\n */\n function div(uint256 a, uint256 b) internal pure returns (uint256) {\n // Solidity only automatically asserts when dividing by 0\n require(b > 0, \"SafeMath: division by zero\");\n uint256 c = a / b;\n // assert(a == b * c + a % b); // There is no case in which this doesn't hold\n\n return c;\n }\n\n /**\n * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\n * Reverts when dividing by zero.\n *\n * Counterpart to Solidity's `%` operator. This function uses a `revert`\n * opcode (which leaves remaining gas untouched) while Solidity uses an\n * invalid opcode to revert (consuming all remaining gas).\n *\n * Requirements:\n * - The divisor cannot be zero.\n */\n function mod(uint256 a, uint256 b) internal pure returns (uint256) {\n require(b != 0, \"SafeMath: modulo by zero\");\n return a % b;\n }\n}\n", - "sourcePath": "@openzeppelin/contracts/math/SafeMath.sol", + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"details\":\"Wrappers over Solidity's arithmetic operations with added overflow checks. * Arithmetic operations in Solidity wrap on overflow. This can easily result in bugs, because programmers usually assume that an overflow raises an error, which is the standard behavior in high level programming languages. `SafeMath` restores this intuition by reverting the transaction when an operation overflows. * Using this library instead of the unchecked operations eliminates an entire class of bugs, so it's recommended to use it always.\",\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"openzeppelin-solidity/contracts/math/SafeMath.sol\":\"SafeMath\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]}},\"version\":1}", + "bytecode": "0x604c6023600b82828239805160001a607314601657fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea165627a7a72305820295ccf0dba8f9a4cbded643079beefc369e53af7da51db0ec40e2fd8694a9bc60029", + "deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600080fdfea165627a7a72305820295ccf0dba8f9a4cbded643079beefc369e53af7da51db0ec40e2fd8694a9bc60029", + "sourceMap": "589:4708:56:-;;132:2:-1;166:7;155:9;146:7;137:37;255:7;249:14;246:1;241:23;235:4;232:33;222:2;;269:9;222:2;293:9;290:1;283:20;323:4;314:7;306:22;347:7;338;331:24", + "deployedSourceMap": "589:4708:56:-;;;;;;;;", + "source": "pragma solidity ^0.5.0;\n\n/**\n * @dev Wrappers over Solidity's arithmetic operations with added overflow\n * checks.\n *\n * Arithmetic operations in Solidity wrap on overflow. This can easily result\n * in bugs, because programmers usually assume that an overflow raises an\n * error, which is the standard behavior in high level programming languages.\n * `SafeMath` restores this intuition by reverting the transaction when an\n * operation overflows.\n *\n * Using this library instead of the unchecked operations eliminates an entire\n * class of bugs, so it's recommended to use it always.\n */\nlibrary SafeMath {\n /**\n * @dev Returns the addition of two unsigned integers, reverting on\n * overflow.\n *\n * Counterpart to Solidity's `+` operator.\n *\n * Requirements:\n * - Addition cannot overflow.\n */\n function add(uint256 a, uint256 b) internal pure returns (uint256) {\n uint256 c = a + b;\n require(c >= a, \"SafeMath: addition overflow\");\n\n return c;\n }\n\n /**\n * @dev Returns the subtraction of two unsigned integers, reverting on\n * overflow (when the result is negative).\n *\n * Counterpart to Solidity's `-` operator.\n *\n * Requirements:\n * - Subtraction cannot overflow.\n */\n function sub(uint256 a, uint256 b) internal pure returns (uint256) {\n return sub(a, b, \"SafeMath: subtraction overflow\");\n }\n\n /**\n * @dev Returns the subtraction of two unsigned integers, reverting with custom message on\n * overflow (when the result is negative).\n *\n * Counterpart to Solidity's `-` operator.\n *\n * Requirements:\n * - Subtraction cannot overflow.\n *\n * _Available since v2.4.0._\n */\n function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {\n require(b <= a, errorMessage);\n uint256 c = a - b;\n\n return c;\n }\n\n /**\n * @dev Returns the multiplication of two unsigned integers, reverting on\n * overflow.\n *\n * Counterpart to Solidity's `*` operator.\n *\n * Requirements:\n * - Multiplication cannot overflow.\n */\n function mul(uint256 a, uint256 b) internal pure returns (uint256) {\n // Gas optimization: this is cheaper than requiring 'a' not being zero, but the\n // benefit is lost if 'b' is also tested.\n // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522\n if (a == 0) {\n return 0;\n }\n\n uint256 c = a * b;\n require(c / a == b, \"SafeMath: multiplication overflow\");\n\n return c;\n }\n\n /**\n * @dev Returns the integer division of two unsigned integers. Reverts on\n * division by zero. The result is rounded towards zero.\n *\n * Counterpart to Solidity's `/` operator. Note: this function uses a\n * `revert` opcode (which leaves remaining gas untouched) while Solidity\n * uses an invalid opcode to revert (consuming all remaining gas).\n *\n * Requirements:\n * - The divisor cannot be zero.\n */\n function div(uint256 a, uint256 b) internal pure returns (uint256) {\n return div(a, b, \"SafeMath: division by zero\");\n }\n\n /**\n * @dev Returns the integer division of two unsigned integers. Reverts with custom message on\n * division by zero. The result is rounded towards zero.\n *\n * Counterpart to Solidity's `/` operator. Note: this function uses a\n * `revert` opcode (which leaves remaining gas untouched) while Solidity\n * uses an invalid opcode to revert (consuming all remaining gas).\n *\n * Requirements:\n * - The divisor cannot be zero.\n *\n * _Available since v2.4.0._\n */\n function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {\n // Solidity only automatically asserts when dividing by 0\n require(b > 0, errorMessage);\n uint256 c = a / b;\n // assert(a == b * c + a % b); // There is no case in which this doesn't hold\n\n return c;\n }\n\n /**\n * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\n * Reverts when dividing by zero.\n *\n * Counterpart to Solidity's `%` operator. This function uses a `revert`\n * opcode (which leaves remaining gas untouched) while Solidity uses an\n * invalid opcode to revert (consuming all remaining gas).\n *\n * Requirements:\n * - The divisor cannot be zero.\n */\n function mod(uint256 a, uint256 b) internal pure returns (uint256) {\n return mod(a, b, \"SafeMath: modulo by zero\");\n }\n\n /**\n * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\n * Reverts with custom message when dividing by zero.\n *\n * Counterpart to Solidity's `%` operator. This function uses a `revert`\n * opcode (which leaves remaining gas untouched) while Solidity uses an\n * invalid opcode to revert (consuming all remaining gas).\n *\n * Requirements:\n * - The divisor cannot be zero.\n *\n * _Available since v2.4.0._\n */\n function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {\n require(b != 0, errorMessage);\n return a % b;\n }\n}\n", + "sourcePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", "ast": { - "absolutePath": "@openzeppelin/contracts/math/SafeMath.sol", + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", "exportedSymbols": { "SafeMath": [ - 977 + 11140 ] }, - "id": 978, + "id": 11141, "nodeType": "SourceUnit", "nodes": [ { - "id": 846, + "id": 10955, "literals": [ "solidity", "^", @@ -27,7 +27,7 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:7" + "src": "0:23:56" }, { "baseContracts": [], @@ -35,31 +35,31 @@ "contractKind": "library", "documentation": "@dev Wrappers over Solidity's arithmetic operations with added overflow\nchecks.\n * Arithmetic operations in Solidity wrap on overflow. This can easily result\nin bugs, because programmers usually assume that an overflow raises an\nerror, which is the standard behavior in high level programming languages.\n`SafeMath` restores this intuition by reverting the transaction when an\noperation overflows.\n * Using this library instead of the unchecked operations eliminates an entire\nclass of bugs, so it's recommended to use it always.", "fullyImplemented": true, - "id": 977, + "id": 11140, "linearizedBaseContracts": [ - 977 + 11140 ], "name": "SafeMath", "nodeType": "ContractDefinition", "nodes": [ { "body": { - "id": 870, + "id": 10979, "nodeType": "Block", - "src": "901:109:7", + "src": "901:109:56", "statements": [ { "assignments": [ - 856 + 10965 ], "declarations": [ { "constant": false, - "id": 856, + "id": 10965, "name": "c", "nodeType": "VariableDeclaration", - "scope": 870, - "src": "911:9:7", + "scope": 10979, + "src": "911:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -67,10 +67,10 @@ "typeString": "uint256" }, "typeName": { - "id": 855, + "id": 10964, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "911:7:7", + "src": "911:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -80,26 +80,26 @@ "visibility": "internal" } ], - "id": 860, + "id": 10969, "initialValue": { "argumentTypes": null, "commonType": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 859, + "id": 10968, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 857, + "id": 10966, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 848, - "src": "923:1:7", + "referencedDeclaration": 10957, + "src": "923:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -109,25 +109,25 @@ "operator": "+", "rightExpression": { "argumentTypes": null, - "id": 858, + "id": 10967, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 850, - "src": "927:1:7", + "referencedDeclaration": 10959, + "src": "927:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "923:5:7", + "src": "923:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "911:17:7" + "src": "911:17:56" }, { "expression": { @@ -139,19 +139,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 864, + "id": 10973, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 862, + "id": 10971, "name": "c", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 856, - "src": "946:1:7", + "referencedDeclaration": 10965, + "src": "946:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -161,18 +161,18 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 863, + "id": 10972, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 848, - "src": "951:1:7", + "referencedDeclaration": 10957, + "src": "951:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "946:6:7", + "src": "946:6:56", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -181,14 +181,14 @@ { "argumentTypes": null, "hexValue": "536166654d6174683a206164646974696f6e206f766572666c6f77", - "id": 865, + "id": 10974, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "954:29:7", + "src": "954:29:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_30cc447bcc13b3e22b45cef0dd9b0b514842d836dd9b6eb384e20dedfb47723a", @@ -208,21 +208,21 @@ "typeString": "literal_string \"SafeMath: addition overflow\"" } ], - "id": 861, + "id": 10970, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "938:7:7", + "referencedDeclaration": 12132, + "src": "938:7:56", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 866, + "id": 10975, "isConstant": false, "isLValue": false, "isPure": false, @@ -230,55 +230,55 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "938:46:7", + "src": "938:46:56", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 867, + "id": 10976, "nodeType": "ExpressionStatement", - "src": "938:46:7" + "src": "938:46:56" }, { "expression": { "argumentTypes": null, - "id": 868, + "id": 10977, "name": "c", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 856, - "src": "1002:1:7", + "referencedDeclaration": 10965, + "src": "1002:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 854, - "id": 869, + "functionReturnParameters": 10963, + "id": 10978, "nodeType": "Return", - "src": "995:8:7" + "src": "995:8:56" } ] }, "documentation": "@dev Returns the addition of two unsigned integers, reverting on\noverflow.\n * Counterpart to Solidity's `+` operator.\n * Requirements:\n- Addition cannot overflow.", - "id": 871, + "id": 10980, "implemented": true, "kind": "function", "modifiers": [], "name": "add", "nodeType": "FunctionDefinition", "parameters": { - "id": 851, + "id": 10960, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 848, + "id": 10957, "name": "a", "nodeType": "VariableDeclaration", - "scope": 871, - "src": "847:9:7", + "scope": 10980, + "src": "847:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -286,10 +286,10 @@ "typeString": "uint256" }, "typeName": { - "id": 847, + "id": 10956, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "847:7:7", + "src": "847:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -300,11 +300,11 @@ }, { "constant": false, - "id": 850, + "id": 10959, "name": "b", "nodeType": "VariableDeclaration", - "scope": 871, - "src": "858:9:7", + "scope": 10980, + "src": "858:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -312,10 +312,10 @@ "typeString": "uint256" }, "typeName": { - "id": 849, + "id": 10958, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "858:7:7", + "src": "858:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -325,19 +325,19 @@ "visibility": "internal" } ], - "src": "846:22:7" + "src": "846:22:56" }, "returnParameters": { - "id": 854, + "id": 10963, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 853, + "id": 10962, "name": "", "nodeType": "VariableDeclaration", - "scope": 871, - "src": "892:7:7", + "scope": 10980, + "src": "892:7:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -345,10 +345,10 @@ "typeString": "uint256" }, "typeName": { - "id": 852, + "id": 10961, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "892:7:7", + "src": "892:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -358,19 +358,229 @@ "visibility": "internal" } ], - "src": "891:9:7" + "src": "891:9:56" }, - "scope": 977, - "src": "834:176:7", + "scope": 11140, + "src": "834:176:56", "stateMutability": "pure", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 895, + "id": 10995, "nodeType": "Block", - "src": "1341:112:7", + "src": "1341:67:56", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10990, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10982, + "src": "1362:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 10991, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10984, + "src": "1365:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "536166654d6174683a207375627472616374696f6e206f766572666c6f77", + "id": 10992, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1368:32:56", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_50b058e9b5320e58880d88223c9801cd9eecdcf90323d5c2318bc1b6b916e862", + "typeString": "literal_string \"SafeMath: subtraction overflow\"" + }, + "value": "SafeMath: subtraction overflow" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_50b058e9b5320e58880d88223c9801cd9eecdcf90323d5c2318bc1b6b916e862", + "typeString": "literal_string \"SafeMath: subtraction overflow\"" + } + ], + "id": 10989, + "name": "sub", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 10996, + 11023 + ], + "referencedDeclaration": 11023, + "src": "1358:3:56", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" + } + }, + "id": 10993, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1358:43:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 10988, + "id": 10994, + "nodeType": "Return", + "src": "1351:50:56" + } + ] + }, + "documentation": "@dev Returns the subtraction of two unsigned integers, reverting on\noverflow (when the result is negative).\n * Counterpart to Solidity's `-` operator.\n * Requirements:\n- Subtraction cannot overflow.", + "id": 10996, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "sub", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10985, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10982, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 10996, + "src": "1287:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10981, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1287:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10984, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 10996, + "src": "1298:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10983, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1298:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1286:22:56" + }, + "returnParameters": { + "id": 10988, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10987, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10996, + "src": "1332:7:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10986, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1332:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1331:9:56" + }, + "scope": 11140, + "src": "1274:134:56", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11022, + "nodeType": "Block", + "src": "1827:92:56", "statements": [ { "expression": { @@ -382,19 +592,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 883, + "id": 11010, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 881, + "id": 11008, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 875, - "src": "1359:1:7", + "referencedDeclaration": 11000, + "src": "1845:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -404,18 +614,18 @@ "operator": "<=", "rightExpression": { "argumentTypes": null, - "id": 882, + "id": 11009, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 873, - "src": "1364:1:7", + "referencedDeclaration": 10998, + "src": "1850:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "1359:6:7", + "src": "1845:6:56", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -423,21 +633,16 @@ }, { "argumentTypes": null, - "hexValue": "536166654d6174683a207375627472616374696f6e206f766572666c6f77", - "id": 884, - "isConstant": false, - "isLValue": false, - "isPure": true, - "kind": "string", - "lValueRequested": false, - "nodeType": "Literal", - "src": "1367:32:7", - "subdenomination": null, + "id": 11011, + "name": "errorMessage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11002, + "src": "1853:12:56", "typeDescriptions": { - "typeIdentifier": "t_stringliteral_50b058e9b5320e58880d88223c9801cd9eecdcf90323d5c2318bc1b6b916e862", - "typeString": "literal_string \"SafeMath: subtraction overflow\"" - }, - "value": "SafeMath: subtraction overflow" + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } } ], "expression": { @@ -447,25 +652,25 @@ "typeString": "bool" }, { - "typeIdentifier": "t_stringliteral_50b058e9b5320e58880d88223c9801cd9eecdcf90323d5c2318bc1b6b916e862", - "typeString": "literal_string \"SafeMath: subtraction overflow\"" + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" } ], - "id": 880, + "id": 11007, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "1351:7:7", + "referencedDeclaration": 12132, + "src": "1837:7:56", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 885, + "id": 11012, "isConstant": false, "isLValue": false, "isPure": false, @@ -473,28 +678,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1351:49:7", + "src": "1837:29:56", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 886, + "id": 11013, "nodeType": "ExpressionStatement", - "src": "1351:49:7" + "src": "1837:29:56" }, { "assignments": [ - 888 + 11015 ], "declarations": [ { "constant": false, - "id": 888, + "id": 11015, "name": "c", "nodeType": "VariableDeclaration", - "scope": 895, - "src": "1410:9:7", + "scope": 11022, + "src": "1876:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -502,10 +707,10 @@ "typeString": "uint256" }, "typeName": { - "id": 887, + "id": 11014, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1410:7:7", + "src": "1876:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -515,26 +720,26 @@ "visibility": "internal" } ], - "id": 892, + "id": 11019, "initialValue": { "argumentTypes": null, "commonType": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 891, + "id": 11018, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 889, + "id": 11016, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 873, - "src": "1422:1:7", + "referencedDeclaration": 10998, + "src": "1888:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -544,65 +749,65 @@ "operator": "-", "rightExpression": { "argumentTypes": null, - "id": 890, + "id": 11017, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 875, - "src": "1426:1:7", + "referencedDeclaration": 11000, + "src": "1892:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "1422:5:7", + "src": "1888:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "1410:17:7" + "src": "1876:17:56" }, { "expression": { "argumentTypes": null, - "id": 893, + "id": 11020, "name": "c", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 888, - "src": "1445:1:7", + "referencedDeclaration": 11015, + "src": "1911:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 879, - "id": 894, + "functionReturnParameters": 11006, + "id": 11021, "nodeType": "Return", - "src": "1438:8:7" + "src": "1904:8:56" } ] }, - "documentation": "@dev Returns the subtraction of two unsigned integers, reverting on\noverflow (when the result is negative).\n * Counterpart to Solidity's `-` operator.\n * Requirements:\n- Subtraction cannot overflow.", - "id": 896, + "documentation": "@dev Returns the subtraction of two unsigned integers, reverting with custom message on\noverflow (when the result is negative).\n * Counterpart to Solidity's `-` operator.\n * Requirements:\n- Subtraction cannot overflow.\n * _Available since v2.4.0._", + "id": 11023, "implemented": true, "kind": "function", "modifiers": [], "name": "sub", "nodeType": "FunctionDefinition", "parameters": { - "id": 876, + "id": 11003, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 873, + "id": 10998, "name": "a", "nodeType": "VariableDeclaration", - "scope": 896, - "src": "1287:9:7", + "scope": 11023, + "src": "1745:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -610,10 +815,10 @@ "typeString": "uint256" }, "typeName": { - "id": 872, + "id": 10997, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1287:7:7", + "src": "1745:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -624,11 +829,11 @@ }, { "constant": false, - "id": 875, + "id": 11000, "name": "b", "nodeType": "VariableDeclaration", - "scope": 896, - "src": "1298:9:7", + "scope": 11023, + "src": "1756:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -636,10 +841,10 @@ "typeString": "uint256" }, "typeName": { - "id": 874, + "id": 10999, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1298:7:7", + "src": "1756:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -647,21 +852,47 @@ }, "value": null, "visibility": "internal" + }, + { + "constant": false, + "id": 11002, + "name": "errorMessage", + "nodeType": "VariableDeclaration", + "scope": 11023, + "src": "1767:26:56", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11001, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "1767:6:56", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" } ], - "src": "1286:22:7" + "src": "1744:50:56" }, "returnParameters": { - "id": 879, + "id": 11006, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 878, + "id": 11005, "name": "", "nodeType": "VariableDeclaration", - "scope": 896, - "src": "1332:7:7", + "scope": 11023, + "src": "1818:7:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -669,10 +900,10 @@ "typeString": "uint256" }, "typeName": { - "id": 877, + "id": 11004, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1332:7:7", + "src": "1818:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -682,19 +913,19 @@ "visibility": "internal" } ], - "src": "1331:9:7" + "src": "1817:9:56" }, - "scope": 977, - "src": "1274:179:7", + "scope": 11140, + "src": "1732:187:56", "stateMutability": "pure", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 929, + "id": 11056, "nodeType": "Block", - "src": "1760:392:7", + "src": "2226:392:56", "statements": [ { "condition": { @@ -703,19 +934,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 907, + "id": 11034, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 905, + "id": 11032, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 898, - "src": "1992:1:7", + "referencedDeclaration": 11025, + "src": "2458:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -726,14 +957,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "30", - "id": 906, + "id": 11033, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "1997:1:7", + "src": "2463:1:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -741,33 +972,33 @@ }, "value": "0" }, - "src": "1992:6:7", + "src": "2458:6:56", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "falseBody": null, - "id": 911, + "id": 11038, "nodeType": "IfStatement", - "src": "1988:45:7", + "src": "2454:45:56", "trueBody": { - "id": 910, + "id": 11037, "nodeType": "Block", - "src": "2000:33:7", + "src": "2466:33:56", "statements": [ { "expression": { "argumentTypes": null, "hexValue": "30", - "id": 908, + "id": 11035, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "2021:1:7", + "src": "2487:1:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -775,26 +1006,26 @@ }, "value": "0" }, - "functionReturnParameters": 904, - "id": 909, + "functionReturnParameters": 11031, + "id": 11036, "nodeType": "Return", - "src": "2014:8:7" + "src": "2480:8:56" } ] } }, { "assignments": [ - 913 + 11040 ], "declarations": [ { "constant": false, - "id": 913, + "id": 11040, "name": "c", "nodeType": "VariableDeclaration", - "scope": 929, - "src": "2043:9:7", + "scope": 11056, + "src": "2509:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -802,10 +1033,10 @@ "typeString": "uint256" }, "typeName": { - "id": 912, + "id": 11039, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2043:7:7", + "src": "2509:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -815,26 +1046,26 @@ "visibility": "internal" } ], - "id": 917, + "id": 11044, "initialValue": { "argumentTypes": null, "commonType": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 916, + "id": 11043, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 914, + "id": 11041, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 898, - "src": "2055:1:7", + "referencedDeclaration": 11025, + "src": "2521:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -844,25 +1075,25 @@ "operator": "*", "rightExpression": { "argumentTypes": null, - "id": 915, + "id": 11042, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 900, - "src": "2059:1:7", + "referencedDeclaration": 11027, + "src": "2525:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "2055:5:7", + "src": "2521:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2043:17:7" + "src": "2509:17:56" }, { "expression": { @@ -874,7 +1105,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 923, + "id": 11050, "isConstant": false, "isLValue": false, "isPure": false, @@ -885,19 +1116,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 921, + "id": 11048, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 919, + "id": 11046, "name": "c", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 913, - "src": "2078:1:7", + "referencedDeclaration": 11040, + "src": "2544:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -907,18 +1138,18 @@ "operator": "/", "rightExpression": { "argumentTypes": null, - "id": 920, + "id": 11047, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 898, - "src": "2082:1:7", + "referencedDeclaration": 11025, + "src": "2548:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "2078:5:7", + "src": "2544:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -928,18 +1159,18 @@ "operator": "==", "rightExpression": { "argumentTypes": null, - "id": 922, + "id": 11049, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 900, - "src": "2087:1:7", + "referencedDeclaration": 11027, + "src": "2553:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "2078:10:7", + "src": "2544:10:56", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -948,14 +1179,14 @@ { "argumentTypes": null, "hexValue": "536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77", - "id": 924, + "id": 11051, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "2090:35:7", + "src": "2556:35:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_9113bb53c2876a3805b2c9242029423fc540a728243ce887ab24c82cf119fba3", @@ -975,21 +1206,21 @@ "typeString": "literal_string \"SafeMath: multiplication overflow\"" } ], - "id": 918, + "id": 11045, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "2070:7:7", + "referencedDeclaration": 12132, + "src": "2536:7:56", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 925, + "id": 11052, "isConstant": false, "isLValue": false, "isPure": false, @@ -997,55 +1228,55 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2070:56:7", + "src": "2536:56:56", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 926, + "id": 11053, "nodeType": "ExpressionStatement", - "src": "2070:56:7" + "src": "2536:56:56" }, { "expression": { "argumentTypes": null, - "id": 927, + "id": 11054, "name": "c", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 913, - "src": "2144:1:7", + "referencedDeclaration": 11040, + "src": "2610:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 904, - "id": 928, + "functionReturnParameters": 11031, + "id": 11055, "nodeType": "Return", - "src": "2137:8:7" + "src": "2603:8:56" } ] }, "documentation": "@dev Returns the multiplication of two unsigned integers, reverting on\noverflow.\n * Counterpart to Solidity's `*` operator.\n * Requirements:\n- Multiplication cannot overflow.", - "id": 930, + "id": 11057, "implemented": true, "kind": "function", "modifiers": [], "name": "mul", "nodeType": "FunctionDefinition", "parameters": { - "id": 901, + "id": 11028, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 898, + "id": 11025, "name": "a", "nodeType": "VariableDeclaration", - "scope": 930, - "src": "1706:9:7", + "scope": 11057, + "src": "2172:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1053,10 +1284,10 @@ "typeString": "uint256" }, "typeName": { - "id": 897, + "id": 11024, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1706:7:7", + "src": "2172:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1067,11 +1298,11 @@ }, { "constant": false, - "id": 900, + "id": 11027, "name": "b", "nodeType": "VariableDeclaration", - "scope": 930, - "src": "1717:9:7", + "scope": 11057, + "src": "2183:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1079,10 +1310,10 @@ "typeString": "uint256" }, "typeName": { - "id": 899, + "id": 11026, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1717:7:7", + "src": "2183:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1092,19 +1323,19 @@ "visibility": "internal" } ], - "src": "1705:22:7" + "src": "2171:22:56" }, "returnParameters": { - "id": 904, + "id": 11031, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 903, + "id": 11030, "name": "", "nodeType": "VariableDeclaration", - "scope": 930, - "src": "1751:7:7", + "scope": 11057, + "src": "2217:7:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1112,10 +1343,10 @@ "typeString": "uint256" }, "typeName": { - "id": 902, + "id": 11029, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1751:7:7", + "src": "2217:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1125,19 +1356,19 @@ "visibility": "internal" } ], - "src": "1750:9:7" + "src": "2216:9:56" }, - "scope": 977, - "src": "1693:459:7", + "scope": 11140, + "src": "2159:459:56", "stateMutability": "pure", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 954, + "id": 11072, "nodeType": "Block", - "src": "2674:259:7", + "src": "3140:63:56", "statements": [ { "expression": { @@ -1145,65 +1376,41 @@ "arguments": [ { "argumentTypes": null, - "commonType": { + "id": 11067, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11059, + "src": "3161:1:56", + "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" - }, - "id": 942, - "isConstant": false, - "isLValue": false, - "isPure": false, - "lValueRequested": false, - "leftExpression": { - "argumentTypes": null, - "id": 940, - "name": "b", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 934, - "src": "2758:1:7", - "typeDescriptions": { - "typeIdentifier": "t_uint256", - "typeString": "uint256" - } - }, - "nodeType": "BinaryOperation", - "operator": ">", - "rightExpression": { - "argumentTypes": null, - "hexValue": "30", - "id": 941, - "isConstant": false, - "isLValue": false, - "isPure": true, - "kind": "number", - "lValueRequested": false, - "nodeType": "Literal", - "src": "2762:1:7", - "subdenomination": null, - "typeDescriptions": { - "typeIdentifier": "t_rational_0_by_1", - "typeString": "int_const 0" - }, - "value": "0" - }, - "src": "2758:5:7", + } + }, + { + "argumentTypes": null, + "id": 11068, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11061, + "src": "3164:1:56", "typeDescriptions": { - "typeIdentifier": "t_bool", - "typeString": "bool" + "typeIdentifier": "t_uint256", + "typeString": "uint256" } }, { "argumentTypes": null, "hexValue": "536166654d6174683a206469766973696f6e206279207a65726f", - "id": 943, + "id": 11069, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "2765:28:7", + "src": "3167:28:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_5b7cc70dda4dc2143e5adb63bd5d1f349504f461dbdfd9bc76fac1f8ca6d019f", @@ -1215,29 +1422,33 @@ "expression": { "argumentTypes": [ { - "typeIdentifier": "t_bool", - "typeString": "bool" + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" }, { "typeIdentifier": "t_stringliteral_5b7cc70dda4dc2143e5adb63bd5d1f349504f461dbdfd9bc76fac1f8ca6d019f", "typeString": "literal_string \"SafeMath: division by zero\"" } ], - "id": 939, - "name": "require", + "id": 11066, + "name": "div", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 11073, + 11100 ], - "referencedDeclaration": 1462, - "src": "2750:7:7", + "referencedDeclaration": 11100, + "src": "3157:3:56", "typeDescriptions": { - "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", - "typeString": "function (bool,string memory) pure" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 944, + "id": 11070, "isConstant": false, "isLValue": false, "isPure": false, @@ -1245,28 +1456,253 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2750:44:7", + "src": "3157:39:56", "typeDescriptions": { - "typeIdentifier": "t_tuple$__$", - "typeString": "tuple()" + "typeIdentifier": "t_uint256", + "typeString": "uint256" } }, - "id": 945, - "nodeType": "ExpressionStatement", - "src": "2750:44:7" - }, - { - "assignments": [ - 947 - ], - "declarations": [ - { - "constant": false, - "id": 947, - "name": "c", + "functionReturnParameters": 11065, + "id": 11071, + "nodeType": "Return", + "src": "3150:46:56" + } + ] + }, + "documentation": "@dev Returns the integer division of two unsigned integers. Reverts on\ndivision by zero. The result is rounded towards zero.\n * Counterpart to Solidity's `/` operator. Note: this function uses a\n`revert` opcode (which leaves remaining gas untouched) while Solidity\nuses an invalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.", + "id": 11073, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "div", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11062, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11059, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 11073, + "src": "3086:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11058, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3086:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11061, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 11073, + "src": "3097:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11060, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3097:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3085:22:56" + }, + "returnParameters": { + "id": 11065, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11064, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11073, + "src": "3131:7:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11063, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3131:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3130:9:56" + }, + "scope": 11140, + "src": "3073:130:56", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11099, + "nodeType": "Block", + "src": "3813:243:56", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 11087, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 11085, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11077, + "src": "3897:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": ">", + "rightExpression": { + "argumentTypes": null, + "hexValue": "30", + "id": 11086, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3901:1:56", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "src": "3897:5:56", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "id": 11088, + "name": "errorMessage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11079, + "src": "3904:12:56", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } + ], + "id": 11084, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "3889:7:56", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11089, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "3889:28:56", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11090, + "nodeType": "ExpressionStatement", + "src": "3889:28:56" + }, + { + "assignments": [ + 11092 + ], + "declarations": [ + { + "constant": false, + "id": 11092, + "name": "c", "nodeType": "VariableDeclaration", - "scope": 954, - "src": "2804:9:7", + "scope": 11099, + "src": "3927:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1274,107 +1710,343 @@ "typeString": "uint256" }, "typeName": { - "id": 946, + "id": 11091, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2804:7:7", + "src": "3927:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 11096, + "initialValue": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 11095, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 11093, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11075, + "src": "3939:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "id": 11094, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11077, + "src": "3943:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "3939:5:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "3927:17:56" + }, + { + "expression": { + "argumentTypes": null, + "id": 11097, + "name": "c", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11092, + "src": "4048:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 11083, + "id": 11098, + "nodeType": "Return", + "src": "4041:8:56" + } + ] + }, + "documentation": "@dev Returns the integer division of two unsigned integers. Reverts with custom message on\ndivision by zero. The result is rounded towards zero.\n * Counterpart to Solidity's `/` operator. Note: this function uses a\n`revert` opcode (which leaves remaining gas untouched) while Solidity\nuses an invalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.\n * _Available since v2.4.0._", + "id": 11100, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "div", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11080, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11075, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 11100, + "src": "3731:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11074, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3731:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11077, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 11100, + "src": "3742:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11076, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3742:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11079, + "name": "errorMessage", + "nodeType": "VariableDeclaration", + "scope": 11100, + "src": "3753:26:56", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11078, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "3753:6:56", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3730:50:56" + }, + "returnParameters": { + "id": 11083, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11082, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11100, + "src": "3804:7:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11081, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3804:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3803:9:56" + }, + "scope": 11140, + "src": "3718:338:56", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11115, + "nodeType": "Block", + "src": "4567:61:56", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11110, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11102, + "src": "4588:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } - }, - "value": null, - "visibility": "internal" - } - ], - "id": 951, - "initialValue": { - "argumentTypes": null, - "commonType": { - "typeIdentifier": "t_uint256", - "typeString": "uint256" + }, + { + "argumentTypes": null, + "id": 11111, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11104, + "src": "4591:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "536166654d6174683a206d6f64756c6f206279207a65726f", + "id": 11112, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4594:26:56", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_726e51f7b81fce0a68f5f214f445e275313b20b1633f08ce954ee39abf8d7832", + "typeString": "literal_string \"SafeMath: modulo by zero\"" + }, + "value": "SafeMath: modulo by zero" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_726e51f7b81fce0a68f5f214f445e275313b20b1633f08ce954ee39abf8d7832", + "typeString": "literal_string \"SafeMath: modulo by zero\"" + } + ], + "id": 11109, + "name": "mod", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 11116, + 11139 + ], + "referencedDeclaration": 11139, + "src": "4584:3:56", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" + } }, - "id": 950, + "id": 11113, "isConstant": false, "isLValue": false, "isPure": false, + "kind": "functionCall", "lValueRequested": false, - "leftExpression": { - "argumentTypes": null, - "id": 948, - "name": "a", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 932, - "src": "2816:1:7", - "typeDescriptions": { - "typeIdentifier": "t_uint256", - "typeString": "uint256" - } - }, - "nodeType": "BinaryOperation", - "operator": "/", - "rightExpression": { - "argumentTypes": null, - "id": 949, - "name": "b", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 934, - "src": "2820:1:7", - "typeDescriptions": { - "typeIdentifier": "t_uint256", - "typeString": "uint256" - } - }, - "src": "2816:5:7", - "typeDescriptions": { - "typeIdentifier": "t_uint256", - "typeString": "uint256" - } - }, - "nodeType": "VariableDeclarationStatement", - "src": "2804:17:7" - }, - { - "expression": { - "argumentTypes": null, - "id": 952, - "name": "c", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 947, - "src": "2925:1:7", + "names": [], + "nodeType": "FunctionCall", + "src": "4584:37:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 938, - "id": 953, + "functionReturnParameters": 11108, + "id": 11114, "nodeType": "Return", - "src": "2918:8:7" + "src": "4577:44:56" } ] }, - "documentation": "@dev Returns the integer division of two unsigned integers. Reverts on\ndivision by zero. The result is rounded towards zero.\n * Counterpart to Solidity's `/` operator. Note: this function uses a\n`revert` opcode (which leaves remaining gas untouched) while Solidity\nuses an invalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.", - "id": 955, + "documentation": "@dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\nReverts when dividing by zero.\n * Counterpart to Solidity's `%` operator. This function uses a `revert`\nopcode (which leaves remaining gas untouched) while Solidity uses an\ninvalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.", + "id": 11116, "implemented": true, "kind": "function", "modifiers": [], - "name": "div", + "name": "mod", "nodeType": "FunctionDefinition", "parameters": { - "id": 935, + "id": 11105, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 932, + "id": 11102, "name": "a", "nodeType": "VariableDeclaration", - "scope": 955, - "src": "2620:9:7", + "scope": 11116, + "src": "4513:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1382,10 +2054,10 @@ "typeString": "uint256" }, "typeName": { - "id": 931, + "id": 11101, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2620:7:7", + "src": "4513:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1396,11 +2068,11 @@ }, { "constant": false, - "id": 934, + "id": 11104, "name": "b", "nodeType": "VariableDeclaration", - "scope": 955, - "src": "2631:9:7", + "scope": 11116, + "src": "4524:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1408,10 +2080,10 @@ "typeString": "uint256" }, "typeName": { - "id": 933, + "id": 11103, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2631:7:7", + "src": "4524:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1421,19 +2093,19 @@ "visibility": "internal" } ], - "src": "2619:22:7" + "src": "4512:22:56" }, "returnParameters": { - "id": 938, + "id": 11108, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 937, + "id": 11107, "name": "", "nodeType": "VariableDeclaration", - "scope": 955, - "src": "2665:7:7", + "scope": 11116, + "src": "4558:7:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1441,10 +2113,10 @@ "typeString": "uint256" }, "typeName": { - "id": 936, + "id": 11106, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2665:7:7", + "src": "4558:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1454,19 +2126,19 @@ "visibility": "internal" } ], - "src": "2664:9:7" + "src": "4557:9:56" }, - "scope": 977, - "src": "2607:326:7", + "scope": 11140, + "src": "4500:128:56", "stateMutability": "pure", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 975, + "id": 11138, "nodeType": "Block", - "src": "3444:82:7", + "src": "5227:68:56", "statements": [ { "expression": { @@ -1478,19 +2150,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 967, + "id": 11130, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 965, + "id": 11128, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 959, - "src": "3462:1:7", + "referencedDeclaration": 11120, + "src": "5245:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1501,14 +2173,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "30", - "id": 966, + "id": 11129, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "3467:1:7", + "src": "5250:1:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -1516,7 +2188,7 @@ }, "value": "0" }, - "src": "3462:6:7", + "src": "5245:6:56", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1524,21 +2196,16 @@ }, { "argumentTypes": null, - "hexValue": "536166654d6174683a206d6f64756c6f206279207a65726f", - "id": 968, - "isConstant": false, - "isLValue": false, - "isPure": true, - "kind": "string", - "lValueRequested": false, - "nodeType": "Literal", - "src": "3470:26:7", - "subdenomination": null, + "id": 11131, + "name": "errorMessage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11122, + "src": "5253:12:56", "typeDescriptions": { - "typeIdentifier": "t_stringliteral_726e51f7b81fce0a68f5f214f445e275313b20b1633f08ce954ee39abf8d7832", - "typeString": "literal_string \"SafeMath: modulo by zero\"" - }, - "value": "SafeMath: modulo by zero" + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } } ], "expression": { @@ -1548,25 +2215,25 @@ "typeString": "bool" }, { - "typeIdentifier": "t_stringliteral_726e51f7b81fce0a68f5f214f445e275313b20b1633f08ce954ee39abf8d7832", - "typeString": "literal_string \"SafeMath: modulo by zero\"" + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" } ], - "id": 964, + "id": 11127, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "3454:7:7", + "referencedDeclaration": 12132, + "src": "5237:7:56", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 969, + "id": 11132, "isConstant": false, "isLValue": false, "isPure": false, @@ -1574,15 +2241,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3454:43:7", + "src": "5237:29:56", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 970, + "id": 11133, "nodeType": "ExpressionStatement", - "src": "3454:43:7" + "src": "5237:29:56" }, { "expression": { @@ -1591,19 +2258,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 973, + "id": 11136, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 971, + "id": 11134, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 957, - "src": "3514:1:7", + "referencedDeclaration": 11118, + "src": "5283:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1613,48 +2280,48 @@ "operator": "%", "rightExpression": { "argumentTypes": null, - "id": 972, + "id": 11135, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 959, - "src": "3518:1:7", + "referencedDeclaration": 11120, + "src": "5287:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "3514:5:7", + "src": "5283:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 963, - "id": 974, + "functionReturnParameters": 11126, + "id": 11137, "nodeType": "Return", - "src": "3507:12:7" + "src": "5276:12:56" } ] }, - "documentation": "@dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\nReverts when dividing by zero.\n * Counterpart to Solidity's `%` operator. This function uses a `revert`\nopcode (which leaves remaining gas untouched) while Solidity uses an\ninvalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.", - "id": 976, + "documentation": "@dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\nReverts with custom message when dividing by zero.\n * Counterpart to Solidity's `%` operator. This function uses a `revert`\nopcode (which leaves remaining gas untouched) while Solidity uses an\ninvalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.\n * _Available since v2.4.0._", + "id": 11139, "implemented": true, "kind": "function", "modifiers": [], "name": "mod", "nodeType": "FunctionDefinition", "parameters": { - "id": 960, + "id": 11123, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 957, + "id": 11118, "name": "a", "nodeType": "VariableDeclaration", - "scope": 976, - "src": "3390:9:7", + "scope": 11139, + "src": "5145:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1662,10 +2329,10 @@ "typeString": "uint256" }, "typeName": { - "id": 956, + "id": 11117, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3390:7:7", + "src": "5145:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1676,11 +2343,11 @@ }, { "constant": false, - "id": 959, + "id": 11120, "name": "b", "nodeType": "VariableDeclaration", - "scope": 976, - "src": "3401:9:7", + "scope": 11139, + "src": "5156:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1688,10 +2355,10 @@ "typeString": "uint256" }, "typeName": { - "id": 958, + "id": 11119, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3401:7:7", + "src": "5156:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1699,21 +2366,47 @@ }, "value": null, "visibility": "internal" + }, + { + "constant": false, + "id": 11122, + "name": "errorMessage", + "nodeType": "VariableDeclaration", + "scope": 11139, + "src": "5167:26:56", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11121, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "5167:6:56", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" } ], - "src": "3389:22:7" + "src": "5144:50:56" }, "returnParameters": { - "id": 963, + "id": 11126, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 962, + "id": 11125, "name": "", "nodeType": "VariableDeclaration", - "scope": 976, - "src": "3435:7:7", + "scope": 11139, + "src": "5218:7:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1721,10 +2414,10 @@ "typeString": "uint256" }, "typeName": { - "id": 961, + "id": 11124, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3435:7:7", + "src": "5218:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1734,33 +2427,33 @@ "visibility": "internal" } ], - "src": "3434:9:7" + "src": "5217:9:56" }, - "scope": 977, - "src": "3377:149:7", + "scope": 11140, + "src": "5132:163:56", "stateMutability": "pure", "superFunction": null, "visibility": "internal" } ], - "scope": 978, - "src": "589:2939:7" + "scope": 11141, + "src": "589:4708:56" } ], - "src": "0:3529:7" + "src": "0:5298:56" }, "legacyAST": { - "absolutePath": "@openzeppelin/contracts/math/SafeMath.sol", + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", "exportedSymbols": { "SafeMath": [ - 977 + 11140 ] }, - "id": 978, + "id": 11141, "nodeType": "SourceUnit", "nodes": [ { - "id": 846, + "id": 10955, "literals": [ "solidity", "^", @@ -1768,7 +2461,7 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:7" + "src": "0:23:56" }, { "baseContracts": [], @@ -1776,31 +2469,31 @@ "contractKind": "library", "documentation": "@dev Wrappers over Solidity's arithmetic operations with added overflow\nchecks.\n * Arithmetic operations in Solidity wrap on overflow. This can easily result\nin bugs, because programmers usually assume that an overflow raises an\nerror, which is the standard behavior in high level programming languages.\n`SafeMath` restores this intuition by reverting the transaction when an\noperation overflows.\n * Using this library instead of the unchecked operations eliminates an entire\nclass of bugs, so it's recommended to use it always.", "fullyImplemented": true, - "id": 977, + "id": 11140, "linearizedBaseContracts": [ - 977 + 11140 ], "name": "SafeMath", "nodeType": "ContractDefinition", "nodes": [ { "body": { - "id": 870, + "id": 10979, "nodeType": "Block", - "src": "901:109:7", + "src": "901:109:56", "statements": [ { "assignments": [ - 856 + 10965 ], "declarations": [ { "constant": false, - "id": 856, + "id": 10965, "name": "c", "nodeType": "VariableDeclaration", - "scope": 870, - "src": "911:9:7", + "scope": 10979, + "src": "911:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1808,10 +2501,10 @@ "typeString": "uint256" }, "typeName": { - "id": 855, + "id": 10964, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "911:7:7", + "src": "911:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1821,26 +2514,26 @@ "visibility": "internal" } ], - "id": 860, + "id": 10969, "initialValue": { "argumentTypes": null, "commonType": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 859, + "id": 10968, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 857, + "id": 10966, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 848, - "src": "923:1:7", + "referencedDeclaration": 10957, + "src": "923:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1850,25 +2543,25 @@ "operator": "+", "rightExpression": { "argumentTypes": null, - "id": 858, + "id": 10967, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 850, - "src": "927:1:7", + "referencedDeclaration": 10959, + "src": "927:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "923:5:7", + "src": "923:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "911:17:7" + "src": "911:17:56" }, { "expression": { @@ -1880,19 +2573,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 864, + "id": 10973, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 862, + "id": 10971, "name": "c", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 856, - "src": "946:1:7", + "referencedDeclaration": 10965, + "src": "946:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1902,68 +2595,296 @@ "operator": ">=", "rightExpression": { "argumentTypes": null, - "id": 863, + "id": 10972, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 848, - "src": "951:1:7", + "referencedDeclaration": 10957, + "src": "951:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "946:6:7", + "src": "946:6:56", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + { + "argumentTypes": null, + "hexValue": "536166654d6174683a206164646974696f6e206f766572666c6f77", + "id": 10974, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "954:29:56", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_30cc447bcc13b3e22b45cef0dd9b0b514842d836dd9b6eb384e20dedfb47723a", + "typeString": "literal_string \"SafeMath: addition overflow\"" + }, + "value": "SafeMath: addition overflow" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_30cc447bcc13b3e22b45cef0dd9b0b514842d836dd9b6eb384e20dedfb47723a", + "typeString": "literal_string \"SafeMath: addition overflow\"" + } + ], + "id": 10970, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "938:7:56", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 10975, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "938:46:56", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 10976, + "nodeType": "ExpressionStatement", + "src": "938:46:56" + }, + { + "expression": { + "argumentTypes": null, + "id": 10977, + "name": "c", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10965, + "src": "1002:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 10963, + "id": 10978, + "nodeType": "Return", + "src": "995:8:56" + } + ] + }, + "documentation": "@dev Returns the addition of two unsigned integers, reverting on\noverflow.\n * Counterpart to Solidity's `+` operator.\n * Requirements:\n- Addition cannot overflow.", + "id": 10980, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "add", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 10960, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10957, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 10980, + "src": "847:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10956, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "847:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 10959, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 10980, + "src": "858:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10958, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "858:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "846:22:56" + }, + "returnParameters": { + "id": 10963, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 10962, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 10980, + "src": "892:7:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 10961, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "892:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "891:9:56" + }, + "scope": 11140, + "src": "834:176:56", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 10995, + "nodeType": "Block", + "src": "1341:67:56", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 10990, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10982, + "src": "1362:1:56", "typeDescriptions": { - "typeIdentifier": "t_bool", - "typeString": "bool" + "typeIdentifier": "t_uint256", + "typeString": "uint256" } }, { "argumentTypes": null, - "hexValue": "536166654d6174683a206164646974696f6e206f766572666c6f77", - "id": 865, + "id": 10991, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 10984, + "src": "1365:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "536166654d6174683a207375627472616374696f6e206f766572666c6f77", + "id": 10992, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "954:29:7", + "src": "1368:32:56", "subdenomination": null, "typeDescriptions": { - "typeIdentifier": "t_stringliteral_30cc447bcc13b3e22b45cef0dd9b0b514842d836dd9b6eb384e20dedfb47723a", - "typeString": "literal_string \"SafeMath: addition overflow\"" + "typeIdentifier": "t_stringliteral_50b058e9b5320e58880d88223c9801cd9eecdcf90323d5c2318bc1b6b916e862", + "typeString": "literal_string \"SafeMath: subtraction overflow\"" }, - "value": "SafeMath: addition overflow" + "value": "SafeMath: subtraction overflow" } ], "expression": { "argumentTypes": [ { - "typeIdentifier": "t_bool", - "typeString": "bool" + "typeIdentifier": "t_uint256", + "typeString": "uint256" }, { - "typeIdentifier": "t_stringliteral_30cc447bcc13b3e22b45cef0dd9b0b514842d836dd9b6eb384e20dedfb47723a", - "typeString": "literal_string \"SafeMath: addition overflow\"" + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_50b058e9b5320e58880d88223c9801cd9eecdcf90323d5c2318bc1b6b916e862", + "typeString": "literal_string \"SafeMath: subtraction overflow\"" } ], - "id": 861, - "name": "require", + "id": 10989, + "name": "sub", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 10996, + 11023 ], - "referencedDeclaration": 1462, - "src": "938:7:7", + "referencedDeclaration": 11023, + "src": "1358:3:56", "typeDescriptions": { - "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", - "typeString": "function (bool,string memory) pure" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 866, + "id": 10993, "isConstant": false, "isLValue": false, "isPure": false, @@ -1971,55 +2892,37 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "938:46:7", - "typeDescriptions": { - "typeIdentifier": "t_tuple$__$", - "typeString": "tuple()" - } - }, - "id": 867, - "nodeType": "ExpressionStatement", - "src": "938:46:7" - }, - { - "expression": { - "argumentTypes": null, - "id": 868, - "name": "c", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 856, - "src": "1002:1:7", + "src": "1358:43:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 854, - "id": 869, + "functionReturnParameters": 10988, + "id": 10994, "nodeType": "Return", - "src": "995:8:7" + "src": "1351:50:56" } ] }, - "documentation": "@dev Returns the addition of two unsigned integers, reverting on\noverflow.\n * Counterpart to Solidity's `+` operator.\n * Requirements:\n- Addition cannot overflow.", - "id": 871, + "documentation": "@dev Returns the subtraction of two unsigned integers, reverting on\noverflow (when the result is negative).\n * Counterpart to Solidity's `-` operator.\n * Requirements:\n- Subtraction cannot overflow.", + "id": 10996, "implemented": true, "kind": "function", "modifiers": [], - "name": "add", + "name": "sub", "nodeType": "FunctionDefinition", "parameters": { - "id": 851, + "id": 10985, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 848, + "id": 10982, "name": "a", "nodeType": "VariableDeclaration", - "scope": 871, - "src": "847:9:7", + "scope": 10996, + "src": "1287:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2027,10 +2930,10 @@ "typeString": "uint256" }, "typeName": { - "id": 847, + "id": 10981, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "847:7:7", + "src": "1287:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2041,11 +2944,11 @@ }, { "constant": false, - "id": 850, + "id": 10984, "name": "b", "nodeType": "VariableDeclaration", - "scope": 871, - "src": "858:9:7", + "scope": 10996, + "src": "1298:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2053,10 +2956,10 @@ "typeString": "uint256" }, "typeName": { - "id": 849, + "id": 10983, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "858:7:7", + "src": "1298:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2066,19 +2969,19 @@ "visibility": "internal" } ], - "src": "846:22:7" + "src": "1286:22:56" }, "returnParameters": { - "id": 854, + "id": 10988, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 853, + "id": 10987, "name": "", "nodeType": "VariableDeclaration", - "scope": 871, - "src": "892:7:7", + "scope": 10996, + "src": "1332:7:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2086,10 +2989,10 @@ "typeString": "uint256" }, "typeName": { - "id": 852, + "id": 10986, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "892:7:7", + "src": "1332:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2099,19 +3002,19 @@ "visibility": "internal" } ], - "src": "891:9:7" + "src": "1331:9:56" }, - "scope": 977, - "src": "834:176:7", + "scope": 11140, + "src": "1274:134:56", "stateMutability": "pure", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 895, + "id": 11022, "nodeType": "Block", - "src": "1341:112:7", + "src": "1827:92:56", "statements": [ { "expression": { @@ -2123,19 +3026,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 883, + "id": 11010, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 881, + "id": 11008, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 875, - "src": "1359:1:7", + "referencedDeclaration": 11000, + "src": "1845:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2145,18 +3048,18 @@ "operator": "<=", "rightExpression": { "argumentTypes": null, - "id": 882, + "id": 11009, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 873, - "src": "1364:1:7", + "referencedDeclaration": 10998, + "src": "1850:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "1359:6:7", + "src": "1845:6:56", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -2164,21 +3067,16 @@ }, { "argumentTypes": null, - "hexValue": "536166654d6174683a207375627472616374696f6e206f766572666c6f77", - "id": 884, - "isConstant": false, - "isLValue": false, - "isPure": true, - "kind": "string", - "lValueRequested": false, - "nodeType": "Literal", - "src": "1367:32:7", - "subdenomination": null, + "id": 11011, + "name": "errorMessage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11002, + "src": "1853:12:56", "typeDescriptions": { - "typeIdentifier": "t_stringliteral_50b058e9b5320e58880d88223c9801cd9eecdcf90323d5c2318bc1b6b916e862", - "typeString": "literal_string \"SafeMath: subtraction overflow\"" - }, - "value": "SafeMath: subtraction overflow" + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } } ], "expression": { @@ -2188,25 +3086,25 @@ "typeString": "bool" }, { - "typeIdentifier": "t_stringliteral_50b058e9b5320e58880d88223c9801cd9eecdcf90323d5c2318bc1b6b916e862", - "typeString": "literal_string \"SafeMath: subtraction overflow\"" + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" } ], - "id": 880, + "id": 11007, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "1351:7:7", + "referencedDeclaration": 12132, + "src": "1837:7:56", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 885, + "id": 11012, "isConstant": false, "isLValue": false, "isPure": false, @@ -2214,28 +3112,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1351:49:7", + "src": "1837:29:56", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 886, + "id": 11013, "nodeType": "ExpressionStatement", - "src": "1351:49:7" + "src": "1837:29:56" }, { "assignments": [ - 888 + 11015 ], "declarations": [ { "constant": false, - "id": 888, + "id": 11015, "name": "c", "nodeType": "VariableDeclaration", - "scope": 895, - "src": "1410:9:7", + "scope": 11022, + "src": "1876:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2243,10 +3141,10 @@ "typeString": "uint256" }, "typeName": { - "id": 887, + "id": 11014, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1410:7:7", + "src": "1876:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2256,26 +3154,26 @@ "visibility": "internal" } ], - "id": 892, + "id": 11019, "initialValue": { "argumentTypes": null, "commonType": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 891, + "id": 11018, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 889, + "id": 11016, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 873, - "src": "1422:1:7", + "referencedDeclaration": 10998, + "src": "1888:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2285,65 +3183,65 @@ "operator": "-", "rightExpression": { "argumentTypes": null, - "id": 890, + "id": 11017, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 875, - "src": "1426:1:7", + "referencedDeclaration": 11000, + "src": "1892:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "1422:5:7", + "src": "1888:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "1410:17:7" + "src": "1876:17:56" }, { "expression": { "argumentTypes": null, - "id": 893, + "id": 11020, "name": "c", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 888, - "src": "1445:1:7", + "referencedDeclaration": 11015, + "src": "1911:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 879, - "id": 894, + "functionReturnParameters": 11006, + "id": 11021, "nodeType": "Return", - "src": "1438:8:7" + "src": "1904:8:56" } ] }, - "documentation": "@dev Returns the subtraction of two unsigned integers, reverting on\noverflow (when the result is negative).\n * Counterpart to Solidity's `-` operator.\n * Requirements:\n- Subtraction cannot overflow.", - "id": 896, + "documentation": "@dev Returns the subtraction of two unsigned integers, reverting with custom message on\noverflow (when the result is negative).\n * Counterpart to Solidity's `-` operator.\n * Requirements:\n- Subtraction cannot overflow.\n * _Available since v2.4.0._", + "id": 11023, "implemented": true, "kind": "function", "modifiers": [], "name": "sub", "nodeType": "FunctionDefinition", "parameters": { - "id": 876, + "id": 11003, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 873, + "id": 10998, "name": "a", "nodeType": "VariableDeclaration", - "scope": 896, - "src": "1287:9:7", + "scope": 11023, + "src": "1745:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2351,10 +3249,10 @@ "typeString": "uint256" }, "typeName": { - "id": 872, + "id": 10997, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1287:7:7", + "src": "1745:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2365,11 +3263,11 @@ }, { "constant": false, - "id": 875, + "id": 11000, "name": "b", "nodeType": "VariableDeclaration", - "scope": 896, - "src": "1298:9:7", + "scope": 11023, + "src": "1756:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2377,10 +3275,10 @@ "typeString": "uint256" }, "typeName": { - "id": 874, + "id": 10999, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1298:7:7", + "src": "1756:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2388,21 +3286,47 @@ }, "value": null, "visibility": "internal" + }, + { + "constant": false, + "id": 11002, + "name": "errorMessage", + "nodeType": "VariableDeclaration", + "scope": 11023, + "src": "1767:26:56", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11001, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "1767:6:56", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" } ], - "src": "1286:22:7" + "src": "1744:50:56" }, "returnParameters": { - "id": 879, + "id": 11006, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 878, + "id": 11005, "name": "", "nodeType": "VariableDeclaration", - "scope": 896, - "src": "1332:7:7", + "scope": 11023, + "src": "1818:7:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2410,10 +3334,10 @@ "typeString": "uint256" }, "typeName": { - "id": 877, + "id": 11004, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1332:7:7", + "src": "1818:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2423,19 +3347,19 @@ "visibility": "internal" } ], - "src": "1331:9:7" + "src": "1817:9:56" }, - "scope": 977, - "src": "1274:179:7", + "scope": 11140, + "src": "1732:187:56", "stateMutability": "pure", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 929, + "id": 11056, "nodeType": "Block", - "src": "1760:392:7", + "src": "2226:392:56", "statements": [ { "condition": { @@ -2444,19 +3368,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 907, + "id": 11034, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 905, + "id": 11032, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 898, - "src": "1992:1:7", + "referencedDeclaration": 11025, + "src": "2458:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2467,14 +3391,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "30", - "id": 906, + "id": 11033, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "1997:1:7", + "src": "2463:1:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -2482,33 +3406,33 @@ }, "value": "0" }, - "src": "1992:6:7", + "src": "2458:6:56", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, "falseBody": null, - "id": 911, + "id": 11038, "nodeType": "IfStatement", - "src": "1988:45:7", + "src": "2454:45:56", "trueBody": { - "id": 910, + "id": 11037, "nodeType": "Block", - "src": "2000:33:7", + "src": "2466:33:56", "statements": [ { "expression": { "argumentTypes": null, "hexValue": "30", - "id": 908, + "id": 11035, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "2021:1:7", + "src": "2487:1:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -2516,26 +3440,26 @@ }, "value": "0" }, - "functionReturnParameters": 904, - "id": 909, + "functionReturnParameters": 11031, + "id": 11036, "nodeType": "Return", - "src": "2014:8:7" + "src": "2480:8:56" } ] } }, { "assignments": [ - 913 + 11040 ], "declarations": [ { "constant": false, - "id": 913, + "id": 11040, "name": "c", "nodeType": "VariableDeclaration", - "scope": 929, - "src": "2043:9:7", + "scope": 11056, + "src": "2509:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2543,10 +3467,10 @@ "typeString": "uint256" }, "typeName": { - "id": 912, + "id": 11039, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2043:7:7", + "src": "2509:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2556,26 +3480,26 @@ "visibility": "internal" } ], - "id": 917, + "id": 11044, "initialValue": { "argumentTypes": null, "commonType": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 916, + "id": 11043, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 914, + "id": 11041, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 898, - "src": "2055:1:7", + "referencedDeclaration": 11025, + "src": "2521:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2585,25 +3509,25 @@ "operator": "*", "rightExpression": { "argumentTypes": null, - "id": 915, + "id": 11042, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 900, - "src": "2059:1:7", + "referencedDeclaration": 11027, + "src": "2525:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "2055:5:7", + "src": "2521:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2043:17:7" + "src": "2509:17:56" }, { "expression": { @@ -2615,7 +3539,7 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 923, + "id": 11050, "isConstant": false, "isLValue": false, "isPure": false, @@ -2626,19 +3550,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 921, + "id": 11048, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 919, + "id": 11046, "name": "c", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 913, - "src": "2078:1:7", + "referencedDeclaration": 11040, + "src": "2544:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2648,18 +3572,18 @@ "operator": "/", "rightExpression": { "argumentTypes": null, - "id": 920, + "id": 11047, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 898, - "src": "2082:1:7", + "referencedDeclaration": 11025, + "src": "2548:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "2078:5:7", + "src": "2544:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2669,18 +3593,18 @@ "operator": "==", "rightExpression": { "argumentTypes": null, - "id": 922, + "id": 11049, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 900, - "src": "2087:1:7", + "referencedDeclaration": 11027, + "src": "2553:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "2078:10:7", + "src": "2544:10:56", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -2689,48 +3613,276 @@ { "argumentTypes": null, "hexValue": "536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77", - "id": 924, + "id": 11051, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "2090:35:7", + "src": "2556:35:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_9113bb53c2876a3805b2c9242029423fc540a728243ce887ab24c82cf119fba3", "typeString": "literal_string \"SafeMath: multiplication overflow\"" }, - "value": "SafeMath: multiplication overflow" + "value": "SafeMath: multiplication overflow" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_bool", + "typeString": "bool" + }, + { + "typeIdentifier": "t_stringliteral_9113bb53c2876a3805b2c9242029423fc540a728243ce887ab24c82cf119fba3", + "typeString": "literal_string \"SafeMath: multiplication overflow\"" + } + ], + "id": 11045, + "name": "require", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12131, + 12132 + ], + "referencedDeclaration": 12132, + "src": "2536:7:56", + "typeDescriptions": { + "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", + "typeString": "function (bool,string memory) pure" + } + }, + "id": 11052, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2536:56:56", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 11053, + "nodeType": "ExpressionStatement", + "src": "2536:56:56" + }, + { + "expression": { + "argumentTypes": null, + "id": 11054, + "name": "c", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11040, + "src": "2610:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 11031, + "id": 11055, + "nodeType": "Return", + "src": "2603:8:56" + } + ] + }, + "documentation": "@dev Returns the multiplication of two unsigned integers, reverting on\noverflow.\n * Counterpart to Solidity's `*` operator.\n * Requirements:\n- Multiplication cannot overflow.", + "id": 11057, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "mul", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11028, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11025, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 11057, + "src": "2172:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11024, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2172:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11027, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 11057, + "src": "2183:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11026, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2183:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2171:22:56" + }, + "returnParameters": { + "id": 11031, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11030, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11057, + "src": "2217:7:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11029, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "2217:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "2216:9:56" + }, + "scope": 11140, + "src": "2159:459:56", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11072, + "nodeType": "Block", + "src": "3140:63:56", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11067, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11059, + "src": "3161:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 11068, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11061, + "src": "3164:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "536166654d6174683a206469766973696f6e206279207a65726f", + "id": 11069, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "3167:28:56", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_5b7cc70dda4dc2143e5adb63bd5d1f349504f461dbdfd9bc76fac1f8ca6d019f", + "typeString": "literal_string \"SafeMath: division by zero\"" + }, + "value": "SafeMath: division by zero" } ], "expression": { "argumentTypes": [ { - "typeIdentifier": "t_bool", - "typeString": "bool" + "typeIdentifier": "t_uint256", + "typeString": "uint256" }, { - "typeIdentifier": "t_stringliteral_9113bb53c2876a3805b2c9242029423fc540a728243ce887ab24c82cf119fba3", - "typeString": "literal_string \"SafeMath: multiplication overflow\"" + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_5b7cc70dda4dc2143e5adb63bd5d1f349504f461dbdfd9bc76fac1f8ca6d019f", + "typeString": "literal_string \"SafeMath: division by zero\"" } ], - "id": 918, - "name": "require", + "id": 11066, + "name": "div", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 11073, + 11100 ], - "referencedDeclaration": 1462, - "src": "2070:7:7", + "referencedDeclaration": 11100, + "src": "3157:3:56", "typeDescriptions": { - "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", - "typeString": "function (bool,string memory) pure" + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" } }, - "id": 925, + "id": 11070, "isConstant": false, "isLValue": false, "isPure": false, @@ -2738,55 +3890,37 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2070:56:7", - "typeDescriptions": { - "typeIdentifier": "t_tuple$__$", - "typeString": "tuple()" - } - }, - "id": 926, - "nodeType": "ExpressionStatement", - "src": "2070:56:7" - }, - { - "expression": { - "argumentTypes": null, - "id": 927, - "name": "c", - "nodeType": "Identifier", - "overloadedDeclarations": [], - "referencedDeclaration": 913, - "src": "2144:1:7", + "src": "3157:39:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 904, - "id": 928, + "functionReturnParameters": 11065, + "id": 11071, "nodeType": "Return", - "src": "2137:8:7" + "src": "3150:46:56" } ] }, - "documentation": "@dev Returns the multiplication of two unsigned integers, reverting on\noverflow.\n * Counterpart to Solidity's `*` operator.\n * Requirements:\n- Multiplication cannot overflow.", - "id": 930, + "documentation": "@dev Returns the integer division of two unsigned integers. Reverts on\ndivision by zero. The result is rounded towards zero.\n * Counterpart to Solidity's `/` operator. Note: this function uses a\n`revert` opcode (which leaves remaining gas untouched) while Solidity\nuses an invalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.", + "id": 11073, "implemented": true, "kind": "function", "modifiers": [], - "name": "mul", + "name": "div", "nodeType": "FunctionDefinition", "parameters": { - "id": 901, + "id": 11062, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 898, + "id": 11059, "name": "a", "nodeType": "VariableDeclaration", - "scope": 930, - "src": "1706:9:7", + "scope": 11073, + "src": "3086:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2794,10 +3928,10 @@ "typeString": "uint256" }, "typeName": { - "id": 897, + "id": 11058, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1706:7:7", + "src": "3086:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2808,11 +3942,11 @@ }, { "constant": false, - "id": 900, + "id": 11061, "name": "b", "nodeType": "VariableDeclaration", - "scope": 930, - "src": "1717:9:7", + "scope": 11073, + "src": "3097:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2820,10 +3954,10 @@ "typeString": "uint256" }, "typeName": { - "id": 899, + "id": 11060, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1717:7:7", + "src": "3097:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2833,19 +3967,19 @@ "visibility": "internal" } ], - "src": "1705:22:7" + "src": "3085:22:56" }, "returnParameters": { - "id": 904, + "id": 11065, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 903, + "id": 11064, "name": "", "nodeType": "VariableDeclaration", - "scope": 930, - "src": "1751:7:7", + "scope": 11073, + "src": "3131:7:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -2853,10 +3987,10 @@ "typeString": "uint256" }, "typeName": { - "id": 902, + "id": 11063, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1751:7:7", + "src": "3131:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2866,19 +4000,19 @@ "visibility": "internal" } ], - "src": "1750:9:7" + "src": "3130:9:56" }, - "scope": 977, - "src": "1693:459:7", + "scope": 11140, + "src": "3073:130:56", "stateMutability": "pure", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 954, + "id": 11099, "nodeType": "Block", - "src": "2674:259:7", + "src": "3813:243:56", "statements": [ { "expression": { @@ -2890,19 +4024,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 942, + "id": 11087, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 940, + "id": 11085, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 934, - "src": "2758:1:7", + "referencedDeclaration": 11077, + "src": "3897:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -2913,14 +4047,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "30", - "id": 941, + "id": 11086, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "2762:1:7", + "src": "3901:1:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -2928,7 +4062,7 @@ }, "value": "0" }, - "src": "2758:5:7", + "src": "3897:5:56", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -2936,21 +4070,16 @@ }, { "argumentTypes": null, - "hexValue": "536166654d6174683a206469766973696f6e206279207a65726f", - "id": 943, - "isConstant": false, - "isLValue": false, - "isPure": true, - "kind": "string", - "lValueRequested": false, - "nodeType": "Literal", - "src": "2765:28:7", - "subdenomination": null, + "id": 11088, + "name": "errorMessage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11079, + "src": "3904:12:56", "typeDescriptions": { - "typeIdentifier": "t_stringliteral_5b7cc70dda4dc2143e5adb63bd5d1f349504f461dbdfd9bc76fac1f8ca6d019f", - "typeString": "literal_string \"SafeMath: division by zero\"" - }, - "value": "SafeMath: division by zero" + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } } ], "expression": { @@ -2960,25 +4089,25 @@ "typeString": "bool" }, { - "typeIdentifier": "t_stringliteral_5b7cc70dda4dc2143e5adb63bd5d1f349504f461dbdfd9bc76fac1f8ca6d019f", - "typeString": "literal_string \"SafeMath: division by zero\"" + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" } ], - "id": 939, + "id": 11084, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "2750:7:7", + "referencedDeclaration": 12132, + "src": "3889:7:56", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 944, + "id": 11089, "isConstant": false, "isLValue": false, "isPure": false, @@ -2986,28 +4115,28 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "2750:44:7", + "src": "3889:28:56", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 945, + "id": 11090, "nodeType": "ExpressionStatement", - "src": "2750:44:7" + "src": "3889:28:56" }, { "assignments": [ - 947 + 11092 ], "declarations": [ { "constant": false, - "id": 947, + "id": 11092, "name": "c", "nodeType": "VariableDeclaration", - "scope": 954, - "src": "2804:9:7", + "scope": 11099, + "src": "3927:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3015,10 +4144,10 @@ "typeString": "uint256" }, "typeName": { - "id": 946, + "id": 11091, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2804:7:7", + "src": "3927:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3028,26 +4157,26 @@ "visibility": "internal" } ], - "id": 951, + "id": 11096, "initialValue": { "argumentTypes": null, "commonType": { "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 950, + "id": 11095, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 948, + "id": 11093, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 932, - "src": "2816:1:7", + "referencedDeclaration": 11075, + "src": "3939:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3057,65 +4186,301 @@ "operator": "/", "rightExpression": { "argumentTypes": null, - "id": 949, + "id": 11094, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 934, - "src": "2820:1:7", + "referencedDeclaration": 11077, + "src": "3943:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "2816:5:7", + "src": "3939:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, "nodeType": "VariableDeclarationStatement", - "src": "2804:17:7" + "src": "3927:17:56" }, { "expression": { "argumentTypes": null, - "id": 952, + "id": 11097, "name": "c", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 947, - "src": "2925:1:7", + "referencedDeclaration": 11092, + "src": "4048:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 938, - "id": 953, + "functionReturnParameters": 11083, + "id": 11098, "nodeType": "Return", - "src": "2918:8:7" + "src": "4041:8:56" } ] }, - "documentation": "@dev Returns the integer division of two unsigned integers. Reverts on\ndivision by zero. The result is rounded towards zero.\n * Counterpart to Solidity's `/` operator. Note: this function uses a\n`revert` opcode (which leaves remaining gas untouched) while Solidity\nuses an invalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.", - "id": 955, + "documentation": "@dev Returns the integer division of two unsigned integers. Reverts with custom message on\ndivision by zero. The result is rounded towards zero.\n * Counterpart to Solidity's `/` operator. Note: this function uses a\n`revert` opcode (which leaves remaining gas untouched) while Solidity\nuses an invalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.\n * _Available since v2.4.0._", + "id": 11100, "implemented": true, "kind": "function", "modifiers": [], "name": "div", "nodeType": "FunctionDefinition", "parameters": { - "id": 935, + "id": 11080, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11075, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 11100, + "src": "3731:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11074, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3731:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11077, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 11100, + "src": "3742:9:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11076, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3742:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 11079, + "name": "errorMessage", + "nodeType": "VariableDeclaration", + "scope": 11100, + "src": "3753:26:56", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11078, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "3753:6:56", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3730:50:56" + }, + "returnParameters": { + "id": 11083, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 11082, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 11100, + "src": "3804:7:56", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 11081, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "3804:7:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "3803:9:56" + }, + "scope": 11140, + "src": "3718:338:56", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 11115, + "nodeType": "Block", + "src": "4567:61:56", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 11110, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11102, + "src": "4588:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "id": 11111, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11104, + "src": "4591:1:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + { + "argumentTypes": null, + "hexValue": "536166654d6174683a206d6f64756c6f206279207a65726f", + "id": 11112, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "4594:26:56", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_726e51f7b81fce0a68f5f214f445e275313b20b1633f08ce954ee39abf8d7832", + "typeString": "literal_string \"SafeMath: modulo by zero\"" + }, + "value": "SafeMath: modulo by zero" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + { + "typeIdentifier": "t_stringliteral_726e51f7b81fce0a68f5f214f445e275313b20b1633f08ce954ee39abf8d7832", + "typeString": "literal_string \"SafeMath: modulo by zero\"" + } + ], + "id": 11109, + "name": "mod", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 11116, + 11139 + ], + "referencedDeclaration": 11139, + "src": "4584:3:56", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$_t_string_memory_ptr_$returns$_t_uint256_$", + "typeString": "function (uint256,uint256,string memory) pure returns (uint256)" + } + }, + "id": 11113, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "4584:37:56", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 11108, + "id": 11114, + "nodeType": "Return", + "src": "4577:44:56" + } + ] + }, + "documentation": "@dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\nReverts when dividing by zero.\n * Counterpart to Solidity's `%` operator. This function uses a `revert`\nopcode (which leaves remaining gas untouched) while Solidity uses an\ninvalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.", + "id": 11116, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "mod", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 11105, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 932, + "id": 11102, "name": "a", "nodeType": "VariableDeclaration", - "scope": 955, - "src": "2620:9:7", + "scope": 11116, + "src": "4513:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3123,10 +4488,10 @@ "typeString": "uint256" }, "typeName": { - "id": 931, + "id": 11101, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2620:7:7", + "src": "4513:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3137,11 +4502,11 @@ }, { "constant": false, - "id": 934, + "id": 11104, "name": "b", "nodeType": "VariableDeclaration", - "scope": 955, - "src": "2631:9:7", + "scope": 11116, + "src": "4524:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3149,10 +4514,10 @@ "typeString": "uint256" }, "typeName": { - "id": 933, + "id": 11103, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2631:7:7", + "src": "4524:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3162,19 +4527,19 @@ "visibility": "internal" } ], - "src": "2619:22:7" + "src": "4512:22:56" }, "returnParameters": { - "id": 938, + "id": 11108, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 937, + "id": 11107, "name": "", "nodeType": "VariableDeclaration", - "scope": 955, - "src": "2665:7:7", + "scope": 11116, + "src": "4558:7:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3182,10 +4547,10 @@ "typeString": "uint256" }, "typeName": { - "id": 936, + "id": 11106, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "2665:7:7", + "src": "4558:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3195,19 +4560,19 @@ "visibility": "internal" } ], - "src": "2664:9:7" + "src": "4557:9:56" }, - "scope": 977, - "src": "2607:326:7", + "scope": 11140, + "src": "4500:128:56", "stateMutability": "pure", "superFunction": null, "visibility": "internal" }, { "body": { - "id": 975, + "id": 11138, "nodeType": "Block", - "src": "3444:82:7", + "src": "5227:68:56", "statements": [ { "expression": { @@ -3219,19 +4584,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 967, + "id": 11130, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 965, + "id": 11128, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 959, - "src": "3462:1:7", + "referencedDeclaration": 11120, + "src": "5245:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3242,14 +4607,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "30", - "id": 966, + "id": 11129, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "3467:1:7", + "src": "5250:1:56", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_0_by_1", @@ -3257,7 +4622,7 @@ }, "value": "0" }, - "src": "3462:6:7", + "src": "5245:6:56", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -3265,21 +4630,16 @@ }, { "argumentTypes": null, - "hexValue": "536166654d6174683a206d6f64756c6f206279207a65726f", - "id": 968, - "isConstant": false, - "isLValue": false, - "isPure": true, - "kind": "string", - "lValueRequested": false, - "nodeType": "Literal", - "src": "3470:26:7", - "subdenomination": null, + "id": 11131, + "name": "errorMessage", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11122, + "src": "5253:12:56", "typeDescriptions": { - "typeIdentifier": "t_stringliteral_726e51f7b81fce0a68f5f214f445e275313b20b1633f08ce954ee39abf8d7832", - "typeString": "literal_string \"SafeMath: modulo by zero\"" - }, - "value": "SafeMath: modulo by zero" + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" + } } ], "expression": { @@ -3289,25 +4649,25 @@ "typeString": "bool" }, { - "typeIdentifier": "t_stringliteral_726e51f7b81fce0a68f5f214f445e275313b20b1633f08ce954ee39abf8d7832", - "typeString": "literal_string \"SafeMath: modulo by zero\"" + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string memory" } ], - "id": 964, + "id": 11127, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "3454:7:7", + "referencedDeclaration": 12132, + "src": "5237:7:56", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 969, + "id": 11132, "isConstant": false, "isLValue": false, "isPure": false, @@ -3315,15 +4675,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "3454:43:7", + "src": "5237:29:56", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 970, + "id": 11133, "nodeType": "ExpressionStatement", - "src": "3454:43:7" + "src": "5237:29:56" }, { "expression": { @@ -3332,19 +4692,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 973, + "id": 11136, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 971, + "id": 11134, "name": "a", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 957, - "src": "3514:1:7", + "referencedDeclaration": 11118, + "src": "5283:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3354,48 +4714,48 @@ "operator": "%", "rightExpression": { "argumentTypes": null, - "id": 972, + "id": 11135, "name": "b", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 959, - "src": "3518:1:7", + "referencedDeclaration": 11120, + "src": "5287:1:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "src": "3514:5:7", + "src": "5283:5:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 963, - "id": 974, + "functionReturnParameters": 11126, + "id": 11137, "nodeType": "Return", - "src": "3507:12:7" + "src": "5276:12:56" } ] }, - "documentation": "@dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\nReverts when dividing by zero.\n * Counterpart to Solidity's `%` operator. This function uses a `revert`\nopcode (which leaves remaining gas untouched) while Solidity uses an\ninvalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.", - "id": 976, + "documentation": "@dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\nReverts with custom message when dividing by zero.\n * Counterpart to Solidity's `%` operator. This function uses a `revert`\nopcode (which leaves remaining gas untouched) while Solidity uses an\ninvalid opcode to revert (consuming all remaining gas).\n * Requirements:\n- The divisor cannot be zero.\n * _Available since v2.4.0._", + "id": 11139, "implemented": true, "kind": "function", "modifiers": [], "name": "mod", "nodeType": "FunctionDefinition", "parameters": { - "id": 960, + "id": 11123, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 957, + "id": 11118, "name": "a", "nodeType": "VariableDeclaration", - "scope": 976, - "src": "3390:9:7", + "scope": 11139, + "src": "5145:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3403,10 +4763,10 @@ "typeString": "uint256" }, "typeName": { - "id": 956, + "id": 11117, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3390:7:7", + "src": "5145:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3417,11 +4777,11 @@ }, { "constant": false, - "id": 959, + "id": 11120, "name": "b", "nodeType": "VariableDeclaration", - "scope": 976, - "src": "3401:9:7", + "scope": 11139, + "src": "5156:9:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3429,10 +4789,10 @@ "typeString": "uint256" }, "typeName": { - "id": 958, + "id": 11119, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3401:7:7", + "src": "5156:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3440,21 +4800,47 @@ }, "value": null, "visibility": "internal" + }, + { + "constant": false, + "id": 11122, + "name": "errorMessage", + "nodeType": "VariableDeclaration", + "scope": 11139, + "src": "5167:26:56", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_string_memory_ptr", + "typeString": "string" + }, + "typeName": { + "id": 11121, + "name": "string", + "nodeType": "ElementaryTypeName", + "src": "5167:6:56", + "typeDescriptions": { + "typeIdentifier": "t_string_storage_ptr", + "typeString": "string" + } + }, + "value": null, + "visibility": "internal" } ], - "src": "3389:22:7" + "src": "5144:50:56" }, "returnParameters": { - "id": 963, + "id": 11126, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 962, + "id": 11125, "name": "", "nodeType": "VariableDeclaration", - "scope": 976, - "src": "3435:7:7", + "scope": 11139, + "src": "5218:7:56", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -3462,10 +4848,10 @@ "typeString": "uint256" }, "typeName": { - "id": 961, + "id": 11124, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "3435:7:7", + "src": "5218:7:56", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -3475,20 +4861,20 @@ "visibility": "internal" } ], - "src": "3434:9:7" + "src": "5217:9:56" }, - "scope": 977, - "src": "3377:149:7", + "scope": 11140, + "src": "5132:163:56", "stateMutability": "pure", "superFunction": null, "visibility": "internal" } ], - "scope": 978, - "src": "589:2939:7" + "scope": 11141, + "src": "589:4708:56" } ], - "src": "0:3529:7" + "src": "0:5298:56" }, "compiler": { "name": "solc", @@ -3496,7 +4882,7 @@ }, "networks": {}, "schemaVersion": "3.0.16", - "updatedAt": "2019-11-04T18:56:07.486Z", + "updatedAt": "2019-11-07T14:57:54.930Z", "devdoc": { "details": "Wrappers over Solidity's arithmetic operations with added overflow checks. * Arithmetic operations in Solidity wrap on overflow. This can easily result in bugs, because programmers usually assume that an overflow raises an error, which is the standard behavior in high level programming languages. `SafeMath` restores this intuition by reverting the transaction when an operation overflows. * Using this library instead of the unchecked operations eliminates an entire class of bugs, so it's recommended to use it always.", "methods": {} diff --git a/client/src/contracts/UintStorage.json b/client/src/contracts/UintStorage.json new file mode 100644 index 0000000..59353f6 --- /dev/null +++ b/client/src/contracts/UintStorage.json @@ -0,0 +1,800 @@ +{ + "contractName": "UintStorage", + "abi": [ + { + "constant": true, + "inputs": [ + { + "name": "_key", + "type": "bytes32" + } + ], + "name": "getUint", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[{\"name\":\"_key\",\"type\":\"bytes32\"}],\"name\":\"getUint\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol\":\"UintStorage\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol\":{\"keccak256\":\"0x3f74e899243a66d556c0fa81875ab95ed1e3af1909b0281d03fe89590b95121f\",\"urls\":[\"bzzr://ef6ed6edeb1ec124bf1749991346f0708214f7e12c353175d36b491bce45d7a4\"]}},\"version\":1}", + "bytecode": "0x6080604052348015600f57600080fd5b5060b48061001e6000396000f3fe6080604052348015600f57600080fd5b506004361060285760003560e01c8063bd02d0f514602d575b600080fd5b605660048036036020811015604157600080fd5b8101908080359060200190929190505050606c565b6040518082815260200191505060405180910390f35b600080600083815260200190815260200160002054905091905056fea165627a7a72305820c5f85215846b86bf574a701bb744ce646725bb8b9dc22ade967160861329a1960029", + "deployedBytecode": "0x6080604052348015600f57600080fd5b506004361060285760003560e01c8063bd02d0f514602d575b600080fd5b605660048036036020811015604157600080fd5b8101908080359060200190929190505050606c565b6040518082815260200191505060405180910390f35b600080600083815260200190815260200160002054905091905056fea165627a7a72305820c5f85215846b86bf574a701bb744ce646725bb8b9dc22ade967160861329a1960029", + "sourceMap": "25:274:12:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;25:274:12;;;;;;;", + "deployedSourceMap": "25:274:12:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;25:274:12;;;;;;;;;;;;;;;;;;;100:96;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;100:96:12;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;152:7;178:5;:11;184:4;178:11;;;;;;;;;;;;171:18;;100:96;;;:::o", + "source": "pragma solidity ^0.5.0;\n\ncontract UintStorage {\n mapping(bytes32 => uint256) private uints;\n\n function getUint(bytes32 _key) public view returns (uint256) {\n return uints[_key];\n }\n\n function _setUint(bytes32 _key, uint256 _value) internal {\n uints[_key] = _value;\n }\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol", + "exportedSymbols": { + "UintStorage": [ + 1511 + ] + }, + "id": 1512, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1480, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:12" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 1511, + "linearizedBaseContracts": [ + 1511 + ], + "name": "UintStorage", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 1484, + "name": "uints", + "nodeType": "VariableDeclaration", + "scope": 1511, + "src": "52:41:12", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_uint256_$", + "typeString": "mapping(bytes32 => uint256)" + }, + "typeName": { + "id": 1483, + "keyType": { + "id": 1481, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "60:7:12", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "nodeType": "Mapping", + "src": "52:27:12", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_uint256_$", + "typeString": "mapping(bytes32 => uint256)" + }, + "valueType": { + "id": 1482, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "71:7:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + "value": null, + "visibility": "private" + }, + { + "body": { + "id": 1495, + "nodeType": "Block", + "src": "161:35:12", + "statements": [ + { + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 1491, + "name": "uints", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1484, + "src": "178:5:12", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_uint256_$", + "typeString": "mapping(bytes32 => uint256)" + } + }, + "id": 1493, + "indexExpression": { + "argumentTypes": null, + "id": 1492, + "name": "_key", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1486, + "src": "184:4:12", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "178:11:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1490, + "id": 1494, + "nodeType": "Return", + "src": "171:18:12" + } + ] + }, + "documentation": null, + "id": 1496, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUint", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1487, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1486, + "name": "_key", + "nodeType": "VariableDeclaration", + "scope": 1496, + "src": "117:12:12", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1485, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "117:7:12", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "116:14:12" + }, + "returnParameters": { + "id": 1490, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1489, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1496, + "src": "152:7:12", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1488, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "152:7:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "151:9:12" + }, + "scope": 1511, + "src": "100:96:12", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 1509, + "nodeType": "Block", + "src": "259:37:12", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1507, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 1503, + "name": "uints", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1484, + "src": "269:5:12", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_uint256_$", + "typeString": "mapping(bytes32 => uint256)" + } + }, + "id": 1505, + "indexExpression": { + "argumentTypes": null, + "id": 1504, + "name": "_key", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1498, + "src": "275:4:12", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "269:11:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 1506, + "name": "_value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1500, + "src": "283:6:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "269:20:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 1508, + "nodeType": "ExpressionStatement", + "src": "269:20:12" + } + ] + }, + "documentation": null, + "id": 1510, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "_setUint", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1501, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1498, + "name": "_key", + "nodeType": "VariableDeclaration", + "scope": 1510, + "src": "220:12:12", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1497, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "220:7:12", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1500, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 1510, + "src": "234:14:12", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1499, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "234:7:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "219:30:12" + }, + "returnParameters": { + "id": 1502, + "nodeType": "ParameterList", + "parameters": [], + "src": "259:0:12" + }, + "scope": 1511, + "src": "202:94:12", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 1512, + "src": "25:274:12" + } + ], + "src": "0:300:12" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/UintStorage.sol", + "exportedSymbols": { + "UintStorage": [ + 1511 + ] + }, + "id": 1512, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 1480, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:12" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": null, + "fullyImplemented": true, + "id": 1511, + "linearizedBaseContracts": [ + 1511 + ], + "name": "UintStorage", + "nodeType": "ContractDefinition", + "nodes": [ + { + "constant": false, + "id": 1484, + "name": "uints", + "nodeType": "VariableDeclaration", + "scope": 1511, + "src": "52:41:12", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_uint256_$", + "typeString": "mapping(bytes32 => uint256)" + }, + "typeName": { + "id": 1483, + "keyType": { + "id": 1481, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "60:7:12", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "nodeType": "Mapping", + "src": "52:27:12", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_uint256_$", + "typeString": "mapping(bytes32 => uint256)" + }, + "valueType": { + "id": 1482, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "71:7:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + "value": null, + "visibility": "private" + }, + { + "body": { + "id": 1495, + "nodeType": "Block", + "src": "161:35:12", + "statements": [ + { + "expression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 1491, + "name": "uints", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1484, + "src": "178:5:12", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_uint256_$", + "typeString": "mapping(bytes32 => uint256)" + } + }, + "id": 1493, + "indexExpression": { + "argumentTypes": null, + "id": 1492, + "name": "_key", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1486, + "src": "184:4:12", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "178:11:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 1490, + "id": 1494, + "nodeType": "Return", + "src": "171:18:12" + } + ] + }, + "documentation": null, + "id": 1496, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUint", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1487, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1486, + "name": "_key", + "nodeType": "VariableDeclaration", + "scope": 1496, + "src": "117:12:12", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1485, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "117:7:12", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "116:14:12" + }, + "returnParameters": { + "id": 1490, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1489, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 1496, + "src": "152:7:12", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1488, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "152:7:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "151:9:12" + }, + "scope": 1511, + "src": "100:96:12", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 1509, + "nodeType": "Block", + "src": "259:37:12", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 1507, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 1503, + "name": "uints", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1484, + "src": "269:5:12", + "typeDescriptions": { + "typeIdentifier": "t_mapping$_t_bytes32_$_t_uint256_$", + "typeString": "mapping(bytes32 => uint256)" + } + }, + "id": 1505, + "indexExpression": { + "argumentTypes": null, + "id": 1504, + "name": "_key", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1498, + "src": "275:4:12", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "269:11:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 1506, + "name": "_value", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1500, + "src": "283:6:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "269:20:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 1508, + "nodeType": "ExpressionStatement", + "src": "269:20:12" + } + ] + }, + "documentation": null, + "id": 1510, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "_setUint", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 1501, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 1498, + "name": "_key", + "nodeType": "VariableDeclaration", + "scope": 1510, + "src": "220:12:12", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + }, + "typeName": { + "id": 1497, + "name": "bytes32", + "nodeType": "ElementaryTypeName", + "src": "220:7:12", + "typeDescriptions": { + "typeIdentifier": "t_bytes32", + "typeString": "bytes32" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 1500, + "name": "_value", + "nodeType": "VariableDeclaration", + "scope": 1510, + "src": "234:14:12", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 1499, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "234:7:12", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "219:30:12" + }, + "returnParameters": { + "id": 1502, + "nodeType": "ParameterList", + "parameters": [], + "src": "259:0:12" + }, + "scope": 1511, + "src": "202:94:12", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 1512, + "src": "25:274:12" + } + ], + "src": "0:300:12" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.585Z", + "devdoc": { + "methods": {} + }, + "userdoc": { + "methods": {} + } +} \ No newline at end of file diff --git a/client/src/contracts/UniswapExchange.json b/client/src/contracts/UniswapExchange.json index c372072..e174b9a 100644 --- a/client/src/contracts/UniswapExchange.json +++ b/client/src/contracts/UniswapExchange.json @@ -95,22 +95,22 @@ "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":false,\"inputs\":[{\"name\":\"tokens_sold\",\"type\":\"uint256\"},{\"name\":\"min_eth\",\"type\":\"uint256\"},{\"name\":\"deadline\",\"type\":\"uint256\"}],\"name\":\"tokenToEthSwapInput\",\"outputs\":[{\"name\":\"eth_bought\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"eth_bought\",\"type\":\"uint256\"},{\"name\":\"max_tokens\",\"type\":\"uint256\"},{\"name\":\"deadline\",\"type\":\"uint256\"},{\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"tokenToEthTransferOutput\",\"outputs\":[{\"name\":\"tokens_sold\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[],\"name\":\"topUp\",\"outputs\":[],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"},{\"constant\":false,\"inputs\":[{\"name\":\"min_tokens\",\"type\":\"uint256\"},{\"name\":\"deadline\",\"type\":\"uint256\"}],\"name\":\"ethToTokenSwapInput\",\"outputs\":[{\"name\":\"tokens_bought\",\"type\":\"uint256\"}],\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"function\"}],\"devdoc\":{\"methods\":{}},\"userdoc\":{\"methods\":{}}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol\":\"UniswapExchange\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol\":{\"keccak256\":\"0x35ce204d214fb0d5b2e05df0b9e45833a2e8db564c995db36bfc023ff4a3f4f4\",\"urls\":[\"bzzr://5d4c7bc352bb1accf85e754811b6c0acc9bf0be87e852ba011c92b1344cfa463\"]}},\"version\":1}", "bytecode": "0x608060405234801561001057600080fd5b5061036a806100206000396000f3fe60806040526004361061003f5760003560e01c806395e3c50b14610044578063d4e4841d146100a7578063dc29f1de1461012a578063f39b5b9b14610134575b600080fd5b34801561005057600080fd5b506100916004803603606081101561006757600080fd5b81019080803590602001909291908035906020019092919080359060200190929190505050610180565b6040518082815260200191505060405180910390f35b3480156100b357600080fd5b50610114600480360360808110156100ca57600080fd5b81019080803590602001909291908035906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610202565b6040518082815260200191505060405180910390f35b6101326102bb565b005b61016a6004803603604081101561014a57600080fd5b8101908080359060200190929190803590602001909291905050506102bd565b6040518082815260200191505060405180910390f35b6000601482116101f8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f546f6b656e20546f2045746820446561646c696e65204f75740000000000000081525060200191505060405180910390fd5b8290509392505050565b60006014831161027a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f546f6b656e20546f2045746820446561646c696e65204f75740000000000000081525060200191505060405180910390fd5b8173ffffffffffffffffffffffffffffffffffffffff166108fc869081150290604051600060405180830381858888f1935050505050839050949350505050565b565b600060148211610335576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f45746820546f20546f6b656e20446561646c696e65204f75740000000000000081525060200191505060405180910390fd5b8290509291505056fea165627a7a72305820e2fc227114c6efefd87deaf47ff1014bebdec3cb515168852b3bb4e4dd26f3a40029", "deployedBytecode": "0x60806040526004361061003f5760003560e01c806395e3c50b14610044578063d4e4841d146100a7578063dc29f1de1461012a578063f39b5b9b14610134575b600080fd5b34801561005057600080fd5b506100916004803603606081101561006757600080fd5b81019080803590602001909291908035906020019092919080359060200190929190505050610180565b6040518082815260200191505060405180910390f35b3480156100b357600080fd5b50610114600480360360808110156100ca57600080fd5b81019080803590602001909291908035906020019092919080359060200190929190803573ffffffffffffffffffffffffffffffffffffffff169060200190929190505050610202565b6040518082815260200191505060405180910390f35b6101326102bb565b005b61016a6004803603604081101561014a57600080fd5b8101908080359060200190929190803590602001909291905050506102bd565b6040518082815260200191505060405180910390f35b6000601482116101f8576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f546f6b656e20546f2045746820446561646c696e65204f75740000000000000081525060200191505060405180910390fd5b8290509392505050565b60006014831161027a576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f546f6b656e20546f2045746820446561646c696e65204f75740000000000000081525060200191505060405180910390fd5b8173ffffffffffffffffffffffffffffffffffffffff166108fc869081150290604051600060405180830381858888f1935050505050839050949350505050565b565b600060148211610335576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004018080602001828103825260198152602001807f45746820546f20546f6b656e20446561646c696e65204f75740000000000000081525060200191505060405180910390fd5b8290509291505056fea165627a7a72305820e2fc227114c6efefd87deaf47ff1014bebdec3cb515168852b3bb4e4dd26f3a40029", - "sourceMap": "135:1711:6:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;135:1711:6;;;;;;;", - "deployedSourceMap": "135:1711:6:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;698:509;;8:9:-1;5:2;;;30:1;27;20:12;5:2;698:509:6;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;698:509:6;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1211:590;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1211:590:6;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;1211:590:6;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1805:38;;;:::i;:::-;;189:505;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;189:505:6;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;698:509;801:19;1000:2;989:8;:13;981:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1195:7;1188:14;;698:509;;;;;:::o;1211:590::-;1360:20;1560:2;1549:8;:13;1541:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1747:9;:14;;:26;1762:10;1747:26;;;;;;;;;;;;;;;;;;;;;;;;1786:10;1779:17;;1211:590;;;;;;:::o;1805:38::-;:::o;189:505::-;282:22;484:2;473:8;:13;465:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;679:10;672:17;;189:505;;;;:::o", + "sourceMap": "135:1711:7:-;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;135:1711:7;;;;;;;", + "deployedSourceMap": "135:1711:7:-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;698:509;;8:9:-1;5:2;;;30:1;27;20:12;5:2;698:509:7;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;698:509:7;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1211:590;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1211:590:7;;;;;;13:3:-1;8;5:12;2:2;;;30:1;27;20:12;2:2;1211:590:7;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1805:38;;;:::i;:::-;;189:505;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;189:505:7;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;698:509;801:19;1000:2;989:8;:13;981:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1195:7;1188:14;;698:509;;;;;:::o;1211:590::-;1360:20;1560:2;1549:8;:13;1541:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1747:9;:14;;:26;1762:10;1747:26;;;;;;;;;;;;;;;;;;;;;;;;1786:10;1779:17;;1211:590;;;;;;:::o;1805:38::-;:::o;189:505::-;282:22;484:2;473:8;:13;465:51;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;679:10;672:17;;189:505;;;;:::o", "source": "pragma solidity ^0.5.0;\n// Solidity Interface\n// https://github.com/Uniswap/contracts-vyper/blob/master/contracts/uniswap_exchange.vy\n\ncontract UniswapExchange {\n\n // Trade ETH to ERC20\n function ethToTokenSwapInput(uint256 min_tokens, uint256 deadline) external payable returns (uint256 tokens_bought){\n // THIS IS JUST A DEMO TO TEST VARIOUS FUNCTIONS WITHOUT LIVE MIGRATE\n // assert deadline >= block.timestamp and (eth_sold > 0 and min_tokens > 0)\n require(deadline > 20, \"Eth To Token Deadline Out\"); // This is just to make test for a revert\n\n // assert tokens_bought >= min_tokens\n // assert self.token.transfer(recipient, tokens_bought)\n\n return min_tokens;\n }\n\n function tokenToEthSwapInput(uint256 tokens_sold, uint256 min_eth, uint256 deadline) external returns (uint256 eth_bought){\n // THIS IS JUST A DEMO TO TEST VARIOUS FUNCTIONS WITHOUT LIVE MIGRATE\n // assert deadline >= block.timestamp and (eth_sold > 0 and min_tokens > 0)\n require(deadline > 20, \"Token To Eth Deadline Out\"); // This is just to make test for a revert\n\n // assert tokens_bought >= min_tokens\n // assert self.token.transfer(recipient, tokens_bought)\n\n return min_eth;\n }\n\n function tokenToEthTransferOutput(uint256 eth_bought,\n uint256 max_tokens,\n uint256 deadline,\n address payable recipient) external returns (uint256 tokens_sold){\n // THIS IS JUST A DEMO TO TEST VARIOUS FUNCTIONS WITHOUT LIVE MIGRATE\n // assert deadline >= block.timestamp and (eth_sold > 0 and min_tokens > 0)\n require(deadline > 20, \"Token To Eth Deadline Out\"); // This is just to make test for a revert\n\n // assert tokens_bought >= min_tokens\n // assert self.token.transfer(recipient, tokens_bought)\n recipient.send(eth_bought);\n return max_tokens;\n }\n\n function topUp() public payable {\n\n }\n\n}\n", "sourcePath": "/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol", "ast": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol", "exportedSymbols": { "UniswapExchange": [ - 844 + 920 ] }, - "id": 845, + "id": 921, "nodeType": "SourceUnit", "nodes": [ { - "id": 770, + "id": 846, "literals": [ "solidity", "^", @@ -118,7 +118,7 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:6" + "src": "0:23:7" }, { "baseContracts": [], @@ -126,18 +126,18 @@ "contractKind": "contract", "documentation": null, "fullyImplemented": true, - "id": 844, + "id": 920, "linearizedBaseContracts": [ - 844 + 920 ], "name": "UniswapExchange", "nodeType": "ContractDefinition", "nodes": [ { "body": { - "id": 788, + "id": 864, "nodeType": "Block", - "src": "305:389:6", + "src": "305:389:7", "statements": [ { "expression": { @@ -149,19 +149,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 782, + "id": 858, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 780, + "id": 856, "name": "deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 774, - "src": "473:8:6", + "referencedDeclaration": 850, + "src": "473:8:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -172,14 +172,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "3230", - "id": 781, + "id": 857, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "484:2:6", + "src": "484:2:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_20_by_1", @@ -187,7 +187,7 @@ }, "value": "20" }, - "src": "473:13:6", + "src": "473:13:7", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -196,14 +196,14 @@ { "argumentTypes": null, "hexValue": "45746820546f20546f6b656e20446561646c696e65204f7574", - "id": 783, + "id": 859, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "488:27:6", + "src": "488:27:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_3d1d0d33032c0d16d8754d8271ce9ae596e6041a66cbbf03b83858dd4bdb2dbe", @@ -223,21 +223,21 @@ "typeString": "literal_string \"Eth To Token Deadline Out\"" } ], - "id": 779, + "id": 855, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "465:7:6", + "referencedDeclaration": 12132, + "src": "465:7:7", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 784, + "id": 860, "isConstant": false, "isLValue": false, "isPure": false, @@ -245,55 +245,55 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "465:51:6", + "src": "465:51:7", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 785, + "id": 861, "nodeType": "ExpressionStatement", - "src": "465:51:6" + "src": "465:51:7" }, { "expression": { "argumentTypes": null, - "id": 786, + "id": 862, "name": "min_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 772, - "src": "679:10:6", + "referencedDeclaration": 848, + "src": "679:10:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 778, - "id": 787, + "functionReturnParameters": 854, + "id": 863, "nodeType": "Return", - "src": "672:17:6" + "src": "672:17:7" } ] }, "documentation": null, - "id": 789, + "id": 865, "implemented": true, "kind": "function", "modifiers": [], "name": "ethToTokenSwapInput", "nodeType": "FunctionDefinition", "parameters": { - "id": 775, + "id": 851, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 772, + "id": 848, "name": "min_tokens", "nodeType": "VariableDeclaration", - "scope": 789, - "src": "218:18:6", + "scope": 865, + "src": "218:18:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -301,10 +301,10 @@ "typeString": "uint256" }, "typeName": { - "id": 771, + "id": 847, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "218:7:6", + "src": "218:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -315,11 +315,11 @@ }, { "constant": false, - "id": 774, + "id": 850, "name": "deadline", "nodeType": "VariableDeclaration", - "scope": 789, - "src": "238:16:6", + "scope": 865, + "src": "238:16:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -327,10 +327,10 @@ "typeString": "uint256" }, "typeName": { - "id": 773, + "id": 849, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "238:7:6", + "src": "238:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -340,19 +340,19 @@ "visibility": "internal" } ], - "src": "217:38:6" + "src": "217:38:7" }, "returnParameters": { - "id": 778, + "id": 854, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 777, + "id": 853, "name": "tokens_bought", "nodeType": "VariableDeclaration", - "scope": 789, - "src": "282:22:6", + "scope": 865, + "src": "282:22:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -360,10 +360,10 @@ "typeString": "uint256" }, "typeName": { - "id": 776, + "id": 852, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "282:7:6", + "src": "282:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -373,19 +373,19 @@ "visibility": "internal" } ], - "src": "281:24:6" + "src": "281:24:7" }, - "scope": 844, - "src": "189:505:6", + "scope": 920, + "src": "189:505:7", "stateMutability": "payable", "superFunction": null, "visibility": "external" }, { "body": { - "id": 809, + "id": 885, "nodeType": "Block", - "src": "821:386:6", + "src": "821:386:7", "statements": [ { "expression": { @@ -397,19 +397,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 803, + "id": 879, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 801, + "id": 877, "name": "deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 795, - "src": "989:8:6", + "referencedDeclaration": 871, + "src": "989:8:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -420,14 +420,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "3230", - "id": 802, + "id": 878, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "1000:2:6", + "src": "1000:2:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_20_by_1", @@ -435,7 +435,7 @@ }, "value": "20" }, - "src": "989:13:6", + "src": "989:13:7", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -444,14 +444,14 @@ { "argumentTypes": null, "hexValue": "546f6b656e20546f2045746820446561646c696e65204f7574", - "id": 804, + "id": 880, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "1004:27:6", + "src": "1004:27:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_1e8f99c7a3c4a5ee8690405518ad037e0200f0a99289439a48aecc98f9b4efd6", @@ -471,21 +471,21 @@ "typeString": "literal_string \"Token To Eth Deadline Out\"" } ], - "id": 800, + "id": 876, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "981:7:6", + "referencedDeclaration": 12132, + "src": "981:7:7", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 805, + "id": 881, "isConstant": false, "isLValue": false, "isPure": false, @@ -493,55 +493,55 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "981:51:6", + "src": "981:51:7", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 806, + "id": 882, "nodeType": "ExpressionStatement", - "src": "981:51:6" + "src": "981:51:7" }, { "expression": { "argumentTypes": null, - "id": 807, + "id": 883, "name": "min_eth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 793, - "src": "1195:7:6", + "referencedDeclaration": 869, + "src": "1195:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 799, - "id": 808, + "functionReturnParameters": 875, + "id": 884, "nodeType": "Return", - "src": "1188:14:6" + "src": "1188:14:7" } ] }, "documentation": null, - "id": 810, + "id": 886, "implemented": true, "kind": "function", "modifiers": [], "name": "tokenToEthSwapInput", "nodeType": "FunctionDefinition", "parameters": { - "id": 796, + "id": 872, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 791, + "id": 867, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 810, - "src": "727:19:6", + "scope": 886, + "src": "727:19:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -549,10 +549,10 @@ "typeString": "uint256" }, "typeName": { - "id": 790, + "id": 866, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "727:7:6", + "src": "727:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -563,11 +563,11 @@ }, { "constant": false, - "id": 793, + "id": 869, "name": "min_eth", "nodeType": "VariableDeclaration", - "scope": 810, - "src": "748:15:6", + "scope": 886, + "src": "748:15:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -575,10 +575,10 @@ "typeString": "uint256" }, "typeName": { - "id": 792, + "id": 868, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "748:7:6", + "src": "748:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -589,11 +589,11 @@ }, { "constant": false, - "id": 795, + "id": 871, "name": "deadline", "nodeType": "VariableDeclaration", - "scope": 810, - "src": "765:16:6", + "scope": 886, + "src": "765:16:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -601,10 +601,10 @@ "typeString": "uint256" }, "typeName": { - "id": 794, + "id": 870, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "765:7:6", + "src": "765:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -614,19 +614,19 @@ "visibility": "internal" } ], - "src": "726:56:6" + "src": "726:56:7" }, "returnParameters": { - "id": 799, + "id": 875, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 798, + "id": 874, "name": "eth_bought", "nodeType": "VariableDeclaration", - "scope": 810, - "src": "801:19:6", + "scope": 886, + "src": "801:19:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -634,10 +634,10 @@ "typeString": "uint256" }, "typeName": { - "id": 797, + "id": 873, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "801:7:6", + "src": "801:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -647,19 +647,19 @@ "visibility": "internal" } ], - "src": "800:21:6" + "src": "800:21:7" }, - "scope": 844, - "src": "698:509:6", + "scope": 920, + "src": "698:509:7", "stateMutability": "nonpayable", "superFunction": null, "visibility": "external" }, { "body": { - "id": 838, + "id": 914, "nodeType": "Block", - "src": "1381:420:6", + "src": "1381:420:7", "statements": [ { "expression": { @@ -671,19 +671,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 826, + "id": 902, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 824, + "id": 900, "name": "deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 816, - "src": "1549:8:6", + "referencedDeclaration": 892, + "src": "1549:8:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -694,14 +694,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "3230", - "id": 825, + "id": 901, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "1560:2:6", + "src": "1560:2:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_20_by_1", @@ -709,7 +709,7 @@ }, "value": "20" }, - "src": "1549:13:6", + "src": "1549:13:7", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -718,14 +718,14 @@ { "argumentTypes": null, "hexValue": "546f6b656e20546f2045746820446561646c696e65204f7574", - "id": 827, + "id": 903, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "1564:27:6", + "src": "1564:27:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_1e8f99c7a3c4a5ee8690405518ad037e0200f0a99289439a48aecc98f9b4efd6", @@ -745,21 +745,21 @@ "typeString": "literal_string \"Token To Eth Deadline Out\"" } ], - "id": 823, + "id": 899, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "1541:7:6", + "referencedDeclaration": 12132, + "src": "1541:7:7", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 828, + "id": 904, "isConstant": false, "isLValue": false, "isPure": false, @@ -767,15 +767,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1541:51:6", + "src": "1541:51:7", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 829, + "id": 905, "nodeType": "ExpressionStatement", - "src": "1541:51:6" + "src": "1541:51:7" }, { "expression": { @@ -783,12 +783,12 @@ "arguments": [ { "argumentTypes": null, - "id": 833, + "id": 909, "name": "eth_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 812, - "src": "1762:10:6", + "referencedDeclaration": 888, + "src": "1762:10:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -804,18 +804,18 @@ ], "expression": { "argumentTypes": null, - "id": 830, + "id": 906, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 818, - "src": "1747:9:6", + "referencedDeclaration": 894, + "src": "1747:9:7", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "id": 832, + "id": 908, "isConstant": false, "isLValue": false, "isPure": false, @@ -823,13 +823,13 @@ "memberName": "send", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1747:14:6", + "src": "1747:14:7", "typeDescriptions": { "typeIdentifier": "t_function_send_nonpayable$_t_uint256_$returns$_t_bool_$", "typeString": "function (uint256) returns (bool)" } }, - "id": 834, + "id": 910, "isConstant": false, "isLValue": false, "isPure": false, @@ -837,55 +837,55 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1747:26:6", + "src": "1747:26:7", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, - "id": 835, + "id": 911, "nodeType": "ExpressionStatement", - "src": "1747:26:6" + "src": "1747:26:7" }, { "expression": { "argumentTypes": null, - "id": 836, + "id": 912, "name": "max_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 814, - "src": "1786:10:6", + "referencedDeclaration": 890, + "src": "1786:10:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 822, - "id": 837, + "functionReturnParameters": 898, + "id": 913, "nodeType": "Return", - "src": "1779:17:6" + "src": "1779:17:7" } ] }, "documentation": null, - "id": 839, + "id": 915, "implemented": true, "kind": "function", "modifiers": [], "name": "tokenToEthTransferOutput", "nodeType": "FunctionDefinition", "parameters": { - "id": 819, + "id": 895, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 812, + "id": 888, "name": "eth_bought", "nodeType": "VariableDeclaration", - "scope": 839, - "src": "1245:18:6", + "scope": 915, + "src": "1245:18:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -893,10 +893,10 @@ "typeString": "uint256" }, "typeName": { - "id": 811, + "id": 887, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1245:7:6", + "src": "1245:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -907,11 +907,11 @@ }, { "constant": false, - "id": 814, + "id": 890, "name": "max_tokens", "nodeType": "VariableDeclaration", - "scope": 839, - "src": "1269:18:6", + "scope": 915, + "src": "1269:18:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -919,10 +919,10 @@ "typeString": "uint256" }, "typeName": { - "id": 813, + "id": 889, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1269:7:6", + "src": "1269:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -933,11 +933,11 @@ }, { "constant": false, - "id": 816, + "id": 892, "name": "deadline", "nodeType": "VariableDeclaration", - "scope": 839, - "src": "1293:16:6", + "scope": 915, + "src": "1293:16:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -945,10 +945,10 @@ "typeString": "uint256" }, "typeName": { - "id": 815, + "id": 891, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1293:7:6", + "src": "1293:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -959,11 +959,11 @@ }, { "constant": false, - "id": 818, + "id": 894, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 839, - "src": "1315:25:6", + "scope": 915, + "src": "1315:25:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -971,10 +971,10 @@ "typeString": "address payable" }, "typeName": { - "id": 817, + "id": 893, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1315:15:6", + "src": "1315:15:7", "stateMutability": "payable", "typeDescriptions": { "typeIdentifier": "t_address_payable", @@ -985,19 +985,19 @@ "visibility": "internal" } ], - "src": "1244:97:6" + "src": "1244:97:7" }, "returnParameters": { - "id": 822, + "id": 898, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 821, + "id": 897, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 839, - "src": "1360:20:6", + "scope": 915, + "src": "1360:20:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1005,10 +1005,10 @@ "typeString": "uint256" }, "typeName": { - "id": 820, + "id": 896, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1360:7:6", + "src": "1360:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1018,65 +1018,65 @@ "visibility": "internal" } ], - "src": "1359:22:6" + "src": "1359:22:7" }, - "scope": 844, - "src": "1211:590:6", + "scope": 920, + "src": "1211:590:7", "stateMutability": "nonpayable", "superFunction": null, "visibility": "external" }, { "body": { - "id": 842, + "id": 918, "nodeType": "Block", - "src": "1837:6:6", + "src": "1837:6:7", "statements": [] }, "documentation": null, - "id": 843, + "id": 919, "implemented": true, "kind": "function", "modifiers": [], "name": "topUp", "nodeType": "FunctionDefinition", "parameters": { - "id": 840, + "id": 916, "nodeType": "ParameterList", "parameters": [], - "src": "1819:2:6" + "src": "1819:2:7" }, "returnParameters": { - "id": 841, + "id": 917, "nodeType": "ParameterList", "parameters": [], - "src": "1837:0:6" + "src": "1837:0:7" }, - "scope": 844, - "src": "1805:38:6", + "scope": 920, + "src": "1805:38:7", "stateMutability": "payable", "superFunction": null, "visibility": "public" } ], - "scope": 845, - "src": "135:1711:6" + "scope": 921, + "src": "135:1711:7" } ], - "src": "0:1847:6" + "src": "0:1847:7" }, "legacyAST": { "absolutePath": "/Users/jg/Documents/aaveBot/contracts/UniswapExchange.sol", "exportedSymbols": { "UniswapExchange": [ - 844 + 920 ] }, - "id": 845, + "id": 921, "nodeType": "SourceUnit", "nodes": [ { - "id": 770, + "id": 846, "literals": [ "solidity", "^", @@ -1084,7 +1084,7 @@ ".0" ], "nodeType": "PragmaDirective", - "src": "0:23:6" + "src": "0:23:7" }, { "baseContracts": [], @@ -1092,18 +1092,18 @@ "contractKind": "contract", "documentation": null, "fullyImplemented": true, - "id": 844, + "id": 920, "linearizedBaseContracts": [ - 844 + 920 ], "name": "UniswapExchange", "nodeType": "ContractDefinition", "nodes": [ { "body": { - "id": 788, + "id": 864, "nodeType": "Block", - "src": "305:389:6", + "src": "305:389:7", "statements": [ { "expression": { @@ -1115,19 +1115,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 782, + "id": 858, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 780, + "id": 856, "name": "deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 774, - "src": "473:8:6", + "referencedDeclaration": 850, + "src": "473:8:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1138,14 +1138,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "3230", - "id": 781, + "id": 857, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "484:2:6", + "src": "484:2:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_20_by_1", @@ -1153,7 +1153,7 @@ }, "value": "20" }, - "src": "473:13:6", + "src": "473:13:7", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1162,14 +1162,14 @@ { "argumentTypes": null, "hexValue": "45746820546f20546f6b656e20446561646c696e65204f7574", - "id": 783, + "id": 859, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "488:27:6", + "src": "488:27:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_3d1d0d33032c0d16d8754d8271ce9ae596e6041a66cbbf03b83858dd4bdb2dbe", @@ -1189,21 +1189,21 @@ "typeString": "literal_string \"Eth To Token Deadline Out\"" } ], - "id": 779, + "id": 855, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "465:7:6", + "referencedDeclaration": 12132, + "src": "465:7:7", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 784, + "id": 860, "isConstant": false, "isLValue": false, "isPure": false, @@ -1211,55 +1211,55 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "465:51:6", + "src": "465:51:7", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 785, + "id": 861, "nodeType": "ExpressionStatement", - "src": "465:51:6" + "src": "465:51:7" }, { "expression": { "argumentTypes": null, - "id": 786, + "id": 862, "name": "min_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 772, - "src": "679:10:6", + "referencedDeclaration": 848, + "src": "679:10:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 778, - "id": 787, + "functionReturnParameters": 854, + "id": 863, "nodeType": "Return", - "src": "672:17:6" + "src": "672:17:7" } ] }, "documentation": null, - "id": 789, + "id": 865, "implemented": true, "kind": "function", "modifiers": [], "name": "ethToTokenSwapInput", "nodeType": "FunctionDefinition", "parameters": { - "id": 775, + "id": 851, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 772, + "id": 848, "name": "min_tokens", "nodeType": "VariableDeclaration", - "scope": 789, - "src": "218:18:6", + "scope": 865, + "src": "218:18:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1267,10 +1267,10 @@ "typeString": "uint256" }, "typeName": { - "id": 771, + "id": 847, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "218:7:6", + "src": "218:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1281,11 +1281,11 @@ }, { "constant": false, - "id": 774, + "id": 850, "name": "deadline", "nodeType": "VariableDeclaration", - "scope": 789, - "src": "238:16:6", + "scope": 865, + "src": "238:16:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1293,10 +1293,10 @@ "typeString": "uint256" }, "typeName": { - "id": 773, + "id": 849, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "238:7:6", + "src": "238:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1306,19 +1306,19 @@ "visibility": "internal" } ], - "src": "217:38:6" + "src": "217:38:7" }, "returnParameters": { - "id": 778, + "id": 854, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 777, + "id": 853, "name": "tokens_bought", "nodeType": "VariableDeclaration", - "scope": 789, - "src": "282:22:6", + "scope": 865, + "src": "282:22:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1326,10 +1326,10 @@ "typeString": "uint256" }, "typeName": { - "id": 776, + "id": 852, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "282:7:6", + "src": "282:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1339,19 +1339,19 @@ "visibility": "internal" } ], - "src": "281:24:6" + "src": "281:24:7" }, - "scope": 844, - "src": "189:505:6", + "scope": 920, + "src": "189:505:7", "stateMutability": "payable", "superFunction": null, "visibility": "external" }, { "body": { - "id": 809, + "id": 885, "nodeType": "Block", - "src": "821:386:6", + "src": "821:386:7", "statements": [ { "expression": { @@ -1363,19 +1363,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 803, + "id": 879, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 801, + "id": 877, "name": "deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 795, - "src": "989:8:6", + "referencedDeclaration": 871, + "src": "989:8:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1386,14 +1386,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "3230", - "id": 802, + "id": 878, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "1000:2:6", + "src": "1000:2:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_20_by_1", @@ -1401,7 +1401,7 @@ }, "value": "20" }, - "src": "989:13:6", + "src": "989:13:7", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1410,14 +1410,14 @@ { "argumentTypes": null, "hexValue": "546f6b656e20546f2045746820446561646c696e65204f7574", - "id": 804, + "id": 880, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "1004:27:6", + "src": "1004:27:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_1e8f99c7a3c4a5ee8690405518ad037e0200f0a99289439a48aecc98f9b4efd6", @@ -1437,21 +1437,21 @@ "typeString": "literal_string \"Token To Eth Deadline Out\"" } ], - "id": 800, + "id": 876, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "981:7:6", + "referencedDeclaration": 12132, + "src": "981:7:7", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 805, + "id": 881, "isConstant": false, "isLValue": false, "isPure": false, @@ -1459,55 +1459,55 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "981:51:6", + "src": "981:51:7", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 806, + "id": 882, "nodeType": "ExpressionStatement", - "src": "981:51:6" + "src": "981:51:7" }, { "expression": { "argumentTypes": null, - "id": 807, + "id": 883, "name": "min_eth", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 793, - "src": "1195:7:6", + "referencedDeclaration": 869, + "src": "1195:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 799, - "id": 808, + "functionReturnParameters": 875, + "id": 884, "nodeType": "Return", - "src": "1188:14:6" + "src": "1188:14:7" } ] }, "documentation": null, - "id": 810, + "id": 886, "implemented": true, "kind": "function", "modifiers": [], "name": "tokenToEthSwapInput", "nodeType": "FunctionDefinition", "parameters": { - "id": 796, + "id": 872, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 791, + "id": 867, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 810, - "src": "727:19:6", + "scope": 886, + "src": "727:19:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1515,10 +1515,10 @@ "typeString": "uint256" }, "typeName": { - "id": 790, + "id": 866, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "727:7:6", + "src": "727:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1529,11 +1529,11 @@ }, { "constant": false, - "id": 793, + "id": 869, "name": "min_eth", "nodeType": "VariableDeclaration", - "scope": 810, - "src": "748:15:6", + "scope": 886, + "src": "748:15:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1541,10 +1541,10 @@ "typeString": "uint256" }, "typeName": { - "id": 792, + "id": 868, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "748:7:6", + "src": "748:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1555,11 +1555,11 @@ }, { "constant": false, - "id": 795, + "id": 871, "name": "deadline", "nodeType": "VariableDeclaration", - "scope": 810, - "src": "765:16:6", + "scope": 886, + "src": "765:16:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1567,10 +1567,10 @@ "typeString": "uint256" }, "typeName": { - "id": 794, + "id": 870, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "765:7:6", + "src": "765:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1580,19 +1580,19 @@ "visibility": "internal" } ], - "src": "726:56:6" + "src": "726:56:7" }, "returnParameters": { - "id": 799, + "id": 875, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 798, + "id": 874, "name": "eth_bought", "nodeType": "VariableDeclaration", - "scope": 810, - "src": "801:19:6", + "scope": 886, + "src": "801:19:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1600,10 +1600,10 @@ "typeString": "uint256" }, "typeName": { - "id": 797, + "id": 873, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "801:7:6", + "src": "801:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1613,19 +1613,19 @@ "visibility": "internal" } ], - "src": "800:21:6" + "src": "800:21:7" }, - "scope": 844, - "src": "698:509:6", + "scope": 920, + "src": "698:509:7", "stateMutability": "nonpayable", "superFunction": null, "visibility": "external" }, { "body": { - "id": 838, + "id": 914, "nodeType": "Block", - "src": "1381:420:6", + "src": "1381:420:7", "statements": [ { "expression": { @@ -1637,19 +1637,19 @@ "typeIdentifier": "t_uint256", "typeString": "uint256" }, - "id": 826, + "id": 902, "isConstant": false, "isLValue": false, "isPure": false, "lValueRequested": false, "leftExpression": { "argumentTypes": null, - "id": 824, + "id": 900, "name": "deadline", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 816, - "src": "1549:8:6", + "referencedDeclaration": 892, + "src": "1549:8:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1660,14 +1660,14 @@ "rightExpression": { "argumentTypes": null, "hexValue": "3230", - "id": 825, + "id": 901, "isConstant": false, "isLValue": false, "isPure": true, "kind": "number", "lValueRequested": false, "nodeType": "Literal", - "src": "1560:2:6", + "src": "1560:2:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_rational_20_by_1", @@ -1675,7 +1675,7 @@ }, "value": "20" }, - "src": "1549:13:6", + "src": "1549:13:7", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" @@ -1684,14 +1684,14 @@ { "argumentTypes": null, "hexValue": "546f6b656e20546f2045746820446561646c696e65204f7574", - "id": 827, + "id": 903, "isConstant": false, "isLValue": false, "isPure": true, "kind": "string", "lValueRequested": false, "nodeType": "Literal", - "src": "1564:27:6", + "src": "1564:27:7", "subdenomination": null, "typeDescriptions": { "typeIdentifier": "t_stringliteral_1e8f99c7a3c4a5ee8690405518ad037e0200f0a99289439a48aecc98f9b4efd6", @@ -1711,21 +1711,21 @@ "typeString": "literal_string \"Token To Eth Deadline Out\"" } ], - "id": 823, + "id": 899, "name": "require", "nodeType": "Identifier", "overloadedDeclarations": [ - 1461, - 1462 + 12131, + 12132 ], - "referencedDeclaration": 1462, - "src": "1541:7:6", + "referencedDeclaration": 12132, + "src": "1541:7:7", "typeDescriptions": { "typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$", "typeString": "function (bool,string memory) pure" } }, - "id": 828, + "id": 904, "isConstant": false, "isLValue": false, "isPure": false, @@ -1733,15 +1733,15 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1541:51:6", + "src": "1541:51:7", "typeDescriptions": { "typeIdentifier": "t_tuple$__$", "typeString": "tuple()" } }, - "id": 829, + "id": 905, "nodeType": "ExpressionStatement", - "src": "1541:51:6" + "src": "1541:51:7" }, { "expression": { @@ -1749,12 +1749,12 @@ "arguments": [ { "argumentTypes": null, - "id": 833, + "id": 909, "name": "eth_bought", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 812, - "src": "1762:10:6", + "referencedDeclaration": 888, + "src": "1762:10:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1770,18 +1770,18 @@ ], "expression": { "argumentTypes": null, - "id": 830, + "id": 906, "name": "recipient", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 818, - "src": "1747:9:6", + "referencedDeclaration": 894, + "src": "1747:9:7", "typeDescriptions": { "typeIdentifier": "t_address_payable", "typeString": "address payable" } }, - "id": 832, + "id": 908, "isConstant": false, "isLValue": false, "isPure": false, @@ -1789,13 +1789,13 @@ "memberName": "send", "nodeType": "MemberAccess", "referencedDeclaration": null, - "src": "1747:14:6", + "src": "1747:14:7", "typeDescriptions": { "typeIdentifier": "t_function_send_nonpayable$_t_uint256_$returns$_t_bool_$", "typeString": "function (uint256) returns (bool)" } }, - "id": 834, + "id": 910, "isConstant": false, "isLValue": false, "isPure": false, @@ -1803,55 +1803,55 @@ "lValueRequested": false, "names": [], "nodeType": "FunctionCall", - "src": "1747:26:6", + "src": "1747:26:7", "typeDescriptions": { "typeIdentifier": "t_bool", "typeString": "bool" } }, - "id": 835, + "id": 911, "nodeType": "ExpressionStatement", - "src": "1747:26:6" + "src": "1747:26:7" }, { "expression": { "argumentTypes": null, - "id": 836, + "id": 912, "name": "max_tokens", "nodeType": "Identifier", "overloadedDeclarations": [], - "referencedDeclaration": 814, - "src": "1786:10:6", + "referencedDeclaration": 890, + "src": "1786:10:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" } }, - "functionReturnParameters": 822, - "id": 837, + "functionReturnParameters": 898, + "id": 913, "nodeType": "Return", - "src": "1779:17:6" + "src": "1779:17:7" } ] }, "documentation": null, - "id": 839, + "id": 915, "implemented": true, "kind": "function", "modifiers": [], "name": "tokenToEthTransferOutput", "nodeType": "FunctionDefinition", "parameters": { - "id": 819, + "id": 895, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 812, + "id": 888, "name": "eth_bought", "nodeType": "VariableDeclaration", - "scope": 839, - "src": "1245:18:6", + "scope": 915, + "src": "1245:18:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1859,10 +1859,10 @@ "typeString": "uint256" }, "typeName": { - "id": 811, + "id": 887, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1245:7:6", + "src": "1245:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1873,11 +1873,11 @@ }, { "constant": false, - "id": 814, + "id": 890, "name": "max_tokens", "nodeType": "VariableDeclaration", - "scope": 839, - "src": "1269:18:6", + "scope": 915, + "src": "1269:18:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1885,10 +1885,10 @@ "typeString": "uint256" }, "typeName": { - "id": 813, + "id": 889, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1269:7:6", + "src": "1269:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1899,11 +1899,11 @@ }, { "constant": false, - "id": 816, + "id": 892, "name": "deadline", "nodeType": "VariableDeclaration", - "scope": 839, - "src": "1293:16:6", + "scope": 915, + "src": "1293:16:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1911,10 +1911,10 @@ "typeString": "uint256" }, "typeName": { - "id": 815, + "id": 891, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1293:7:6", + "src": "1293:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1925,11 +1925,11 @@ }, { "constant": false, - "id": 818, + "id": 894, "name": "recipient", "nodeType": "VariableDeclaration", - "scope": 839, - "src": "1315:25:6", + "scope": 915, + "src": "1315:25:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1937,10 +1937,10 @@ "typeString": "address payable" }, "typeName": { - "id": 817, + "id": 893, "name": "address", "nodeType": "ElementaryTypeName", - "src": "1315:15:6", + "src": "1315:15:7", "stateMutability": "payable", "typeDescriptions": { "typeIdentifier": "t_address_payable", @@ -1951,19 +1951,19 @@ "visibility": "internal" } ], - "src": "1244:97:6" + "src": "1244:97:7" }, "returnParameters": { - "id": 822, + "id": 898, "nodeType": "ParameterList", "parameters": [ { "constant": false, - "id": 821, + "id": 897, "name": "tokens_sold", "nodeType": "VariableDeclaration", - "scope": 839, - "src": "1360:20:6", + "scope": 915, + "src": "1360:20:7", "stateVariable": false, "storageLocation": "default", "typeDescriptions": { @@ -1971,10 +1971,10 @@ "typeString": "uint256" }, "typeName": { - "id": 820, + "id": 896, "name": "uint256", "nodeType": "ElementaryTypeName", - "src": "1360:7:6", + "src": "1360:7:7", "typeDescriptions": { "typeIdentifier": "t_uint256", "typeString": "uint256" @@ -1984,52 +1984,52 @@ "visibility": "internal" } ], - "src": "1359:22:6" + "src": "1359:22:7" }, - "scope": 844, - "src": "1211:590:6", + "scope": 920, + "src": "1211:590:7", "stateMutability": "nonpayable", "superFunction": null, "visibility": "external" }, { "body": { - "id": 842, + "id": 918, "nodeType": "Block", - "src": "1837:6:6", + "src": "1837:6:7", "statements": [] }, "documentation": null, - "id": 843, + "id": 919, "implemented": true, "kind": "function", "modifiers": [], "name": "topUp", "nodeType": "FunctionDefinition", "parameters": { - "id": 840, + "id": 916, "nodeType": "ParameterList", "parameters": [], - "src": "1819:2:6" + "src": "1819:2:7" }, "returnParameters": { - "id": 841, + "id": 917, "nodeType": "ParameterList", "parameters": [], - "src": "1837:0:6" + "src": "1837:0:7" }, - "scope": 844, - "src": "1805:38:6", + "scope": 920, + "src": "1805:38:7", "stateMutability": "payable", "superFunction": null, "visibility": "public" } ], - "scope": 845, - "src": "135:1711:6" + "scope": 921, + "src": "135:1711:7" } ], - "src": "0:1847:6" + "src": "0:1847:7" }, "compiler": { "name": "solc", @@ -2037,7 +2037,7 @@ }, "networks": {}, "schemaVersion": "3.0.16", - "updatedAt": "2019-11-04T18:56:07.484Z", + "updatedAt": "2019-11-07T15:21:05.384Z", "devdoc": { "methods": {} }, diff --git a/client/src/contracts/WadRayMath.json b/client/src/contracts/WadRayMath.json new file mode 100644 index 0000000..98daf98 --- /dev/null +++ b/client/src/contracts/WadRayMath.json @@ -0,0 +1,4656 @@ +{ + "contractName": "WadRayMath", + "abi": [], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[],\"devdoc\":{\"author\":\"Aave\",\"details\":\"Provides mul and div function for wads (decimal numbers with 18 digits precision) and rays (decimals with 27 digits)\",\"methods\":{},\"title\":\"WadRayMath library\"},\"userdoc\":{\"methods\":{},\"notice\":\"****************\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":\"WadRayMath\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]}},\"version\":1}", + "bytecode": "0x604c6023600b82828239805160001a607314601657fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea165627a7a723058202b7c888ae0ba59bab1b07cbb70f3dd047838f76bccb4c184f528d402d69e16c90029", + "deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600080fdfea165627a7a723058202b7c888ae0ba59bab1b07cbb70f3dd047838f76bccb4c184f528d402d69e16c90029", + "sourceMap": "272:1420:29:-;;132:2:-1;166:7;155:9;146:7;137:37;255:7;249:14;246:1;241:23;235:4;232:33;222:2;;269:9;222:2;293:9;290:1;283:20;323:4;314:7;306:22;347:7;338;331:24", + "deployedSourceMap": "272:1420:29:-;;;;;;;;", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/math/SafeMath.sol\";\n\n/******************\n@title WadRayMath library\n@author Aave\n@dev Provides mul and div function for wads (decimal numbers with 18 digits precision) and rays (decimals with 27 digits)\n */\n\nlibrary WadRayMath {\n using SafeMath for uint256;\n\n uint256 internal constant WAD = 1e18;\n uint256 internal constant halfWAD = WAD / 2;\n\n uint256 internal constant RAY = 1e27;\n uint256 internal constant halfRAY = RAY / 2;\n\n uint256 constant WAD_RAY_RATIO = 1e9;\n\n function ray() internal pure returns (uint256) {\n return RAY;\n }\n function wad() internal pure returns (uint256) {\n return WAD;\n }\n\n function halfRay() internal pure returns (uint256) {\n return halfRAY;\n }\n\n function halfWad() internal pure returns (uint256) {\n return halfWAD;\n }\n\n\n function wadMul(uint256 a, uint256 b) internal pure returns (uint256) {\n return halfWAD.add(a.mul(b)).div(WAD);\n }\n\n function wadDiv(uint256 a, uint256 b) internal pure returns (uint256) {\n uint256 halfB = b / 2;\n\n return halfB.add(a.mul(WAD)).div(b);\n }\n\n function rayMul(uint256 a, uint256 b) internal pure returns (uint256) {\n return halfRAY.add(a.mul(b)).div(RAY);\n }\n\n function rayDiv(uint256 a, uint256 b) internal pure returns (uint256) {\n uint256 halfB = b / 2;\n\n return halfB.add(a.mul(RAY)).div(b);\n }\n\n function rayToWad(uint256 a) internal pure returns (uint256) {\n return a.div(WAD_RAY_RATIO);\n }\n\n function wadToRay(uint256 a) internal pure returns (uint256) {\n return a.mul(WAD_RAY_RATIO);\n }\n\n}\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "exportedSymbols": { + "WadRayMath": [ + 9174 + ] + }, + "id": 9175, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 8996, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:29" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 8997, + "nodeType": "ImportDirective", + "scope": 9175, + "sourceUnit": 11141, + "src": "25:59:29", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "library", + "documentation": "****************\n@title WadRayMath library\n@author Aave\n@dev Provides mul and div function for wads (decimal numbers with 18 digits precision) and rays (decimals with 27 digits)", + "fullyImplemented": true, + "id": 9174, + "linearizedBaseContracts": [ + 9174 + ], + "name": "WadRayMath", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 9000, + "libraryName": { + "contractScope": null, + "id": 8998, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "303:8:29", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "297:27:29", + "typeName": { + "id": 8999, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "316:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "constant": true, + "id": 9003, + "name": "WAD", + "nodeType": "VariableDeclaration", + "scope": 9174, + "src": "330:36:29", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9001, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "330:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "31653138", + "id": 9002, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "362:4:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000_by_1", + "typeString": "int_const 1000000000000000000" + }, + "value": "1e18" + }, + "visibility": "internal" + }, + { + "constant": true, + "id": 9008, + "name": "halfWAD", + "nodeType": "VariableDeclaration", + "scope": 9174, + "src": "372:43:29", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9004, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "372:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9007, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9005, + "name": "WAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9003, + "src": "408:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "hexValue": "32", + "id": 9006, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "414:1:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_2_by_1", + "typeString": "int_const 2" + }, + "value": "2" + }, + "src": "408:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": true, + "id": 9011, + "name": "RAY", + "nodeType": "VariableDeclaration", + "scope": 9174, + "src": "422:36:29", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9009, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "422:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "31653237", + "id": 9010, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "454:4:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000000000000_by_1", + "typeString": "int_const 1000000000000000000000000000" + }, + "value": "1e27" + }, + "visibility": "internal" + }, + { + "constant": true, + "id": 9016, + "name": "halfRAY", + "nodeType": "VariableDeclaration", + "scope": 9174, + "src": "464:43:29", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9012, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "464:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9015, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9013, + "name": "RAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9011, + "src": "500:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "hexValue": "32", + "id": 9014, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "506:1:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_2_by_1", + "typeString": "int_const 2" + }, + "value": "2" + }, + "src": "500:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": true, + "id": 9019, + "name": "WAD_RAY_RATIO", + "nodeType": "VariableDeclaration", + "scope": 9174, + "src": "514:36:29", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9017, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "514:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "316539", + "id": 9018, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "547:3:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000_by_1", + "typeString": "int_const 1000000000" + }, + "value": "1e9" + }, + "visibility": "internal" + }, + { + "body": { + "id": 9026, + "nodeType": "Block", + "src": "604:27:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9024, + "name": "RAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9011, + "src": "621:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9023, + "id": 9025, + "nodeType": "Return", + "src": "614:10:29" + } + ] + }, + "documentation": null, + "id": 9027, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "ray", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9020, + "nodeType": "ParameterList", + "parameters": [], + "src": "569:2:29" + }, + "returnParameters": { + "id": 9023, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9022, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9027, + "src": "595:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9021, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "595:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "594:9:29" + }, + "scope": 9174, + "src": "557:74:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9034, + "nodeType": "Block", + "src": "683:27:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9032, + "name": "WAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9003, + "src": "700:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9031, + "id": 9033, + "nodeType": "Return", + "src": "693:10:29" + } + ] + }, + "documentation": null, + "id": 9035, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "wad", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9028, + "nodeType": "ParameterList", + "parameters": [], + "src": "648:2:29" + }, + "returnParameters": { + "id": 9031, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9030, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9035, + "src": "674:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9029, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "674:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "673:9:29" + }, + "scope": 9174, + "src": "636:74:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9042, + "nodeType": "Block", + "src": "767:31:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9040, + "name": "halfRAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9016, + "src": "784:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9039, + "id": 9041, + "nodeType": "Return", + "src": "777:14:29" + } + ] + }, + "documentation": null, + "id": 9043, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "halfRay", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9036, + "nodeType": "ParameterList", + "parameters": [], + "src": "732:2:29" + }, + "returnParameters": { + "id": 9039, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9038, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9043, + "src": "758:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9037, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "758:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "757:9:29" + }, + "scope": 9174, + "src": "716:82:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9050, + "nodeType": "Block", + "src": "855:31:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9048, + "name": "halfWAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9008, + "src": "872:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9047, + "id": 9049, + "nodeType": "Return", + "src": "865:14:29" + } + ] + }, + "documentation": null, + "id": 9051, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "halfWad", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9044, + "nodeType": "ParameterList", + "parameters": [], + "src": "820:2:29" + }, + "returnParameters": { + "id": 9047, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9046, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9051, + "src": "846:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9045, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "846:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "845:9:29" + }, + "scope": 9174, + "src": "804:82:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9071, + "nodeType": "Block", + "src": "963:54:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9068, + "name": "WAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9003, + "src": "1006:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9064, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9055, + "src": "998:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9062, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9053, + "src": "992:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9063, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "992:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "992:8:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9060, + "name": "halfWAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9008, + "src": "980:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9061, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "980:11:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9066, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "980:21:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9067, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "980:25:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9069, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "980:30:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9059, + "id": 9070, + "nodeType": "Return", + "src": "973:37:29" + } + ] + }, + "documentation": null, + "id": 9072, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "wadMul", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9056, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9053, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9072, + "src": "909:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9052, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "909:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9055, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 9072, + "src": "920:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9054, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "920:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "908:22:29" + }, + "returnParameters": { + "id": 9059, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9058, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9072, + "src": "954:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9057, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "954:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "953:9:29" + }, + "scope": 9174, + "src": "893:124:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9098, + "nodeType": "Block", + "src": "1093:84:29", + "statements": [ + { + "assignments": [ + 9082 + ], + "declarations": [ + { + "constant": false, + "id": 9082, + "name": "halfB", + "nodeType": "VariableDeclaration", + "scope": 9098, + "src": "1103:13:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9081, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1103:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9086, + "initialValue": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9085, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9083, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9076, + "src": "1119:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "hexValue": "32", + "id": 9084, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1123:1:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_2_by_1", + "typeString": "int_const 2" + }, + "value": "2" + }, + "src": "1119:5:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1103:21:29" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9095, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9076, + "src": "1168:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9091, + "name": "WAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9003, + "src": "1158:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9089, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9074, + "src": "1152:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9090, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "1152:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9092, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1152:10:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9087, + "name": "halfB", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9082, + "src": "1142:5:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9088, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1142:9:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9093, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1142:21:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9094, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "1142:25:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9096, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1142:28:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9080, + "id": 9097, + "nodeType": "Return", + "src": "1135:35:29" + } + ] + }, + "documentation": null, + "id": 9099, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "wadDiv", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9077, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9074, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9099, + "src": "1039:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9073, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1039:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9076, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 9099, + "src": "1050:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9075, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1050:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1038:22:29" + }, + "returnParameters": { + "id": 9080, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9079, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9099, + "src": "1084:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9078, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1084:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1083:9:29" + }, + "scope": 9174, + "src": "1023:154:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9119, + "nodeType": "Block", + "src": "1253:54:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9116, + "name": "RAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9011, + "src": "1296:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9112, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9103, + "src": "1288:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9110, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9101, + "src": "1282:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9111, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "1282:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9113, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1282:8:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9108, + "name": "halfRAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9016, + "src": "1270:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9109, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1270:11:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9114, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1270:21:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9115, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "1270:25:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9117, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1270:30:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9107, + "id": 9118, + "nodeType": "Return", + "src": "1263:37:29" + } + ] + }, + "documentation": null, + "id": 9120, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "rayMul", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9104, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9101, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9120, + "src": "1199:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9100, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1199:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9103, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 9120, + "src": "1210:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9102, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1210:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1198:22:29" + }, + "returnParameters": { + "id": 9107, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9106, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9120, + "src": "1244:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9105, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1244:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1243:9:29" + }, + "scope": 9174, + "src": "1183:124:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9146, + "nodeType": "Block", + "src": "1383:84:29", + "statements": [ + { + "assignments": [ + 9130 + ], + "declarations": [ + { + "constant": false, + "id": 9130, + "name": "halfB", + "nodeType": "VariableDeclaration", + "scope": 9146, + "src": "1393:13:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9129, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1393:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9134, + "initialValue": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9133, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9131, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9124, + "src": "1409:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "hexValue": "32", + "id": 9132, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1413:1:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_2_by_1", + "typeString": "int_const 2" + }, + "value": "2" + }, + "src": "1409:5:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1393:21:29" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9143, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9124, + "src": "1458:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9139, + "name": "RAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9011, + "src": "1448:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9137, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9122, + "src": "1442:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9138, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "1442:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9140, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1442:10:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9135, + "name": "halfB", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9130, + "src": "1432:5:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9136, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1432:9:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9141, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1432:21:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9142, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "1432:25:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9144, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1432:28:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9128, + "id": 9145, + "nodeType": "Return", + "src": "1425:35:29" + } + ] + }, + "documentation": null, + "id": 9147, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "rayDiv", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9125, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9122, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9147, + "src": "1329:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9121, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1329:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9124, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 9147, + "src": "1340:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9123, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1340:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1328:22:29" + }, + "returnParameters": { + "id": 9128, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9127, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9147, + "src": "1374:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9126, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1374:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1373:9:29" + }, + "scope": 9174, + "src": "1313:154:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9159, + "nodeType": "Block", + "src": "1534:44:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9156, + "name": "WAD_RAY_RATIO", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9019, + "src": "1557:13:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9154, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9149, + "src": "1551:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9155, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "1551:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9157, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1551:20:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9153, + "id": 9158, + "nodeType": "Return", + "src": "1544:27:29" + } + ] + }, + "documentation": null, + "id": 9160, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "rayToWad", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9150, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9149, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9160, + "src": "1491:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9148, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1491:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1490:11:29" + }, + "returnParameters": { + "id": 9153, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9152, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9160, + "src": "1525:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9151, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1525:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1524:9:29" + }, + "scope": 9174, + "src": "1473:105:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9172, + "nodeType": "Block", + "src": "1645:44:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9169, + "name": "WAD_RAY_RATIO", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9019, + "src": "1668:13:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9167, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9162, + "src": "1662:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9168, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "1662:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9170, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1662:20:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9166, + "id": 9171, + "nodeType": "Return", + "src": "1655:27:29" + } + ] + }, + "documentation": null, + "id": 9173, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "wadToRay", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9163, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9162, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9173, + "src": "1602:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9161, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1602:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1601:11:29" + }, + "returnParameters": { + "id": 9166, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9165, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9173, + "src": "1636:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9164, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1636:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1635:9:29" + }, + "scope": 9174, + "src": "1584:105:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 9175, + "src": "272:1420:29" + } + ], + "src": "0:1693:29" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol", + "exportedSymbols": { + "WadRayMath": [ + 9174 + ] + }, + "id": 9175, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 8996, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:29" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "file": "openzeppelin-solidity/contracts/math/SafeMath.sol", + "id": 8997, + "nodeType": "ImportDirective", + "scope": 9175, + "sourceUnit": 11141, + "src": "25:59:29", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "library", + "documentation": "****************\n@title WadRayMath library\n@author Aave\n@dev Provides mul and div function for wads (decimal numbers with 18 digits precision) and rays (decimals with 27 digits)", + "fullyImplemented": true, + "id": 9174, + "linearizedBaseContracts": [ + 9174 + ], + "name": "WadRayMath", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 9000, + "libraryName": { + "contractScope": null, + "id": 8998, + "name": "SafeMath", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 11140, + "src": "303:8:29", + "typeDescriptions": { + "typeIdentifier": "t_contract$_SafeMath_$11140", + "typeString": "library SafeMath" + } + }, + "nodeType": "UsingForDirective", + "src": "297:27:29", + "typeName": { + "id": 8999, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "316:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + }, + { + "constant": true, + "id": 9003, + "name": "WAD", + "nodeType": "VariableDeclaration", + "scope": 9174, + "src": "330:36:29", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9001, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "330:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "31653138", + "id": 9002, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "362:4:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000_by_1", + "typeString": "int_const 1000000000000000000" + }, + "value": "1e18" + }, + "visibility": "internal" + }, + { + "constant": true, + "id": 9008, + "name": "halfWAD", + "nodeType": "VariableDeclaration", + "scope": 9174, + "src": "372:43:29", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9004, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "372:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9007, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9005, + "name": "WAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9003, + "src": "408:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "hexValue": "32", + "id": 9006, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "414:1:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_2_by_1", + "typeString": "int_const 2" + }, + "value": "2" + }, + "src": "408:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": true, + "id": 9011, + "name": "RAY", + "nodeType": "VariableDeclaration", + "scope": 9174, + "src": "422:36:29", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9009, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "422:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "31653237", + "id": 9010, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "454:4:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000000000000000000000_by_1", + "typeString": "int_const 1000000000000000000000000000" + }, + "value": "1e27" + }, + "visibility": "internal" + }, + { + "constant": true, + "id": 9016, + "name": "halfRAY", + "nodeType": "VariableDeclaration", + "scope": 9174, + "src": "464:43:29", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9012, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "464:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9015, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9013, + "name": "RAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9011, + "src": "500:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "hexValue": "32", + "id": 9014, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "506:1:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_2_by_1", + "typeString": "int_const 2" + }, + "value": "2" + }, + "src": "500:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "visibility": "internal" + }, + { + "constant": true, + "id": 9019, + "name": "WAD_RAY_RATIO", + "nodeType": "VariableDeclaration", + "scope": 9174, + "src": "514:36:29", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9017, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "514:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": { + "argumentTypes": null, + "hexValue": "316539", + "id": 9018, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "547:3:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_1000000000_by_1", + "typeString": "int_const 1000000000" + }, + "value": "1e9" + }, + "visibility": "internal" + }, + { + "body": { + "id": 9026, + "nodeType": "Block", + "src": "604:27:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9024, + "name": "RAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9011, + "src": "621:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9023, + "id": 9025, + "nodeType": "Return", + "src": "614:10:29" + } + ] + }, + "documentation": null, + "id": 9027, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "ray", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9020, + "nodeType": "ParameterList", + "parameters": [], + "src": "569:2:29" + }, + "returnParameters": { + "id": 9023, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9022, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9027, + "src": "595:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9021, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "595:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "594:9:29" + }, + "scope": 9174, + "src": "557:74:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9034, + "nodeType": "Block", + "src": "683:27:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9032, + "name": "WAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9003, + "src": "700:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9031, + "id": 9033, + "nodeType": "Return", + "src": "693:10:29" + } + ] + }, + "documentation": null, + "id": 9035, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "wad", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9028, + "nodeType": "ParameterList", + "parameters": [], + "src": "648:2:29" + }, + "returnParameters": { + "id": 9031, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9030, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9035, + "src": "674:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9029, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "674:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "673:9:29" + }, + "scope": 9174, + "src": "636:74:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9042, + "nodeType": "Block", + "src": "767:31:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9040, + "name": "halfRAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9016, + "src": "784:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9039, + "id": 9041, + "nodeType": "Return", + "src": "777:14:29" + } + ] + }, + "documentation": null, + "id": 9043, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "halfRay", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9036, + "nodeType": "ParameterList", + "parameters": [], + "src": "732:2:29" + }, + "returnParameters": { + "id": 9039, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9038, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9043, + "src": "758:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9037, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "758:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "757:9:29" + }, + "scope": 9174, + "src": "716:82:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9050, + "nodeType": "Block", + "src": "855:31:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9048, + "name": "halfWAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9008, + "src": "872:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9047, + "id": 9049, + "nodeType": "Return", + "src": "865:14:29" + } + ] + }, + "documentation": null, + "id": 9051, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "halfWad", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9044, + "nodeType": "ParameterList", + "parameters": [], + "src": "820:2:29" + }, + "returnParameters": { + "id": 9047, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9046, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9051, + "src": "846:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9045, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "846:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "845:9:29" + }, + "scope": 9174, + "src": "804:82:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9071, + "nodeType": "Block", + "src": "963:54:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9068, + "name": "WAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9003, + "src": "1006:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9064, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9055, + "src": "998:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9062, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9053, + "src": "992:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9063, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "992:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9065, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "992:8:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9060, + "name": "halfWAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9008, + "src": "980:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9061, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "980:11:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9066, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "980:21:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9067, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "980:25:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9069, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "980:30:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9059, + "id": 9070, + "nodeType": "Return", + "src": "973:37:29" + } + ] + }, + "documentation": null, + "id": 9072, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "wadMul", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9056, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9053, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9072, + "src": "909:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9052, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "909:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9055, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 9072, + "src": "920:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9054, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "920:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "908:22:29" + }, + "returnParameters": { + "id": 9059, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9058, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9072, + "src": "954:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9057, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "954:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "953:9:29" + }, + "scope": 9174, + "src": "893:124:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9098, + "nodeType": "Block", + "src": "1093:84:29", + "statements": [ + { + "assignments": [ + 9082 + ], + "declarations": [ + { + "constant": false, + "id": 9082, + "name": "halfB", + "nodeType": "VariableDeclaration", + "scope": 9098, + "src": "1103:13:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9081, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1103:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9086, + "initialValue": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9085, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9083, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9076, + "src": "1119:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "hexValue": "32", + "id": 9084, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1123:1:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_2_by_1", + "typeString": "int_const 2" + }, + "value": "2" + }, + "src": "1119:5:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1103:21:29" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9095, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9076, + "src": "1168:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9091, + "name": "WAD", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9003, + "src": "1158:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9089, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9074, + "src": "1152:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9090, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "1152:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9092, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1152:10:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9087, + "name": "halfB", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9082, + "src": "1142:5:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9088, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1142:9:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9093, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1142:21:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9094, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "1142:25:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9096, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1142:28:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9080, + "id": 9097, + "nodeType": "Return", + "src": "1135:35:29" + } + ] + }, + "documentation": null, + "id": 9099, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "wadDiv", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9077, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9074, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9099, + "src": "1039:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9073, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1039:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9076, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 9099, + "src": "1050:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9075, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1050:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1038:22:29" + }, + "returnParameters": { + "id": 9080, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9079, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9099, + "src": "1084:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9078, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1084:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1083:9:29" + }, + "scope": 9174, + "src": "1023:154:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9119, + "nodeType": "Block", + "src": "1253:54:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9116, + "name": "RAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9011, + "src": "1296:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9112, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9103, + "src": "1288:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9110, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9101, + "src": "1282:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9111, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "1282:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9113, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1282:8:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9108, + "name": "halfRAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9016, + "src": "1270:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9109, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1270:11:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9114, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1270:21:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9115, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "1270:25:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9117, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1270:30:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9107, + "id": 9118, + "nodeType": "Return", + "src": "1263:37:29" + } + ] + }, + "documentation": null, + "id": 9120, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "rayMul", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9104, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9101, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9120, + "src": "1199:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9100, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1199:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9103, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 9120, + "src": "1210:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9102, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1210:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1198:22:29" + }, + "returnParameters": { + "id": 9107, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9106, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9120, + "src": "1244:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9105, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1244:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1243:9:29" + }, + "scope": 9174, + "src": "1183:124:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9146, + "nodeType": "Block", + "src": "1383:84:29", + "statements": [ + { + "assignments": [ + 9130 + ], + "declarations": [ + { + "constant": false, + "id": 9130, + "name": "halfB", + "nodeType": "VariableDeclaration", + "scope": 9146, + "src": "1393:13:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9129, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1393:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9134, + "initialValue": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9133, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9131, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9124, + "src": "1409:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "/", + "rightExpression": { + "argumentTypes": null, + "hexValue": "32", + "id": 9132, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1413:1:29", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_2_by_1", + "typeString": "int_const 2" + }, + "value": "2" + }, + "src": "1409:5:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1393:21:29" + }, + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9143, + "name": "b", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9124, + "src": "1458:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9139, + "name": "RAY", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9011, + "src": "1448:3:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9137, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9122, + "src": "1442:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9138, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "1442:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9140, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1442:10:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9135, + "name": "halfB", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9130, + "src": "1432:5:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9136, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "add", + "nodeType": "MemberAccess", + "referencedDeclaration": 10980, + "src": "1432:9:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9141, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1432:21:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9142, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "1432:25:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9144, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1432:28:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9128, + "id": 9145, + "nodeType": "Return", + "src": "1425:35:29" + } + ] + }, + "documentation": null, + "id": 9147, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "rayDiv", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9125, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9122, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9147, + "src": "1329:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9121, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1329:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9124, + "name": "b", + "nodeType": "VariableDeclaration", + "scope": 9147, + "src": "1340:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9123, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1340:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1328:22:29" + }, + "returnParameters": { + "id": 9128, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9127, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9147, + "src": "1374:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9126, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1374:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1373:9:29" + }, + "scope": 9174, + "src": "1313:154:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9159, + "nodeType": "Block", + "src": "1534:44:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9156, + "name": "WAD_RAY_RATIO", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9019, + "src": "1557:13:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9154, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9149, + "src": "1551:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9155, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "div", + "nodeType": "MemberAccess", + "referencedDeclaration": 11073, + "src": "1551:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9157, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1551:20:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9153, + "id": 9158, + "nodeType": "Return", + "src": "1544:27:29" + } + ] + }, + "documentation": null, + "id": 9160, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "rayToWad", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9150, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9149, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9160, + "src": "1491:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9148, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1491:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1490:11:29" + }, + "returnParameters": { + "id": 9153, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9152, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9160, + "src": "1525:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9151, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1525:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1524:9:29" + }, + "scope": 9174, + "src": "1473:105:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + }, + { + "body": { + "id": 9172, + "nodeType": "Block", + "src": "1645:44:29", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9169, + "name": "WAD_RAY_RATIO", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9019, + "src": "1668:13:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "expression": { + "argumentTypes": null, + "id": 9167, + "name": "a", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9162, + "src": "1662:1:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9168, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "mul", + "nodeType": "MemberAccess", + "referencedDeclaration": 11057, + "src": "1662:5:29", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$", + "typeString": "function (uint256,uint256) pure returns (uint256)" + } + }, + "id": 9170, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1662:20:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9166, + "id": 9171, + "nodeType": "Return", + "src": "1655:27:29" + } + ] + }, + "documentation": null, + "id": 9173, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "wadToRay", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9163, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9162, + "name": "a", + "nodeType": "VariableDeclaration", + "scope": 9173, + "src": "1602:9:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9161, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1602:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1601:11:29" + }, + "returnParameters": { + "id": 9166, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9165, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9173, + "src": "1636:7:29", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9164, + "name": "uint256", + "nodeType": "ElementaryTypeName", + "src": "1636:7:29", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1635:9:29" + }, + "scope": 9174, + "src": "1584:105:29", + "stateMutability": "pure", + "superFunction": null, + "visibility": "internal" + } + ], + "scope": 9175, + "src": "272:1420:29" + } + ], + "src": "0:1693:29" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.838Z", + "devdoc": { + "author": "Aave", + "details": "Provides mul and div function for wads (decimal numbers with 18 digits precision) and rays (decimals with 27 digits)", + "methods": {}, + "title": "WadRayMath library" + }, + "userdoc": { + "methods": {}, + "notice": "****************" + } +} \ No newline at end of file diff --git a/client/src/contracts/WalletBalanceProvider.json b/client/src/contracts/WalletBalanceProvider.json new file mode 100644 index 0000000..6a3fe05 --- /dev/null +++ b/client/src/contracts/WalletBalanceProvider.json @@ -0,0 +1,3778 @@ +{ + "contractName": "WalletBalanceProvider", + "abi": [ + { + "inputs": [ + { + "name": "_provider", + "type": "address" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "constant": true, + "inputs": [ + { + "name": "_user", + "type": "address" + }, + { + "name": "_token", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_user", + "type": "address" + } + ], + "name": "getUserWalletBalances", + "outputs": [ + { + "name": "", + "type": "address[]" + }, + { + "name": "", + "type": "uint256[]" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } + ], + "metadata": "{\"compiler\":{\"version\":\"0.5.8+commit.23d335f2\"},\"language\":\"Solidity\",\"output\":{\"abi\":[{\"constant\":true,\"inputs\":[{\"name\":\"_user\",\"type\":\"address\"}],\"name\":\"getUserWalletBalances\",\"outputs\":[{\"name\":\"\",\"type\":\"address[]\"},{\"name\":\"\",\"type\":\"uint256[]\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"constant\":true,\"inputs\":[{\"name\":\"_user\",\"type\":\"address\"},{\"name\":\"_token\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"name\":\"\",\"type\":\"uint256\"}],\"payable\":false,\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"name\":\"_provider\",\"type\":\"address\"}],\"payable\":false,\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"payable\":true,\"stateMutability\":\"payable\",\"type\":\"fallback\"}],\"devdoc\":{\"author\":\"Aave, influenced by https://github.com/wbobeirne/eth-balance-checker/blob/master/contracts/BalanceChecker.sol\",\"details\":\"NOTE: THIS CONTRACT IS NOT USED WITHIN THE AAVE PROTOCOL. It's an accessory contract used to reduce the number of calls towards the blockchain.************************************************************************************\",\"methods\":{\"balanceOf(address,address)\":{\"details\":\"Check the token balance of a wallet in a token contract Returns the balance of the token for user. Avoids possible errors: - return 0 on non-contract address*\"},\"getUserWalletBalances(address)\":{\"details\":\"provides balances of user wallet for all reserves available on the pool\"}},\"title\":\"WalletBalanceProvider contract\"},\"userdoc\":{\"methods\":{},\"notice\":\"***********************************************************************************Implements a logic of getting multiple tokens balance for one user address\"}},\"settings\":{\"compilationTarget\":{\"/Users/jg/Documents/aaveBot/contracts/misc/WalletBalanceProvider.sol\":\"WalletBalanceProvider\"},\"evmVersion\":\"petersburg\",\"libraries\":{},\"optimizer\":{\"enabled\":false,\"runs\":200},\"remappings\":[]},\"sources\":{\"/Users/jg/Documents/aaveBot/contracts/configuration/AddressStorage.sol\":{\"keccak256\":\"0x079fa4d71c003221d60845732d33079b160e5669d06a61c36127bbfe3845b171\",\"urls\":[\"bzzr://d3c3a417d1b4893c2f90d32384733d645de302737087045b0d8890b3ba8849be\"]},\"/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x0ae6004410cd58a1c5151e67959167cf58cd5e77e8b625677826e295905fb318\",\"urls\":[\"bzzr://d223bea23f0e9bd70844e9852f490be93d30fc1c31bf114c807d0e4fe07d929b\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingPoolAddressesProvider.sol\":{\"keccak256\":\"0x911d879835bcaaaa2a20deceeab04deefef4e7f003f35e31835a85fce1db28d9\",\"urls\":[\"bzzr://733f4b4a6f0423a212d08d6a05ee20959827e7d57f91be515dd28919a6fd6f90\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/ILendingRateOracle.sol\":{\"keccak256\":\"0xeeae2b67fa36103fe1c3a4e346b9c04171f9065949953abd00104c357834b0e3\",\"urls\":[\"bzzr://4e3bd29abfa796726532c3e42dd8039ab0f93388d7bbf358428dbc9b0399664a\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol\":{\"keccak256\":\"0xedadfd1f3b2c918850172cc7cce78418253a5552c747e19f738e3f660c9edf34\",\"urls\":[\"bzzr://5f8a4791649bfc30040b55cdf63d3f2ab253b14825632965ca82699d13267f29\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IPriceOracle.sol\":{\"keccak256\":\"0x0adf744884b9262f507aba565d1c96c82397f58d399a2dc2c60a452953197574\",\"urls\":[\"bzzr://03099f88c041565b5ac13ea7e645a8f9bff0c29bfa584c7969372ce12c5473f5\"]},\"/Users/jg/Documents/aaveBot/contracts/interfaces/IReserveInterestRateStrategy.sol\":{\"keccak256\":\"0x35a7f1a34259948cdcb03084718f765215fe69559f557b395d9d6e18c63ac823\",\"urls\":[\"bzzr://f529e265dd06192a1d552f1f41c245790419562dfb52e7be9d443c758ccb72d0\"]},\"/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol\":{\"keccak256\":\"0xca757f989e0e7519d03d4e3086028e3022306ec4bb7f610fa78bff866f04c998\",\"urls\":[\"bzzr://f381f642ecce43d76d9e0011ea3c7c6218d1eaa2e0d3a7d5aecd55552cc0fb27\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/CoreLibrary.sol\":{\"keccak256\":\"0xb8b4844881a9ea5c3f0f2584061efcbfb6c96863ca3a07b960d2f9d323293cac\",\"urls\":[\"bzzr://8cb1c5dcce198c0f60c21bd9807b361fc214a60d4b3aa3442153b045b51a4325\"]},\"/Users/jg/Documents/aaveBot/contracts/libraries/WadRayMath.sol\":{\"keccak256\":\"0xe6d11705b3624dae6e5b5817e46baed8e0ebc8f54ab0b110524eb49ee4dbf67f\",\"urls\":[\"bzzr://d5aaa20f0b44d0e9fa8ae5270dfe459f5da9a5b3b184a63983b9293d9bd78f39\"]},\"/Users/jg/Documents/aaveBot/contracts/misc/WalletBalanceProvider.sol\":{\"keccak256\":\"0x37ed218654d89d2bd783077acd52d69093df9de25fd39acf7f5ce723003a0e0d\",\"urls\":[\"bzzr://fb3b4caf1bf283f9917099c9695a563044437fa8ffc5990f71ebcdaf141a45b1\"]},\"openzeppelin-solidity/contracts/GSN/Context.sol\":{\"keccak256\":\"0x90a3995645af7562d84b9d69363ffa5ae7217714ab61e951bf7bc450f40e4061\",\"urls\":[\"bzzr://51482c01bddf23793bddee43b60ab9578a62948a4f2082def24ea792a553b055\"]},\"openzeppelin-solidity/contracts/math/SafeMath.sol\":{\"keccak256\":\"0x640b6dee7a4b830bdfd52b5031a07fc2b12209f5b2e29e5d364a7d37f69d8076\",\"urls\":[\"bzzr://292843005e754e752644f767477ec5ad7a1ffc91ddb18c38b8079c62f3993cad\"]},\"openzeppelin-solidity/contracts/ownership/Ownable.sol\":{\"keccak256\":\"0xecd8ab29d9a5771c3964d0cd1788c4a5098a0081b20fb275da850a22b1c59806\",\"urls\":[\"bzzr://4950def18270142a78d503ef6b7b13bdb053f2f050cee50c883cd7cab2bb02d7\"]},\"openzeppelin-solidity/contracts/token/ERC20/ERC20.sol\":{\"keccak256\":\"0x65a4078c03875c25413a068ce9cfdd7e68a90f8786612d1189c89341e6e3b802\",\"urls\":[\"bzzr://fefcc5ec4e313a66c9fd38375983b5973c528e7e19b6d37c2f1ac6745295e6e2\"]},\"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\":{\"keccak256\":\"0xe5bb0f57cff3e299f360052ba50f1ea0fff046df2be070b6943e0e3c3fdad8a9\",\"urls\":[\"bzzr://cf2d583b8dce38d0617fdcd65f2fd9f126fe17b7f683b5a515ea9d2762d8b062\"]},\"openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol\":{\"keccak256\":\"0x6f2c9955d65c522b80f4b8792f076512d2df947d2112cbc4d98a4781ed42ede2\",\"urls\":[\"bzzr://d2ff5aadcb697bc27ca3b0f6c40b4998e8cf0a1bd0f761d1df6d5981777841ae\"]},\"openzeppelin-solidity/contracts/utils/Address.sol\":{\"keccak256\":\"0x70df50e240407aa50915ad14f61b1a901fa335b37de20955b99ed647be756af0\",\"urls\":[\"bzzr://cd04ca8d050befdf06ac93c2f6f5ea7250d2199b44aecbe54ded512e823f711a\"]}},\"version\":1}", + "bytecode": "0x608060405234801561001057600080fd5b506040516020806107cf8339810180604052602081101561003057600080fd5b8101908080519060200190929190505050806000806101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055505061073e806100916000396000f3fe6080604052600436106100295760003560e01c80639e3c93091461007a578063f7888aec14610168575b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e8152602001806106e5602e913960400191505060405180910390fd5b34801561008657600080fd5b506100c96004803603602081101561009d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506101ed565b604051808060200180602001838103835285818151815260200191508051906020019060200280838360005b838110156101105780820151818401526020810190506100f5565b50505050905001838103825284818151815260200191508051906020019060200280838360005b83811015610152578082015181840152602081019050610137565b5050505090500194505050505060405180910390f35b34801561017457600080fd5b506101d76004803603604081101561018b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506105a9565b6040518082815260200191505060405180910390f35b60608060008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801561025957600080fd5b505afa15801561026d573d6000803e3d6000fd5b505050506040513d602081101561028357600080fd5b8101908080519060200190929190505050905060608173ffffffffffffffffffffffffffffffffffffffff16630902f1ac6040518163ffffffff1660e01b815260040160006040518083038186803b1580156102de57600080fd5b505afa1580156102f2573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250602081101561031c57600080fd5b81019080805164010000000081111561033457600080fd5b8281019050602081018481111561034a57600080fd5b815185602082028301116401000000008211171561036757600080fd5b5050929190505050905060008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b1580156103da57600080fd5b505afa1580156103ee573d6000803e3d6000fd5b505050506040513d602081101561040457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b15801561045a57600080fd5b505afa15801561046e573d6000803e3d6000fd5b505050506040513d602081101561048457600080fd5b81019080805190602001909291905050509050606082516040519080825280602002602001820160405280156104c95781602001602082028038833980820191505090505b50905060008090505b8351811015610599578273ffffffffffffffffffffffffffffffffffffffff168482815181106104fe57fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161461055b5761053e8885838151811061053157fe5b60200260200101516105a9565b82828151811061054a57fe5b60200260200101818152505061058c565b8773ffffffffffffffffffffffffffffffffffffffff163182828151811061057f57fe5b6020026020010181815250505b80806001019150506104d2565b5082819550955050505050915091565b60006105ca8273ffffffffffffffffffffffffffffffffffffffff16610699565b1561068e578173ffffffffffffffffffffffffffffffffffffffff166370a08231846040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561064c57600080fd5b505afa158015610660573d6000803e3d6000fd5b505050506040513d602081101561067657600080fd5b81019080805190602001909291905050509050610693565b600090505b92915050565b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f91506000801b82141580156106db5750808214155b9250505091905056fe57616c6c657442616c616e636550726f766964657220646f6573206e6f7420616363657074207061796d656e7473a165627a7a7230582020d8dbac9c3dbc50396afd763ac033054a14b6e6db027d70ad60d0aa7ea6adcf0029", + "deployedBytecode": "0x6080604052600436106100295760003560e01c80639e3c93091461007a578063f7888aec14610168575b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260040180806020018281038252602e8152602001806106e5602e913960400191505060405180910390fd5b34801561008657600080fd5b506100c96004803603602081101561009d57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506101ed565b604051808060200180602001838103835285818151815260200191508051906020019060200280838360005b838110156101105780820151818401526020810190506100f5565b50505050905001838103825284818151815260200191508051906020019060200280838360005b83811015610152578082015181840152602081019050610137565b5050505090500194505050505060405180910390f35b34801561017457600080fd5b506101d76004803603604081101561018b57600080fd5b81019080803573ffffffffffffffffffffffffffffffffffffffff169060200190929190803573ffffffffffffffffffffffffffffffffffffffff1690602001909291905050506105a9565b6040518082815260200191505060405180910390f35b60608060008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663ed6ff7606040518163ffffffff1660e01b815260040160206040518083038186803b15801561025957600080fd5b505afa15801561026d573d6000803e3d6000fd5b505050506040513d602081101561028357600080fd5b8101908080519060200190929190505050905060608173ffffffffffffffffffffffffffffffffffffffff16630902f1ac6040518163ffffffff1660e01b815260040160006040518083038186803b1580156102de57600080fd5b505afa1580156102f2573d6000803e3d6000fd5b505050506040513d6000823e3d601f19601f82011682018060405250602081101561031c57600080fd5b81019080805164010000000081111561033457600080fd5b8281019050602081018481111561034a57600080fd5b815185602082028301116401000000008211171561036757600080fd5b5050929190505050905060008060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663b5722bb56040518163ffffffff1660e01b815260040160206040518083038186803b1580156103da57600080fd5b505afa1580156103ee573d6000803e3d6000fd5b505050506040513d602081101561040457600080fd5b810190808051906020019092919050505073ffffffffffffffffffffffffffffffffffffffff166317bfdd576040518163ffffffff1660e01b815260040160206040518083038186803b15801561045a57600080fd5b505afa15801561046e573d6000803e3d6000fd5b505050506040513d602081101561048457600080fd5b81019080805190602001909291905050509050606082516040519080825280602002602001820160405280156104c95781602001602082028038833980820191505090505b50905060008090505b8351811015610599578273ffffffffffffffffffffffffffffffffffffffff168482815181106104fe57fe5b602002602001015173ffffffffffffffffffffffffffffffffffffffff161461055b5761053e8885838151811061053157fe5b60200260200101516105a9565b82828151811061054a57fe5b60200260200101818152505061058c565b8773ffffffffffffffffffffffffffffffffffffffff163182828151811061057f57fe5b6020026020010181815250505b80806001019150506104d2565b5082819550955050505050915091565b60006105ca8273ffffffffffffffffffffffffffffffffffffffff16610699565b1561068e578173ffffffffffffffffffffffffffffffffffffffff166370a08231846040518263ffffffff1660e01b8152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060206040518083038186803b15801561064c57600080fd5b505afa158015610660573d6000803e3d6000fd5b505050506040513d602081101561067657600080fd5b81019080805190602001909291905050509050610693565b600090505b92915050565b60008060007fc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a47060001b9050833f91506000801b82141580156106db5750808214155b9250505091905056fe57616c6c657442616c616e636550726f766964657220646f6573206e6f7420616363657074207061796d656e7473a165627a7a7230582020d8dbac9c3dbc50396afd763ac033054a14b6e6db027d70ad60d0aa7ea6adcf0029", + "sourceMap": "878:1692:30:-;;;992:98;8:9:-1;5:2;;;30:1;27;20:12;5:2;992:98:30;;;;;;;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;992:98:30;;;;;;;;;;;;;;;;1073:9;1062:8;;:20;;;;;;;;;;;;;;;;;;992:98;878:1692;;;;;;", + "deployedSourceMap": "878:1692:30:-;;;;;;;;;;;;;;;;;;;;;;;1198:56;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;1833:735;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1833:735:30;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1833:735:30;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1833:735:30;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;23:1:-1;8:100;33:3;30:1;27:10;8:100;;;99:1;94:3;90:11;84:18;80:1;75:3;71:11;64:39;52:2;49:1;45:10;40:15;;8:100;;;12:14;1833:735:30;;;;;;;;;;;;;;;;;;;1461:269;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1461:269:30;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1461:269:30;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;;;1833:735;1900:16;1918:13;1944:20;1983:8;;;;;;;;;;;:27;;;:29;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1983:29:30;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1983:29:30;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1983:29:30;;;;;;;;;;;;;;;;1944:69;;2024:25;2052:4;:16;;;:18;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2052:18:30;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2052:18:30;;;;;;39:16:-1;36:1;17:17;2:54;2052:18:30;101:4:-1;97:9;90:4;84;80:15;76:31;69:5;65:43;126:6;120:4;113:20;0:138;13:2;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2052:18:30;;;;;;19:11:-1;14:3;11:20;8:2;;;44:1;41;34:12;8:2;71:11;66:3;62:21;55:28;;123:4;118:3;114:14;159:9;141:16;138:31;135:2;;;182:1;179;172:12;135:2;219:3;213:10;331:9;325:2;311:12;307:21;289:16;285:44;282:59;261:11;247:12;244:29;233:116;230:2;;;362:1;359;352:12;230:2;0:373;;2052:18:30;;;;;;2024:46;;2080:23;2131:8;;;;;;;;;;;:35;;;:37;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2131:37:30;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2131:37:30;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2131:37:30;;;;;;;;;;;;;;;;2106:82;;;:84;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;2106:84:30;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;2106:84:30;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;2106:84:30;;;;;;;;;;;;;;;;2080:110;;2201:22;2237:8;:15;2226:27;;;;;;;;;;;;;;;;;;;;;;29:2:-1;21:6;17:15;117:4;105:10;97:6;88:34;148:4;140:6;136:17;126:27;;0:157;2226:27:30;;;;2201:52;;2269:6;2278:1;2269:10;;2264:260;2285:8;:15;2281:1;:19;2264:260;;;2340:15;2325:30;;:8;2334:1;2325:11;;;;;;;;;;;;;;:30;;;2321:193;;2389:29;2399:5;2406:8;2415:1;2406:11;;;;;;;;;;;;;;2389:9;:29::i;:::-;2375:8;2384:1;2375:11;;;;;;;;;;;;;:43;;;;;2321:193;;;2471:5;:13;;;2457:8;2466:1;2457:11;;;;;;;;;;;;;:27;;;;;2321:193;2302:3;;;;;;;2264:260;;;;2542:8;2552;2534:27;;;;;;;;1833:735;;;:::o;1461:269::-;1532:4;1601:19;:6;:17;;;:19::i;:::-;1597:127;;;1650:6;1643:24;;;1668:5;1643:31;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8:9:-1;5:2;;;30:1;27;20:12;5:2;1643:31:30;;;;8:9:-1;5:2;;;45:16;42:1;39;24:38;77:16;74:1;67:27;5:2;1643:31:30;;;;;;;13:2:-1;8:3;5:11;2:2;;;29:1;26;19:12;2:2;1643:31:30;;;;;;;;;;;;;;;;1636:38;;;;1597:127;1712:1;1705:8;;1461:269;;;;;:::o;557:797:62:-;617:4;1062:16;1088:19;1110:66;1088:88;;;;1277:7;1265:20;1253:32;;1316:3;1304:15;;:8;:15;;:42;;;;;1335:11;1323:8;:23;;1304:42;1296:51;;;;557:797;;;:::o", + "source": "pragma solidity ^0.5.0;\n\nimport \"openzeppelin-solidity/contracts/utils/Address.sol\";\nimport \"openzeppelin-solidity/contracts/token/ERC20/IERC20.sol\";\n\nimport \"../configuration/LendingPoolAddressesProvider.sol\";\nimport \"../lendingpool/LendingPoolCore.sol\";\nimport \"../interfaces/INetworkMetadataProvider.sol\";\n\n\n/*************************************************************************************\n@title WalletBalanceProvider contract\n@author Aave, influenced by https://github.com/wbobeirne/eth-balance-checker/blob/master/contracts/BalanceChecker.sol\n@notice Implements a logic of getting multiple tokens balance for one user address\n\n@dev NOTE: THIS CONTRACT IS NOT USED WITHIN THE AAVE PROTOCOL. It's an accessory contract used to reduce the number of calls\ntowards the blockchain.\n\n *************************************************************************************/\n\n\ncontract WalletBalanceProvider {\n\n using Address for address;\n\n LendingPoolAddressesProvider provider;\n\n constructor(LendingPoolAddressesProvider _provider) public {\n\n provider = _provider;\n\n }\n /**\n @dev Fallback function, don't accept any ETH\n **/\n function() external payable {\n revert(\"WalletBalanceProvider does not accept payments\");\n }\n\n /**\n @dev Check the token balance of a wallet in a token contract\n\n Returns the balance of the token for user. Avoids possible errors:\n - return 0 on non-contract address\n **/\n function balanceOf(address _user, address _token) public view returns (uint) {\n // check if token is actually a contract\n if (_token.isContract()) {\n return IERC20(_token).balanceOf(_user);\n } else {\n return 0;\n }\n }\n\n\n /**\n @dev provides balances of user wallet for all reserves available on the pool\n */\n function getUserWalletBalances(address _user) public view returns (address[] memory, uint[] memory) {\n\n LendingPoolCore core = LendingPoolCore(provider.getLendingPoolCore());\n\n address[] memory reserves = core.getReserves();\n address ethereumAddress = INetworkMetadataProvider(provider.getNetworkMetadataProvider()).getEthereumAddress();\n\n uint[] memory balances = new uint[](reserves.length);\n\n for (uint j = 0; j < reserves.length; j++) {\n if (reserves[j] != ethereumAddress) {\n balances[j] = balanceOf(_user, reserves[j]);\n } else {\n balances[j] = _user.balance; // ETH balance\n }\n }\n\n return (reserves, balances);\n }\n}", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/misc/WalletBalanceProvider.sol", + "ast": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/misc/WalletBalanceProvider.sol", + "exportedSymbols": { + "WalletBalanceProvider": [ + 9322 + ] + }, + "id": 9323, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9176, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:30" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "file": "openzeppelin-solidity/contracts/utils/Address.sol", + "id": 9177, + "nodeType": "ImportDirective", + "scope": 9323, + "sourceUnit": 12082, + "src": "25:59:30", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "id": 9178, + "nodeType": "ImportDirective", + "scope": 9323, + "sourceUnit": 11787, + "src": "85:64:30", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 9179, + "nodeType": "ImportDirective", + "scope": 9323, + "sourceUnit": 1358, + "src": "151:59:30", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "../lendingpool/LendingPoolCore.sol", + "id": 9180, + "nodeType": "ImportDirective", + "scope": 9323, + "sourceUnit": 6683, + "src": "211:44:30", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "file": "../interfaces/INetworkMetadataProvider.sol", + "id": 9181, + "nodeType": "ImportDirective", + "scope": 9323, + "sourceUnit": 1933, + "src": "256:52:30", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title WalletBalanceProvider contract\n@author Aave, influenced by https://github.com/wbobeirne/eth-balance-checker/blob/master/contracts/BalanceChecker.sol\n@notice Implements a logic of getting multiple tokens balance for one user address\n@dev NOTE: THIS CONTRACT IS NOT USED WITHIN THE AAVE PROTOCOL. It's an accessory contract used to reduce the number of calls\ntowards the blockchain.************************************************************************************", + "fullyImplemented": true, + "id": 9322, + "linearizedBaseContracts": [ + 9322 + ], + "name": "WalletBalanceProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 9184, + "libraryName": { + "contractScope": null, + "id": 9182, + "name": "Address", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12081, + "src": "922:7:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + }, + "nodeType": "UsingForDirective", + "src": "916:26:30", + "typeName": { + "id": 9183, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "934:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + }, + { + "constant": false, + "id": 9186, + "name": "provider", + "nodeType": "VariableDeclaration", + "scope": 9322, + "src": "948:37:30", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 9185, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "948:28:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 9195, + "nodeType": "Block", + "src": "1051:39:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9193, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9191, + "name": "provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9186, + "src": "1062:8:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9192, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9188, + "src": "1073:9:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "1062:20:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9194, + "nodeType": "ExpressionStatement", + "src": "1062:20:30" + } + ] + }, + "documentation": null, + "id": 9196, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9189, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9188, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 9196, + "src": "1004:38:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 9187, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1004:28:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1003:40:30" + }, + "returnParameters": { + "id": 9190, + "nodeType": "ParameterList", + "parameters": [], + "src": "1051:0:30" + }, + "scope": 9322, + "src": "992:98:30", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 9203, + "nodeType": "Block", + "src": "1188:73:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "57616c6c657442616c616e636550726f766964657220646f6573206e6f7420616363657074207061796d656e7473", + "id": 9200, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1205:48:30", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_280c41bb8c1f7e09048b5cede0ca45bf41459598df6520c48a3b75dc7dc5acb9", + "typeString": "literal_string \"WalletBalanceProvider does not accept payments\"" + }, + "value": "WalletBalanceProvider does not accept payments" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_280c41bb8c1f7e09048b5cede0ca45bf41459598df6520c48a3b75dc7dc5acb9", + "typeString": "literal_string \"WalletBalanceProvider does not accept payments\"" + } + ], + "id": 9199, + "name": "revert", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12133, + 12134 + ], + "referencedDeclaration": 12134, + "src": "1198:6:30", + "typeDescriptions": { + "typeIdentifier": "t_function_revert_pure$_t_string_memory_ptr_$returns$__$", + "typeString": "function (string memory) pure" + } + }, + "id": 9201, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1198:56:30", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9202, + "nodeType": "ExpressionStatement", + "src": "1198:56:30" + } + ] + }, + "documentation": "@dev Fallback function, don't accept any ETH*", + "id": 9204, + "implemented": true, + "kind": "fallback", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9197, + "nodeType": "ParameterList", + "parameters": [], + "src": "1168:2:30" + }, + "returnParameters": { + "id": 9198, + "nodeType": "ParameterList", + "parameters": [], + "src": "1188:0:30" + }, + "scope": 9322, + "src": "1160:101:30", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 9228, + "nodeType": "Block", + "src": "1538:192:30", + "statements": [ + { + "condition": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9213, + "name": "_token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9208, + "src": "1601:6:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 9214, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isContract", + "nodeType": "MemberAccess", + "referencedDeclaration": 12033, + "src": "1601:17:30", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$bound_to$_t_address_$", + "typeString": "function (address) view returns (bool)" + } + }, + "id": 9215, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1601:19:30", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 9226, + "nodeType": "Block", + "src": "1691:33:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 9224, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1712:1:30", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 9212, + "id": 9225, + "nodeType": "Return", + "src": "1705:8:30" + } + ] + }, + "id": 9227, + "nodeType": "IfStatement", + "src": "1597:127:30", + "trueBody": { + "id": 9223, + "nodeType": "Block", + "src": "1622:63:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9220, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9206, + "src": "1668:5:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9217, + "name": "_token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9208, + "src": "1650:6:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9216, + "name": "IERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11786, + "src": "1643:6:30", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IERC20_$11786_$", + "typeString": "type(contract IERC20)" + } + }, + "id": 9218, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1643:14:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 9219, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOf", + "nodeType": "MemberAccess", + "referencedDeclaration": 11731, + "src": "1643:24:30", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 9221, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1643:31:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9212, + "id": 9222, + "nodeType": "Return", + "src": "1636:38:30" + } + ] + } + } + ] + }, + "documentation": "@dev Check the token balance of a wallet in a token contract\nReturns the balance of the token for user. Avoids possible errors:\n- return 0 on non-contract address*", + "id": 9229, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "balanceOf", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9209, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9206, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 9229, + "src": "1480:13:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9205, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1480:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9208, + "name": "_token", + "nodeType": "VariableDeclaration", + "scope": 9229, + "src": "1495:14:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9207, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1495:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1479:31:30" + }, + "returnParameters": { + "id": 9212, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9211, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9229, + "src": "1532:4:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9210, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "1532:4:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1531:6:30" + }, + "scope": 9322, + "src": "1461:269:30", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 9320, + "nodeType": "Block", + "src": "1933:635:30", + "statements": [ + { + "assignments": [ + 9241 + ], + "declarations": [ + { + "constant": false, + "id": 9241, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 9320, + "src": "1944:20:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 9240, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "1944:15:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9247, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9243, + "name": "provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9186, + "src": "1983:8:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9244, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "1983:27:30", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 9245, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1983:29:30", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 9242, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "1967:15:30", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 9246, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1967:46:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1944:69:30" + }, + { + "assignments": [ + 9251 + ], + "declarations": [ + { + "constant": false, + "id": 9251, + "name": "reserves", + "nodeType": "VariableDeclaration", + "scope": 9320, + "src": "2024:25:30", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 9249, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2024:7:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 9250, + "length": null, + "nodeType": "ArrayTypeName", + "src": "2024:9:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9255, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9252, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9241, + "src": "2052:4:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 9253, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserves", + "nodeType": "MemberAccess", + "referencedDeclaration": 6134, + "src": "2052:16:30", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_array$_t_address_$dyn_memory_ptr_$", + "typeString": "function () view external returns (address[] memory)" + } + }, + "id": 9254, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2052:18:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2024:46:30" + }, + { + "assignments": [ + 9257 + ], + "declarations": [ + { + "constant": false, + "id": 9257, + "name": "ethereumAddress", + "nodeType": "VariableDeclaration", + "scope": 9320, + "src": "2080:23:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9256, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2080:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9265, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9259, + "name": "provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9186, + "src": "2131:8:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9260, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1216, + "src": "2131:35:30", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 9261, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2131:37:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9258, + "name": "INetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1932, + "src": "2106:24:30", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_INetworkMetadataProvider_$1932_$", + "typeString": "type(contract INetworkMetadataProvider)" + } + }, + "id": 9262, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2106:63:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 9263, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1926, + "src": "2106:82:30", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 9264, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2106:84:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2080:110:30" + }, + { + "assignments": [ + 9269 + ], + "declarations": [ + { + "constant": false, + "id": 9269, + "name": "balances", + "nodeType": "VariableDeclaration", + "scope": 9320, + "src": "2201:22:30", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", + "typeString": "uint256[]" + }, + "typeName": { + "baseType": { + "id": 9267, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "2201:4:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9268, + "length": null, + "nodeType": "ArrayTypeName", + "src": "2201:6:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", + "typeString": "uint256[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9276, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 9273, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9251, + "src": "2237:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 9274, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "length", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2237:15:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9272, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "NewExpression", + "src": "2226:10:30", + "typeDescriptions": { + "typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_uint256_$dyn_memory_$", + "typeString": "function (uint256) pure returns (uint256[] memory)" + }, + "typeName": { + "baseType": { + "id": 9270, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "2230:4:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9271, + "length": null, + "nodeType": "ArrayTypeName", + "src": "2230:6:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", + "typeString": "uint256[]" + } + } + }, + "id": 9275, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2226:27:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory", + "typeString": "uint256[] memory" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2201:52:30" + }, + { + "body": { + "id": 9314, + "nodeType": "Block", + "src": "2307:217:30", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 9292, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9288, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9251, + "src": "2325:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 9290, + "indexExpression": { + "argumentTypes": null, + "id": 9289, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2334:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2325:11:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 9291, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9257, + "src": "2340:15:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "2325:30:30", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 9312, + "nodeType": "Block", + "src": "2439:75:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9310, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9305, + "name": "balances", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9269, + "src": "2457:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", + "typeString": "uint256[] memory" + } + }, + "id": 9307, + "indexExpression": { + "argumentTypes": null, + "id": 9306, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2466:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "2457:11:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 9308, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9231, + "src": "2471:5:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 9309, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balance", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2471:13:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2457:27:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9311, + "nodeType": "ExpressionStatement", + "src": "2457:27:30" + } + ] + }, + "id": 9313, + "nodeType": "IfStatement", + "src": "2321:193:30", + "trueBody": { + "id": 9304, + "nodeType": "Block", + "src": "2357:76:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9302, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9293, + "name": "balances", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9269, + "src": "2375:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", + "typeString": "uint256[] memory" + } + }, + "id": 9295, + "indexExpression": { + "argumentTypes": null, + "id": 9294, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2384:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "2375:11:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9297, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9231, + "src": "2399:5:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9298, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9251, + "src": "2406:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 9300, + "indexExpression": { + "argumentTypes": null, + "id": 9299, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2415:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2406:11:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9296, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9229, + "src": "2389:9:30", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view returns (uint256)" + } + }, + "id": 9301, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2389:29:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2375:43:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9303, + "nodeType": "ExpressionStatement", + "src": "2375:43:30" + } + ] + } + } + ] + }, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9284, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9281, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2281:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 9282, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9251, + "src": "2285:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 9283, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "length", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2285:15:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2281:19:30", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 9315, + "initializationExpression": { + "assignments": [ + 9278 + ], + "declarations": [ + { + "constant": false, + "id": 9278, + "name": "j", + "nodeType": "VariableDeclaration", + "scope": 9315, + "src": "2269:6:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9277, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "2269:4:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9280, + "initialValue": { + "argumentTypes": null, + "hexValue": "30", + "id": 9279, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2278:1:30", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "nodeType": "VariableDeclarationStatement", + "src": "2269:10:30" + }, + "loopExpression": { + "expression": { + "argumentTypes": null, + "id": 9286, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "++", + "prefix": false, + "src": "2302:3:30", + "subExpression": { + "argumentTypes": null, + "id": 9285, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2302:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9287, + "nodeType": "ExpressionStatement", + "src": "2302:3:30" + }, + "nodeType": "ForStatement", + "src": "2264:260:30" + }, + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 9316, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9251, + "src": "2542:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + { + "argumentTypes": null, + "id": 9317, + "name": "balances", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9269, + "src": "2552:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", + "typeString": "uint256[] memory" + } + } + ], + "id": 9318, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "2541:20:30", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_array$_t_address_$dyn_memory_ptr_$_t_array$_t_uint256_$dyn_memory_ptr_$", + "typeString": "tuple(address[] memory,uint256[] memory)" + } + }, + "functionReturnParameters": 9239, + "id": 9319, + "nodeType": "Return", + "src": "2534:27:30" + } + ] + }, + "documentation": "@dev provides balances of user wallet for all reserves available on the pool", + "id": 9321, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserWalletBalances", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9232, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9231, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 9321, + "src": "1864:13:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9230, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1864:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1863:15:30" + }, + "returnParameters": { + "id": 9239, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9235, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9321, + "src": "1900:16:30", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 9233, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1900:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 9234, + "length": null, + "nodeType": "ArrayTypeName", + "src": "1900:9:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9238, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9321, + "src": "1918:13:30", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", + "typeString": "uint256[]" + }, + "typeName": { + "baseType": { + "id": 9236, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "1918:4:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9237, + "length": null, + "nodeType": "ArrayTypeName", + "src": "1918:6:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", + "typeString": "uint256[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1899:33:30" + }, + "scope": 9322, + "src": "1833:735:30", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + } + ], + "scope": 9323, + "src": "878:1692:30" + } + ], + "src": "0:2570:30" + }, + "legacyAST": { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/misc/WalletBalanceProvider.sol", + "exportedSymbols": { + "WalletBalanceProvider": [ + 9322 + ] + }, + "id": 9323, + "nodeType": "SourceUnit", + "nodes": [ + { + "id": 9176, + "literals": [ + "solidity", + "^", + "0.5", + ".0" + ], + "nodeType": "PragmaDirective", + "src": "0:23:30" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/utils/Address.sol", + "file": "openzeppelin-solidity/contracts/utils/Address.sol", + "id": 9177, + "nodeType": "ImportDirective", + "scope": 9323, + "sourceUnit": 12082, + "src": "25:59:30", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "file": "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol", + "id": 9178, + "nodeType": "ImportDirective", + "scope": 9323, + "sourceUnit": 11787, + "src": "85:64:30", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/configuration/LendingPoolAddressesProvider.sol", + "file": "../configuration/LendingPoolAddressesProvider.sol", + "id": 9179, + "nodeType": "ImportDirective", + "scope": 9323, + "sourceUnit": 1358, + "src": "151:59:30", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/lendingpool/LendingPoolCore.sol", + "file": "../lendingpool/LendingPoolCore.sol", + "id": 9180, + "nodeType": "ImportDirective", + "scope": 9323, + "sourceUnit": 6683, + "src": "211:44:30", + "symbolAliases": [], + "unitAlias": "" + }, + { + "absolutePath": "/Users/jg/Documents/aaveBot/contracts/interfaces/INetworkMetadataProvider.sol", + "file": "../interfaces/INetworkMetadataProvider.sol", + "id": 9181, + "nodeType": "ImportDirective", + "scope": 9323, + "sourceUnit": 1933, + "src": "256:52:30", + "symbolAliases": [], + "unitAlias": "" + }, + { + "baseContracts": [], + "contractDependencies": [], + "contractKind": "contract", + "documentation": "***********************************************************************************\n@title WalletBalanceProvider contract\n@author Aave, influenced by https://github.com/wbobeirne/eth-balance-checker/blob/master/contracts/BalanceChecker.sol\n@notice Implements a logic of getting multiple tokens balance for one user address\n@dev NOTE: THIS CONTRACT IS NOT USED WITHIN THE AAVE PROTOCOL. It's an accessory contract used to reduce the number of calls\ntowards the blockchain.************************************************************************************", + "fullyImplemented": true, + "id": 9322, + "linearizedBaseContracts": [ + 9322 + ], + "name": "WalletBalanceProvider", + "nodeType": "ContractDefinition", + "nodes": [ + { + "id": 9184, + "libraryName": { + "contractScope": null, + "id": 9182, + "name": "Address", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 12081, + "src": "922:7:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_Address_$12081", + "typeString": "library Address" + } + }, + "nodeType": "UsingForDirective", + "src": "916:26:30", + "typeName": { + "id": 9183, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "934:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + }, + { + "constant": false, + "id": 9186, + "name": "provider", + "nodeType": "VariableDeclaration", + "scope": 9322, + "src": "948:37:30", + "stateVariable": true, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 9185, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "948:28:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + }, + { + "body": { + "id": 9195, + "nodeType": "Block", + "src": "1051:39:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9193, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "id": 9191, + "name": "provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9186, + "src": "1062:8:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "id": 9192, + "name": "_provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9188, + "src": "1073:9:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "src": "1062:20:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9194, + "nodeType": "ExpressionStatement", + "src": "1062:20:30" + } + ] + }, + "documentation": null, + "id": 9196, + "implemented": true, + "kind": "constructor", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9189, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9188, + "name": "_provider", + "nodeType": "VariableDeclaration", + "scope": 9196, + "src": "1004:38:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + }, + "typeName": { + "contractScope": null, + "id": 9187, + "name": "LendingPoolAddressesProvider", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 1357, + "src": "1004:28:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1003:40:30" + }, + "returnParameters": { + "id": 9190, + "nodeType": "ParameterList", + "parameters": [], + "src": "1051:0:30" + }, + "scope": 9322, + "src": "992:98:30", + "stateMutability": "nonpayable", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 9203, + "nodeType": "Block", + "src": "1188:73:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "hexValue": "57616c6c657442616c616e636550726f766964657220646f6573206e6f7420616363657074207061796d656e7473", + "id": 9200, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "string", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1205:48:30", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_stringliteral_280c41bb8c1f7e09048b5cede0ca45bf41459598df6520c48a3b75dc7dc5acb9", + "typeString": "literal_string \"WalletBalanceProvider does not accept payments\"" + }, + "value": "WalletBalanceProvider does not accept payments" + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_stringliteral_280c41bb8c1f7e09048b5cede0ca45bf41459598df6520c48a3b75dc7dc5acb9", + "typeString": "literal_string \"WalletBalanceProvider does not accept payments\"" + } + ], + "id": 9199, + "name": "revert", + "nodeType": "Identifier", + "overloadedDeclarations": [ + 12133, + 12134 + ], + "referencedDeclaration": 12134, + "src": "1198:6:30", + "typeDescriptions": { + "typeIdentifier": "t_function_revert_pure$_t_string_memory_ptr_$returns$__$", + "typeString": "function (string memory) pure" + } + }, + "id": 9201, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1198:56:30", + "typeDescriptions": { + "typeIdentifier": "t_tuple$__$", + "typeString": "tuple()" + } + }, + "id": 9202, + "nodeType": "ExpressionStatement", + "src": "1198:56:30" + } + ] + }, + "documentation": "@dev Fallback function, don't accept any ETH*", + "id": 9204, + "implemented": true, + "kind": "fallback", + "modifiers": [], + "name": "", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9197, + "nodeType": "ParameterList", + "parameters": [], + "src": "1168:2:30" + }, + "returnParameters": { + "id": 9198, + "nodeType": "ParameterList", + "parameters": [], + "src": "1188:0:30" + }, + "scope": 9322, + "src": "1160:101:30", + "stateMutability": "payable", + "superFunction": null, + "visibility": "external" + }, + { + "body": { + "id": 9228, + "nodeType": "Block", + "src": "1538:192:30", + "statements": [ + { + "condition": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9213, + "name": "_token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9208, + "src": "1601:6:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 9214, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "isContract", + "nodeType": "MemberAccess", + "referencedDeclaration": 12033, + "src": "1601:17:30", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$bound_to$_t_address_$", + "typeString": "function (address) view returns (bool)" + } + }, + "id": 9215, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1601:19:30", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 9226, + "nodeType": "Block", + "src": "1691:33:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "hexValue": "30", + "id": 9224, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "1712:1:30", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "functionReturnParameters": 9212, + "id": 9225, + "nodeType": "Return", + "src": "1705:8:30" + } + ] + }, + "id": 9227, + "nodeType": "IfStatement", + "src": "1597:127:30", + "trueBody": { + "id": 9223, + "nodeType": "Block", + "src": "1622:63:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9220, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9206, + "src": "1668:5:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9217, + "name": "_token", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9208, + "src": "1650:6:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9216, + "name": "IERC20", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 11786, + "src": "1643:6:30", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_IERC20_$11786_$", + "typeString": "type(contract IERC20)" + } + }, + "id": 9218, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1643:14:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_IERC20_$11786", + "typeString": "contract IERC20" + } + }, + "id": 9219, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balanceOf", + "nodeType": "MemberAccess", + "referencedDeclaration": 11731, + "src": "1643:24:30", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$", + "typeString": "function (address) view external returns (uint256)" + } + }, + "id": 9221, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1643:31:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "functionReturnParameters": 9212, + "id": 9222, + "nodeType": "Return", + "src": "1636:38:30" + } + ] + } + } + ] + }, + "documentation": "@dev Check the token balance of a wallet in a token contract\nReturns the balance of the token for user. Avoids possible errors:\n- return 0 on non-contract address*", + "id": 9229, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "balanceOf", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9209, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9206, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 9229, + "src": "1480:13:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9205, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1480:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9208, + "name": "_token", + "nodeType": "VariableDeclaration", + "scope": 9229, + "src": "1495:14:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9207, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1495:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1479:31:30" + }, + "returnParameters": { + "id": 9212, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9211, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9229, + "src": "1532:4:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9210, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "1532:4:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1531:6:30" + }, + "scope": 9322, + "src": "1461:269:30", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + }, + { + "body": { + "id": 9320, + "nodeType": "Block", + "src": "1933:635:30", + "statements": [ + { + "assignments": [ + 9241 + ], + "declarations": [ + { + "constant": false, + "id": 9241, + "name": "core", + "nodeType": "VariableDeclaration", + "scope": 9320, + "src": "1944:20:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + }, + "typeName": { + "contractScope": null, + "id": 9240, + "name": "LendingPoolCore", + "nodeType": "UserDefinedTypeName", + "referencedDeclaration": 6682, + "src": "1944:15:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9247, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9243, + "name": "provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9186, + "src": "1983:8:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9244, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getLendingPoolCore", + "nodeType": "MemberAccess", + "referencedDeclaration": 1116, + "src": "1983:27:30", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_payable_$", + "typeString": "function () view external returns (address payable)" + } + }, + "id": 9245, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1983:29:30", + "typeDescriptions": { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address_payable", + "typeString": "address payable" + } + ], + "id": 9242, + "name": "LendingPoolCore", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 6682, + "src": "1967:15:30", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_LendingPoolCore_$6682_$", + "typeString": "type(contract LendingPoolCore)" + } + }, + "id": 9246, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "1967:46:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "1944:69:30" + }, + { + "assignments": [ + 9251 + ], + "declarations": [ + { + "constant": false, + "id": 9251, + "name": "reserves", + "nodeType": "VariableDeclaration", + "scope": 9320, + "src": "2024:25:30", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 9249, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2024:7:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 9250, + "length": null, + "nodeType": "ArrayTypeName", + "src": "2024:9:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9255, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9252, + "name": "core", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9241, + "src": "2052:4:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolCore_$6682", + "typeString": "contract LendingPoolCore" + } + }, + "id": 9253, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getReserves", + "nodeType": "MemberAccess", + "referencedDeclaration": 6134, + "src": "2052:16:30", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_array$_t_address_$dyn_memory_ptr_$", + "typeString": "function () view external returns (address[] memory)" + } + }, + "id": 9254, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2052:18:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2024:46:30" + }, + { + "assignments": [ + 9257 + ], + "declarations": [ + { + "constant": false, + "id": 9257, + "name": "ethereumAddress", + "nodeType": "VariableDeclaration", + "scope": 9320, + "src": "2080:23:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9256, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "2080:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9265, + "initialValue": { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "arguments": [], + "expression": { + "argumentTypes": [], + "expression": { + "argumentTypes": null, + "id": 9259, + "name": "provider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9186, + "src": "2131:8:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_LendingPoolAddressesProvider_$1357", + "typeString": "contract LendingPoolAddressesProvider" + } + }, + "id": 9260, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getNetworkMetadataProvider", + "nodeType": "MemberAccess", + "referencedDeclaration": 1216, + "src": "2131:35:30", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 9261, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2131:37:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9258, + "name": "INetworkMetadataProvider", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 1932, + "src": "2106:24:30", + "typeDescriptions": { + "typeIdentifier": "t_type$_t_contract$_INetworkMetadataProvider_$1932_$", + "typeString": "type(contract INetworkMetadataProvider)" + } + }, + "id": 9262, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "typeConversion", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2106:63:30", + "typeDescriptions": { + "typeIdentifier": "t_contract$_INetworkMetadataProvider_$1932", + "typeString": "contract INetworkMetadataProvider" + } + }, + "id": 9263, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "getEthereumAddress", + "nodeType": "MemberAccess", + "referencedDeclaration": 1926, + "src": "2106:82:30", + "typeDescriptions": { + "typeIdentifier": "t_function_external_view$__$returns$_t_address_$", + "typeString": "function () view external returns (address)" + } + }, + "id": 9264, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2106:84:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2080:110:30" + }, + { + "assignments": [ + 9269 + ], + "declarations": [ + { + "constant": false, + "id": 9269, + "name": "balances", + "nodeType": "VariableDeclaration", + "scope": 9320, + "src": "2201:22:30", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", + "typeString": "uint256[]" + }, + "typeName": { + "baseType": { + "id": 9267, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "2201:4:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9268, + "length": null, + "nodeType": "ArrayTypeName", + "src": "2201:6:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", + "typeString": "uint256[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9276, + "initialValue": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 9273, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9251, + "src": "2237:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 9274, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "length", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2237:15:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + ], + "id": 9272, + "isConstant": false, + "isLValue": false, + "isPure": true, + "lValueRequested": false, + "nodeType": "NewExpression", + "src": "2226:10:30", + "typeDescriptions": { + "typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_uint256_$dyn_memory_$", + "typeString": "function (uint256) pure returns (uint256[] memory)" + }, + "typeName": { + "baseType": { + "id": 9270, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "2230:4:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9271, + "length": null, + "nodeType": "ArrayTypeName", + "src": "2230:6:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", + "typeString": "uint256[]" + } + } + }, + "id": 9275, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2226:27:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory", + "typeString": "uint256[] memory" + } + }, + "nodeType": "VariableDeclarationStatement", + "src": "2201:52:30" + }, + { + "body": { + "id": 9314, + "nodeType": "Block", + "src": "2307:217:30", + "statements": [ + { + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "id": 9292, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9288, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9251, + "src": "2325:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 9290, + "indexExpression": { + "argumentTypes": null, + "id": 9289, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2334:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2325:11:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "nodeType": "BinaryOperation", + "operator": "!=", + "rightExpression": { + "argumentTypes": null, + "id": 9291, + "name": "ethereumAddress", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9257, + "src": "2340:15:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "src": "2325:30:30", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "falseBody": { + "id": 9312, + "nodeType": "Block", + "src": "2439:75:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9310, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9305, + "name": "balances", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9269, + "src": "2457:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", + "typeString": "uint256[] memory" + } + }, + "id": 9307, + "indexExpression": { + "argumentTypes": null, + "id": 9306, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2466:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "2457:11:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 9308, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9231, + "src": "2471:5:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 9309, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "balance", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2471:13:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2457:27:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9311, + "nodeType": "ExpressionStatement", + "src": "2457:27:30" + } + ] + }, + "id": 9313, + "nodeType": "IfStatement", + "src": "2321:193:30", + "trueBody": { + "id": 9304, + "nodeType": "Block", + "src": "2357:76:30", + "statements": [ + { + "expression": { + "argumentTypes": null, + "id": 9302, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftHandSide": { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9293, + "name": "balances", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9269, + "src": "2375:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", + "typeString": "uint256[] memory" + } + }, + "id": 9295, + "indexExpression": { + "argumentTypes": null, + "id": 9294, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2384:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": true, + "nodeType": "IndexAccess", + "src": "2375:11:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "Assignment", + "operator": "=", + "rightHandSide": { + "argumentTypes": null, + "arguments": [ + { + "argumentTypes": null, + "id": 9297, + "name": "_user", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9231, + "src": "2399:5:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + { + "argumentTypes": null, + "baseExpression": { + "argumentTypes": null, + "id": 9298, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9251, + "src": "2406:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 9300, + "indexExpression": { + "argumentTypes": null, + "id": 9299, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2415:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "isConstant": false, + "isLValue": true, + "isPure": false, + "lValueRequested": false, + "nodeType": "IndexAccess", + "src": "2406:11:30", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + } + ], + "expression": { + "argumentTypes": [ + { + "typeIdentifier": "t_address", + "typeString": "address" + }, + { + "typeIdentifier": "t_address", + "typeString": "address" + } + ], + "id": 9296, + "name": "balanceOf", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9229, + "src": "2389:9:30", + "typeDescriptions": { + "typeIdentifier": "t_function_internal_view$_t_address_$_t_address_$returns$_t_uint256_$", + "typeString": "function (address,address) view returns (uint256)" + } + }, + "id": 9301, + "isConstant": false, + "isLValue": false, + "isPure": false, + "kind": "functionCall", + "lValueRequested": false, + "names": [], + "nodeType": "FunctionCall", + "src": "2389:29:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2375:43:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9303, + "nodeType": "ExpressionStatement", + "src": "2375:43:30" + } + ] + } + } + ] + }, + "condition": { + "argumentTypes": null, + "commonType": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "id": 9284, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "leftExpression": { + "argumentTypes": null, + "id": 9281, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2281:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "nodeType": "BinaryOperation", + "operator": "<", + "rightExpression": { + "argumentTypes": null, + "expression": { + "argumentTypes": null, + "id": 9282, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9251, + "src": "2285:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + "id": 9283, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "memberName": "length", + "nodeType": "MemberAccess", + "referencedDeclaration": null, + "src": "2285:15:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "src": "2281:19:30", + "typeDescriptions": { + "typeIdentifier": "t_bool", + "typeString": "bool" + } + }, + "id": 9315, + "initializationExpression": { + "assignments": [ + 9278 + ], + "declarations": [ + { + "constant": false, + "id": 9278, + "name": "j", + "nodeType": "VariableDeclaration", + "scope": 9315, + "src": "2269:6:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + }, + "typeName": { + "id": 9277, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "2269:4:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "value": null, + "visibility": "internal" + } + ], + "id": 9280, + "initialValue": { + "argumentTypes": null, + "hexValue": "30", + "id": 9279, + "isConstant": false, + "isLValue": false, + "isPure": true, + "kind": "number", + "lValueRequested": false, + "nodeType": "Literal", + "src": "2278:1:30", + "subdenomination": null, + "typeDescriptions": { + "typeIdentifier": "t_rational_0_by_1", + "typeString": "int_const 0" + }, + "value": "0" + }, + "nodeType": "VariableDeclarationStatement", + "src": "2269:10:30" + }, + "loopExpression": { + "expression": { + "argumentTypes": null, + "id": 9286, + "isConstant": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "UnaryOperation", + "operator": "++", + "prefix": false, + "src": "2302:3:30", + "subExpression": { + "argumentTypes": null, + "id": 9285, + "name": "j", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9278, + "src": "2302:1:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9287, + "nodeType": "ExpressionStatement", + "src": "2302:3:30" + }, + "nodeType": "ForStatement", + "src": "2264:260:30" + }, + { + "expression": { + "argumentTypes": null, + "components": [ + { + "argumentTypes": null, + "id": 9316, + "name": "reserves", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9251, + "src": "2542:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[] memory" + } + }, + { + "argumentTypes": null, + "id": 9317, + "name": "balances", + "nodeType": "Identifier", + "overloadedDeclarations": [], + "referencedDeclaration": 9269, + "src": "2552:8:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", + "typeString": "uint256[] memory" + } + } + ], + "id": 9318, + "isConstant": false, + "isInlineArray": false, + "isLValue": false, + "isPure": false, + "lValueRequested": false, + "nodeType": "TupleExpression", + "src": "2541:20:30", + "typeDescriptions": { + "typeIdentifier": "t_tuple$_t_array$_t_address_$dyn_memory_ptr_$_t_array$_t_uint256_$dyn_memory_ptr_$", + "typeString": "tuple(address[] memory,uint256[] memory)" + } + }, + "functionReturnParameters": 9239, + "id": 9319, + "nodeType": "Return", + "src": "2534:27:30" + } + ] + }, + "documentation": "@dev provides balances of user wallet for all reserves available on the pool", + "id": 9321, + "implemented": true, + "kind": "function", + "modifiers": [], + "name": "getUserWalletBalances", + "nodeType": "FunctionDefinition", + "parameters": { + "id": 9232, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9231, + "name": "_user", + "nodeType": "VariableDeclaration", + "scope": 9321, + "src": "1864:13:30", + "stateVariable": false, + "storageLocation": "default", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + }, + "typeName": { + "id": 9230, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1864:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1863:15:30" + }, + "returnParameters": { + "id": 9239, + "nodeType": "ParameterList", + "parameters": [ + { + "constant": false, + "id": 9235, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9321, + "src": "1900:16:30", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_memory_ptr", + "typeString": "address[]" + }, + "typeName": { + "baseType": { + "id": 9233, + "name": "address", + "nodeType": "ElementaryTypeName", + "src": "1900:7:30", + "stateMutability": "nonpayable", + "typeDescriptions": { + "typeIdentifier": "t_address", + "typeString": "address" + } + }, + "id": 9234, + "length": null, + "nodeType": "ArrayTypeName", + "src": "1900:9:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_address_$dyn_storage_ptr", + "typeString": "address[]" + } + }, + "value": null, + "visibility": "internal" + }, + { + "constant": false, + "id": 9238, + "name": "", + "nodeType": "VariableDeclaration", + "scope": 9321, + "src": "1918:13:30", + "stateVariable": false, + "storageLocation": "memory", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr", + "typeString": "uint256[]" + }, + "typeName": { + "baseType": { + "id": 9236, + "name": "uint", + "nodeType": "ElementaryTypeName", + "src": "1918:4:30", + "typeDescriptions": { + "typeIdentifier": "t_uint256", + "typeString": "uint256" + } + }, + "id": 9237, + "length": null, + "nodeType": "ArrayTypeName", + "src": "1918:6:30", + "typeDescriptions": { + "typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr", + "typeString": "uint256[]" + } + }, + "value": null, + "visibility": "internal" + } + ], + "src": "1899:33:30" + }, + "scope": 9322, + "src": "1833:735:30", + "stateMutability": "view", + "superFunction": null, + "visibility": "public" + } + ], + "scope": 9323, + "src": "878:1692:30" + } + ], + "src": "0:2570:30" + }, + "compiler": { + "name": "solc", + "version": "0.5.8+commit.23d335f2.Emscripten.clang" + }, + "networks": {}, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T14:57:54.845Z", + "devdoc": { + "author": "Aave, influenced by https://github.com/wbobeirne/eth-balance-checker/blob/master/contracts/BalanceChecker.sol", + "details": "NOTE: THIS CONTRACT IS NOT USED WITHIN THE AAVE PROTOCOL. It's an accessory contract used to reduce the number of calls towards the blockchain.************************************************************************************", + "methods": { + "balanceOf(address,address)": { + "details": "Check the token balance of a wallet in a token contract Returns the balance of the token for user. Avoids possible errors: - return 0 on non-contract address*" + }, + "getUserWalletBalances(address)": { + "details": "provides balances of user wallet for all reserves available on the pool" + } + }, + "title": "WalletBalanceProvider contract" + }, + "userdoc": { + "methods": {}, + "notice": "***********************************************************************************Implements a logic of getting multiple tokens balance for one user address" + } +} \ No newline at end of file diff --git a/client/src/contracts/uniswap_exchange_custom.json b/client/src/contracts/uniswap_exchange_custom.json new file mode 100644 index 0000000..42deae9 --- /dev/null +++ b/client/src/contracts/uniswap_exchange_custom.json @@ -0,0 +1,1169 @@ +{ + "contractName": "uniswap_exchange_custom", + "abi": [ + { + "name": "TokenPurchase", + "inputs": [ + { + "type": "address", + "name": "buyer", + "indexed": true + }, + { + "type": "uint256", + "name": "eth_sold", + "indexed": true + }, + { + "type": "uint256", + "name": "tokens_bought", + "indexed": true + } + ], + "anonymous": false, + "type": "event" + }, + { + "name": "EthPurchase", + "inputs": [ + { + "type": "address", + "name": "buyer", + "indexed": true + }, + { + "type": "uint256", + "name": "tokens_sold", + "indexed": true + }, + { + "type": "uint256", + "name": "eth_bought", + "indexed": true + } + ], + "anonymous": false, + "type": "event" + }, + { + "name": "AddLiquidity", + "inputs": [ + { + "type": "address", + "name": "provider", + "indexed": true + }, + { + "type": "uint256", + "name": "eth_amount", + "indexed": true + }, + { + "type": "uint256", + "name": "token_amount", + "indexed": true + } + ], + "anonymous": false, + "type": "event" + }, + { + "name": "RemoveLiquidity", + "inputs": [ + { + "type": "address", + "name": "provider", + "indexed": true + }, + { + "type": "uint256", + "name": "eth_amount", + "indexed": true + }, + { + "type": "uint256", + "name": "token_amount", + "indexed": true + } + ], + "anonymous": false, + "type": "event" + }, + { + "name": "Transfer", + "inputs": [ + { + "type": "address", + "name": "_from", + "indexed": true + }, + { + "type": "address", + "name": "_to", + "indexed": true + }, + { + "type": "uint256", + "name": "_value", + "indexed": false + } + ], + "anonymous": false, + "type": "event" + }, + { + "name": "Approval", + "inputs": [ + { + "type": "address", + "name": "_owner", + "indexed": true + }, + { + "type": "address", + "name": "_spender", + "indexed": true + }, + { + "type": "uint256", + "name": "_value", + "indexed": false + } + ], + "anonymous": false, + "type": "event" + }, + { + "name": "setup", + "outputs": [], + "inputs": [ + { + "type": "address", + "name": "token_addr" + }, + { + "type": "uint256", + "name": "token_id" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 210890 + }, + { + "name": "addLiquidity", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "min_liquidity" + }, + { + "type": "uint256", + "name": "max_tokens" + }, + { + "type": "uint256", + "name": "deadline" + } + ], + "constant": false, + "payable": true, + "type": "function", + "gas": 82616 + }, + { + "name": "removeLiquidity", + "outputs": [ + { + "type": "uint256", + "name": "out" + }, + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "amount" + }, + { + "type": "uint256", + "name": "min_eth" + }, + { + "type": "uint256", + "name": "min_tokens" + }, + { + "type": "uint256", + "name": "deadline" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 116814 + }, + { + "name": "__default__", + "outputs": [], + "inputs": [], + "constant": false, + "payable": true, + "type": "function" + }, + { + "name": "ethToTokenSwapInput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "min_tokens" + }, + { + "type": "uint256", + "name": "deadline" + } + ], + "constant": false, + "payable": true, + "type": "function", + "gas": 12757 + }, + { + "name": "ethToTokenTransferInput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "min_tokens" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "address", + "name": "recipient" + } + ], + "constant": false, + "payable": true, + "type": "function", + "gas": 12965 + }, + { + "name": "ethToTokenSwapOutput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_bought" + }, + { + "type": "uint256", + "name": "deadline" + } + ], + "constant": false, + "payable": true, + "type": "function", + "gas": 50463 + }, + { + "name": "ethToTokenTransferOutput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_bought" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "address", + "name": "recipient" + } + ], + "constant": false, + "payable": true, + "type": "function", + "gas": 50671 + }, + { + "name": "tokenToEthSwapInput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_sold" + }, + { + "type": "uint256", + "name": "min_eth" + }, + { + "type": "uint256", + "name": "deadline" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 43031 + }, + { + "name": "tokenToEthTransferInput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_sold" + }, + { + "type": "uint256", + "name": "min_eth" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "address", + "name": "recipient" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 43240 + }, + { + "name": "tokenToEthSwapOutput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "eth_bought" + }, + { + "type": "uint256", + "name": "max_tokens" + }, + { + "type": "uint256", + "name": "deadline" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 50175 + }, + { + "name": "tokenToEthTransferOutput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "eth_bought" + }, + { + "type": "uint256", + "name": "max_tokens" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "address", + "name": "recipient" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 50384 + }, + { + "name": "tokenToTokenSwapInput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_sold" + }, + { + "type": "uint256", + "name": "min_tokens_bought" + }, + { + "type": "uint256", + "name": "min_eth_bought" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "uint256", + "name": "token_addr" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 50968 + }, + { + "name": "tokenToTokenTransferInput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_sold" + }, + { + "type": "uint256", + "name": "min_tokens_bought" + }, + { + "type": "uint256", + "name": "min_eth_bought" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "address", + "name": "recipient" + }, + { + "type": "uint256", + "name": "token_addr" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 51059 + }, + { + "name": "tokenToTokenSwapOutput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_bought" + }, + { + "type": "uint256", + "name": "max_tokens_sold" + }, + { + "type": "uint256", + "name": "max_eth_sold" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "uint256", + "name": "token_addr" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 54889 + }, + { + "name": "tokenToTokenTransferOutput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_bought" + }, + { + "type": "uint256", + "name": "max_tokens_sold" + }, + { + "type": "uint256", + "name": "max_eth_sold" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "address", + "name": "recipient" + }, + { + "type": "uint256", + "name": "token_addr" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 54980 + }, + { + "name": "tokenToExchangeSwapInput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_sold" + }, + { + "type": "uint256", + "name": "min_tokens_bought" + }, + { + "type": "uint256", + "name": "min_eth_bought" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "address", + "name": "exchange_addr" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 49342 + }, + { + "name": "tokenToExchangeTransferInput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_sold" + }, + { + "type": "uint256", + "name": "min_tokens_bought" + }, + { + "type": "uint256", + "name": "min_eth_bought" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "address", + "name": "recipient" + }, + { + "type": "address", + "name": "exchange_addr" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 49532 + }, + { + "name": "tokenToExchangeSwapOutput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_bought" + }, + { + "type": "uint256", + "name": "max_tokens_sold" + }, + { + "type": "uint256", + "name": "max_eth_sold" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "address", + "name": "exchange_addr" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 53233 + }, + { + "name": "tokenToExchangeTransferOutput", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_bought" + }, + { + "type": "uint256", + "name": "max_tokens_sold" + }, + { + "type": "uint256", + "name": "max_eth_sold" + }, + { + "type": "uint256", + "name": "deadline" + }, + { + "type": "address", + "name": "recipient" + }, + { + "type": "address", + "name": "exchange_addr" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 53423 + }, + { + "name": "getEthToTokenInputPrice", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "eth_sold" + } + ], + "constant": true, + "payable": false, + "type": "function", + "gas": 5542 + }, + { + "name": "getEthToTokenOutputPrice", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_bought" + } + ], + "constant": true, + "payable": false, + "type": "function", + "gas": 6872 + }, + { + "name": "getTokenToEthInputPrice", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "tokens_sold" + } + ], + "constant": true, + "payable": false, + "type": "function", + "gas": 5637 + }, + { + "name": "getTokenToEthOutputPrice", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "eth_bought" + } + ], + "constant": true, + "payable": false, + "type": "function", + "gas": 6897 + }, + { + "name": "tokenAddress", + "outputs": [ + { + "type": "address", + "name": "out" + } + ], + "inputs": [], + "constant": true, + "payable": false, + "type": "function", + "gas": 1413 + }, + { + "name": "factoryAddress", + "outputs": [ + { + "type": "address", + "name": "out" + } + ], + "inputs": [], + "constant": true, + "payable": false, + "type": "function", + "gas": 1443 + }, + { + "name": "balanceOf", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "address", + "name": "_owner" + } + ], + "constant": true, + "payable": false, + "type": "function", + "gas": 1645 + }, + { + "name": "transfer", + "outputs": [ + { + "type": "bool", + "name": "out" + } + ], + "inputs": [ + { + "type": "address", + "name": "_to" + }, + { + "type": "uint256", + "name": "_value" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 75034 + }, + { + "name": "transferFrom", + "outputs": [ + { + "type": "bool", + "name": "out" + } + ], + "inputs": [ + { + "type": "address", + "name": "_from" + }, + { + "type": "address", + "name": "_to" + }, + { + "type": "uint256", + "name": "_value" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 110907 + }, + { + "name": "approve", + "outputs": [ + { + "type": "bool", + "name": "out" + } + ], + "inputs": [ + { + "type": "address", + "name": "_spender" + }, + { + "type": "uint256", + "name": "_value" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 38769 + }, + { + "name": "allowance", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [ + { + "type": "address", + "name": "_owner" + }, + { + "type": "address", + "name": "_spender" + } + ], + "constant": true, + "payable": false, + "type": "function", + "gas": 1925 + }, + { + "name": "name", + "outputs": [ + { + "type": "bytes32", + "name": "out" + } + ], + "inputs": [], + "constant": true, + "payable": false, + "type": "function", + "gas": 1623 + }, + { + "name": "symbol", + "outputs": [ + { + "type": "bytes32", + "name": "out" + } + ], + "inputs": [], + "constant": true, + "payable": false, + "type": "function", + "gas": 1653 + }, + { + "name": "decimals", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [], + "constant": true, + "payable": false, + "type": "function", + "gas": 1683 + }, + { + "name": "totalSupply", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [], + "constant": true, + "payable": false, + "type": "function", + "gas": 1713 + } + ], + "bytecode": "0x612fc356600035601c52740100000000000000000000000000000000000000006020526f7fffffffffffffffffffffffffffffff6040527fffffffffffffffffffffffffffffffff8000000000000000000000000000000060605274012a05f1fffffffffffffffffffffffffdabf41c006080527ffffffffffffffffffffffffed5fa0e000000000000000000000000000000000060a05263f46d1982600051141561014257604060046101403734156100b457600080fd5b60043560205181106100c557600080fd5b506000610140511415600654156007541516166100e157600080fd5b3360075561014051600655610160516008557f556e6973776170205631000000000000000000000000000000000000000000006000557f554e492d563100000000000000000000000000000000000000000000000000006001556012600255005b63422f104360005114156105b25760606004610140376000341160006101605111164261018051111661017457600080fd5b6003546101a05260006101a0511115610445576000610140511161019757600080fd5b34303110156101a557600080fd5b343031036103a0526006543b6101ba57600080fd5b6006543014156101c957600080fd5b602061046060246370a082316103e05230610400526103fc6006545afa6101ef57600080fd5b600050610460516103c0526103a05161020757600080fd5b6103a051341515610219576000610236565b6103c051346103c0513402041461022f57600080fd5b6103c05134025b0460016103a05161024657600080fd5b6103a051341515610258576000610275565b6103c051346103c0513402041461026e57600080fd5b6103c05134025b0401101561028257600080fd5b60016103a05161029157600080fd5b6103a0513415156102a35760006102c0565b6103c051346103c051340204146102b957600080fd5b6103c05134025b0401610480526103a0516102d357600080fd5b6103a0513415156102e5576000610302565b6101a051346101a051340204146102fb57600080fd5b6101a05134025b046104a052610140516104a0511015610480516101605110151661032557600080fd5b60043360e05260c052604060c02080546104a051825401101561034757600080fd5b6104a0518154018155506101a0516104a0516101a05101101561036957600080fd5b6104a0516101a051016003556006543b61038257600080fd5b60065430141561039157600080fd5b602061058060646323b872dd6104c052336104e052306105005261048051610520526104dc60006006545af16103c657600080fd5b600050610580516103d657600080fd5b6104805134337f06239653922ac7bea6aa2b19dc486b9361821d37712eb796adfd38d81de278ca60006000a46104a0516105a0523360007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60206105a0a36104a05160005260206000f36105b0565b633b9aca003410156000600654141560006007541415161661046657600080fd5b306007543b61047457600080fd5b60075430141561048357600080fd5b60206102406024630b9d58476101c0526008546101e0526101dc6007545afa6104ab57600080fd5b60005061024051146104bc57600080fd5b6101605161026052303161028052610280516003556102805160043360e05260c052604060c020556006543b6104f157600080fd5b60065430141561050057600080fd5b602061036060646323b872dd6102a052336102c052306102e05261026051610300526102bc60006006545af161053557600080fd5b6000506103605161054557600080fd5b6102605134337f06239653922ac7bea6aa2b19dc486b9361821d37712eb796adfd38d81de278ca60006000a461028051610380523360007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef6020610380a36102805160005260206000f35b005b63f88bf15a600051141561085157608060046101403734156105d357600080fd5b600061018051116000610160511116426101a051116000610140511116166105fa57600080fd5b6003546101c05260006101c0511161061157600080fd5b6006543b61061e57600080fd5b60065430141561062d57600080fd5b602061028060246370a0823161020052306102205261021c6006545afa61065357600080fd5b600050610280516101e0526101c05161066b57600080fd5b6101c0516101405115156106805760006106a0565b30316101405130316101405102041461069857600080fd5b303161014051025b046102a0526101c0516106b257600080fd5b6101c0516101405115156106c75760006106ed565b6101e051610140516101e051610140510204146106e357600080fd5b6101e05161014051025b046102c052610180516102c0511015610160516102a05110151661071057600080fd5b60043360e05260c052604060c020610140518154101561072f57600080fd5b61014051815403815550610140516101c051101561074c57600080fd5b610140516101c0510360035560006000600060006102a051336000f161077157600080fd5b6006543b61077e57600080fd5b60065430141561078d57600080fd5b6020610380604463a9059cbb6102e05233610300526102c051610320526102fc60006006545af16107bd57600080fd5b600050610380516107cd57600080fd5b6102c0516102a051337f0fbf06c058b90cb038a618f8c2acbf6145f8b3570fd1fa56abb8f0f3f05b36e860006000a4610140516103a0526000337fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60206103a0a360406103c0526103e06102a05181526102c0518160200152506103c0516103e0f3005b6000156109cd575b6101a05261014052610160526101805260006101805111600061016051111661088157600080fd5b6101405115156108925760006108b5565b6103e5610140516103e5610140510204146108ac57600080fd5b6103e561014051025b6101c0526101c05115156108ca5760006108f0565b610180516101c051610180516101c0510204146108e657600080fd5b610180516101c051025b6101e052610160511515610905576000610928565b6103e8610160516103e86101605102041461091f57600080fd5b6103e861016051025b6101c05161016051151561093d576000610960565b6103e8610160516103e86101605102041461095757600080fd5b6103e861016051025b01101561096c57600080fd5b6101c0516101605115156109815760006109a4565b6103e8610160516103e86101605102041461099b57600080fd5b6103e861016051025b0161020052610200516109b657600080fd5b610200516101e051046000526000516101a0515650005b600015610bfa575b6101a0526101405261016052610180526000610180511160006101605111166109fd57600080fd5b610160511515610a0e576000610a34565b61014051610160516101405161016051020414610a2a57600080fd5b6101405161016051025b1515610a41576000610afd565b6103e8610160511515610a55576000610a7b565b61014051610160516101405161016051020414610a7157600080fd5b6101405161016051025b6103e8610160511515610a8f576000610ab5565b61014051610160516101405161016051020414610aab57600080fd5b6101405161016051025b020414610ac157600080fd5b6103e8610160511515610ad5576000610afb565b61014051610160516101405161016051020414610af157600080fd5b6101405161016051025b025b6101c05261014051610180511015610b1457600080fd5b6101405161018051031515610b2a576000610b95565b6103e561014051610180511015610b4057600080fd5b6101405161018051036103e561014051610180511015610b5f57600080fd5b610140516101805103020414610b7457600080fd5b6103e561014051610180511015610b8a57600080fd5b610140516101805103025b6101e0526101e051610ba657600080fd5b6101e0516101c0510460016101e051610bbe57600080fd5b6101e0516101c05104011015610bd357600080fd5b60016101e051610be257600080fd5b6101e0516101c05104016000526000516101a0515650005b600015610dfb575b6101e0526101405261016052610180526101a0526101c0526000610160511160006101405111164261018051101516610c3a57600080fd5b6006543b610c4757600080fd5b600654301415610c5657600080fd5b60206102a060246370a0823161022052306102405261023c6006545afa610c7c57600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c0516389f2a8716102e05261014051610300526101405130311015610cdd57600080fd5b6101405130310361032052610200516103405261034051610320516103005160065801610859565b6103a0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103a0516102c052610160516102c0511015610d5857600080fd5b6006543b610d6557600080fd5b600654301415610d7457600080fd5b6020610460604463a9059cbb6103c0526101c0516103e0526102c051610400526103dc60006006545af1610da757600080fd5b60005061046051610db757600080fd5b6102c051610140516101a0517fcd60aa75dea3072fbc07ae6d7d856b5dc5f4eee88854f5b4abf7b680ef8bc50f60006000a46102c0516000526000516101e0515650005b63f39b5b9b6000511415610e785760406004610140376101405161016051638c717a3361018052346101a052610140516101c052610160516101e0523361020052336102205261022051610200516101e0516101c0516101a05160065801610c02565b6102805261016052610140526102805160005260206000f3005b63ad65d76d6000511415610f2b5760606004610140376044356020518110610e9f57600080fd5b5060006101805114153061018051141516610eb957600080fd5b610140516101605161018051638c717a336101a052346101c052610140516101e0526101605161020052336102205261018051610240526102405161022051610200516101e0516101c05160065801610c02565b6102a0526101805261016052610140526102a05160005260206000f3005b600015611173575b6101e0526101405261016052610180526101a0526101c0526000610160511160006101405111164261018051101516610f6b57600080fd5b6006543b610f7857600080fd5b600654301415610f8757600080fd5b60206102a060246370a0823161022052306102405261023c6006545afa610fad57600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c05163fd11c2236102e0526101405161030052610160513031101561100e57600080fd5b61016051303103610320526102005161034052610340516103205161030051600658016109d5565b6103a0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103a0516102c05260016102c051026103e0526103e05161016051101561109457600080fd5b6103e05161016051036103c05260006103c05111156110ca5760006000600060006103c0516101a0516000f16110c957600080fd5b5b6006543b6110d757600080fd5b6006543014156110e657600080fd5b60206104a0604463a9059cbb610400526101c05161042052610140516104405261041c60006006545af161111957600080fd5b6000506104a05161112957600080fd5b6101405160016102c051026101a0517fcd60aa75dea3072fbc07ae6d7d856b5dc5f4eee88854f5b4abf7b680ef8bc50f60006000a460016102c051026000526000516101e0515650005b636b1d4db760005114156111f05760406004610140376101405161016051632dff394e61018052610140516101a052346101c052610160516101e0523361020052336102205261022051610200516101e0516101c0516101a05160065801610f33565b6102805261016052610140526102805160005260206000f3005b630b57363860005114156112a3576060600461014037604435602051811061121757600080fd5b506000610180511415306101805114151661123157600080fd5b610140516101605161018051632dff394e6101a052610140516101c052346101e0526101605161020052336102205261018051610240526102405161022051610200516101e0516101c05160065801610f33565b6102a0526101805261016052610140526102a05160005260206000f3005b600015611422575b6101e0526101405261016052610180526101a0526101c05260006101605111600061014051111642610180511015166112e357600080fd5b6006543b6112f057600080fd5b6006543014156112ff57600080fd5b60206102a060246370a0823161022052306102405261023c6006545afa61132557600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c0516389f2a8716102e0526101405161030052610200516103205230316103405261034051610320516103005160065801610859565b6103a0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103a0516102c05260016102c051026103c052610160516103c05110156113f657600080fd5b60006000600060006103c0516101c0516000f161141257600080fd5b60006000526000516101e0515650005b6395e3c50b60005114156114b5576060600461014037341561144357600080fd5b61014051610160516101805163fa1bb7be6101a052610140516101c052610160516101e0526101805161020052336102205233610240526102405161022051610200516101e0516101c051600658016112ab565b6102a0526101805261016052610140526102a05160005260206000f3005b637237e031600051141561157e57608060046101403734156114d657600080fd5b60643560205181106114e757600080fd5b5060006101a0511415306101a05114151661150157600080fd5b6101405161016051610180516101a05163fa1bb7be6101c052610140516101e0526101605161020052610180516102205233610240526101a05161026052610260516102405161022051610200516101e051600658016112ab565b6102c0526101a0526101805261016052610140526102c05160005260206000f3005b600015611782575b6101e0526101405261016052610180526101a0526101c0526000610140511142610180511015166115b657600080fd5b6006543b6115c357600080fd5b6006543014156115d257600080fd5b60206102a060246370a0823161022052306102405261023c6006545afa6115f857600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c05163fd11c2236102e05261014051610300526102005161032052303161034052610340516103205161030051600658016109d5565b6103a0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103a0516102c0526102c0516101605110156116be57600080fd5b6000600060006000610140516101c0516000f16116da57600080fd5b6006543b6116e757600080fd5b6006543014156116f657600080fd5b602061048060646323b872dd6103c0526101a0516103e05230610400526102c051610420526103dc60006006545af161172e57600080fd5b6000506104805161173e57600080fd5b610140516102c0516101a0517f7f4091b46c33e918a0f3aa42307641d17bb67029427a5369e54b35398423870560006000a46102c0516000526000516101e0515650005b63013efd8b600051141561181557606060046101403734156117a357600080fd5b61014051610160516101805163984fe8f66101a052610140516101c052610160516101e0526101805161020052336102205233610240526102405161022051610200516101e0516101c05160065801611586565b6102a0526101805261016052610140526102a05160005260206000f3005b63d4e4841d60005114156118de576080600461014037341561183657600080fd5b606435602051811061184757600080fd5b5060006101a0511415306101a05114151661186157600080fd5b6101405161016051610180516101a05163984fe8f66101c052610140516101e0526101605161020052610180516102205233610240526101a05161026052610260516102405161022051610200516101e05160065801611586565b6102c0526101a0526101805261016052610140526102c05160005260206000f3005b600015611b79575b610220526101405261016052610180526101a0526101c0526101e0526102005260006101805111600061016051111660006101405111426101a0511015161661192e57600080fd5b6000610200511415306102005114151661194757600080fd5b6006543b61195457600080fd5b60065430141561196357600080fd5b60206102e060246370a0823161026052306102805261027c6006545afa61198957600080fd5b6000506102e051610240526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c0516102e051610300516389f2a871610320526101405161034052610240516103605230316103805261038051610360516103405160065801610859565b6103e052610300526102e0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103e05161030052600161030051026104005261018051610400511015611a6a57600080fd5b6006543b611a7757600080fd5b600654301415611a8657600080fd5b60206104e060646323b872dd610420526101c051610440523061046052610140516104805261043c60006006545af1611abe57600080fd5b6000506104e051611ace57600080fd5b610200513b611adc57600080fd5b61020051301415611aec57600080fd5b60206105e0606463ad65d76d6105205261016051610540526101a051610560526101e0516105805261053c61040051610200515af1611b2a57600080fd5b6000506105e0516105005261040051610140516101c0517f7f4091b46c33e918a0f3aa42307641d17bb67029427a5369e54b35398423870560006000a461050051600052600051610220515650005b637c3755c46000511415611cb45760a06004610140373415611b9a57600080fd5b6007543b611ba757600080fd5b600754301415611bb657600080fd5b60206102806024630b9d5847610200526101c0516102205261021c6007545afa611bdf57600080fd5b600050610280516101e0526101405161016051610180516101a0516101c0516101e051610200516102205161024051610260516102805163204ea33b6102a052610140516102c052610160516102e05261018051610300526101a05161032052336103405233610360526101e0516103805261038051610360516103405161032051610300516102e0516102c051600658016118e6565b6103e05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103e05160005260206000f3005b6391ff65e46000511415611e0c5760c06004610140373415611cd557600080fd5b6084356020518110611ce657600080fd5b506007543b611cf457600080fd5b600754301415611d0357600080fd5b60206102a06024630b9d5847610220526101e0516102405261023c6007545afa611d2c57600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a05163204ea33b6102c052610140516102e052610160516103005261018051610320526101a0516103405233610360526101c05161038052610200516103a0526103a05161038051610360516103405161032051610300516102e051600658016118e6565b610400526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526104005160005260206000f3005b600015612122575b610220526101405261016052610180526101a0526101c0526101e05261020052600061018051116000610140511116426101a051101516611e5457600080fd5b60006102005114153061020051141516611e6d57600080fd5b610200513b611e7b57600080fd5b61020051301415611e8b57600080fd5b60206102e060246359e9486261026052610140516102805261027c610200515afa611eb557600080fd5b6000506102e051610240526006543b611ecd57600080fd5b600654301415611edc57600080fd5b60206103a060246370a0823161032052306103405261033c6006545afa611f0257600080fd5b6000506103a051610300526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c0516102e05161030051610320516103405161036051610380516103a0516103c05163fd11c2236103e05261024051610400526103005161042052303161044052610440516104205161040051600658016109d5565b6104a0526103c0526103a05261038052610360526103405261032052610300526102e0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526104a0516103c052610240516101805110156103c0516101605110151661201357600080fd5b6006543b61202057600080fd5b60065430141561202f57600080fd5b602061058060646323b872dd6104c0526101c0516104e05230610500526103c051610520526104dc60006006545af161206757600080fd5b6000506105805161207757600080fd5b610200513b61208557600080fd5b6102005130141561209557600080fd5b60206106806064630b5736386105c052610140516105e0526101a051610600526101e051610620526105dc61024051610200515af16120d357600080fd5b600050610680516105a052610240516103c0516101c0517f7f4091b46c33e918a0f3aa42307641d17bb67029427a5369e54b35398423870560006000a46103c051600052600051610220515650005b63766b1f93600051141561225d5760a0600461014037341561214357600080fd5b6007543b61215057600080fd5b60075430141561215f57600080fd5b60206102806024630b9d5847610200526101c0516102205261021c6007545afa61218857600080fd5b600050610280516101e0526101405161016051610180516101a0516101c0516101e0516102005161022051610240516102605161028051631a7b28f26102a052610140516102c052610160516102e05261018051610300526101a05161032052336103405233610360526101e0516103805261038051610360516103405161032051610300516102e0516102c05160065801611e14565b6103e05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103e05160005260206000f3005b637796792660005114156123b55760c0600461014037341561227e57600080fd5b608435602051811061228f57600080fd5b506007543b61229d57600080fd5b6007543014156122ac57600080fd5b60206102a06024630b9d5847610220526101e0516102405261023c6007545afa6122d557600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a051631a7b28f26102c052610140516102e052610160516103005261018051610320526101a0516103405233610360526101c05161038052610200516103a0526103a05161038051610360516103405161032051610300516102e05160065801611e14565b610400526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526104005160005260206000f3005b63b1cb43bf60005114156124825760a060046101403734156123d657600080fd5b60843560205181106123e757600080fd5b506101405161016051610180516101a0516101c05163204ea33b6101e0526101405161020052610160516102205261018051610240526101a051610260523361028052336102a0526101c0516102c0526102c0516102a0516102805161026051610240516102205161020051600658016118e6565b610320526101c0526101a0526101805261016052610140526103205160005260206000f3005b63ec384a3e600051141561257c5760c060046101403734156124a357600080fd5b60843560205181106124b457600080fd5b5060a43560205181106124c657600080fd5b50306101c05114156124d757600080fd5b6101405161016051610180516101a0516101c0516101e05163204ea33b610200526101405161022052610160516102405261018051610260526101a05161028052336102a0526101c0516102c0526101e0516102e0526102e0516102c0516102a05161028051610260516102405161022051600658016118e6565b610340526101e0526101c0526101a0526101805261016052610140526103405160005260206000f3005b63ea650c7d60005114156126495760a0600461014037341561259d57600080fd5b60843560205181106125ae57600080fd5b506101405161016051610180516101a0516101c051631a7b28f26101e0526101405161020052610160516102205261018051610240526101a051610260523361028052336102a0526101c0516102c0526102c0516102a051610280516102605161024051610220516102005160065801611e14565b610320526101c0526101a0526101805261016052610140526103205160005260206000f3005b63981a132760005114156127435760c0600461014037341561266a57600080fd5b608435602051811061267b57600080fd5b5060a435602051811061268d57600080fd5b50306101c051141561269e57600080fd5b6101405161016051610180516101a0516101c0516101e051631a7b28f2610200526101405161022052610160516102405261018051610260526101a05161028052336102a0526101c0516102c0526101e0516102e0526102e0516102c0516102a0516102805161026051610240516102205160065801611e14565b610340526101e0526101c0526101a0526101805261016052610140526103405160005260206000f3005b63cd7724c3600051141561283f576020600461014037341561276457600080fd5b6000610140511161277457600080fd5b6006543b61278157600080fd5b60065430141561279057600080fd5b602061020060246370a0823161018052306101a05261019c6006545afa6127b657600080fd5b60005061020051610160526101405161016051610180516101a0516101c0516101e051610200516389f2a871610220526101405161024052303161026052610160516102805261028051610260516102405160065801610859565b6102e052610200526101e0526101c0526101a0526101805261016052610140526102e05160005260206000f3005b6359e94862600051141561294e576020600461014037341561286057600080fd5b6000610140511161287057600080fd5b6006543b61287d57600080fd5b60065430141561288c57600080fd5b602061020060246370a0823161018052306101a05261019c6006545afa6128b257600080fd5b60005061020051610160526101405161016051610180516101a0516101c0516101e051610200516102205163fd11c223610240526101405161026052303161028052610160516102a0526102a0516102805161026051600658016109d5565b6103005261022052610200526101e0526101c0526101a05261018052610160526101405261030051610220526001610220510260005260206000f3005b6395b68fe76000511415612a5d576020600461014037341561296f57600080fd5b6000610140511161297f57600080fd5b6006543b61298c57600080fd5b60065430141561299b57600080fd5b602061020060246370a0823161018052306101a05261019c6006545afa6129c157600080fd5b60005061020051610160526101405161016051610180516101a0516101c0516101e05161020051610220516389f2a871610240526101405161026052610160516102805230316102a0526102a051610280516102605160065801610859565b6103005261022052610200526101e0526101c0526101a05261018052610160526101405261030051610220526001610220510260005260206000f3005b632640f62c6000511415612b595760206004610140373415612a7e57600080fd5b60006101405111612a8e57600080fd5b6006543b612a9b57600080fd5b600654301415612aaa57600080fd5b602061020060246370a0823161018052306101a05261019c6006545afa612ad057600080fd5b60005061020051610160526101405161016051610180516101a0516101c0516101e0516102005163fd11c2236102205261014051610240526101605161026052303161028052610280516102605161024051600658016109d5565b6102e052610200526101e0526101c0526101a0526101805261016052610140526102e05160005260206000f3005b639d76ea586000511415612b7f573415612b7257600080fd5b60065460005260206000f3005b63966dae0e6000511415612ba5573415612b9857600080fd5b60075460005260206000f3005b6370a082316000511415612bf45760206004610140373415612bc657600080fd5b6004356020518110612bd757600080fd5b5060046101405160e05260c052604060c0205460005260206000f3005b63a9059cbb6000511415612cbf5760406004610140373415612c1557600080fd5b6004356020518110612c2657600080fd5b5060043360e05260c052604060c0206101605181541015612c4657600080fd5b6101605181540381555060046101405160e05260c052604060c0208054610160518254011015612c7557600080fd5b61016051815401815550610160516101805261014051337fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef6020610180a3600160005260206000f3005b6323b872dd6000511415612dda5760606004610140373415612ce057600080fd5b6004356020518110612cf157600080fd5b506024356020518110612d0357600080fd5b5060046101405160e05260c052604060c0206101805181541015612d2657600080fd5b6101805181540381555060046101605160e05260c052604060c0208054610180518254011015612d5557600080fd5b6101805181540181555060056101405160e05260c052604060c0203360e05260c052604060c0206101805181541015612d8d57600080fd5b61018051815403815550610180516101a05261016051610140517fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60206101a0a3600160005260206000f3005b63095ea7b36000511415612e6f5760406004610140373415612dfb57600080fd5b6004356020518110612e0c57600080fd5b506101605160053360e05260c052604060c0206101405160e05260c052604060c02055610160516101805261014051337f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9256020610180a3600160005260206000f3005b63dd62ed3e6000511415612edf5760406004610140373415612e9057600080fd5b6004356020518110612ea157600080fd5b506024356020518110612eb357600080fd5b5060056101405160e05260c052604060c0206101605160e05260c052604060c0205460005260206000f3005b6306fdde036000511415612f05573415612ef857600080fd5b60005460005260206000f3005b6395d89b416000511415612f2b573415612f1e57600080fd5b60015460005260206000f3005b63313ce5676000511415612f51573415612f4457600080fd5b60025460005260206000f3005b6318160ddd6000511415612f77573415612f6a57600080fd5b60035460005260206000f3005b638c717a33610140523461016052600161018052426101a052336101c052336101e0526101e0516101c0516101a051610180516101605160065801610c02565b610240526102405b610004612fc303610004600039610004612fc3036000f3", + "deployedBytecode": "0x600035601c52740100000000000000000000000000000000000000006020526f7fffffffffffffffffffffffffffffff6040527fffffffffffffffffffffffffffffffff8000000000000000000000000000000060605274012a05f1fffffffffffffffffffffffffdabf41c006080527ffffffffffffffffffffffffed5fa0e000000000000000000000000000000000060a05263f46d1982600051141561014257604060046101403734156100b457600080fd5b60043560205181106100c557600080fd5b506000610140511415600654156007541516166100e157600080fd5b3360075561014051600655610160516008557f556e6973776170205631000000000000000000000000000000000000000000006000557f554e492d563100000000000000000000000000000000000000000000000000006001556012600255005b63422f104360005114156105b25760606004610140376000341160006101605111164261018051111661017457600080fd5b6003546101a05260006101a0511115610445576000610140511161019757600080fd5b34303110156101a557600080fd5b343031036103a0526006543b6101ba57600080fd5b6006543014156101c957600080fd5b602061046060246370a082316103e05230610400526103fc6006545afa6101ef57600080fd5b600050610460516103c0526103a05161020757600080fd5b6103a051341515610219576000610236565b6103c051346103c0513402041461022f57600080fd5b6103c05134025b0460016103a05161024657600080fd5b6103a051341515610258576000610275565b6103c051346103c0513402041461026e57600080fd5b6103c05134025b0401101561028257600080fd5b60016103a05161029157600080fd5b6103a0513415156102a35760006102c0565b6103c051346103c051340204146102b957600080fd5b6103c05134025b0401610480526103a0516102d357600080fd5b6103a0513415156102e5576000610302565b6101a051346101a051340204146102fb57600080fd5b6101a05134025b046104a052610140516104a0511015610480516101605110151661032557600080fd5b60043360e05260c052604060c02080546104a051825401101561034757600080fd5b6104a0518154018155506101a0516104a0516101a05101101561036957600080fd5b6104a0516101a051016003556006543b61038257600080fd5b60065430141561039157600080fd5b602061058060646323b872dd6104c052336104e052306105005261048051610520526104dc60006006545af16103c657600080fd5b600050610580516103d657600080fd5b6104805134337f06239653922ac7bea6aa2b19dc486b9361821d37712eb796adfd38d81de278ca60006000a46104a0516105a0523360007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60206105a0a36104a05160005260206000f36105b0565b633b9aca003410156000600654141560006007541415161661046657600080fd5b306007543b61047457600080fd5b60075430141561048357600080fd5b60206102406024630b9d58476101c0526008546101e0526101dc6007545afa6104ab57600080fd5b60005061024051146104bc57600080fd5b6101605161026052303161028052610280516003556102805160043360e05260c052604060c020556006543b6104f157600080fd5b60065430141561050057600080fd5b602061036060646323b872dd6102a052336102c052306102e05261026051610300526102bc60006006545af161053557600080fd5b6000506103605161054557600080fd5b6102605134337f06239653922ac7bea6aa2b19dc486b9361821d37712eb796adfd38d81de278ca60006000a461028051610380523360007fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef6020610380a36102805160005260206000f35b005b63f88bf15a600051141561085157608060046101403734156105d357600080fd5b600061018051116000610160511116426101a051116000610140511116166105fa57600080fd5b6003546101c05260006101c0511161061157600080fd5b6006543b61061e57600080fd5b60065430141561062d57600080fd5b602061028060246370a0823161020052306102205261021c6006545afa61065357600080fd5b600050610280516101e0526101c05161066b57600080fd5b6101c0516101405115156106805760006106a0565b30316101405130316101405102041461069857600080fd5b303161014051025b046102a0526101c0516106b257600080fd5b6101c0516101405115156106c75760006106ed565b6101e051610140516101e051610140510204146106e357600080fd5b6101e05161014051025b046102c052610180516102c0511015610160516102a05110151661071057600080fd5b60043360e05260c052604060c020610140518154101561072f57600080fd5b61014051815403815550610140516101c051101561074c57600080fd5b610140516101c0510360035560006000600060006102a051336000f161077157600080fd5b6006543b61077e57600080fd5b60065430141561078d57600080fd5b6020610380604463a9059cbb6102e05233610300526102c051610320526102fc60006006545af16107bd57600080fd5b600050610380516107cd57600080fd5b6102c0516102a051337f0fbf06c058b90cb038a618f8c2acbf6145f8b3570fd1fa56abb8f0f3f05b36e860006000a4610140516103a0526000337fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60206103a0a360406103c0526103e06102a05181526102c0518160200152506103c0516103e0f3005b6000156109cd575b6101a05261014052610160526101805260006101805111600061016051111661088157600080fd5b6101405115156108925760006108b5565b6103e5610140516103e5610140510204146108ac57600080fd5b6103e561014051025b6101c0526101c05115156108ca5760006108f0565b610180516101c051610180516101c0510204146108e657600080fd5b610180516101c051025b6101e052610160511515610905576000610928565b6103e8610160516103e86101605102041461091f57600080fd5b6103e861016051025b6101c05161016051151561093d576000610960565b6103e8610160516103e86101605102041461095757600080fd5b6103e861016051025b01101561096c57600080fd5b6101c0516101605115156109815760006109a4565b6103e8610160516103e86101605102041461099b57600080fd5b6103e861016051025b0161020052610200516109b657600080fd5b610200516101e051046000526000516101a0515650005b600015610bfa575b6101a0526101405261016052610180526000610180511160006101605111166109fd57600080fd5b610160511515610a0e576000610a34565b61014051610160516101405161016051020414610a2a57600080fd5b6101405161016051025b1515610a41576000610afd565b6103e8610160511515610a55576000610a7b565b61014051610160516101405161016051020414610a7157600080fd5b6101405161016051025b6103e8610160511515610a8f576000610ab5565b61014051610160516101405161016051020414610aab57600080fd5b6101405161016051025b020414610ac157600080fd5b6103e8610160511515610ad5576000610afb565b61014051610160516101405161016051020414610af157600080fd5b6101405161016051025b025b6101c05261014051610180511015610b1457600080fd5b6101405161018051031515610b2a576000610b95565b6103e561014051610180511015610b4057600080fd5b6101405161018051036103e561014051610180511015610b5f57600080fd5b610140516101805103020414610b7457600080fd5b6103e561014051610180511015610b8a57600080fd5b610140516101805103025b6101e0526101e051610ba657600080fd5b6101e0516101c0510460016101e051610bbe57600080fd5b6101e0516101c05104011015610bd357600080fd5b60016101e051610be257600080fd5b6101e0516101c05104016000526000516101a0515650005b600015610dfb575b6101e0526101405261016052610180526101a0526101c0526000610160511160006101405111164261018051101516610c3a57600080fd5b6006543b610c4757600080fd5b600654301415610c5657600080fd5b60206102a060246370a0823161022052306102405261023c6006545afa610c7c57600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c0516389f2a8716102e05261014051610300526101405130311015610cdd57600080fd5b6101405130310361032052610200516103405261034051610320516103005160065801610859565b6103a0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103a0516102c052610160516102c0511015610d5857600080fd5b6006543b610d6557600080fd5b600654301415610d7457600080fd5b6020610460604463a9059cbb6103c0526101c0516103e0526102c051610400526103dc60006006545af1610da757600080fd5b60005061046051610db757600080fd5b6102c051610140516101a0517fcd60aa75dea3072fbc07ae6d7d856b5dc5f4eee88854f5b4abf7b680ef8bc50f60006000a46102c0516000526000516101e0515650005b63f39b5b9b6000511415610e785760406004610140376101405161016051638c717a3361018052346101a052610140516101c052610160516101e0523361020052336102205261022051610200516101e0516101c0516101a05160065801610c02565b6102805261016052610140526102805160005260206000f3005b63ad65d76d6000511415610f2b5760606004610140376044356020518110610e9f57600080fd5b5060006101805114153061018051141516610eb957600080fd5b610140516101605161018051638c717a336101a052346101c052610140516101e0526101605161020052336102205261018051610240526102405161022051610200516101e0516101c05160065801610c02565b6102a0526101805261016052610140526102a05160005260206000f3005b600015611173575b6101e0526101405261016052610180526101a0526101c0526000610160511160006101405111164261018051101516610f6b57600080fd5b6006543b610f7857600080fd5b600654301415610f8757600080fd5b60206102a060246370a0823161022052306102405261023c6006545afa610fad57600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c05163fd11c2236102e0526101405161030052610160513031101561100e57600080fd5b61016051303103610320526102005161034052610340516103205161030051600658016109d5565b6103a0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103a0516102c05260016102c051026103e0526103e05161016051101561109457600080fd5b6103e05161016051036103c05260006103c05111156110ca5760006000600060006103c0516101a0516000f16110c957600080fd5b5b6006543b6110d757600080fd5b6006543014156110e657600080fd5b60206104a0604463a9059cbb610400526101c05161042052610140516104405261041c60006006545af161111957600080fd5b6000506104a05161112957600080fd5b6101405160016102c051026101a0517fcd60aa75dea3072fbc07ae6d7d856b5dc5f4eee88854f5b4abf7b680ef8bc50f60006000a460016102c051026000526000516101e0515650005b636b1d4db760005114156111f05760406004610140376101405161016051632dff394e61018052610140516101a052346101c052610160516101e0523361020052336102205261022051610200516101e0516101c0516101a05160065801610f33565b6102805261016052610140526102805160005260206000f3005b630b57363860005114156112a3576060600461014037604435602051811061121757600080fd5b506000610180511415306101805114151661123157600080fd5b610140516101605161018051632dff394e6101a052610140516101c052346101e0526101605161020052336102205261018051610240526102405161022051610200516101e0516101c05160065801610f33565b6102a0526101805261016052610140526102a05160005260206000f3005b600015611422575b6101e0526101405261016052610180526101a0526101c05260006101605111600061014051111642610180511015166112e357600080fd5b6006543b6112f057600080fd5b6006543014156112ff57600080fd5b60206102a060246370a0823161022052306102405261023c6006545afa61132557600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c0516389f2a8716102e0526101405161030052610200516103205230316103405261034051610320516103005160065801610859565b6103a0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103a0516102c05260016102c051026103c052610160516103c05110156113f657600080fd5b60006000600060006103c0516101c0516000f161141257600080fd5b60006000526000516101e0515650005b6395e3c50b60005114156114b5576060600461014037341561144357600080fd5b61014051610160516101805163fa1bb7be6101a052610140516101c052610160516101e0526101805161020052336102205233610240526102405161022051610200516101e0516101c051600658016112ab565b6102a0526101805261016052610140526102a05160005260206000f3005b637237e031600051141561157e57608060046101403734156114d657600080fd5b60643560205181106114e757600080fd5b5060006101a0511415306101a05114151661150157600080fd5b6101405161016051610180516101a05163fa1bb7be6101c052610140516101e0526101605161020052610180516102205233610240526101a05161026052610260516102405161022051610200516101e051600658016112ab565b6102c0526101a0526101805261016052610140526102c05160005260206000f3005b600015611782575b6101e0526101405261016052610180526101a0526101c0526000610140511142610180511015166115b657600080fd5b6006543b6115c357600080fd5b6006543014156115d257600080fd5b60206102a060246370a0823161022052306102405261023c6006545afa6115f857600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c05163fd11c2236102e05261014051610300526102005161032052303161034052610340516103205161030051600658016109d5565b6103a0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103a0516102c0526102c0516101605110156116be57600080fd5b6000600060006000610140516101c0516000f16116da57600080fd5b6006543b6116e757600080fd5b6006543014156116f657600080fd5b602061048060646323b872dd6103c0526101a0516103e05230610400526102c051610420526103dc60006006545af161172e57600080fd5b6000506104805161173e57600080fd5b610140516102c0516101a0517f7f4091b46c33e918a0f3aa42307641d17bb67029427a5369e54b35398423870560006000a46102c0516000526000516101e0515650005b63013efd8b600051141561181557606060046101403734156117a357600080fd5b61014051610160516101805163984fe8f66101a052610140516101c052610160516101e0526101805161020052336102205233610240526102405161022051610200516101e0516101c05160065801611586565b6102a0526101805261016052610140526102a05160005260206000f3005b63d4e4841d60005114156118de576080600461014037341561183657600080fd5b606435602051811061184757600080fd5b5060006101a0511415306101a05114151661186157600080fd5b6101405161016051610180516101a05163984fe8f66101c052610140516101e0526101605161020052610180516102205233610240526101a05161026052610260516102405161022051610200516101e05160065801611586565b6102c0526101a0526101805261016052610140526102c05160005260206000f3005b600015611b79575b610220526101405261016052610180526101a0526101c0526101e0526102005260006101805111600061016051111660006101405111426101a0511015161661192e57600080fd5b6000610200511415306102005114151661194757600080fd5b6006543b61195457600080fd5b60065430141561196357600080fd5b60206102e060246370a0823161026052306102805261027c6006545afa61198957600080fd5b6000506102e051610240526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c0516102e051610300516389f2a871610320526101405161034052610240516103605230316103805261038051610360516103405160065801610859565b6103e052610300526102e0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103e05161030052600161030051026104005261018051610400511015611a6a57600080fd5b6006543b611a7757600080fd5b600654301415611a8657600080fd5b60206104e060646323b872dd610420526101c051610440523061046052610140516104805261043c60006006545af1611abe57600080fd5b6000506104e051611ace57600080fd5b610200513b611adc57600080fd5b61020051301415611aec57600080fd5b60206105e0606463ad65d76d6105205261016051610540526101a051610560526101e0516105805261053c61040051610200515af1611b2a57600080fd5b6000506105e0516105005261040051610140516101c0517f7f4091b46c33e918a0f3aa42307641d17bb67029427a5369e54b35398423870560006000a461050051600052600051610220515650005b637c3755c46000511415611cb45760a06004610140373415611b9a57600080fd5b6007543b611ba757600080fd5b600754301415611bb657600080fd5b60206102806024630b9d5847610200526101c0516102205261021c6007545afa611bdf57600080fd5b600050610280516101e0526101405161016051610180516101a0516101c0516101e051610200516102205161024051610260516102805163204ea33b6102a052610140516102c052610160516102e05261018051610300526101a05161032052336103405233610360526101e0516103805261038051610360516103405161032051610300516102e0516102c051600658016118e6565b6103e05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103e05160005260206000f3005b6391ff65e46000511415611e0c5760c06004610140373415611cd557600080fd5b6084356020518110611ce657600080fd5b506007543b611cf457600080fd5b600754301415611d0357600080fd5b60206102a06024630b9d5847610220526101e0516102405261023c6007545afa611d2c57600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a05163204ea33b6102c052610140516102e052610160516103005261018051610320526101a0516103405233610360526101c05161038052610200516103a0526103a05161038051610360516103405161032051610300516102e051600658016118e6565b610400526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526104005160005260206000f3005b600015612122575b610220526101405261016052610180526101a0526101c0526101e05261020052600061018051116000610140511116426101a051101516611e5457600080fd5b60006102005114153061020051141516611e6d57600080fd5b610200513b611e7b57600080fd5b61020051301415611e8b57600080fd5b60206102e060246359e9486261026052610140516102805261027c610200515afa611eb557600080fd5b6000506102e051610240526006543b611ecd57600080fd5b600654301415611edc57600080fd5b60206103a060246370a0823161032052306103405261033c6006545afa611f0257600080fd5b6000506103a051610300526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a0516102c0516102e05161030051610320516103405161036051610380516103a0516103c05163fd11c2236103e05261024051610400526103005161042052303161044052610440516104205161040051600658016109d5565b6104a0526103c0526103a05261038052610360526103405261032052610300526102e0526102c0526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526104a0516103c052610240516101805110156103c0516101605110151661201357600080fd5b6006543b61202057600080fd5b60065430141561202f57600080fd5b602061058060646323b872dd6104c0526101c0516104e05230610500526103c051610520526104dc60006006545af161206757600080fd5b6000506105805161207757600080fd5b610200513b61208557600080fd5b6102005130141561209557600080fd5b60206106806064630b5736386105c052610140516105e0526101a051610600526101e051610620526105dc61024051610200515af16120d357600080fd5b600050610680516105a052610240516103c0516101c0517f7f4091b46c33e918a0f3aa42307641d17bb67029427a5369e54b35398423870560006000a46103c051600052600051610220515650005b63766b1f93600051141561225d5760a0600461014037341561214357600080fd5b6007543b61215057600080fd5b60075430141561215f57600080fd5b60206102806024630b9d5847610200526101c0516102205261021c6007545afa61218857600080fd5b600050610280516101e0526101405161016051610180516101a0516101c0516101e0516102005161022051610240516102605161028051631a7b28f26102a052610140516102c052610160516102e05261018051610300526101a05161032052336103405233610360526101e0516103805261038051610360516103405161032051610300516102e0516102c05160065801611e14565b6103e05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526103e05160005260206000f3005b637796792660005114156123b55760c0600461014037341561227e57600080fd5b608435602051811061228f57600080fd5b506007543b61229d57600080fd5b6007543014156122ac57600080fd5b60206102a06024630b9d5847610220526101e0516102405261023c6007545afa6122d557600080fd5b6000506102a051610200526101405161016051610180516101a0516101c0516101e05161020051610220516102405161026051610280516102a051631a7b28f26102c052610140516102e052610160516103005261018051610320526101a0516103405233610360526101c05161038052610200516103a0526103a05161038051610360516103405161032051610300516102e05160065801611e14565b610400526102a05261028052610260526102405261022052610200526101e0526101c0526101a0526101805261016052610140526104005160005260206000f3005b63b1cb43bf60005114156124825760a060046101403734156123d657600080fd5b60843560205181106123e757600080fd5b506101405161016051610180516101a0516101c05163204ea33b6101e0526101405161020052610160516102205261018051610240526101a051610260523361028052336102a0526101c0516102c0526102c0516102a0516102805161026051610240516102205161020051600658016118e6565b610320526101c0526101a0526101805261016052610140526103205160005260206000f3005b63ec384a3e600051141561257c5760c060046101403734156124a357600080fd5b60843560205181106124b457600080fd5b5060a43560205181106124c657600080fd5b50306101c05114156124d757600080fd5b6101405161016051610180516101a0516101c0516101e05163204ea33b610200526101405161022052610160516102405261018051610260526101a05161028052336102a0526101c0516102c0526101e0516102e0526102e0516102c0516102a05161028051610260516102405161022051600658016118e6565b610340526101e0526101c0526101a0526101805261016052610140526103405160005260206000f3005b63ea650c7d60005114156126495760a0600461014037341561259d57600080fd5b60843560205181106125ae57600080fd5b506101405161016051610180516101a0516101c051631a7b28f26101e0526101405161020052610160516102205261018051610240526101a051610260523361028052336102a0526101c0516102c0526102c0516102a051610280516102605161024051610220516102005160065801611e14565b610320526101c0526101a0526101805261016052610140526103205160005260206000f3005b63981a132760005114156127435760c0600461014037341561266a57600080fd5b608435602051811061267b57600080fd5b5060a435602051811061268d57600080fd5b50306101c051141561269e57600080fd5b6101405161016051610180516101a0516101c0516101e051631a7b28f2610200526101405161022052610160516102405261018051610260526101a05161028052336102a0526101c0516102c0526101e0516102e0526102e0516102c0516102a0516102805161026051610240516102205160065801611e14565b610340526101e0526101c0526101a0526101805261016052610140526103405160005260206000f3005b63cd7724c3600051141561283f576020600461014037341561276457600080fd5b6000610140511161277457600080fd5b6006543b61278157600080fd5b60065430141561279057600080fd5b602061020060246370a0823161018052306101a05261019c6006545afa6127b657600080fd5b60005061020051610160526101405161016051610180516101a0516101c0516101e051610200516389f2a871610220526101405161024052303161026052610160516102805261028051610260516102405160065801610859565b6102e052610200526101e0526101c0526101a0526101805261016052610140526102e05160005260206000f3005b6359e94862600051141561294e576020600461014037341561286057600080fd5b6000610140511161287057600080fd5b6006543b61287d57600080fd5b60065430141561288c57600080fd5b602061020060246370a0823161018052306101a05261019c6006545afa6128b257600080fd5b60005061020051610160526101405161016051610180516101a0516101c0516101e051610200516102205163fd11c223610240526101405161026052303161028052610160516102a0526102a0516102805161026051600658016109d5565b6103005261022052610200526101e0526101c0526101a05261018052610160526101405261030051610220526001610220510260005260206000f3005b6395b68fe76000511415612a5d576020600461014037341561296f57600080fd5b6000610140511161297f57600080fd5b6006543b61298c57600080fd5b60065430141561299b57600080fd5b602061020060246370a0823161018052306101a05261019c6006545afa6129c157600080fd5b60005061020051610160526101405161016051610180516101a0516101c0516101e05161020051610220516389f2a871610240526101405161026052610160516102805230316102a0526102a051610280516102605160065801610859565b6103005261022052610200526101e0526101c0526101a05261018052610160526101405261030051610220526001610220510260005260206000f3005b632640f62c6000511415612b595760206004610140373415612a7e57600080fd5b60006101405111612a8e57600080fd5b6006543b612a9b57600080fd5b600654301415612aaa57600080fd5b602061020060246370a0823161018052306101a05261019c6006545afa612ad057600080fd5b60005061020051610160526101405161016051610180516101a0516101c0516101e0516102005163fd11c2236102205261014051610240526101605161026052303161028052610280516102605161024051600658016109d5565b6102e052610200526101e0526101c0526101a0526101805261016052610140526102e05160005260206000f3005b639d76ea586000511415612b7f573415612b7257600080fd5b60065460005260206000f3005b63966dae0e6000511415612ba5573415612b9857600080fd5b60075460005260206000f3005b6370a082316000511415612bf45760206004610140373415612bc657600080fd5b6004356020518110612bd757600080fd5b5060046101405160e05260c052604060c0205460005260206000f3005b63a9059cbb6000511415612cbf5760406004610140373415612c1557600080fd5b6004356020518110612c2657600080fd5b5060043360e05260c052604060c0206101605181541015612c4657600080fd5b6101605181540381555060046101405160e05260c052604060c0208054610160518254011015612c7557600080fd5b61016051815401815550610160516101805261014051337fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef6020610180a3600160005260206000f3005b6323b872dd6000511415612dda5760606004610140373415612ce057600080fd5b6004356020518110612cf157600080fd5b506024356020518110612d0357600080fd5b5060046101405160e05260c052604060c0206101805181541015612d2657600080fd5b6101805181540381555060046101605160e05260c052604060c0208054610180518254011015612d5557600080fd5b6101805181540181555060056101405160e05260c052604060c0203360e05260c052604060c0206101805181541015612d8d57600080fd5b61018051815403815550610180516101a05261016051610140517fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef60206101a0a3600160005260206000f3005b63095ea7b36000511415612e6f5760406004610140373415612dfb57600080fd5b6004356020518110612e0c57600080fd5b506101605160053360e05260c052604060c0206101405160e05260c052604060c02055610160516101805261014051337f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b9256020610180a3600160005260206000f3005b63dd62ed3e6000511415612edf5760406004610140373415612e9057600080fd5b6004356020518110612ea157600080fd5b506024356020518110612eb357600080fd5b5060056101405160e05260c052604060c0206101605160e05260c052604060c0205460005260206000f3005b6306fdde036000511415612f05573415612ef857600080fd5b60005460005260206000f3005b6395d89b416000511415612f2b573415612f1e57600080fd5b60015460005260206000f3005b63313ce5676000511415612f51573415612f4457600080fd5b60025460005260206000f3005b6318160ddd6000511415612f77573415612f6a57600080fd5b60035460005260206000f3005b638c717a33610140523461016052600161018052426101a052336101c052336101e0526101e0516101c0516101a051610180516101605160065801610c02565b61024052610240", + "source": "# @title Uniswap Exchange Interface V1\n# @notice Source code found at https://github.com/uniswap\n# @notice Use at your own risk\n\ncontract Factory():\n def getExchange(token_id: uint256) -> address: constant\n\ncontract Exchange():\n def getEthToTokenOutputPrice(tokens_bought: uint256) -> uint256(wei): constant\n def ethToTokenTransferInput(min_tokens: uint256, deadline: timestamp, recipient: address) -> uint256: modifying\n def ethToTokenTransferOutput(tokens_bought: uint256, deadline: timestamp, recipient: address) -> uint256(wei): modifying\n\nTokenPurchase: event({buyer: indexed(address), eth_sold: indexed(uint256(wei)), tokens_bought: indexed(uint256)})\nEthPurchase: event({buyer: indexed(address), tokens_sold: indexed(uint256), eth_bought: indexed(uint256(wei))})\nAddLiquidity: event({provider: indexed(address), eth_amount: indexed(uint256(wei)), token_amount: indexed(uint256)})\nRemoveLiquidity: event({provider: indexed(address), eth_amount: indexed(uint256(wei)), token_amount: indexed(uint256)})\nTransfer: event({_from: indexed(address), _to: indexed(address), _value: uint256})\nApproval: event({_owner: indexed(address), _spender: indexed(address), _value: uint256})\n\nname: public(bytes32) # Uniswap V1\nsymbol: public(bytes32) # UNI-V1\ndecimals: public(uint256) # 18\ntotalSupply: public(uint256) # total number of UNI in existence\nbalances: uint256[address] # UNI balance of an address\nallowances: (uint256[address])[address] # UNI allowance of one address on another\ntoken: address(ERC20) # address of the ERC20 token traded on this contract\nfactory: Factory # interface for the factory that created this contract\ntokenId: uint256 # Custom addition - token id\n\n# @dev This function acts as a contract constructor which is not currently supported in contracts deployed\n# using create_with_code_of(). It is called once by the factory during contract creation.\n@public\ndef setup(token_addr: address, token_id: uint256):\n assert (self.factory == ZERO_ADDRESS and self.token == ZERO_ADDRESS) and token_addr != ZERO_ADDRESS\n self.factory = msg.sender\n self.token = token_addr\n self.tokenId = token_id\n self.name = 0x556e697377617020563100000000000000000000000000000000000000000000\n self.symbol = 0x554e492d56310000000000000000000000000000000000000000000000000000\n self.decimals = 18\n\n# @notice Deposit ETH and Tokens (self.token) at current ratio to mint UNI tokens.\n# @dev min_liquidity does nothing when total UNI supply is 0.\n# @param min_liquidity Minimum number of UNI sender will mint if total UNI supply is greater than 0.\n# @param max_tokens Maximum number of tokens deposited. Deposits max amount if total UNI supply is 0.\n# @param deadline Time after which this transaction can no longer be executed.\n# @return The amount of UNI minted.\n@public\n@payable\ndef addLiquidity(min_liquidity: uint256, max_tokens: uint256, deadline: timestamp) -> uint256:\n assert deadline > block.timestamp and (max_tokens > 0 and msg.value > 0)\n total_liquidity: uint256 = self.totalSupply\n if total_liquidity > 0:\n assert min_liquidity > 0\n eth_reserve: uint256(wei) = self.balance - msg.value\n token_reserve: uint256 = self.token.balanceOf(self)\n token_amount: uint256 = msg.value * token_reserve / eth_reserve + 1\n liquidity_minted: uint256 = msg.value * total_liquidity / eth_reserve\n assert max_tokens >= token_amount and liquidity_minted >= min_liquidity\n self.balances[msg.sender] += liquidity_minted\n self.totalSupply = total_liquidity + liquidity_minted\n assert self.token.transferFrom(msg.sender, self, token_amount)\n log.AddLiquidity(msg.sender, msg.value, token_amount)\n log.Transfer(ZERO_ADDRESS, msg.sender, liquidity_minted)\n return liquidity_minted\n else:\n assert (self.factory != ZERO_ADDRESS and self.token != ZERO_ADDRESS) and msg.value >= 1000000000\n assert self.factory.getExchange(self.tokenId) == self\n token_amount: uint256 = max_tokens\n initial_liquidity: uint256 = as_unitless_number(self.balance)\n self.totalSupply = initial_liquidity\n self.balances[msg.sender] = initial_liquidity\n assert self.token.transferFrom(msg.sender, self, token_amount)\n log.AddLiquidity(msg.sender, msg.value, token_amount)\n log.Transfer(ZERO_ADDRESS, msg.sender, initial_liquidity)\n return initial_liquidity\n\n# @dev Burn UNI tokens to withdraw ETH and Tokens at current ratio.\n# @param amount Amount of UNI burned.\n# @param min_eth Minimum ETH withdrawn.\n# @param min_tokens Minimum Tokens withdrawn.\n# @param deadline Time after which this transaction can no longer be executed.\n# @return The amount of ETH and Tokens withdrawn.\n@public\ndef removeLiquidity(amount: uint256, min_eth: uint256(wei), min_tokens: uint256, deadline: timestamp) -> (uint256(wei), uint256):\n assert (amount > 0 and deadline > block.timestamp) and (min_eth > 0 and min_tokens > 0)\n total_liquidity: uint256 = self.totalSupply\n assert total_liquidity > 0\n token_reserve: uint256 = self.token.balanceOf(self)\n eth_amount: uint256(wei) = amount * self.balance / total_liquidity\n token_amount: uint256 = amount * token_reserve / total_liquidity\n assert eth_amount >= min_eth and token_amount >= min_tokens\n self.balances[msg.sender] -= amount\n self.totalSupply = total_liquidity - amount\n send(msg.sender, eth_amount)\n assert self.token.transfer(msg.sender, token_amount)\n log.RemoveLiquidity(msg.sender, eth_amount, token_amount)\n log.Transfer(msg.sender, ZERO_ADDRESS, amount)\n return eth_amount, token_amount\n\n# @dev Pricing function for converting between ETH and Tokens.\n# @param input_amount Amount of ETH or Tokens being sold.\n# @param input_reserve Amount of ETH or Tokens (input type) in exchange reserves.\n# @param output_reserve Amount of ETH or Tokens (output type) in exchange reserves.\n# @return Amount of ETH or Tokens bought.\n@private\n@constant\ndef getInputPrice(input_amount: uint256, input_reserve: uint256, output_reserve: uint256) -> uint256:\n assert input_reserve > 0 and output_reserve > 0\n input_amount_with_fee: uint256 = input_amount * 997\n numerator: uint256 = input_amount_with_fee * output_reserve\n denominator: uint256 = (input_reserve * 1000) + input_amount_with_fee\n return numerator / denominator\n\n# @dev Pricing function for converting between ETH and Tokens.\n# @param output_amount Amount of ETH or Tokens being bought.\n# @param input_reserve Amount of ETH or Tokens (input type) in exchange reserves.\n# @param output_reserve Amount of ETH or Tokens (output type) in exchange reserves.\n# @return Amount of ETH or Tokens sold.\n@private\n@constant\ndef getOutputPrice(output_amount: uint256, input_reserve: uint256, output_reserve: uint256) -> uint256:\n assert input_reserve > 0 and output_reserve > 0\n numerator: uint256 = input_reserve * output_amount * 1000\n denominator: uint256 = (output_reserve - output_amount) * 997\n return numerator / denominator + 1\n\n@private\ndef ethToTokenInput(eth_sold: uint256(wei), min_tokens: uint256, deadline: timestamp, buyer: address, recipient: address) -> uint256:\n assert deadline >= block.timestamp and (eth_sold > 0 and min_tokens > 0)\n token_reserve: uint256 = self.token.balanceOf(self)\n tokens_bought: uint256 = self.getInputPrice(as_unitless_number(eth_sold), as_unitless_number(self.balance - eth_sold), token_reserve)\n assert tokens_bought >= min_tokens\n assert self.token.transfer(recipient, tokens_bought)\n log.TokenPurchase(buyer, eth_sold, tokens_bought)\n return tokens_bought\n\n# @notice Convert ETH to Tokens.\n# @dev User specifies exact input (msg.value).\n# @dev User cannot specify minimum output or deadline.\n@public\n@payable\ndef __default__():\n self.ethToTokenInput(msg.value, 1, block.timestamp, msg.sender, msg.sender)\n\n# @notice Convert ETH to Tokens.\n# @dev User specifies exact input (msg.value) and minimum output.\n# @param min_tokens Minimum Tokens bought.\n# @param deadline Time after which this transaction can no longer be executed.\n# @return Amount of Tokens bought.\n@public\n@payable\ndef ethToTokenSwapInput(min_tokens: uint256, deadline: timestamp) -> uint256:\n return self.ethToTokenInput(msg.value, min_tokens, deadline, msg.sender, msg.sender)\n\n# @notice Convert ETH to Tokens and transfers Tokens to recipient.\n# @dev User specifies exact input (msg.value) and minimum output\n# @param min_tokens Minimum Tokens bought.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param recipient The address that receives output Tokens.\n# @return Amount of Tokens bought.\n@public\n@payable\ndef ethToTokenTransferInput(min_tokens: uint256, deadline: timestamp, recipient: address) -> uint256:\n assert recipient != self and recipient != ZERO_ADDRESS\n return self.ethToTokenInput(msg.value, min_tokens, deadline, msg.sender, recipient)\n\n@private\ndef ethToTokenOutput(tokens_bought: uint256, max_eth: uint256(wei), deadline: timestamp, buyer: address, recipient: address) -> uint256(wei):\n assert deadline >= block.timestamp and (tokens_bought > 0 and max_eth > 0)\n token_reserve: uint256 = self.token.balanceOf(self)\n eth_sold: uint256 = self.getOutputPrice(tokens_bought, as_unitless_number(self.balance - max_eth), token_reserve)\n # Throws if eth_sold > max_eth\n eth_refund: uint256(wei) = max_eth - as_wei_value(eth_sold, 'wei')\n if eth_refund > 0:\n send(buyer, eth_refund)\n assert self.token.transfer(recipient, tokens_bought)\n log.TokenPurchase(buyer, as_wei_value(eth_sold, 'wei'), tokens_bought)\n return as_wei_value(eth_sold, 'wei')\n\n# @notice Convert ETH to Tokens.\n# @dev User specifies maximum input (msg.value) and exact output.\n# @param tokens_bought Amount of tokens bought.\n# @param deadline Time after which this transaction can no longer be executed.\n# @return Amount of ETH sold.\n@public\n@payable\ndef ethToTokenSwapOutput(tokens_bought: uint256, deadline: timestamp) -> uint256(wei):\n return self.ethToTokenOutput(tokens_bought, msg.value, deadline, msg.sender, msg.sender)\n\n# @notice Convert ETH to Tokens and transfers Tokens to recipient.\n# @dev User specifies maximum input (msg.value) and exact output.\n# @param tokens_bought Amount of tokens bought.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param recipient The address that receives output Tokens.\n# @return Amount of ETH sold.\n@public\n@payable\ndef ethToTokenTransferOutput(tokens_bought: uint256, deadline: timestamp, recipient: address) -> uint256(wei):\n assert recipient != self and recipient != ZERO_ADDRESS\n return self.ethToTokenOutput(tokens_bought, msg.value, deadline, msg.sender, recipient)\n\n@private\ndef tokenToEthInput(tokens_sold: uint256, min_eth: uint256(wei), deadline: timestamp, buyer: address, recipient: address) -> uint256(wei):\n\n assert deadline >= block.timestamp and (tokens_sold > 0 and min_eth > 0)\n token_reserve: uint256 = self.token.balanceOf(self)\n eth_bought: uint256 = self.getInputPrice(tokens_sold, token_reserve, as_unitless_number(self.balance))\n wei_bought: uint256(wei) = as_wei_value(eth_bought, 'wei')\n assert wei_bought >= min_eth\n send(recipient, wei_bought)\n return 0\n \"\"\"\n assert self.token.transferFrom(buyer, self, tokens_sold)\n log.EthPurchase(buyer, tokens_sold, wei_bought)\n return wei_bought\n \"\"\"\n\n\n# @notice Convert Tokens to ETH.\n# @dev User specifies exact input and minimum output.\n# @param tokens_sold Amount of Tokens sold.\n# @param min_eth Minimum ETH purchased.\n# @param deadline Time after which this transaction can no longer be executed.\n# @return Amount of ETH bought.\n@public\ndef tokenToEthSwapInput(tokens_sold: uint256, min_eth: uint256(wei), deadline: timestamp) -> uint256(wei):\n return self.tokenToEthInput(tokens_sold, min_eth, deadline, msg.sender, msg.sender)\n\n# @notice Convert Tokens to ETH and transfers ETH to recipient.\n# @dev User specifies exact input and minimum output.\n# @param tokens_sold Amount of Tokens sold.\n# @param min_eth Minimum ETH purchased.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param recipient The address that receives output ETH.\n# @return Amount of ETH bought.\n@public\ndef tokenToEthTransferInput(tokens_sold: uint256, min_eth: uint256(wei), deadline: timestamp, recipient: address) -> uint256(wei):\n assert recipient != self and recipient != ZERO_ADDRESS\n return self.tokenToEthInput(tokens_sold, min_eth, deadline, msg.sender, recipient)\n\n@private\ndef tokenToEthOutput(eth_bought: uint256(wei), max_tokens: uint256, deadline: timestamp, buyer: address, recipient: address) -> uint256:\n assert deadline >= block.timestamp and eth_bought > 0\n token_reserve: uint256 = self.token.balanceOf(self)\n tokens_sold: uint256 = self.getOutputPrice(as_unitless_number(eth_bought), token_reserve, as_unitless_number(self.balance))\n # tokens sold is always > 0\n assert max_tokens >= tokens_sold\n send(recipient, eth_bought)\n assert self.token.transferFrom(buyer, self, tokens_sold)\n log.EthPurchase(buyer, tokens_sold, eth_bought)\n return tokens_sold\n\n# @notice Convert Tokens to ETH.\n# @dev User specifies maximum input and exact output.\n# @param eth_bought Amount of ETH purchased.\n# @param max_tokens Maximum Tokens sold.\n# @param deadline Time after which this transaction can no longer be executed.\n# @return Amount of Tokens sold.\n@public\ndef tokenToEthSwapOutput(eth_bought: uint256(wei), max_tokens: uint256, deadline: timestamp) -> uint256:\n return self.tokenToEthOutput(eth_bought, max_tokens, deadline, msg.sender, msg.sender)\n\n# @notice Convert Tokens to ETH and transfers ETH to recipient.\n# @dev User specifies maximum input and exact output.\n# @param eth_bought Amount of ETH purchased.\n# @param max_tokens Maximum Tokens sold.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param recipient The address that receives output ETH.\n# @return Amount of Tokens sold.\n@public\ndef tokenToEthTransferOutput(eth_bought: uint256(wei), max_tokens: uint256, deadline: timestamp, recipient: address) -> uint256:\n assert recipient != self and recipient != ZERO_ADDRESS\n return self.tokenToEthOutput(eth_bought, max_tokens, deadline, msg.sender, recipient)\n\n@private\ndef tokenToTokenInput(tokens_sold: uint256, min_tokens_bought: uint256, min_eth_bought: uint256(wei), deadline: timestamp, buyer: address, recipient: address, exchange_addr: address) -> uint256:\n assert (deadline >= block.timestamp and tokens_sold > 0) and (min_tokens_bought > 0 and min_eth_bought > 0)\n assert exchange_addr != self and exchange_addr != ZERO_ADDRESS\n token_reserve: uint256 = self.token.balanceOf(self)\n eth_bought: uint256 = self.getInputPrice(tokens_sold, token_reserve, as_unitless_number(self.balance))\n wei_bought: uint256(wei) = as_wei_value(eth_bought, 'wei')\n assert wei_bought >= min_eth_bought\n assert self.token.transferFrom(buyer, self, tokens_sold)\n tokens_bought: uint256 = Exchange(exchange_addr).ethToTokenTransferInput(min_tokens_bought, deadline, recipient, value=wei_bought)\n log.EthPurchase(buyer, tokens_sold, wei_bought)\n return tokens_bought\n\n# @notice Convert Tokens (self.token) to Tokens (token_addr).\n# @dev User specifies exact input and minimum output.\n# @param tokens_sold Amount of Tokens sold.\n# @param min_tokens_bought Minimum Tokens (token_addr) purchased.\n# @param min_eth_bought Minimum ETH purchased as intermediary.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param token_addr The address of the token being purchased.\n# @return Amount of Tokens (token_addr) bought.\n@public\ndef tokenToTokenSwapInput(tokens_sold: uint256, min_tokens_bought: uint256, min_eth_bought: uint256(wei), deadline: timestamp, token_addr: uint256) -> uint256:\n exchange_addr: address = self.factory.getExchange(token_addr)\n return self.tokenToTokenInput(tokens_sold, min_tokens_bought, min_eth_bought, deadline, msg.sender, msg.sender, exchange_addr)\n\n# @notice Convert Tokens (self.token) to Tokens (token_addr) and transfers\n# Tokens (token_addr) to recipient.\n# @dev User specifies exact input and minimum output.\n# @param tokens_sold Amount of Tokens sold.\n# @param min_tokens_bought Minimum Tokens (token_addr) purchased.\n# @param min_eth_bought Minimum ETH purchased as intermediary.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param recipient The address that receives output ETH.\n# @param token_addr The address of the token being purchased.\n# @return Amount of Tokens (token_addr) bought.\n@public\ndef tokenToTokenTransferInput(tokens_sold: uint256, min_tokens_bought: uint256, min_eth_bought: uint256(wei), deadline: timestamp, recipient: address, token_addr: uint256) -> uint256:\n exchange_addr: address = self.factory.getExchange(token_addr)\n return self.tokenToTokenInput(tokens_sold, min_tokens_bought, min_eth_bought, deadline, msg.sender, recipient, exchange_addr)\n\n@private\ndef tokenToTokenOutput(tokens_bought: uint256, max_tokens_sold: uint256, max_eth_sold: uint256(wei), deadline: timestamp, buyer: address, recipient: address, exchange_addr: address) -> uint256:\n assert deadline >= block.timestamp and (tokens_bought > 0 and max_eth_sold > 0)\n assert exchange_addr != self and exchange_addr != ZERO_ADDRESS\n eth_bought: uint256(wei) = Exchange(exchange_addr).getEthToTokenOutputPrice(tokens_bought)\n token_reserve: uint256 = self.token.balanceOf(self)\n tokens_sold: uint256 = self.getOutputPrice(as_unitless_number(eth_bought), token_reserve, as_unitless_number(self.balance))\n # tokens sold is always > 0\n assert max_tokens_sold >= tokens_sold and max_eth_sold >= eth_bought\n assert self.token.transferFrom(buyer, self, tokens_sold)\n eth_sold: uint256(wei) = Exchange(exchange_addr).ethToTokenTransferOutput(tokens_bought, deadline, recipient, value=eth_bought)\n log.EthPurchase(buyer, tokens_sold, eth_bought)\n return tokens_sold\n\n# @notice Convert Tokens (self.token) to Tokens (token_addr).\n# @dev User specifies maximum input and exact output.\n# @param tokens_bought Amount of Tokens (token_addr) bought.\n# @param max_tokens_sold Maximum Tokens (self.token) sold.\n# @param max_eth_sold Maximum ETH purchased as intermediary.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param token_addr The address of the token being purchased.\n# @return Amount of Tokens (self.token) sold.\n@public\ndef tokenToTokenSwapOutput(tokens_bought: uint256, max_tokens_sold: uint256, max_eth_sold: uint256(wei), deadline: timestamp, token_addr: uint256) -> uint256:\n exchange_addr: address = self.factory.getExchange(token_addr)\n return self.tokenToTokenOutput(tokens_bought, max_tokens_sold, max_eth_sold, deadline, msg.sender, msg.sender, exchange_addr)\n\n# @notice Convert Tokens (self.token) to Tokens (token_addr) and transfers\n# Tokens (token_addr) to recipient.\n# @dev User specifies maximum input and exact output.\n# @param tokens_bought Amount of Tokens (token_addr) bought.\n# @param max_tokens_sold Maximum Tokens (self.token) sold.\n# @param max_eth_sold Maximum ETH purchased as intermediary.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param recipient The address that receives output ETH.\n# @param token_addr The address of the token being purchased.\n# @return Amount of Tokens (self.token) sold.\n@public\ndef tokenToTokenTransferOutput(tokens_bought: uint256, max_tokens_sold: uint256, max_eth_sold: uint256(wei), deadline: timestamp, recipient: address, token_addr: uint256) -> uint256:\n exchange_addr: address = self.factory.getExchange(token_addr)\n return self.tokenToTokenOutput(tokens_bought, max_tokens_sold, max_eth_sold, deadline, msg.sender, recipient, exchange_addr)\n\n# @notice Convert Tokens (self.token) to Tokens (exchange_addr.token).\n# @dev Allows trades through contracts that were not deployed from the same factory.\n# @dev User specifies exact input and minimum output.\n# @param tokens_sold Amount of Tokens sold.\n# @param min_tokens_bought Minimum Tokens (token_addr) purchased.\n# @param min_eth_bought Minimum ETH purchased as intermediary.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param exchange_addr The address of the exchange for the token being purchased.\n# @return Amount of Tokens (exchange_addr.token) bought.\n@public\ndef tokenToExchangeSwapInput(tokens_sold: uint256, min_tokens_bought: uint256, min_eth_bought: uint256(wei), deadline: timestamp, exchange_addr: address) -> uint256:\n return self.tokenToTokenInput(tokens_sold, min_tokens_bought, min_eth_bought, deadline, msg.sender, msg.sender, exchange_addr)\n\n# @notice Convert Tokens (self.token) to Tokens (exchange_addr.token) and transfers\n# Tokens (exchange_addr.token) to recipient.\n# @dev Allows trades through contracts that were not deployed from the same factory.\n# @dev User specifies exact input and minimum output.\n# @param tokens_sold Amount of Tokens sold.\n# @param min_tokens_bought Minimum Tokens (token_addr) purchased.\n# @param min_eth_bought Minimum ETH purchased as intermediary.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param recipient The address that receives output ETH.\n# @param exchange_addr The address of the exchange for the token being purchased.\n# @return Amount of Tokens (exchange_addr.token) bought.\n@public\ndef tokenToExchangeTransferInput(tokens_sold: uint256, min_tokens_bought: uint256, min_eth_bought: uint256(wei), deadline: timestamp, recipient: address, exchange_addr: address) -> uint256:\n assert recipient != self\n return self.tokenToTokenInput(tokens_sold, min_tokens_bought, min_eth_bought, deadline, msg.sender, recipient, exchange_addr)\n\n# @notice Convert Tokens (self.token) to Tokens (exchange_addr.token).\n# @dev Allows trades through contracts that were not deployed from the same factory.\n# @dev User specifies maximum input and exact output.\n# @param tokens_bought Amount of Tokens (token_addr) bought.\n# @param max_tokens_sold Maximum Tokens (self.token) sold.\n# @param max_eth_sold Maximum ETH purchased as intermediary.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param exchange_addr The address of the exchange for the token being purchased.\n# @return Amount of Tokens (self.token) sold.\n@public\ndef tokenToExchangeSwapOutput(tokens_bought: uint256, max_tokens_sold: uint256, max_eth_sold: uint256(wei), deadline: timestamp, exchange_addr: address) -> uint256:\n return self.tokenToTokenOutput(tokens_bought, max_tokens_sold, max_eth_sold, deadline, msg.sender, msg.sender, exchange_addr)\n\n# @notice Convert Tokens (self.token) to Tokens (exchange_addr.token) and transfers\n# Tokens (exchange_addr.token) to recipient.\n# @dev Allows trades through contracts that were not deployed from the same factory.\n# @dev User specifies maximum input and exact output.\n# @param tokens_bought Amount of Tokens (token_addr) bought.\n# @param max_tokens_sold Maximum Tokens (self.token) sold.\n# @param max_eth_sold Maximum ETH purchased as intermediary.\n# @param deadline Time after which this transaction can no longer be executed.\n# @param recipient The address that receives output ETH.\n# @param token_addr The address of the token being purchased.\n# @return Amount of Tokens (self.token) sold.\n@public\ndef tokenToExchangeTransferOutput(tokens_bought: uint256, max_tokens_sold: uint256, max_eth_sold: uint256(wei), deadline: timestamp, recipient: address, exchange_addr: address) -> uint256:\n assert recipient != self\n return self.tokenToTokenOutput(tokens_bought, max_tokens_sold, max_eth_sold, deadline, msg.sender, recipient, exchange_addr)\n\n# @notice Public price function for ETH to Token trades with an exact input.\n# @param eth_sold Amount of ETH sold.\n# @return Amount of Tokens that can be bought with input ETH.\n@public\n@constant\ndef getEthToTokenInputPrice(eth_sold: uint256(wei)) -> uint256:\n assert eth_sold > 0\n token_reserve: uint256 = self.token.balanceOf(self)\n return self.getInputPrice(as_unitless_number(eth_sold), as_unitless_number(self.balance), token_reserve)\n\n# @notice Public price function for ETH to Token trades with an exact output.\n# @param tokens_bought Amount of Tokens bought.\n# @return Amount of ETH needed to buy output Tokens.\n@public\n@constant\ndef getEthToTokenOutputPrice(tokens_bought: uint256) -> uint256(wei):\n assert tokens_bought > 0\n token_reserve: uint256 = self.token.balanceOf(self)\n eth_sold: uint256 = self.getOutputPrice(tokens_bought, as_unitless_number(self.balance), token_reserve)\n return as_wei_value(eth_sold, 'wei')\n\n# @notice Public price function for Token to ETH trades with an exact input.\n# @param tokens_sold Amount of Tokens sold.\n# @return Amount of ETH that can be bought with input Tokens.\n@public\n@constant\ndef getTokenToEthInputPrice(tokens_sold: uint256) -> uint256(wei):\n assert tokens_sold > 0\n token_reserve: uint256 = self.token.balanceOf(self)\n eth_bought: uint256 = self.getInputPrice(tokens_sold, token_reserve, as_unitless_number(self.balance))\n return as_wei_value(eth_bought, 'wei')\n\n# @notice Public price function for Token to ETH trades with an exact output.\n# @param eth_bought Amount of output ETH.\n# @return Amount of Tokens needed to buy output ETH.\n@public\n@constant\ndef getTokenToEthOutputPrice(eth_bought: uint256(wei)) -> uint256:\n assert eth_bought > 0\n token_reserve: uint256 = self.token.balanceOf(self)\n return self.getOutputPrice(as_unitless_number(eth_bought), token_reserve, as_unitless_number(self.balance))\n\n# @return Address of Token that is sold on this exchange.\n@public\n@constant\ndef tokenAddress() -> address:\n return self.token\n\n# @return Address of factory that created this exchange.\n@public\n@constant\ndef factoryAddress() -> address(Factory):\n return self.factory\n\n# ERC20 compatibility for exchange liquidity modified from\n# https://github.com/ethereum/vyper/blob/master/examples/tokens/ERC20.vy\n@public\n@constant\ndef balanceOf(_owner : address) -> uint256:\n return self.balances[_owner]\n\n@public\ndef transfer(_to : address, _value : uint256) -> bool:\n self.balances[msg.sender] -= _value\n self.balances[_to] += _value\n log.Transfer(msg.sender, _to, _value)\n return True\n\n@public\ndef transferFrom(_from : address, _to : address, _value : uint256) -> bool:\n self.balances[_from] -= _value\n self.balances[_to] += _value\n self.allowances[_from][msg.sender] -= _value\n log.Transfer(_from, _to, _value)\n return True\n\n@public\ndef approve(_spender : address, _value : uint256) -> bool:\n self.allowances[msg.sender][_spender] = _value\n log.Approval(msg.sender, _spender, _value)\n return True\n\n@public\n@constant\ndef allowance(_owner : address, _spender : address) -> uint256:\n return self.allowances[_owner][_spender]\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/uniswap_exchange_custom.vy", + "compiler": { + "name": "vyper", + "version": "0.1.0b4" + }, + "networks": { + "42": { + "events": { + "0xcd60aa75dea3072fbc07ae6d7d856b5dc5f4eee88854f5b4abf7b680ef8bc50f": { + "name": "TokenPurchase", + "inputs": [ + { + "type": "address", + "name": "buyer", + "indexed": true + }, + { + "type": "uint256", + "name": "eth_sold", + "indexed": true + }, + { + "type": "uint256", + "name": "tokens_bought", + "indexed": true + } + ], + "anonymous": false, + "type": "event", + "signature": "0xcd60aa75dea3072fbc07ae6d7d856b5dc5f4eee88854f5b4abf7b680ef8bc50f" + }, + "0x7f4091b46c33e918a0f3aa42307641d17bb67029427a5369e54b353984238705": { + "name": "EthPurchase", + "inputs": [ + { + "type": "address", + "name": "buyer", + "indexed": true + }, + { + "type": "uint256", + "name": "tokens_sold", + "indexed": true + }, + { + "type": "uint256", + "name": "eth_bought", + "indexed": true + } + ], + "anonymous": false, + "type": "event", + "signature": "0x7f4091b46c33e918a0f3aa42307641d17bb67029427a5369e54b353984238705" + }, + "0x06239653922ac7bea6aa2b19dc486b9361821d37712eb796adfd38d81de278ca": { + "name": "AddLiquidity", + "inputs": [ + { + "type": "address", + "name": "provider", + "indexed": true + }, + { + "type": "uint256", + "name": "eth_amount", + "indexed": true + }, + { + "type": "uint256", + "name": "token_amount", + "indexed": true + } + ], + "anonymous": false, + "type": "event", + "signature": "0x06239653922ac7bea6aa2b19dc486b9361821d37712eb796adfd38d81de278ca" + }, + "0x0fbf06c058b90cb038a618f8c2acbf6145f8b3570fd1fa56abb8f0f3f05b36e8": { + "name": "RemoveLiquidity", + "inputs": [ + { + "type": "address", + "name": "provider", + "indexed": true + }, + { + "type": "uint256", + "name": "eth_amount", + "indexed": true + }, + { + "type": "uint256", + "name": "token_amount", + "indexed": true + } + ], + "anonymous": false, + "type": "event", + "signature": "0x0fbf06c058b90cb038a618f8c2acbf6145f8b3570fd1fa56abb8f0f3f05b36e8" + }, + "0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef": { + "name": "Transfer", + "inputs": [ + { + "type": "address", + "name": "_from", + "indexed": true + }, + { + "type": "address", + "name": "_to", + "indexed": true + }, + { + "type": "uint256", + "name": "_value", + "indexed": false + } + ], + "anonymous": false, + "type": "event", + "signature": "0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef" + }, + "0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925": { + "name": "Approval", + "inputs": [ + { + "type": "address", + "name": "_owner", + "indexed": true + }, + { + "type": "address", + "name": "_spender", + "indexed": true + }, + { + "type": "uint256", + "name": "_value", + "indexed": false + } + ], + "anonymous": false, + "type": "event", + "signature": "0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925" + } + }, + "links": {}, + "address": "0x60c8f5f17Fe63018d87542F4B95fB388b5A5Ce50", + "transactionHash": "0x22db9b3c8a8c1d878571c0f090251fb41046f1c15c435c24d57e134c1d5b8249" + } + }, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T15:21:05.387Z" +} \ No newline at end of file diff --git a/client/src/contracts/uniswap_factory_custom.json b/client/src/contracts/uniswap_factory_custom.json new file mode 100644 index 0000000..e947d24 --- /dev/null +++ b/client/src/contracts/uniswap_factory_custom.json @@ -0,0 +1,177 @@ +{ + "contractName": "uniswap_factory_custom", + "abi": [ + { + "name": "NewExchange", + "inputs": [ + { + "type": "address", + "name": "token", + "indexed": true + }, + { + "type": "address", + "name": "exchange", + "indexed": true + } + ], + "anonymous": false, + "type": "event" + }, + { + "name": "initializeFactory", + "outputs": [], + "inputs": [ + { + "type": "address", + "name": "template" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 35725 + }, + { + "name": "createExchange", + "outputs": [ + { + "type": "address", + "name": "out" + } + ], + "inputs": [ + { + "type": "address", + "name": "token" + } + ], + "constant": false, + "payable": false, + "type": "function", + "gas": 187915 + }, + { + "name": "getExchange", + "outputs": [ + { + "type": "address", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "token" + } + ], + "constant": true, + "payable": false, + "type": "function", + "gas": 676 + }, + { + "name": "getToken", + "outputs": [ + { + "type": "address", + "name": "out" + } + ], + "inputs": [ + { + "type": "address", + "name": "exchange" + } + ], + "constant": true, + "payable": false, + "type": "function", + "gas": 745 + }, + { + "name": "getTokenWithId", + "outputs": [ + { + "type": "address", + "name": "out" + } + ], + "inputs": [ + { + "type": "uint256", + "name": "token_id" + } + ], + "constant": true, + "payable": false, + "type": "function", + "gas": 736 + }, + { + "name": "exchangeTemplate", + "outputs": [ + { + "type": "address", + "name": "out" + } + ], + "inputs": [], + "constant": true, + "payable": false, + "type": "function", + "gas": 633 + }, + { + "name": "tokenCount", + "outputs": [ + { + "type": "uint256", + "name": "out" + } + ], + "inputs": [], + "constant": true, + "payable": false, + "type": "function", + "gas": 663 + } + ], + "bytecode": "0x6103c856600035601c52740100000000000000000000000000000000000000006020526f7fffffffffffffffffffffffffffffff6040527fffffffffffffffffffffffffffffffff8000000000000000000000000000000060605274012a05f1fffffffffffffffffffffffffdabf41c006080527ffffffffffffffffffffffffed5fa0e000000000000000000000000000000000060a05263538a3f0e60005114156100ed57602060046101403734156100b457600080fd5b60043560205181106100c557600080fd5b50600054156100d357600080fd5b60006101405114156100e457600080fd5b61014051600055005b631648f38e60005114156102a9576020600461014037341561010e57600080fd5b600435602051811061011f57600080fd5b50600061014051141561013157600080fd5b6000600054141561014157600080fd5b7f602e600c600039602e6000f33660006000376110006000366000730000000000610180526c010000000000000000000000006000540261019b527f5af41558576110006000f30000000000000000000000000000000000000000006101af5260406101806000f0806101b357600080fd5b61016052610160513b6101c557600080fd5b610160513014156101d557600080fd5b60006000604463f46d19826102205261014051610240526001546102605261023c6000610160515af161020757600080fd5b61016051600260015460e05260c052604060c020556101405160036101605160e05260c052604060c02055600154600160015401101561024657600080fd5b6001600154016102c0526102c0516001556101405160046102c05160e05260c052604060c0205561016051610140517f9d42cb017eb05bd8944ab536a8b35bc68085931dd5f4356489801453923953f960006000a36101605160005260206000f3005b630b9d584760005114156102e657602060046101403734156102ca57600080fd5b60026101405160e05260c052604060c0205460005260206000f3005b63597704386000511415610335576020600461014037341561030757600080fd5b600435602051811061031857600080fd5b5060036101405160e05260c052604060c0205460005260206000f3005b63aa65a6c06000511415610372576020600461014037341561035657600080fd5b60046101405160e05260c052604060c0205460005260206000f3005b631c2bbd18600051141561039857341561038b57600080fd5b60005460005260206000f3005b639f181b5e60005114156103be5734156103b157600080fd5b60015460005260206000f3005b60006000fd5b6100046103c8036100046000396100046103c8036000f3", + "deployedBytecode": "0x600035601c52740100000000000000000000000000000000000000006020526f7fffffffffffffffffffffffffffffff6040527fffffffffffffffffffffffffffffffff8000000000000000000000000000000060605274012a05f1fffffffffffffffffffffffffdabf41c006080527ffffffffffffffffffffffffed5fa0e000000000000000000000000000000000060a05263538a3f0e60005114156100ed57602060046101403734156100b457600080fd5b60043560205181106100c557600080fd5b50600054156100d357600080fd5b60006101405114156100e457600080fd5b61014051600055005b631648f38e60005114156102a9576020600461014037341561010e57600080fd5b600435602051811061011f57600080fd5b50600061014051141561013157600080fd5b6000600054141561014157600080fd5b7f602e600c600039602e6000f33660006000376110006000366000730000000000610180526c010000000000000000000000006000540261019b527f5af41558576110006000f30000000000000000000000000000000000000000006101af5260406101806000f0806101b357600080fd5b61016052610160513b6101c557600080fd5b610160513014156101d557600080fd5b60006000604463f46d19826102205261014051610240526001546102605261023c6000610160515af161020757600080fd5b61016051600260015460e05260c052604060c020556101405160036101605160e05260c052604060c02055600154600160015401101561024657600080fd5b6001600154016102c0526102c0516001556101405160046102c05160e05260c052604060c0205561016051610140517f9d42cb017eb05bd8944ab536a8b35bc68085931dd5f4356489801453923953f960006000a36101605160005260206000f3005b630b9d584760005114156102e657602060046101403734156102ca57600080fd5b60026101405160e05260c052604060c0205460005260206000f3005b63597704386000511415610335576020600461014037341561030757600080fd5b600435602051811061031857600080fd5b5060036101405160e05260c052604060c0205460005260206000f3005b63aa65a6c06000511415610372576020600461014037341561035657600080fd5b60046101405160e05260c052604060c0205460005260206000f3005b631c2bbd18600051141561039857341561038b57600080fd5b60005460005260206000f3005b639f181b5e60005114156103be5734156103b157600080fd5b60015460005260206000f3005b60006000fd", + "source": "contract Exchange():\n def setup(token_addr: address, token_id: uint256): modifying\n\nNewExchange: event({token: indexed(address), exchange: indexed(address)})\n\nexchangeTemplate: public(address)\ntokenCount: public(uint256)\ntoken_to_exchange: address[uint256]\nexchange_to_token: address[address]\nid_to_token: address[uint256]\n\n@public\ndef initializeFactory(template: address):\n assert self.exchangeTemplate == ZERO_ADDRESS\n assert template != ZERO_ADDRESS\n self.exchangeTemplate = template\n\n@public\ndef createExchange(token: address) -> address:\n assert token != ZERO_ADDRESS\n assert self.exchangeTemplate != ZERO_ADDRESS\n # assert self.token_to_exchange[token] == ZERO_ADDRESS\n exchange: address = create_with_code_of(self.exchangeTemplate)\n Exchange(exchange).setup(token, self.tokenCount)\n self.token_to_exchange[self.tokenCount] = exchange # Change to index by uint256 instead of token address\n self.exchange_to_token[exchange] = token\n token_id: uint256 = self.tokenCount + 1\n self.tokenCount = token_id\n self.id_to_token[token_id] = token\n log.NewExchange(token, exchange)\n return exchange\n\n@public\n@constant\ndef getExchange(token: uint256) -> address:\n return self.token_to_exchange[token]\n\n@public\n@constant\ndef getToken(exchange: address) -> address:\n return self.exchange_to_token[exchange]\n\n@public\n@constant\ndef getTokenWithId(token_id: uint256) -> address:\n return self.id_to_token[token_id]\n", + "sourcePath": "/Users/jg/Documents/aaveBot/contracts/uniswap_factory_custom.vy", + "compiler": { + "name": "vyper", + "version": "0.1.0b4" + }, + "networks": { + "42": { + "events": { + "0x9d42cb017eb05bd8944ab536a8b35bc68085931dd5f4356489801453923953f9": { + "name": "NewExchange", + "inputs": [ + { + "type": "address", + "name": "token", + "indexed": true + }, + { + "type": "address", + "name": "exchange", + "indexed": true + } + ], + "anonymous": false, + "type": "event", + "signature": "0x9d42cb017eb05bd8944ab536a8b35bc68085931dd5f4356489801453923953f9" + } + }, + "links": {}, + "address": "0x830FB2D0C6B97E0BA0cF1010287136D02Cf581B2", + "transactionHash": "0x845ff074db149bf24e1bd59c567bce580b9762dab65adaa9794eafba15e538ee" + } + }, + "schemaVersion": "3.0.16", + "updatedAt": "2019-11-07T15:21:05.386Z" +} \ No newline at end of file diff --git a/contracts/FlashLoanReceiverExample.sol b/contracts/FlashLoanReceiverExample.sol new file mode 100644 index 0000000..2979606 --- /dev/null +++ b/contracts/FlashLoanReceiverExample.sol @@ -0,0 +1,41 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; + +import "./mocks/tokens/MintableERC20.sol"; +import "./flashloan/base/FlashLoanReceiverBase.sol"; +import "./configuration/LendingPoolAddressesProvider.sol"; +import "./configuration/NetworkMetadataProvider.sol"; + +contract FlashLoanReceiverExample is FlashLoanReceiverBase { + + using SafeMath for uint256; + + // Events + event borrowMade(address _reserve, uint256 _amount , uint256 _value); + + + constructor(LendingPoolAddressesProvider _provider) FlashLoanReceiverBase(_provider) + public {} + + + function executeOperation( + address _reserve, + uint256 _amount, + uint256 _fee) external returns(uint256 returnedAmount) { + + //check the contract has the specified balance + require(_amount <= getBalanceInternal(address(this), _reserve), + "Invalid balance for the contract"); + + /** + + CUSTOM ACTION TO PERFORM WITH THE BORROWED LIQUIDITY + + */ + emit borrowMade(_reserve, _amount , address(this).balance); + + transferFundsBackToPoolInternal(_reserve, _amount.add(_fee)); + return _amount.add(_fee); + } +} diff --git a/contracts/configuration/AddressStorage.sol b/contracts/configuration/AddressStorage.sol new file mode 100755 index 0000000..2661cba --- /dev/null +++ b/contracts/configuration/AddressStorage.sol @@ -0,0 +1,14 @@ +pragma solidity ^0.5.0; + +contract AddressStorage { + mapping(bytes32 => address) private addresses; + + function getAddress(bytes32 _key) public view returns (address) { + return addresses[_key]; + } + + function _setAddress(bytes32 _key, address _value) internal { + addresses[_key] = _value; + } + +} diff --git a/contracts/configuration/LendingPoolAddressesProvider.sol b/contracts/configuration/LendingPoolAddressesProvider.sol new file mode 100755 index 0000000..266a53a --- /dev/null +++ b/contracts/configuration/LendingPoolAddressesProvider.sol @@ -0,0 +1,158 @@ +pragma solidity ^0.5.0; + +import "./AddressStorage.sol"; +import "../interfaces/ILendingPoolAddressesProvider.sol"; + +contract LendingPoolAddressesProvider is ILendingPoolAddressesProvider, AddressStorage { + + //events + event LendingPoolUpdated(address indexed newAddress); + event LendingPoolCoreUpdated(address indexed newAddress); + event LendingPoolParametersProviderUpdated(address indexed newAddress); + event LendingPoolManagerUpdated(address indexed newAddress); + event LendingPoolConfiguratorUpdated(address indexed newAddress); + event LendingPoolLiquidationManagerUpdated(address indexed newAddress); + event LendingPoolDataProviderUpdated(address indexed newAddress); + event LendingPoolNetworkMetadataProviderUpdated(address indexed newAddress); + event PriceOracleUpdated(address indexed newAddress); + event LendingRateOracleUpdated(address indexed newAddress); + event FeeProviderUpdated(address indexed newAddress); + event InterestRrateStrategyUpdated(address indexed newAddress); + + + bytes32 private constant LENDING_POOL = "LENDING_POOL"; + bytes32 private constant LENDING_POOL_CORE = "LENDING_POOL_CORE"; + bytes32 private constant LENDING_POOL_CONFIGURATOR = "LENDING_POOL_CONFIGURATOR"; + bytes32 private constant LENDING_POOL_PARAMETERS_PROVIDER = "PARAMETERS_PROVIDER"; + bytes32 private constant LENDING_POOL_MANAGER = "LENDING_POOL_MANAGER"; + bytes32 private constant LENDING_POOL_LIQUIDATION_MANAGER = "LIQUIDATION_MANAGER"; + bytes32 private constant DATA_PROVIDER = "DATA_PROVIDER"; + bytes32 private constant NETWORK_METADATA_PROVIDER = "NETWORK_METADATA_PROVIDER"; + bytes32 private constant PRICE_ORACLE = "PRICE_ORACLE"; + bytes32 private constant LENDING_RATE_ORACLE = "LENDING_RATE_ORACLE"; + bytes32 private constant FEE_PROVIDER = "FEE_PROVIDER"; + bytes32 private constant INTEREST_RATE_STRATEGY = "INTEREST_RATE_STRATEGY"; + bytes32 private constant WALLET_BALANCE_PROVIDER = "WALLET_BALANCE_PROVIDER"; + + function getLendingPool() public view returns (address) { + return getAddress(LENDING_POOL); + } + + // TODO: add access control rules under DAO + function setLendingPool(address _pool) public { + _setAddress(LENDING_POOL, _pool); + emit LendingPoolUpdated(_pool); + } + + function getInterestRateStrategy() public view returns (address) { + return getAddress(INTEREST_RATE_STRATEGY); + } + + // TODO: add access control rules under DAO + function setInterestRateStrategy(address _strategy) public { + _setAddress(INTEREST_RATE_STRATEGY, _strategy); + emit InterestRrateStrategyUpdated(_strategy); + } + + function getLendingPoolCore() public view returns (address payable) { + address payable core = address(uint160(getAddress(LENDING_POOL_CORE))); + return core; + } + + // TODO: add access control rules under DAO + function setLendingPoolCore(address _lendingPoolCore) public { + _setAddress(LENDING_POOL_CORE, _lendingPoolCore); + emit LendingPoolCoreUpdated(_lendingPoolCore); + } + + function getLendingPoolConfigurator() public view returns (address) { + return getAddress(LENDING_POOL_CONFIGURATOR); + } + + // TODO: add access control rules under DAO + function setLendingPoolConfigurator(address _configurator) public { + _setAddress(LENDING_POOL_CONFIGURATOR, _configurator); + emit LendingPoolConfiguratorUpdated(_configurator); + } + + function getLendingPoolManager() public view returns (address) { + return getAddress(LENDING_POOL_MANAGER); + } + + // TODO: add access control rules under DAO + function setLendingPoolManager(address _lendingPoolManager) public { + _setAddress(LENDING_POOL_MANAGER, _lendingPoolManager); + emit LendingPoolManagerUpdated(_lendingPoolManager); + } + + function getLendingPoolDataProvider() public view returns (address) { + return getAddress(DATA_PROVIDER); + } + + // TODO: add access control rules under DAO + function setLendingPoolDataProvider(address _provider) public { + _setAddress(DATA_PROVIDER, _provider); + emit LendingPoolDataProviderUpdated(_provider); + } + + function getNetworkMetadataProvider() public view returns (address) { + return getAddress(NETWORK_METADATA_PROVIDER); + } + + // TODO: add access control rules under DAO + function setNetworkMetadataProvider(address _networkMetadataProvider) public { + _setAddress(NETWORK_METADATA_PROVIDER, _networkMetadataProvider); + emit LendingPoolNetworkMetadataProviderUpdated(_networkMetadataProvider); + } + + function getLendingPoolParametersProvider() public view returns (address) { + return getAddress(LENDING_POOL_PARAMETERS_PROVIDER); + } + + // TODO: add access control rules under DAO + function setLendingPoolParametersProvider(address _parametersProvider) public { + _setAddress(LENDING_POOL_PARAMETERS_PROVIDER, _parametersProvider); + emit LendingPoolParametersProviderUpdated(_parametersProvider); + } + + + function getPriceOracle() public view returns (address) { + return getAddress(PRICE_ORACLE); + } + + // TODO: add access control rules under DAO + function setPriceOracle(address _priceOracle) public { + _setAddress(PRICE_ORACLE, _priceOracle); + emit PriceOracleUpdated(_priceOracle); + } + + function getLendingRateOracle() public view returns (address) { + return getAddress(LENDING_RATE_ORACLE); + } + + // TODO: add access control rules under DAO + function setLendingRateOracle(address _lendingRateOracle) public { + _setAddress(LENDING_RATE_ORACLE, _lendingRateOracle); + emit LendingRateOracleUpdated(_lendingRateOracle); + } + + function getFeeProvider() public view returns (address) { + return getAddress(FEE_PROVIDER); + } + + // TODO: add access control rules under DAO + function setFeeProvider(address _feeProvider) public { + _setAddress(FEE_PROVIDER, _feeProvider); + emit FeeProviderUpdated(_feeProvider); + } + + function getLendingPoolLiquidationManager() public view returns (address) { + return getAddress(LENDING_POOL_LIQUIDATION_MANAGER); + } + + // TODO: add access control rules under DAO + function setLendingPoolLiquidationManager(address _manager) public { + _setAddress(LENDING_POOL_LIQUIDATION_MANAGER, _manager); + emit LendingPoolLiquidationManagerUpdated(_manager); + } +} diff --git a/contracts/configuration/LendingPoolParametersProvider.sol b/contracts/configuration/LendingPoolParametersProvider.sol new file mode 100755 index 0000000..55e70b6 --- /dev/null +++ b/contracts/configuration/LendingPoolParametersProvider.sol @@ -0,0 +1,42 @@ +pragma solidity ^0.5.0; + + +import "openzeppelin-solidity/contracts/ownership/Ownable.sol"; +import "./UintStorage.sol"; + +/** +@title LendingPoolParametersProvider +@author Aave +@notice stores the configuration parameters of the Lending Pool contract + + */ +contract LendingPoolParametersProvider is UintStorage, Ownable { + bytes32 private constant MAX_FIXED_RATE_BORROW_SIZE_PERCENT = "MAX_RATE_BORROW_SIZE_PERCENT"; + bytes32 private constant REBALANCE_DOWN_RATE_DELTA = "REBALANCE_DOWN_RATE_DELTA"; + + /** + @dev returns the maximum fixed rate borrow size, in percentage of the available liquidity. + */ + function getMaxFixedRateBorrowSizePercent() external view returns (uint256) { + return getUint(MAX_FIXED_RATE_BORROW_SIZE_PERCENT); + } + + // TODO: add access control rules under DAO + function setMaxFixedRateBorrowSizePercent(uint256 _borrowSizePercent) external onlyOwner { + return _setUint(MAX_FIXED_RATE_BORROW_SIZE_PERCENT, _borrowSizePercent); + } + + /** + @dev returns the delta between the current fixed rate and the user fixed rate at + which the borrow position of the user will be rebalanced (scaled down) + */ + function getRebalanceDownRateDelta() external view returns (uint256) { + return getUint(REBALANCE_DOWN_RATE_DELTA); + } + + // TODO: add access control rules under DAO + function setRebalanceDownRateDelta(uint256 _delta) external onlyOwner { + return _setUint(REBALANCE_DOWN_RATE_DELTA, _delta); + } + +} diff --git a/contracts/configuration/NetworkMetadataProvider.sol b/contracts/configuration/NetworkMetadataProvider.sol new file mode 100755 index 0000000..940a900 --- /dev/null +++ b/contracts/configuration/NetworkMetadataProvider.sol @@ -0,0 +1,29 @@ +pragma solidity ^0.5.0; + +import "../interfaces/INetworkMetadataProvider.sol"; +import "./UintStorage.sol"; +import "./AddressStorage.sol"; + +contract NetworkMetadataProvider is INetworkMetadataProvider, UintStorage, AddressStorage { + bytes32 private constant BLOCKS_PER_YEAR = "BLOCKS_PER_YEAR"; + bytes32 private constant ETHEREUM_ADDRESS = "ETHEREUM_ADDRESS"; + + function getBlocksPerYear() external view returns (uint256) { + return getUint(BLOCKS_PER_YEAR); + } + + // TODO: add access control rules under DAO + function setBlocksPerYear(uint256 _blocksPerYear) external { + return _setUint(BLOCKS_PER_YEAR, _blocksPerYear); + } + + function getEthereumAddress() external view returns (address) { + return getAddress(ETHEREUM_ADDRESS); + } + + // TODO: add access control rules under DAO + function setEthereumAddress(address _ethereumAddress) external { + return _setAddress(ETHEREUM_ADDRESS, _ethereumAddress); + } + +} diff --git a/contracts/configuration/UintStorage.sol b/contracts/configuration/UintStorage.sol new file mode 100755 index 0000000..9ef593e --- /dev/null +++ b/contracts/configuration/UintStorage.sol @@ -0,0 +1,14 @@ +pragma solidity ^0.5.0; + +contract UintStorage { + mapping(bytes32 => uint256) private uints; + + function getUint(bytes32 _key) public view returns (uint256) { + return uints[_key]; + } + + function _setUint(bytes32 _key, uint256 _value) internal { + uints[_key] = _value; + } + +} diff --git a/contracts/fees/FeeProvider.sol b/contracts/fees/FeeProvider.sol new file mode 100755 index 0000000..6621e04 --- /dev/null +++ b/contracts/fees/FeeProvider.sol @@ -0,0 +1,47 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/ownership/Ownable.sol"; +import "../interfaces/IFeeProvider.sol"; +import "../libraries/WadRayMath.sol"; + +// TODO: move Ownable to governance based ACR +contract FeeProvider is IFeeProvider, Ownable { + using WadRayMath for uint256; + + uint256 originationFeePercentage; + address feesCollectionAddress; + + constructor(address _feesCollectionAddress) public { + feesCollectionAddress = _feesCollectionAddress; + + /** + @notice origination fee is set as default as 25 basis points of the loan amount (0.0025%) + */ + originationFeePercentage = 0.0025 * 1e18; + } + + /** + @dev _user can be used in the future to apply discount to the origination fee based on the + _user account (eg. stake AAVE tokens in the lending pool, or deposit > 1M USD etc.) + */ + function calculateLoanOriginationFee(address _user, uint256 _amount) external view returns (uint256) { + return _amount.wadMul(originationFeePercentage); + } + + function setLoanOriginationFeePercentage(uint256 _percentage) external onlyOwner { + originationFeePercentage = _percentage; + } + + function getLoanOriginationFeePercentage() external view returns (uint256) { + return originationFeePercentage; + } + + function setFeesCollectionAddress(address _feesCollectionAddress) external onlyOwner { + feesCollectionAddress = _feesCollectionAddress; + } + + function getFeesCollectionAddress() external view returns (address) { + return feesCollectionAddress; + } + +} diff --git a/contracts/flashloan/base/FlashLoanReceiverBase.sol b/contracts/flashloan/base/FlashLoanReceiverBase.sol new file mode 100755 index 0000000..af231e0 --- /dev/null +++ b/contracts/flashloan/base/FlashLoanReceiverBase.sol @@ -0,0 +1,51 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; +import "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol"; +import "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol"; +import "../interfaces/IFlashLoanReceiver.sol"; +import "../../interfaces/ILendingPoolAddressesProvider.sol"; +import "../../interfaces/INetworkMetadataProvider.sol"; + +contract FlashLoanReceiverBase is IFlashLoanReceiver { + + using SafeERC20 for IERC20; + using SafeMath for uint256; + + ILendingPoolAddressesProvider addressesProvider; + + constructor(ILendingPoolAddressesProvider _provider) public { + addressesProvider = _provider; + } + + function () external payable { + } + + function transferFundsBackToPoolInternal(address _reserve, uint _amount) internal { + + address payable core = addressesProvider.getLendingPoolCore(); + + transferInternal(core,_reserve, _amount); + } + + function transferInternal(address payable _destination, address _reserve, uint _amount) internal { + if(_reserve == INetworkMetadataProvider(addressesProvider.getNetworkMetadataProvider()).getEthereumAddress()) { + _destination.transfer(_amount); + return; + } + + IERC20(_reserve).safeTransfer(_destination, _amount); + + + } + + function getBalanceInternal(address _target, address _reserve) internal view returns(uint256) { + if(_reserve == INetworkMetadataProvider(addressesProvider.getNetworkMetadataProvider()).getEthereumAddress()) { + + return _target.balance; + } + + return IERC20(_reserve).balanceOf(_target); + + } +} \ No newline at end of file diff --git a/contracts/flashloan/interfaces/IFlashLoanReceiver.sol b/contracts/flashloan/interfaces/IFlashLoanReceiver.sol new file mode 100755 index 0000000..bbbb787 --- /dev/null +++ b/contracts/flashloan/interfaces/IFlashLoanReceiver.sol @@ -0,0 +1,11 @@ +pragma solidity ^0.5.0; + +/************ +@title IFeeProvider interface +@notice Interface for the Aave fee provider. +*/ + +interface IFlashLoanReceiver { + + function executeOperation(address _reserve, uint256 _amount, uint256 _fee) external returns (uint256 returnedAmount); +} diff --git a/contracts/interfaces/IFeeProvider.sol b/contracts/interfaces/IFeeProvider.sol new file mode 100755 index 0000000..40a4a9d --- /dev/null +++ b/contracts/interfaces/IFeeProvider.sol @@ -0,0 +1,19 @@ +pragma solidity ^0.5.0; + +/************ +@title IFeeProvider interface +@notice Interface for the Aave fee provider. +*/ + +interface IFeeProvider { + function calculateLoanOriginationFee(address _user, uint256 _amount) external view returns (uint256); + + function setLoanOriginationFeePercentage(uint256 _amount) external; + + function getLoanOriginationFeePercentage() external view returns (uint256); + + function setFeesCollectionAddress(address _feesCollectionAddress) external; + + function getFeesCollectionAddress() external view returns (address); + +} diff --git a/contracts/interfaces/ILendingPoolAddressesProvider.sol b/contracts/interfaces/ILendingPoolAddressesProvider.sol new file mode 100755 index 0000000..88ca8ac --- /dev/null +++ b/contracts/interfaces/ILendingPoolAddressesProvider.sol @@ -0,0 +1,44 @@ +pragma solidity ^0.5.0; + +/** +@title ILendingPoolAddressesProvider interface +@notice provides the interface to fetch the LendingPoolCore address + */ + +contract ILendingPoolAddressesProvider { + + function getLendingPool() public view returns (address); + function setLendingPool(address _pool) public; + + function getLendingPoolCore() public view returns (address payable); + function setLendingPoolCore(address _lendingPoolCore) public; + + function getLendingPoolConfigurator() public view returns (address); + function setLendingPoolConfigurator(address _configurator) public; + + function getLendingPoolManager() public view returns (address); + function setLendingPoolManager(address _lendingPoolManager) public; + + + function getLendingPoolDataProvider() public view returns (address); + function setLendingPoolDataProvider(address _provider) public; + + function getNetworkMetadataProvider() public view returns (address); + function setNetworkMetadataProvider(address _networkMetadataProvider) public; + + function getLendingPoolParametersProvider() public view returns (address); + function setLendingPoolParametersProvider(address _parametersProvider) public; + + function getPriceOracle() public view returns (address); + function setPriceOracle(address _priceOracle) public; + + function getLendingRateOracle() public view returns (address); + function setLendingRateOracle(address _lendingRateOracle) public; + + function getFeeProvider() public view returns (address); + function setFeeProvider(address _feeProvider) public; + + function getLendingPoolLiquidationManager() public view returns (address); + function setLendingPoolLiquidationManager(address _manager) public; + +} \ No newline at end of file diff --git a/contracts/interfaces/ILendingRateOracle.sol b/contracts/interfaces/ILendingRateOracle.sol new file mode 100755 index 0000000..4f8af3e --- /dev/null +++ b/contracts/interfaces/ILendingRateOracle.sol @@ -0,0 +1,28 @@ +pragma solidity ^0.5.0; + +/************ +@title ILendingRateOracle interface +@notice Interface for the Aave borrow rate oracle. Provides the average market borrow rate to be used as a base for the fixed borrow rate calculations*/ + +interface ILendingRateOracle { + /*********** + @dev returns the market borrow rate in wei + */ + function getMarketBorrowRate(address _asset) external view returns (uint256); + + /*********** + @dev sets the market borrow rate. Rate value must be in wei + */ + function setMarketBorrowRate(address _asset, uint256 _rate) external; + + /*********** + @dev returns the market borrow rate in wei + */ + function getMarketLiquidityRate(address _asset) external view returns (uint256); + + /*********** + @dev sets the market borrow rate. Rate value must be in wei + */ + function setMarketLiquidityRate(address _asset, uint256 _rate) external; + +} diff --git a/contracts/interfaces/INetworkMetadataProvider.sol b/contracts/interfaces/INetworkMetadataProvider.sol new file mode 100755 index 0000000..cfd3417 --- /dev/null +++ b/contracts/interfaces/INetworkMetadataProvider.sol @@ -0,0 +1,29 @@ +pragma solidity ^0.5.0; + +/************ +@title INetworkMetadataProvider interface +@notice Interface for the ethereum network general data +*/ + +interface INetworkMetadataProvider { + /*********** + @dev returns the number of blocks in a year + */ + function getBlocksPerYear() external view returns (uint256); + + /*********** + @dev sets the number of blocks in a year + */ + function setBlocksPerYear(uint256 _blocksPerYear) external; + + /*********** + @dev returns the address used as mock for the ethereum asset + */ + function getEthereumAddress() external view returns (address); + + /*********** + @dev sets the address used as mock for the ethereum asset + */ + function setEthereumAddress(address _ethereumAddress) external; + +} diff --git a/contracts/interfaces/IPriceOracle.sol b/contracts/interfaces/IPriceOracle.sol new file mode 100755 index 0000000..e28a7aa --- /dev/null +++ b/contracts/interfaces/IPriceOracle.sol @@ -0,0 +1,27 @@ +pragma solidity ^0.5.0; + +/************ +@title IPriceOracle interface +@notice Interface for the Aave price oracle.*/ +interface IPriceOracle { + /*********** + @dev returns the asset price in ETH + */ + function getAssetPrice(address _asset) external view returns (uint256); + + /*********** + @dev sets the asset price + */ + function setAssetPrice(address _asset, uint256 _price) external; + + /*********** + @dev returns the asset price in USD + */ + function getEthUsdPrice() external view returns (uint256); + + /*********** + @dev sets the asset price + */ + function setEthUsdPrice(uint256 _price) external; + +} diff --git a/contracts/interfaces/IReserveInterestRateStrategy.sol b/contracts/interfaces/IReserveInterestRateStrategy.sol new file mode 100755 index 0000000..de33bd0 --- /dev/null +++ b/contracts/interfaces/IReserveInterestRateStrategy.sol @@ -0,0 +1,29 @@ +pragma solidity ^0.5.0; + +/** +@title IReserveInterestRateStrategyInterface interface +@notice Interface for the calculation of the interest rates. +*/ + +interface IReserveInterestRateStrategy { + + /** + * @dev returns the base variable borrow rate, in rays + */ + + function getBaseVariableBorrowRate() external view returns (uint); + /** + * @dev calculates the liquidity, fixed, and variable rates depending on the current utilization rate + * and the base parameters + * + */ + function calculateInterestRates( + address _reserve, + uint256 _utilizationRate, + uint256 _totalBorrowsFixed, + uint256 _totalBorrowsVariable, + uint256 _averageFixedBorrowRate) + external + view + returns (uint256 liquidityRate, uint256 fixedBorrowRate, uint256 variableBorrowRate); +} diff --git a/contracts/lendingpool/DefaultReserveInterestRateStrategy.sol b/contracts/lendingpool/DefaultReserveInterestRateStrategy.sol new file mode 100755 index 0000000..c07ccdc --- /dev/null +++ b/contracts/lendingpool/DefaultReserveInterestRateStrategy.sol @@ -0,0 +1,126 @@ +pragma solidity ^0.5.0; + +import "../interfaces/IReserveInterestRateStrategy.sol"; +import "../libraries/WadRayMath.sol"; +import "../configuration/LendingPoolAddressesProvider.sol"; +import "./LendingPoolCore.sol"; +import "../interfaces/ILendingRateOracle.sol"; + + +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; + + + +/** +@title DefaultReserveInterestRateStrategy contract +@notice implements the calculation of the interest rates based on the reserve parameters. +*/ + +contract DefaultReserveInterestRateStrategy is IReserveInterestRateStrategy { + + using WadRayMath for uint256; + using SafeMath for uint256; + + uint256 constant FIXED_RATE_INCREASE_THRESHOLD = (1e27)/4; // 0.25 ray, 25% of the utilization rate + + LendingPoolCore core; + ILendingRateOracle lendingRateOracle; + + uint256 baseVariableBorrowRate; + uint256 variableBorrowRateScaling; + uint256 fixedBorrowRateScaling; + uint256 borrowToLiquidityRateDelta; + address reserve; + + constructor( + address _reserve, + LendingPoolAddressesProvider _provider, + uint256 _baseVariableBorrowRate, + uint256 _variableBorrowRateScaling, + uint256 _fixedBorrowRateScaling, + uint256 _borrowToLiquidityRateDelta) public { + + core = LendingPoolCore(_provider.getLendingPoolCore()); + lendingRateOracle = ILendingRateOracle(_provider.getLendingRateOracle()); + baseVariableBorrowRate = _baseVariableBorrowRate; + variableBorrowRateScaling = _variableBorrowRateScaling; + fixedBorrowRateScaling = _fixedBorrowRateScaling; + borrowToLiquidityRateDelta = _borrowToLiquidityRateDelta; + reserve = _reserve; + } + + /** + @dev accessors + */ + + function getBaseVariableBorrowRate() external view returns(uint256) { + return baseVariableBorrowRate; + } + + function getVariableBorrowRateScaling() external view returns(uint256) { + return variableBorrowRateScaling; + } + + function getFixedBorrowRateScaling() external view returns(uint256) { + return fixedBorrowRateScaling; + } + + function getBorrowToLiquidityRateDelta() external view returns(uint256) { + return borrowToLiquidityRateDelta; + } + + + + /** + @dev returns the interest rates, in rays + */ + function calculateInterestRates( + address _reserve, + uint256 _utilizationRate, + uint256 _totalBorrowsFixed, + uint256 _totalBorrowsVariable, + uint256 _averageFixedBorrowRate + ) external view returns (uint256 currentLiquidityRate, uint256 currentFixedBorrowRate, uint256 currentVariableBorrowRate) { + + currentFixedBorrowRate = lendingRateOracle.getMarketBorrowRate(_reserve); + + if(_utilizationRate > FIXED_RATE_INCREASE_THRESHOLD){ + currentFixedBorrowRate = currentFixedBorrowRate.add(fixedBorrowRateScaling.rayMul(_utilizationRate.sub(FIXED_RATE_INCREASE_THRESHOLD))); + } + + currentVariableBorrowRate = _utilizationRate.rayMul(variableBorrowRateScaling).add( + baseVariableBorrowRate + ); + + currentLiquidityRate = getOverallBorrowRateInternal( + _totalBorrowsFixed, + _totalBorrowsVariable, + currentVariableBorrowRate, + _averageFixedBorrowRate).rayMul(_utilizationRate); + + } + + /** + @dev the weighted average between the fixed interest part and the variable interest part + */ + function getOverallBorrowRateInternal( + uint256 _totalBorrowsFixed, + uint256 _totalBorrowsVariable, + uint256 _currentVariableBorrowRate, + uint256 _currentAverageFixedBorrowRate) internal pure returns (uint256) { + + uint256 totalBorrows = _totalBorrowsFixed.add(_totalBorrowsVariable); + + if (totalBorrows == 0) return 0; + + uint256 weightedVariableRate = _totalBorrowsVariable.wadToRay().rayMul( + _currentVariableBorrowRate + ); + + uint256 weightedFixedRate = _totalBorrowsFixed.wadToRay().rayMul(_currentAverageFixedBorrowRate); + + uint256 overallBorrowRate = weightedVariableRate.add(weightedFixedRate).rayDiv(totalBorrows.wadToRay()); + + return overallBorrowRate; + } +} diff --git a/contracts/lendingpool/LendingPool.sol b/contracts/lendingpool/LendingPool.sol new file mode 100755 index 0000000..4a5cea5 --- /dev/null +++ b/contracts/lendingpool/LendingPool.sol @@ -0,0 +1,763 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; +import "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol"; +import "openzeppelin-solidity/contracts/utils/Address.sol"; +import "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol"; + +import "../configuration/LendingPoolAddressesProvider.sol"; +import "../configuration/LendingPoolParametersProvider.sol"; +import "../configuration/NetworkMetadataProvider.sol"; +import "../tokenization/AToken.sol"; +import "../libraries/CoreLibrary.sol"; +import "../libraries/WadRayMath.sol"; +import "../interfaces/IFeeProvider.sol"; +import "../flashloan/interfaces/IFlashLoanReceiver.sol"; +import "./LendingPoolCore.sol"; +import "./LendingPoolDataProvider.sol"; +import "./LendingPoolLiquidationManager.sol"; + + + +/************************************************************************************* +@title LendingPool contract +@author Aave +@notice Implements the actions of the LendingPool, and exposes accessory methods to access the core information + *************************************************************************************/ + + +contract LendingPool is ReentrancyGuard { + using SafeMath for uint256; + using WadRayMath for uint256; + using Address for address payable; + + LendingPoolAddressesProvider public addressesProvider; + LendingPoolCore core; + LendingPoolDataProvider dataProvider; + LendingPoolParametersProvider parametersProvider; + + /** + @dev events + */ + event Deposit(address indexed _reserve, address indexed _user, uint256 _amount, uint16 indexed _referral, uint256 timestamp); + event RedeemUnderlying( + address indexed _reserve, + address indexed _user, + uint256 _amount, + uint256 timestamp + ); + + event Borrow(address indexed _reserve, address indexed _user, uint256 _amount, uint16 indexed _referral, uint256 timestamp); + event Repay(address indexed _reserve, address indexed _user, uint256 _amount, uint256 timestamp); + event LiquidationCall(address indexed _collateral, address indexed _user, uint256 _amount, address indexed _reserve, uint256 timestamp); + event Swap(address indexed _reserve, address indexed _user, uint256 timestamp); + event FlashLoan(address indexed _target, address indexed _reserve, uint256 _amount, uint256 _fee, uint256 timestamp); + event ReserveUsedAsCollateralEnabled(address indexed _reserve, address indexed _user); + event ReserveUsedAsCollateralDisabled(address indexed _reserve, address indexed _user); + + + /** + @dev modifiers + */ + + modifier onlyOverlyingAToken(address _reserve) { + require( + msg.sender == core.getReserveATokenAddress(_reserve), + "The caller of this function can only be the aToken contract of this reserve" + ); + _; + } + + modifier onlyActiveReserve(address _reserve) { + requireReserveActiveInternal(_reserve); + _; + } + + uint256 constant UINT_MAX_VALUE = uint256(-1); + + constructor(LendingPoolAddressesProvider _addressesProvider) public { + + addressesProvider = _addressesProvider; + core = LendingPoolCore(addressesProvider.getLendingPoolCore()); + dataProvider = LendingPoolDataProvider(addressesProvider.getLendingPoolDataProvider()); + parametersProvider = LendingPoolParametersProvider(addressesProvider.getLendingPoolParametersProvider()); + } + + /** + * @notice deposits The underlying asset into the reserve. A corresponding amount of the overlying asset (aTokens) + * is minted. + */ + function deposit( + address _reserve, + uint256 _amount, + uint16 _referralCode) + external payable nonReentrant onlyActiveReserve(_reserve) { + + //compounding liquidity and borrow interests + core.updateReserveCumulativeIndexes(_reserve); + + //updating reserve data + core.increaseReserveTotalLiquidity(_reserve, _amount); + core.updateReserveInterestRates(_reserve); + core.setReserveLastUpdate(_reserve); + + AToken aToken = AToken(core.getReserveATokenAddress(_reserve)); + + if(aToken.balanceOf(msg.sender) == 0){ + //if this is the first deposit of the user, we configure the deposit as enabled to be used as collateral + core.setUserUseReserveAsCollateral(_reserve, msg.sender, true); + } + + //minting AToken to user 1:1 with the specific exchange rate + aToken.mintOnDeposit(msg.sender, _amount); + + //transfer to the core contract + + core.transferToReserve.value(msg.value)(_reserve, msg.sender, _amount); + + //solium-disable-next-line + emit Deposit(_reserve, msg.sender, _amount, _referralCode, block.timestamp); + + } + + /** + * @notice Allows to redeem a specific amount of underlying asset. + * @dev only aToken contracts can call this function + */ + function redeemUnderlying( + address _reserve, + address payable _user, + uint256 _amount) + external nonReentrant onlyOverlyingAToken(_reserve) onlyActiveReserve(_reserve) { + + uint256 currentAvailableLiquidity = core.getReserveAvailableLiquidity(_reserve); + require(currentAvailableLiquidity >= _amount, "There is not enough liquidity available to redeem"); + + //compound liquidity and variable borrow interests + core.updateReserveCumulativeIndexes(_reserve); + + /** + @dev update reserve data + */ + + core.decreaseReserveTotalLiquidity(_reserve, _amount); + core.updateReserveInterestRates(_reserve); + core.setReserveLastUpdate(_reserve); + + core.transferToUser(_reserve, _user, _amount); + + //solium-disable-next-line + emit RedeemUnderlying(_reserve, _user, _amount, block.timestamp); + + } + + /** + * @dev data structures for local computations in the borrow() method. + */ + + struct BorrowLocalVars { + uint256 currentLtv; + uint256 currentLiquidationThreshold; + uint256 borrowFee; + uint256 requestedBorrowAmountETH; + uint256 amountOfCollateralNeededETH; + uint256 principalBorrowBalance; + uint256 compoundedBorrowBalance; + uint256 compoundedAmount; + uint256 userCollateralBalanceETH; + uint256 userBorrowBalanceETH; + uint256 healthFactor; + uint256 balanceIncrease; + uint256 currentReserveFixedRate; + uint256 availableLiquidity; + } + + /** + * @notice executes a borrow on the reserve of the specific amount with the interestRateMode specified. + */ + + function borrow( + address _reserve, + uint256 _amount, + uint256 _interestRateMode, + uint16 _referralCode) + external nonReentrant onlyActiveReserve(_reserve) { + + BorrowLocalVars memory vars; + + //check that the reserve is enabled for borrowing + require(core.isReserveBorrowingEnabled(_reserve), "Reserve is not enabled for borrowing"); + + //check that the amount is available in the reserve + vars.availableLiquidity = core.getReserveAvailableLiquidity(_reserve); + + require( + vars.availableLiquidity >= _amount, + "There is not enough liquidity available in the reserve" + ); + + //validate interest rate mode + require(uint(CoreLibrary.InterestRateMode.VARIABLE) >= _interestRateMode, "Invalid interest rate mode selected"); + + /** + @dev Following conditions needs to be met if the user is borrowing at a fixed rate: + 1. Reserve must be enabled for fixed rate borrowing + 2. Users cannot borrow from the reserve if their collateral is (mostly) the same currency + they are borrowing, to prevent abuses. + 3. Users will be able to borrow only a relatively small, configurable amount of the total + liquidity + */ + + if(_interestRateMode == uint256(CoreLibrary.InterestRateMode.FIXED)) { + + //check if the borrow mode is fixed and if fixed rate borrowing is enabled on this reserve + require( + _interestRateMode == uint256(CoreLibrary.InterestRateMode.VARIABLE) || + core.getReserveIsFixedBorrowRateEnabled(_reserve), + "Fixed borrows rate are not enabled on this reserve" + ); + + require( + !core.isUserUseReserveAsCollateralEnabled(_reserve, msg.sender) || + !core.isReserveUsageAsCollateralEnabled(_reserve) || + _amount > dataProvider.getUserUnderlyingAssetBalance(_reserve, msg.sender), + "User is trying to borrow an invalid amount" + ); + + /** + @dev calculate the max available loan size in fixed rate mode as a percentage of the + available liquidity + */ + uint256 maxLoanPercent = parametersProvider.getMaxFixedRateBorrowSizePercent(); + uint256 maxLoanSizeFixed = vars.availableLiquidity.mul(maxLoanPercent).div(100); + + require(_amount <= maxLoanSizeFixed, "User is trying to borrow too much liquidity at a fixed rate"); + } + + (, + vars.userCollateralBalanceETH, + vars.userBorrowBalanceETH, + vars.currentLtv, + vars.currentLiquidationThreshold, + vars.healthFactor) = dataProvider.calculateUserGlobalData(msg.sender); + + require(vars.userCollateralBalanceETH > 0, "The collateral balance is 0"); + + require( + vars.healthFactor > dataProvider.getHealthFactorLiquidationThreshold(), + "The borrower can already be liquidated so he cannot borrow more" + ); + + + //calculating fees + vars.borrowFee = IFeeProvider(addressesProvider.getFeeProvider()).calculateLoanOriginationFee( + msg.sender, + _amount + ); + + IPriceOracle oracle = IPriceOracle(addressesProvider.getPriceOracle()); + vars.requestedBorrowAmountETH = oracle.getAssetPrice(_reserve).wadMul(_amount.add(vars.borrowFee)); //price is in ether + + //add the current already borrowed amount to the amount requested to calculate the total collateral needed. + vars.amountOfCollateralNeededETH = vars.userBorrowBalanceETH.add(vars.requestedBorrowAmountETH).mul(100).div( + vars.currentLtv + ); //LTV is calculated in percentage + + require( + vars.amountOfCollateralNeededETH <= vars.userCollateralBalanceETH, + "There is not enough collateral to cover a new borrow" + ); + + //all conditions passed - borrow is accepted + + //step 1: update liquidity index and variable borrow index to allow proper calculation of the compounded interests + core.updateReserveCumulativeIndexes(_reserve); + core.updateUserLastVariableBorrowCumulativeIndex(_reserve, msg.sender); + + //step 2: calculating new borrow principal for the user, which is previous principal + compounded interest + new borrow + (vars.principalBorrowBalance, + vars.compoundedBorrowBalance, + vars.compoundedAmount) = core.getUserBorrowBalances(_reserve, msg.sender); + + vars.balanceIncrease = vars.compoundedAmount.add(_amount); + + /** + @notice increasing reserve total borrows to account for the new borrow balance of the user + @dev NOTE: Depending on the previous borrow mode, the borrows might need to be switched from variable to fixed or viceversa + */ + + vars.currentReserveFixedRate = core.getReserveCurrentFixedBorrowRate(_reserve); + + core.updateReserveTotalBorrowsByRateMode( + _reserve, + msg.sender, + vars.principalBorrowBalance, + vars.balanceIncrease, + CoreLibrary.InterestRateMode(_interestRateMode), + vars.currentReserveFixedRate + ); + + //step 4: update user borrow interest rate + + if (_interestRateMode == uint256(CoreLibrary.InterestRateMode.FIXED)) { + core.updateUserFixedBorrowRate(_reserve, msg.sender); + } else { + //variable + core.resetUserFixedBorrowRate(_reserve, msg.sender); + } + + //step 5: add the compounded amount to the total liquidity of the pool + core.increaseReserveTotalLiquidity(_reserve, vars.compoundedAmount); + + core.updateReserveInterestRates(_reserve); + core.setReserveLastUpdate(_reserve); + + //step 6: updating remaining user data + core.increaseUserPrincipalBorrowBalance(_reserve, msg.sender, vars.balanceIncrease); + core.increaseUserOriginationFee(_reserve, msg.sender, vars.borrowFee); + core.setUserLastUpdate(_reserve, msg.sender); + + //if we reached this point, we can transfer + core.transferToUser(_reserve, msg.sender, _amount); + + //solium-disable-next-line + emit Borrow(_reserve, msg.sender, _amount, _referralCode, block.timestamp); + } + + /** + * @notice repays a borrow on the specific reserve, for the specified amount. + @dev the target user is defined by _onBehalfOf. If there is no repayment on behalf of another account, + _onBehalfOf must be equal to msg.sender. + */ + + function repay( + address _reserve, + uint256 _amount, + address payable _onBehalfOf) + external + payable + nonReentrant + onlyActiveReserve(_reserve) { + + (uint256 principalBorrowBalance, + uint256 compoundedBorrowBalance, + uint256 borrowBalanceIncrease) = core.getUserBorrowBalances(_reserve, _onBehalfOf); + + uint256 originationFee = core.getUserOriginationFee(_reserve, _onBehalfOf); + + require(compoundedBorrowBalance > 0, "The user does not have any borrow pending"); + + require( + _amount != UINT_MAX_VALUE || msg.sender == _onBehalfOf, + "To repay on behalf of an user an explicit amount to repay is needed." + ); + + //default to max amount + uint256 paybackAmount = compoundedBorrowBalance.add(originationFee); + + if (_amount != UINT_MAX_VALUE && _amount < paybackAmount) { + paybackAmount = _amount; + } + + //if the amount is smaller than the origination fee, just transfer the amount to the fee destination address + if (paybackAmount <= originationFee) { + core.decreaseUserOriginationFee(_reserve, _onBehalfOf, paybackAmount); + core.transferToFeeCollectionAddress.value(msg.value)( + _reserve, + _onBehalfOf, + paybackAmount, + IFeeProvider(addressesProvider.getFeeProvider()).getFeesCollectionAddress() + ); //cast the address to payable + return; + } + + uint256 paybackAmountMinusFees = paybackAmount.sub(originationFee); + uint256 actualBalanceDecrease = paybackAmountMinusFees.sub(borrowBalanceIncrease); + + //transfer the fee amount to the fee wallet + core.decreaseUserOriginationFee(_reserve, _onBehalfOf, originationFee); + core.transferToFeeCollectionAddress.value(msg.value)( + _reserve, + _onBehalfOf, + originationFee, + IFeeProvider(addressesProvider.getFeeProvider()).getFeesCollectionAddress() + ); //cast the address to payable + + //update the liquidity and borrow index to comulate the interest until this point + core.updateReserveCumulativeIndexes(_reserve); + core.updateUserLastVariableBorrowCumulativeIndex(_reserve, _onBehalfOf); + + //update the reserve liquidity + core.increaseReserveTotalLiquidity(_reserve, borrowBalanceIncrease); + + //update the user principal borrow balance, adding the cumulated interest and then substracting the payaback amount + core.decreaseUserPrincipalBorrowBalance(_reserve, _onBehalfOf, actualBalanceDecrease); + + //compound the cumulated interest to the borrow balance and then substracting the payback amount + CoreLibrary.InterestRateMode borrowRateMode = core.getUserCurrentBorrowRateMode(_reserve, _onBehalfOf); + + if (borrowRateMode == CoreLibrary.InterestRateMode.FIXED) { + uint256 currentFixedRate = core.getUserCurrentFixedBorrowRate(_reserve, _onBehalfOf); + core.decreaseReserveTotalBorrowsFixedAndUpdateAverageRate(_reserve, actualBalanceDecrease, currentFixedRate); + //if the balance decrease is equal to the previous principal (user is repaying the whole loan) + //and the rate mode is fixed, we reset the interest rate mode of the user + if(actualBalanceDecrease == principalBorrowBalance) { + core.resetUserFixedBorrowRate(_reserve, _onBehalfOf); + } + } else { + core.decreaseReserveTotalBorrowsVariable(_reserve, actualBalanceDecrease); + } + + core.updateReserveInterestRates(_reserve); + + core.setReserveLastUpdate(_reserve); + core.setUserLastUpdate(_reserve, _onBehalfOf); + + core.transferToReserve.value(msg.value)(_reserve, _onBehalfOf, paybackAmountMinusFees); + + //solium-disable-next-line + emit Repay(_reserve, _onBehalfOf, _amount, block.timestamp); + } + + /** + * @notice allows the user to swap the current borrow rate mode, from fixed to variable and viceversa. + */ + + function swapBorrowRateMode(address _reserve) external nonReentrant onlyActiveReserve(_reserve) { + + CoreLibrary.InterestRateMode currentRateMode = core.getUserCurrentBorrowRateMode(_reserve, msg.sender); + (uint256 principalBorrowBalance, + uint256 compoundedBorrowBalance, + uint256 balanceIncrease) = core.getUserBorrowBalances(_reserve, msg.sender); + + require(compoundedBorrowBalance > 0, "User does not have a borrow in progress on this reserve"); + + //compounding reserve indexes + core.updateReserveCumulativeIndexes(_reserve); + core.updateUserLastVariableBorrowCumulativeIndex(_reserve, msg.sender); + + if(currentRateMode == CoreLibrary.InterestRateMode.FIXED){ + + uint256 userFixedRate = core.getUserCurrentFixedBorrowRate(_reserve, msg.sender); + + //switch to variable + core.decreaseReserveTotalBorrowsFixedAndUpdateAverageRate(_reserve, principalBorrowBalance, userFixedRate); //decreasing fixed from old principal balance + core.increaseReserveTotalBorrowsVariable(_reserve, compoundedBorrowBalance); //increase variable borrows + core.resetUserFixedBorrowRate(_reserve, msg.sender); + } + else { + //switch to fixed + + /** + @dev before switching we need to ensure that + 1. fixed borrow rate is enabled on the reserve + 2. user is not trying to abuse the reserve by depositing + more collateral than he is borrowing, artificially lowering + the interest rate, borrowing at variable, and switching to fixed + */ + require( + core.getReserveIsFixedBorrowRateEnabled(_reserve), + "Fixed borrows rate are not enabled on this reserve" + ); + + require( + !core.isUserUseReserveAsCollateralEnabled(_reserve, msg.sender) || + !core.isReserveUsageAsCollateralEnabled(_reserve) || + compoundedBorrowBalance > dataProvider.getUserUnderlyingAssetBalance(_reserve, msg.sender), + "User is trying to borrow an amount that is smaller than what he deposited." + ); + + //all clear - user can switch + uint256 currentFixedRate = core.getReserveCurrentFixedBorrowRate(_reserve); + core.decreaseReserveTotalBorrowsVariable(_reserve, principalBorrowBalance); + core.increaseReserveTotalBorrowsFixedAndUpdateAverageRate(_reserve, compoundedBorrowBalance, currentFixedRate); + core.updateUserFixedBorrowRate(_reserve,msg.sender); + } + + core.increaseReserveTotalLiquidity(_reserve, balanceIncrease); + core.updateReserveInterestRates(_reserve); + + + //compounding cumulated interest + core.increaseUserPrincipalBorrowBalance(_reserve, msg.sender, balanceIncrease); + core.setReserveLastUpdate(_reserve); + core.setUserLastUpdate(_reserve, msg.sender); + + //solium-disable-next-line + emit Swap(_reserve, msg.sender, block.timestamp); + } + + + /** + @notice rebalances the fixed interest rate of a user if current liquidity rate > user fixed rate. + @dev this is regulated by Aave to ensure that the protocol is not abused, and the user is paying a fair + rate. Anyone can call this function though. + */ + + function rebalanceFixedBorrowRate(address _reserve, address _user) external nonReentrant { + + require( + core.getUserCurrentBorrowRateMode(_reserve,_user) == CoreLibrary.InterestRateMode.FIXED, + "The user borrow is variable and cannot be rebalanced" + ); + + (, + uint256 compoundedBalance, + uint256 balanceIncrease) = core.getUserBorrowBalances(_reserve, msg.sender); + + //step 1: user must be borrowing on _reserve at a fixed rate + require( + compoundedBalance > 0, + "User does not have any borrow for this reserve"); + + //step 2: compound the balances, updating indices + core.updateReserveCumulativeIndexes(_reserve); + + uint userCurrentFixedRate = core.getUserCurrentFixedBorrowRate(_reserve,_user); + core.increaseReserveTotalBorrowsFixedAndUpdateAverageRate(_reserve, balanceIncrease, userCurrentFixedRate); + core.increaseUserPrincipalBorrowBalance(_reserve, _user, balanceIncrease); + core.increaseReserveTotalLiquidity(_reserve, balanceIncrease); + core.setReserveLastUpdate(_reserve); + + uint256 liquidityRate = core.getReserveCurrentLiquidityRate(_reserve); + uint256 reserveCurrentFixedRate = core.getReserveCurrentFixedBorrowRate(_reserve); + uint256 rebalanceDownRateThreshold = reserveCurrentFixedRate.rayMul( + WadRayMath + .ray() + .add( + parametersProvider.getRebalanceDownRateDelta() + )); + + //step 3: we have two possible situations to rebalance: + + //1. user fixed borrow rate is below the current liquidity rate. The loan needs to be rebalanced, + //as this situation can be abused (user putting back the borrowed liquidity in the same reserve to earn on it) + //2. user fixed rate is above the market avg borrow rate of a certain delta, and utilization rate is low. + //In this case, the user is paying an interest that is too high, and needs to be rescaled down. + if(userCurrentFixedRate < liquidityRate || + userCurrentFixedRate > rebalanceDownRateThreshold + ) { + //rebalance fixed rate + core.updateUserFixedBorrowRate(_reserve,msg.sender); + core.setUserLastUpdate(_reserve, _user); + return; + } + + revert("Interest rate rebalance conditions where not met"); + } + + /** + * @notice allows user to enable or disable a specific deposit as collateral + */ + + function setUserUseReserveAsCollateral(address _reserve, bool _useAsCollateral) external nonReentrant { + + uint256 underlyingBalance = dataProvider.getUserUnderlyingAssetBalance(_reserve,msg.sender); + + require(underlyingBalance > 0, "User does not have any liquidity deposited"); + + require( + dataProvider.balanceDecreaseAllowed(_reserve, msg.sender, underlyingBalance), + "User deposit is already being used as collateral" + ); + + core.setUserUseReserveAsCollateral(_reserve, msg.sender, _useAsCollateral); + + if(_useAsCollateral){ + emit ReserveUsedAsCollateralEnabled(_reserve, msg.sender); + } + else{ + emit ReserveUsedAsCollateralDisabled(_reserve, msg.sender); + } + } + + /** + * @notice implements loan liquidation + * @dev _receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset. + */ + function liquidationCall(address _collateral, address _reserve, address _user, uint256 _purchaseAmount, bool _receiveAToken) + external + payable + nonReentrant + onlyActiveReserve(_reserve) + { + address liquidationManager = addressesProvider.getLendingPoolLiquidationManager(); + + //solium-disable-next-line + (bool success, bytes memory result) = liquidationManager.delegatecall( + abi.encodeWithSignature("liquidationCall(address,address,address,uint256,bool)", + _collateral, + _reserve, + _user, + _purchaseAmount, + _receiveAToken + )); + require(success, "Liquidation call failed"); + + (uint256 returnCode, string memory returnMessage) = abi.decode(result, (uint256, string)); + + if(returnCode != 0) { //error found + revert(string(abi.encodePacked("Liquidation failed: ", returnMessage))); + } + //solium-disable-next-line + emit LiquidationCall(liquidationManager, _user, _purchaseAmount, _reserve, block.timestamp); + } + + function flashLoan( + address payable _receiver, + address _reserve, + uint _amount) + external + nonReentrant onlyActiveReserve(_reserve) { + + //check that the address is a contract + require(_receiver.isContract(), "The caller of this function must be a contract"); + + //check that the reserve is enabled for borrowing + require(core.isReserveBorrowingEnabled(_reserve),"Reserve is not enabled for borrowing"); + + //check that the reserve has enough available liquidity + uint availableLiquidity = core.getReserveAvailableLiquidity(_reserve); + require(availableLiquidity > _amount, "There is not enough liquidity available to borrow"); + + uint actualBalanceBefore = dataProvider.getCoreActualReserveBalance(_reserve); + + /** + @dev note: this is always true as it's ensured by the protocol, checking for added security + */ + require(availableLiquidity == actualBalanceBefore, "Invalid liquidity available"); + + //calculate amount fee + //TODO refactor this to a global variable + uint amountFee = _amount.div(100); + + require(amountFee > 0, "The amount is too small thus it cannot be borrowed"); + + //get the FlashLoanReceiver instance + IFlashLoanReceiver receiver = IFlashLoanReceiver(_receiver); + + //transfer funds to the receiver + core.transferToUser(_reserve, _receiver, _amount); + + //execute action of the receiver + uint256 returnedAmount = receiver.executeOperation(_reserve, _amount, amountFee); + + //check that the nominal returned amount is greater of equal than borrowed amount plus fees + require(returnedAmount == _amount.add(amountFee), "The nominal returned amount is invalid"); + + //check that the actual balance of the core contract includes the returned amount + uint256 actualBalanceAfter = dataProvider.getCoreActualReserveBalance(_reserve); + + require(actualBalanceAfter == actualBalanceBefore.add(amountFee), "The actual balance of the protocol in inconsistent"); + + //amount returned is correct - compounding the cumulated interest + core.updateReserveCumulativeIndexes(_reserve); + + //compounding the received fee into the reserve + core.cumulateLiquidityToReserveLiquidityIndex(_reserve, amountFee); + + //increase total liquidity by the received fee + core.increaseReserveTotalLiquidity(_reserve,amountFee); + + //recalculate interests + core.updateReserveInterestRates(_reserve); + core.setReserveLastUpdate(_reserve); + + //solium-disable-next-line + emit FlashLoan(_receiver, _reserve, _amount, amountFee, block.timestamp); + + } + + /*************** + @dev accessory methods to fetch data from the core contract + */ + + function getReserveConfigurationData(address _reserve) + external + view + returns ( + uint256 ltv, + uint256 liquidationThreshold, + uint256 liquidationDiscount, + address interestRateStrategyAddress, + bool usageAsCollateralEnabled, + bool borrowingEnabled, + bool fixedBorrowRateEnabled, + bool isActive) + { + return dataProvider.getReserveConfigurationData(_reserve); + } + + + function getReserveData(address _reserve) + external + view + returns ( + uint256 totalLiquidity, + uint256 availableLiquidity, + uint256 totalBorrowsFixed, + uint256 totalBorrowsVariable, + uint256 liquidityRate, + uint256 variableBorrowRate, + uint256 fixedBorrowRate, + uint256 averageFixedBorrowRate, + uint256 utilizationRate, + uint256 liquidityIndex, + uint256 variableBorrowIndex, + address aTokenAddress, + uint40 lastUpdateTimestamp + ) + { + return dataProvider.getReserveData(_reserve); + } + + function getUserAccountData(address _user) + external + view + returns ( + uint256 totalLiquidityETH, + uint256 totalCollateralETH, + uint256 totalBorrowsETH, + uint256 availableBorrowsETH, + uint256 currentLiquidationThreshold, + uint256 ltv, + uint256 healthFactor + ) + { + return dataProvider.getUserAccountData(_user); + } + + function getUserReserveData(address _reserve, address _user) + external + view + returns ( + uint256 currentATokenBalance, + uint256 currentUnderlyingBalance, + uint256 currentBorrowBalance, + uint256 principalBorrowBalance, + uint256 borrowRateMode, + uint256 borrowRate, + uint256 liquidityRate, + uint256 originationFee, + uint256 variableBorrowIndex, + uint256 lastUpdateTimestamp, + bool usageAsCollateralEnabled + ) + { + return dataProvider.getUserReserveData(_reserve, _user); + } + + function getReserves() external view returns(address[] memory){ + return core.getReserves(); + } + + /** + @dev internal function to save on code size for the onlyActiveReserve modifier + */ + function requireReserveActiveInternal(address _reserve) internal view { + require( + core.getReserveIsActive(_reserve), + "Action requires an active reserve" + ); + } +} diff --git a/contracts/lendingpool/LendingPoolConfigurator.sol b/contracts/lendingpool/LendingPoolConfigurator.sol new file mode 100755 index 0000000..9a1e4ab --- /dev/null +++ b/contracts/lendingpool/LendingPoolConfigurator.sol @@ -0,0 +1,238 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/ownership/Ownable.sol"; +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; +import "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol"; +import "../libraries/CoreLibrary.sol"; +import "../configuration/LendingPoolAddressesProvider.sol"; +import "./LendingPoolCore.sol"; +import "../interfaces/IFeeProvider.sol"; +import "../tokenization/AToken.sol"; + + + +/************************************************************************************* +@title LendingPoolConfigurator contract +@author Aave +@notice Executes configuration methods on the LendingPoolCore contract. Allows to enable/disable reserves, +and set different protocol parameters. + *************************************************************************************/ + +contract LendingPoolConfigurator is Ownable { + + using SafeMath for uint256; + + event ReserveInitialized( + address indexed _reserve, + address indexed _aToken, + uint256 _initialExchangeRate, + address _interestRateStrategyAddress); + + event BorrowingEnabledOnReserve( + address _reserve, + bool _fixedRateEnabled + ); + + /** + @dev events + */ + event BorrowingDisabledOnReserve(address indexed _reserve); + event ReserveEnabledAsCollateral(address indexed _reserve, uint256 _ltv, uint256 _liquidationThreshold); + event ReserveDisabledAsCollateral(address indexed _reserve); + event FixedRateEnabledOnReserve(address indexed _reserve); + event FixedRateDisabledOnReserve(address indexed _reserve); + event ReserveActivated(address indexed _reserve); + event ReserveDeactivated(address indexed _reserve); + + LendingPoolAddressesProvider public poolAddressesProvider; + /** + @dev only lending pools can use functions affected by this modifier + */ + modifier onlyLendingPoolManager { + require( + poolAddressesProvider.getLendingPoolManager() == msg.sender, + "The caller must be a lending pool manager" + ); + _; + } + + constructor(LendingPoolAddressesProvider _poolAddressesProvider) + public + { + poolAddressesProvider = _poolAddressesProvider; + } + + /****************************************** + @dev pool core managment functions + ******************************************/ + + function initReserve( + address _reserve, + uint256 _aTokenInitialExchangeRate, + uint256 _underlyingAssetDecimals, + address _interestRateStrategyAddress) + external + onlyLendingPoolManager + { + ERC20Detailed asset = ERC20Detailed(_reserve); + + string memory aTokenName = string(abi.encodePacked("Aave Interest bearing ", asset.name())); + string memory aTokenSymbol = string(abi.encodePacked("a", asset.symbol())); + + initReserveWithData( + _reserve, + aTokenName, + aTokenSymbol, + _aTokenInitialExchangeRate, + _underlyingAssetDecimals, + _interestRateStrategyAddress); + + } + + + /** + @notice initialises the reserve and instantiates the specific aToken with the specified initial exchange rate. + */ + function initReserveWithData( + address _reserve, + string memory aTokenName, + string memory aTokenSymbol, + uint256 _aTokenInitialExchangeRate, + uint256 _underlyingAssetDecimals, + address _interestRateStrategyAddress) + public + onlyLendingPoolManager + { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + + AToken aTokenInstance = new AToken( + poolAddressesProvider, + _reserve, + _underlyingAssetDecimals, + aTokenName, + aTokenSymbol, + 18, + _aTokenInitialExchangeRate + ); + core.initReserve(_reserve, address(aTokenInstance), _underlyingAssetDecimals, _interestRateStrategyAddress); + + emit ReserveInitialized(_reserve, address(aTokenInstance), _aTokenInitialExchangeRate, _interestRateStrategyAddress); + } + + + /** + @notice functions to enable/disable borrowing on reserve. + */ + function enableBorrowingOnReserve( + address _reserve, + bool _fixedBorrowRateEnabled + ) external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.enableBorrowingOnReserve(_reserve, _fixedBorrowRateEnabled); + emit BorrowingEnabledOnReserve(_reserve, _fixedBorrowRateEnabled); + } + + function disableBorrowingOnReserve(address _reserve) external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.disableBorrowingOnReserve(_reserve); + + emit BorrowingDisabledOnReserve(_reserve); + } + + /** + @notice functions to enable/disable usage of the reserve as collateral. + */ + + + function enableReserveAsCollateral(address _reserve, uint256 _baseLTVasCollateral, uint256 _liquidationThreshold) + external + onlyLendingPoolManager + { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.enableReserveAsCollateral(_reserve, _baseLTVasCollateral, _liquidationThreshold); + emit ReserveEnabledAsCollateral(_reserve, _baseLTVasCollateral, _liquidationThreshold); + } + + function disableReserveAsCollateral(address _reserve) external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.disableReserveAsCollateral(_reserve); + + emit ReserveDisabledAsCollateral(_reserve); + } + + /** + @notice functions to enable/disable fixed borrow rate mode on a reserve. + */ + + + function enableReserveFixedBorrowRate(address _reserve) external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.enableReserveFixedBorrowRate(_reserve); + + emit FixedRateEnabledOnReserve(_reserve); + } + + function disableReserveFixedBorrowRate(address _reserve) external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.disableReserveFixedBorrowRate(_reserve); + + emit FixedRateDisabledOnReserve(_reserve); + } + + function activateReserve(address _reserve) external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.activateReserve(_reserve); + + emit ReserveActivated(_reserve); + } + + function deactivateReserve(address _reserve) external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.deactivateReserve(_reserve); + + emit ReserveDeactivated(_reserve); + } + + + /*************** + @dev functions to update available collaterals + @dev the interest rate and the ltv are expressed in percentage + ***************/ + + function setReserveBaseLTVasCollateral(address _reserve, uint256 _ltv) external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.setReserveBaseLTVasCollateral(_reserve, _ltv); + } + + function setReserveLiquidationThreshold(address _reserve, uint256 _threshold) + external + onlyLendingPoolManager + { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.setReserveLiquidationThreshold(_reserve, _threshold); + } + + function setReserveLiquidationDiscount(address _reserve, uint256 _threshold) + external + onlyLendingPoolManager + { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.setReserveLiquidationDiscount(_reserve, _threshold); + } + + + function setReserveInterestRateStrategyAddress( address _reserve, address _rateStrategyAddress) external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.setReserveInterestRateStrategyAddress(_reserve, _rateStrategyAddress); + } + + function setLendingPoolCoreAddressesProvider(address _provider) external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.setAddressesProvider(_provider); + } + + function refreshLendingPoolCoreConfiguration() external onlyLendingPoolManager { + LendingPoolCore core = LendingPoolCore(poolAddressesProvider.getLendingPoolCore()); + core.refreshConfiguration(); + } +} diff --git a/contracts/lendingpool/LendingPoolCore.sol b/contracts/lendingpool/LendingPoolCore.sol new file mode 100755 index 0000000..74a71b0 --- /dev/null +++ b/contracts/lendingpool/LendingPoolCore.sol @@ -0,0 +1,712 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/ownership/Ownable.sol"; +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; +import "openzeppelin-solidity/contracts/token/ERC20/SafeERC20.sol"; +import "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol"; +import "openzeppelin-solidity/contracts/utils/Address.sol"; +import "../libraries/CoreLibrary.sol"; +import "../configuration/LendingPoolAddressesProvider.sol"; +import "../interfaces/IPriceOracle.sol"; +import "../interfaces/ILendingRateOracle.sol"; +import "../interfaces/IReserveInterestRateStrategy.sol"; +import "../interfaces/INetworkMetadataProvider.sol"; +import "../libraries/WadRayMath.sol"; + + +/************************************************************************************* +@title LendingPoolCore contract +@author Aave +@notice Contains all the data and the funds deposited into a lending pool + *************************************************************************************/ + +contract LendingPoolCore is Ownable { + + using SafeMath for uint256; + using WadRayMath for uint256; + using CoreLibrary for CoreLibrary.ReserveData; + using SafeERC20 for ERC20; + using Address for address payable; + + /** + @dev ethereumAddress represents a ERC20 contract address with which the pool identifies ETH + */ + address ethereumAddress; + + address lendingPoolAddress; + + + LendingPoolAddressesProvider public addressesProvider; + + /** + @dev only lending pools can use functions affected by this modifier + */ + modifier onlyLendingPool { + require(lendingPoolAddress == msg.sender, "The caller must be a lending pool contract"); + _; + } + + /** + @dev only lending pools configurator can use functions affected by this modifier + */ + modifier onlyLendingPoolConfigurator { + require( + addressesProvider.getLendingPoolConfigurator() == msg.sender, + "The caller must be a lending pool configurator contract" + ); + _; + } + + + /** + @dev functions affected by this modifier can only be invoked if a reserve is enabled for borrowing and/or collateral + */ + modifier onlyReserveWithEnabledBorrowingOrCollateral(address _reserve) { + require( + reserves[_reserve].borrowingEnabled || reserves[_reserve].usageAsCollateralEnabled, + "Reserve is not enabled for borrowing or for being used as collateral" + ); + _; + } + + /** + @dev functions affected by this modifier can only be invoked if a reserve is enabled for borrowing + */ + modifier onlyReserveWithEnabledBorrowing(address _reserve) { + require(reserves[_reserve].borrowingEnabled, "Reserve is not enabled for borrowing"); + _; + } + + mapping(address => CoreLibrary.ReserveData) reserves; + mapping(address => mapping(address => CoreLibrary.UserReserveData)) usersReserveData; + + address[] public reservesList; + + constructor(LendingPoolAddressesProvider _addressesProvider) public { + addressesProvider = _addressesProvider; + refreshConfigInternal(); + } + + /** + @dev functions to update reserves data + */ + + /** + @notice Updates the reserve Liquidity cumulative interest Ci and the Variable borrows cumulative index Bvc. Please refer to the + whitepaper for further information. + */ + function updateReserveCumulativeIndexes(address _reserve) external onlyLendingPool { + reserves[_reserve].updateCumulativeIndexes(); + } + + /** + @notice cumulates a fixed amount of liquidity to the reserve, considered as a specific interest accrued in one block. Please refer + to the whitepaper for further information. + */ + + function cumulateLiquidityToReserveLiquidityIndex(address _reserve, uint256 _amount) external onlyLendingPool { + reserves[_reserve].cumulateToLiquidityIndex(_amount); + } + + /** + @notice Updates the reserve current fixed borrow rate Rf, the current variable borrow rate Rv and the current liquidity rate Rl. + Please refer to the whitepaper for further information. + */ + + function updateReserveInterestRates(address _reserve) external onlyLendingPool { + + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + (reserve.currentLiquidityRate, + reserve.currentFixedBorrowRate, + reserve.currentVariableBorrowRate) = IReserveInterestRateStrategy(reserve.interestRateStrategyAddress). + calculateInterestRates( + _reserve, + reserve.getReserveUtilizationRate(), + reserve.totalBorrowsFixed, + reserve.totalBorrowsVariable, + reserve.currentAverageFixedBorrowRate + ); + } + + /** + @notice increases the total liquidity Lt of a reserve + */ + + function increaseReserveTotalLiquidity(address _reserve, uint256 _amount) + external + onlyLendingPool + onlyReserveWithEnabledBorrowingOrCollateral(_reserve) + { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + reserve.totalLiquidity = reserve.totalLiquidity.add(_amount); + + } + + /** + @notice decreases the total liquidity Lt of a reserve + */ + + function decreaseReserveTotalLiquidity(address _reserve, uint256 _amount) external onlyLendingPool { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + reserve.totalLiquidity = reserve.totalLiquidity.sub(_amount); + } + + /** + @notice increases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper + for further information. + */ + + function increaseReserveTotalBorrowsFixedAndUpdateAverageRate(address _reserve, uint256 _amount, uint256 _rate) + external + onlyLendingPool + onlyReserveWithEnabledBorrowingOrCollateral(_reserve) + { + reserves[_reserve].increaseTotalBorrowsFixedAndUpdateAverageRate(_amount, _rate); + } + + + /** + @notice decreases the total borrow fixed of a reserve Bf and updates the average fixed borrow rate Raf. Please refer to the whitepaper + for further information. + */ + + + function decreaseReserveTotalBorrowsFixedAndUpdateAverageRate(address _reserve, uint256 _amount, uint256 _rate) + external + onlyLendingPool + { + reserves[_reserve].decreaseTotalBorrowsFixedAndUpdateAverageRate(_amount, _rate); + + } + /** + @notice increases the the total borrow variable of a reserve Bv. + */ + + function increaseReserveTotalBorrowsVariable(address _reserve, uint256 _amount) + external + onlyLendingPool + onlyReserveWithEnabledBorrowingOrCollateral(_reserve) + { + reserves[_reserve].increaseTotalBorrowsVariable(_amount); + } + + /** + @notice decreases the the total borrow variable of a reserve Bv. + */ + + + function decreaseReserveTotalBorrowsVariable(address _reserve, uint256 _amount) external onlyLendingPool { + reserves[_reserve].decreaseTotalBorrowsVariable(_amount); + } + + /*************** + @dev increases the proper total borrows on a reserve depending on the type of interest rate chosen by the user + ***************/ + + function updateReserveTotalBorrowsByRateMode( + address _reserve, + address _user, + uint256 _principalBalance, + uint256 _balanceIncrease, + CoreLibrary.InterestRateMode _newBorrowRateMode, + uint256 _fixedRate + ) external onlyLendingPool { + CoreLibrary.InterestRateMode currentRateMode = getUserCurrentBorrowRateMode(_reserve, _user); + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + + + if (currentRateMode == CoreLibrary.InterestRateMode.FIXED) { + // there was no previous borrow or previous borrow was fixed + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + reserve.decreaseTotalBorrowsFixedAndUpdateAverageRate(_principalBalance, user.fixedBorrowRate); + + if (_newBorrowRateMode == CoreLibrary.InterestRateMode.FIXED) { + reserve.increaseTotalBorrowsFixedAndUpdateAverageRate(_principalBalance.add(_balanceIncrease), _fixedRate); + } else if (_newBorrowRateMode == CoreLibrary.InterestRateMode.VARIABLE) { + //switching the whole amount borrowed to variable + reserve.increaseTotalBorrowsVariable(_principalBalance.add(_balanceIncrease)); + } + } else { + // previous borrow was variable + if (_newBorrowRateMode == CoreLibrary.InterestRateMode.FIXED) { + reserve.decreaseTotalBorrowsVariable(_principalBalance); + reserve.increaseTotalBorrowsFixedAndUpdateAverageRate(_principalBalance.add(_balanceIncrease), _fixedRate); + } else if (_newBorrowRateMode == CoreLibrary.InterestRateMode.VARIABLE) { + //switching the whole amount borrowed to variable + reserve.increaseTotalBorrowsVariable(_balanceIncrease); + } + } + } + + /** + @notice refreshes reserve last updated block number Bl + */ + function setReserveLastUpdate(address _reserve) external onlyLendingPool { + reserves[_reserve].setLastUpdate(); + } + + + /*************** + @dev functions to update users reserve data + */ + + function updateUserLastVariableBorrowCumulativeIndex(address _reserve, address _user) external onlyLendingPool { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + + user.lastVariableBorrowCumulativeIndex = reserve.lastVariableBorrowCumulativeIndex; + } + + function increaseUserOriginationFee(address _reserve, address _user, uint256 _amount) external onlyLendingPool { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + user.originationFee = user.originationFee.add(_amount); + } + + function decreaseUserOriginationFee(address _reserve, address _user, uint256 _amount) external onlyLendingPool { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + user.originationFee = user.originationFee.sub(_amount); + } + + function increaseUserPrincipalBorrowBalance(address _reserve, address _user, uint256 _amount) + external + onlyLendingPool + onlyReserveWithEnabledBorrowing(_reserve) + { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + user.principalBorrowBalance = user.principalBorrowBalance.add(_amount); + } + + function decreaseUserPrincipalBorrowBalance(address _reserve, address _user, uint256 _amount) + external + onlyLendingPool + { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + require(user.principalBorrowBalance >= _amount, "The borrow balance is too low"); + user.principalBorrowBalance = user.principalBorrowBalance.sub(_amount); + } + + function setUserUseReserveAsCollateral(address _reserve, address _user, bool _useAsCollateral) external onlyLendingPool { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + user.useAsCollateral = _useAsCollateral; + } + + function setUserLastUpdate(address _reserve, address _user) external onlyLendingPool { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + + //solium-disable-next-line + user.lastUpdateTimestamp = uint40(block.timestamp); + } + + /****************** + @dev updates the fixed borrow rate for the user + *******************/ + function updateUserFixedBorrowRate(address _reserve, address _user) external onlyLendingPool { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + + user.fixedBorrowRate = getReserveCurrentFixedBorrowRate(_reserve); + } + + function resetUserFixedBorrowRate(address _reserve, address _user) external onlyLendingPool { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + user.fixedBorrowRate = 0; + } + + /********************* + @dev reserve accessors + *********************/ + + function getReserveInterestRateStrategyAddress(address _reserve) public view returns (address) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.interestRateStrategyAddress; + } + + function getReserveATokenAddress(address _reserve) public view returns (address) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.aTokenAddress; + } + + function getReserveAvailableLiquidity(address _reserve) public view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.totalLiquidity.sub(getReserveTotalBorrows(_reserve)); + } + + function getReserveTotalLiquidity(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.totalLiquidity; + } + + function getReserveNormalizedIncome(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.getNormalizedIncome(); + } + + function getReserveTotalBorrows(address _reserve) public view returns (uint256) { + return reserves[_reserve].getTotalBorrows(); + } + + function getReserveTotalBorrowsFixed(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.totalBorrowsFixed; + } + + function getReserveTotalBorrowsVariable(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.totalBorrowsVariable; + } + + function getReserveLiquidationThreshold(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.liquidationThreshold; + } + + function getReserveLiquidationDiscount(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.liquidationDiscount; + } + + function getReserveCurrentVariableBorrowRate(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + + if(reserve.currentVariableBorrowRate == 0) { + return IReserveInterestRateStrategy(reserve.interestRateStrategyAddress) + .getBaseVariableBorrowRate(); + } + return reserve.currentVariableBorrowRate; + } + + function getReserveCurrentFixedBorrowRate(address _reserve) public view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + ILendingRateOracle oracle = ILendingRateOracle(addressesProvider.getLendingRateOracle()); + + if (reserve.currentFixedBorrowRate == 0) { + //no fixed rate borrows yet + return oracle.getMarketBorrowRate(_reserve); + } + + return reserve.currentFixedBorrowRate; + } + + function getReserveCurrentAverageFixedBorrowRate(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.currentAverageFixedBorrowRate; + } + + function getReserveCurrentLiquidityRate(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.currentLiquidityRate; + } + + function getReserveLiquidityCumulativeIndex(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.lastLiquidityCumulativeIndex; + } + + function getReserveVariableBorrowsCumulativeIndex(address _reserve) external view returns (uint256) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.lastVariableBorrowCumulativeIndex; + } + + /** + * @dev this function aggregates the configuration parameters of the reserve. + * It's used in the LendingPoolDataProvider specifically to save gas, and avoid + * multiple external contract calls to fetch the same data. + */ + + function getReserveConfiguration(address _reserve) + external + view + returns (uint256 decimals, + uint256 baseLTVasCollateral, + uint256 liquidationThreshold, + bool usageAsCollateralEnabled, + bool fixedBorrowRateEnabled, + bool borrowingEnabled) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + decimals = reserve.decimals; + baseLTVasCollateral = reserve.baseLTVasCollateral; + liquidationThreshold = reserve.liquidationThreshold; + usageAsCollateralEnabled = reserve.usageAsCollateralEnabled; + fixedBorrowRateEnabled = reserve.isFixedBorrowRateEnabled; + borrowingEnabled = reserve.borrowingEnabled; + } + + function isReserveBorrowingEnabled(address _reserve) external view returns (bool) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.borrowingEnabled; + } + + function isReserveUsageAsCollateralEnabled(address _reserve) external view returns (bool) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.usageAsCollateralEnabled; + } + + function getReserveIsFixedBorrowRateEnabled(address _reserve) external view returns (bool) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.isFixedBorrowRateEnabled; + } + + function getReserveIsActive(address _reserve) external view returns(bool) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + return reserve.isActive; + } + + + function getReserveLastUpdate(address _reserve) external view returns (uint40 timestamp) { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + timestamp = reserve.lastUpdateTimestamp; + } + + /****************** + @dev user accessors + ******************/ + + function isUserUseReserveAsCollateralEnabled(address _reserve, address _user) external view returns (bool) { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + return user.useAsCollateral; + } + function getUserOriginationFee(address _reserve, address _user) external view returns (uint256) { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + return user.originationFee; + } + + function getUserCurrentBorrowRateMode(address _reserve, address _user) + public + view + returns (CoreLibrary.InterestRateMode) + { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + return user.fixedBorrowRate > 0 ? CoreLibrary.InterestRateMode.FIXED : CoreLibrary.InterestRateMode.VARIABLE; + } + + function getUserCurrentFixedBorrowRate(address _reserve, address _user) external view returns (uint256) { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + return user.fixedBorrowRate; + } + + function getUserBorrowBalances( + address _reserve, + address _user) + external view returns ( + uint256 principalBorrowBalance, + uint256 compoundedBorrowBalance, + uint256 compoundedAmount) { + + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + + principalBorrowBalance = user.principalBorrowBalance; + compoundedBorrowBalance = CoreLibrary.getCompoundedBorrowBalance( + user, + reserve + ); + + compoundedAmount = compoundedBorrowBalance.sub(principalBorrowBalance); + } + + function getUserVariableBorrowCumulativeIndex(address _reserve, address _user) external view returns (uint256) { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + return user.lastVariableBorrowCumulativeIndex; + } + + function getUserLastUpdate(address _reserve, address _user) + external + view + returns (uint256 timestamp) + { + CoreLibrary.UserReserveData storage user = usersReserveData[_user][_reserve]; + timestamp = user.lastUpdateTimestamp; + } + + /** + @dev utility functions + */ + + function getReserveUtilizationRate(address _reserve) external view returns (uint256) { + return reserves[_reserve].getReserveUtilizationRate(); + } + + function getReserves() external view returns (address[] memory) { + return reservesList; + } + + /** + @dev Core configuration functions + */ + + function setAddressesProvider(address _addressesProvider ) external onlyLendingPoolConfigurator { + + addressesProvider = LendingPoolAddressesProvider(_addressesProvider); + refreshConfigInternal(); + } + + function refreshConfiguration() external onlyLendingPoolConfigurator { + refreshConfigInternal(); + } + + function initReserve(address _reserve, address _aTokenAddress, uint256 _decimals, address _interestRateStrategyAddress) + external + onlyLendingPoolConfigurator + { + reserves[_reserve].init(_aTokenAddress, _decimals, _interestRateStrategyAddress); + addReserveToListInternal(_reserve); + + } + + function setReserveInterestRateStrategyAddress(address _reserve, address _rateStrategyAddress) external onlyLendingPoolConfigurator { + reserves[_reserve].interestRateStrategyAddress = _rateStrategyAddress; + } + + function enableBorrowingOnReserve( + address _reserve, + bool _fixedBorrowRateEnabled + ) external onlyLendingPoolConfigurator { + reserves[_reserve].enableBorrowing(_fixedBorrowRateEnabled); + } + + function disableBorrowingOnReserve(address _reserve) external onlyLendingPoolConfigurator { + reserves[_reserve].disableBorrowing(); + } + + function enableReserveAsCollateral(address _reserve, uint256 _baseLTVasCollateral, uint256 _liquidationThreshold) + external + onlyLendingPoolConfigurator + { + reserves[_reserve].enableAsCollateral(_baseLTVasCollateral, _liquidationThreshold); + } + + function disableReserveAsCollateral(address _reserve) external onlyLendingPoolConfigurator { + reserves[_reserve].disableAsCollateral(); + } + + function enableReserveFixedBorrowRate(address _reserve) external onlyLendingPoolConfigurator { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + reserve.isFixedBorrowRateEnabled = true; + } + + function disableReserveFixedBorrowRate(address _reserve) external onlyLendingPoolConfigurator { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + reserve.isFixedBorrowRateEnabled = false; + } + + function activateReserve(address _reserve) external onlyLendingPoolConfigurator { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + + require( + reserve.lastLiquidityCumulativeIndex > 0 && + reserve.lastVariableBorrowCumulativeIndex > 0, + "Reserve has not been initialized yet" + ); + reserve.isActive = true; + } + + function deactivateReserve(address _reserve) external onlyLendingPoolConfigurator { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + reserve.isActive = false; + } + + + /*************** + @dev functions to update available collaterals + @dev the interest rate and the ltv are expressed in percentage + */ + + function setReserveBaseLTVasCollateral(address _reserve, uint256 _ltv) + external + onlyLendingPoolConfigurator { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + reserve.baseLTVasCollateral = _ltv; + } + + function setReserveLiquidationThreshold(address _reserve, uint256 _threshold) + external + onlyLendingPoolConfigurator + { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + reserve.liquidationThreshold = _threshold; + } + + function setReserveLiquidationDiscount(address _reserve, uint256 _discount) + external + onlyLendingPoolConfigurator + { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + reserve.liquidationDiscount = _discount; + } + + /** + @notice ETH/token transfer functions + */ + function() external payable { + //only contracts can send ETH to the core + require(msg.sender.isContract(), "Only contracts can send ether to the Lending pool core"); + + } + + function transferToUser(address _reserve, address payable _user, uint256 _amount) external onlyLendingPool { + if (_reserve != ethereumAddress){ + ERC20(_reserve).safeTransfer(_user, _amount); + } + else { + _user.transfer(_amount); + } + } + + function transferToFeeCollectionAddress(address _token, address _user, uint256 _amount, address destination) + external + payable + onlyLendingPool + { + address payable feeAddress = address(uint160(destination)); //cast the address to payable + + if (_token != ethereumAddress) { + ERC20(_token).safeTransferFrom(_user, feeAddress, _amount); + } else { + require(msg.value >= _amount, "The amount and the value sent to deposit do not match"); + feeAddress.transfer(_amount); + } + } + + function transferToReserve(address _reserve, address payable _user, uint256 _amount) external payable onlyLendingPool { + CoreLibrary.ReserveData storage reserve = reserves[_reserve]; + + require( + reserve.usageAsCollateralEnabled || reserve.borrowingEnabled, + "The reserve isn't enabled for borrowing or as collateral" + ); + + if (_reserve != ethereumAddress){ + require(msg.value == 0, "User is sending ETH along with the ERC20 transfer. Check the value attribute of the transaction"); + ERC20(_reserve).safeTransferFrom(_user, address(this), _amount); + + } + else { + require(msg.value >= _amount, "The amount and the value sent to deposit do not match"); + + if(msg.value > _amount) { //send back excess ETH + uint256 excessAmount = msg.value.sub(_amount); + _user.transfer(excessAmount); + } + } + } + + /** + @notice internal functions + */ + + + function refreshConfigInternal() internal { + + ethereumAddress = INetworkMetadataProvider(addressesProvider.getNetworkMetadataProvider()).getEthereumAddress(); + lendingPoolAddress = addressesProvider.getLendingPool(); + } + + function addReserveToListInternal(address _reserve) internal { + bool reserveAlreadyAdded = false; + for (uint256 i = 0; i < reservesList.length; i++) + if (reservesList[i] == _reserve) { + reserveAlreadyAdded = true; + } + if (!reserveAlreadyAdded) reservesList.push(_reserve); + } + +} diff --git a/contracts/lendingpool/LendingPoolDataProvider.sol b/contracts/lendingpool/LendingPoolDataProvider.sol new file mode 100755 index 0000000..5dbbc96 --- /dev/null +++ b/contracts/lendingpool/LendingPoolDataProvider.sol @@ -0,0 +1,385 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/ownership/Ownable.sol"; +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; + +import "../libraries/CoreLibrary.sol"; +import "../configuration/LendingPoolAddressesProvider.sol"; +import "../configuration/NetworkMetadataProvider.sol"; +import "../libraries/WadRayMath.sol"; +import "../interfaces/IFeeProvider.sol"; +import "../tokenization/AToken.sol"; + +import "./LendingPoolCore.sol"; + + + +/************************************************************************************* +@title LendingPoolDataProvider contract +@author Aave +@notice Implements functions to fetch data from the core, and aggregate them in order to allow computation +on the compounded balances and the account balances in ETH + *************************************************************************************/ + +contract LendingPoolDataProvider is Ownable { + using SafeMath for uint256; + using WadRayMath for uint256; + + LendingPoolCore core; + LendingPoolAddressesProvider public addressesProvider; + + /** + @dev specifies the health factor threshold at which the user position is liquidated. + 1 by default, if the health factor drops below 1, the loan gets liquidated. + */ + uint256 constant HEALTH_FACTOR_LIQUIDATION_THRESHOLD = 1e18; + + + constructor(LendingPoolAddressesProvider _addressesProvider) public { + addressesProvider = _addressesProvider; + core = LendingPoolCore(_addressesProvider.getLendingPoolCore()); + } + + /** + @dev struct to hold calculateUserGlobalData() local computations + */ + struct UserGlobalDataLocalVars { + uint256 reserveUnitPrice; + uint256 tokenUnit; + uint256 compoundedLiquidityBalance; + uint256 compoundedBorrowBalance; + uint256 reserveDecimals; + uint256 baseLtv; + uint256 liquidationThreshold; + bool usageAsCollateralEnabled; + } + + /** + @notice calculates the user data across the reserves. + this includes the total liquidity/collateral/borrow balances in ETH, + the average Loan To Value, the average Liquidation Ratio, and the Health factor. + */ + function calculateUserGlobalData(address _user) + public + view + returns ( + uint256 totalLiquidityBalanceETH, + uint256 totalCollateralBalanceETH, + uint256 totalBorrowBalanceETH, + uint256 currentLtv, + uint256 currentLiquidationThreshold, + uint256 healthFactor + ) + { + IPriceOracle oracle = IPriceOracle(addressesProvider.getPriceOracle()); + UserGlobalDataLocalVars memory vars; + + address[] memory reserves = core.getReserves(); + + for (uint256 i = 0; i < reserves.length; i++) { + + (,vars.compoundedBorrowBalance,) = core.getUserBorrowBalances(reserves[i], _user); + vars.compoundedLiquidityBalance = getUserUnderlyingAssetBalance(reserves[i], _user); + + if(vars.compoundedLiquidityBalance == 0 && vars.compoundedBorrowBalance == 0){ + continue; + } + + //fetch reserve data + (vars.reserveDecimals, + vars.baseLtv, + vars.liquidationThreshold, + vars.usageAsCollateralEnabled, + ,) = core.getReserveConfiguration(reserves[i]); + vars.tokenUnit = 10 ** vars.reserveDecimals; + vars.reserveUnitPrice = oracle.getAssetPrice(reserves[i]); + + //liquidity and collateral balance + if (vars.compoundedLiquidityBalance > 0) { + + + uint256 liquidityBalanceETH = vars.reserveUnitPrice.mul(vars.compoundedLiquidityBalance).div( + vars.tokenUnit + ); + totalLiquidityBalanceETH = totalLiquidityBalanceETH.add(liquidityBalanceETH); + + if (vars.usageAsCollateralEnabled && core.isUserUseReserveAsCollateralEnabled(reserves[i], _user)) { + totalCollateralBalanceETH = totalCollateralBalanceETH.add(liquidityBalanceETH); + currentLtv = currentLtv.add(liquidityBalanceETH.mul(vars.baseLtv)); + currentLiquidationThreshold = currentLiquidationThreshold + .add(liquidityBalanceETH.mul(vars.liquidationThreshold)); + } + } + + if (vars.compoundedBorrowBalance > 0) { + totalBorrowBalanceETH = totalBorrowBalanceETH.add(vars.reserveUnitPrice.wadMul(vars.compoundedBorrowBalance)); + } + } + + currentLtv = totalCollateralBalanceETH > 0 ? currentLtv.div(totalCollateralBalanceETH) : 0; + currentLiquidationThreshold = totalCollateralBalanceETH > 0 ? currentLiquidationThreshold.div(totalCollateralBalanceETH) : 0; + + healthFactor = calculateHealthFactorFromBalancesInternal( + totalCollateralBalanceETH, + totalBorrowBalanceETH, + currentLiquidationThreshold + ); + + } + + + /** + @notice gets the underlying asset balance of a user based on the corresponding aToken balance. + */ + + function getUserUnderlyingAssetBalance(address _reserve, address _user) public view returns (uint256) { + + AToken aToken = AToken(core.getReserveATokenAddress(_reserve)); + + return aToken.balanceOfUnderlying(_user); + + } + /** + @notice check if a specific balance decrease is allowed (i.e. doesn't bring the user borrow position health factor under 1) + Used by the transferInternal() method of the aToken contract to check if a transfer of tokens is allowed. + */ + + struct balanceDecreaseAllowedLocalVars { + uint256 decimals; + uint256 collateralBalanceETH; + uint256 borrowBalanceETH; + uint256 currentLiquidationThreshold; + uint256 reserveLiquidationThreshold; + uint256 amountToDecreaseETH; + uint256 collateralBalancefterDecrease; + uint256 liquidationThresholdAfterDecrease; + uint256 healthFactorAfterDecrease; + bool reserveUsageAsCollateralEnabled; + } + + function balanceDecreaseAllowed(address _reserve, address _user, uint _amount) external view returns (bool) { + + balanceDecreaseAllowedLocalVars memory vars; + + (vars.decimals, + , + vars.reserveLiquidationThreshold, + vars.reserveUsageAsCollateralEnabled, + ,) = core.getReserveConfiguration(_reserve); + + if(!vars.reserveUsageAsCollateralEnabled || !core.isUserUseReserveAsCollateralEnabled(_reserve, _user)){ + return true; //if reserve is not used as collateral, no reasons to block the transfer + } + + (, + vars.collateralBalanceETH, + vars.borrowBalanceETH, + , + vars.currentLiquidationThreshold, + ) = calculateUserGlobalData(_user); + + if(vars.borrowBalanceETH == 0){ + return true; //no borrows - no reasons to block the transfer + } + + IPriceOracle oracle = IPriceOracle(addressesProvider.getPriceOracle()); + + vars.amountToDecreaseETH = oracle + .getAssetPrice(_reserve) + .mul(_amount) + .div(10 ** vars.decimals); + + vars.collateralBalancefterDecrease = vars.collateralBalanceETH.sub(vars.amountToDecreaseETH); + + vars.liquidationThresholdAfterDecrease = vars.collateralBalanceETH + .mul(vars.currentLiquidationThreshold) + .sub(vars.amountToDecreaseETH.mul(vars.reserveLiquidationThreshold)) + .div(vars.collateralBalancefterDecrease); + + + uint256 healthFactorAfterDecrease = calculateHealthFactorFromBalancesInternal( + vars.collateralBalancefterDecrease, + vars.borrowBalanceETH, + vars.liquidationThresholdAfterDecrease); + + return healthFactorAfterDecrease > HEALTH_FACTOR_LIQUIDATION_THRESHOLD; + + } + + /** + @notice calculates the equivalent amount in ETH that an user can borrow, depeding on the available collateral and the + average Loan To Value. + */ + + function calculateAvailableBorrowsETHInternal(uint256 collateralBalanceETH, uint256 borrowBalanceETH, uint256 ltv) + internal + view + returns (uint256) { + + uint availableBorrowsETH = collateralBalanceETH.mul(ltv).div(100); //ltv is in percentage + + if(availableBorrowsETH < borrowBalanceETH){ + return 0; + } + + availableBorrowsETH = availableBorrowsETH.sub(borrowBalanceETH); + //calculate fee + uint256 borrowFee = IFeeProvider(addressesProvider.getFeeProvider()).calculateLoanOriginationFee( + msg.sender, + availableBorrowsETH + ); + return availableBorrowsETH.sub(borrowFee); + } + + /** + @notice calculates the health factor from the corresponding balances + */ + function calculateHealthFactorFromBalancesInternal( + uint256 collateralBalanceETH, + uint256 borrowBalanceETH, + uint256 liquidationThreshold + ) + internal + pure + returns (uint256) + { + if (borrowBalanceETH == 0) return uint256(-1); + + return (collateralBalanceETH.mul(liquidationThreshold).div(100)).wadDiv(borrowBalanceETH); + } + + + function getHealthFactorLiquidationThreshold() public pure returns(uint) { + return HEALTH_FACTOR_LIQUIDATION_THRESHOLD; + } + + + function getReserveConfigurationData(address _reserve) + external + view + returns ( + uint256 ltv, + uint256 liquidationThreshold, + uint256 liquidationDiscount, + address rateStrategyAddress, + bool usageAsCollateralEnabled, + bool borrowingEnabled, + bool fixedBorrowRateEnabled, + bool isActive) + { + (, + ltv, + liquidationThreshold, + usageAsCollateralEnabled, + fixedBorrowRateEnabled, + borrowingEnabled) = core.getReserveConfiguration(_reserve); + isActive = core.getReserveIsActive(_reserve); + liquidationDiscount = core.getReserveLiquidationDiscount(_reserve); + + rateStrategyAddress = core.getReserveInterestRateStrategyAddress(_reserve); + } + + function getReserveData(address _reserve) + external + view + returns ( + uint256 totalLiquidity, + uint256 availableLiquidity, + uint256 totalBorrowsFixed, + uint256 totalBorrowsVariable, + uint256 liquidityRate, + uint256 variableBorrowRate, + uint256 fixedBorrowRate, + uint256 averageFixedBorrowRate, + uint256 utilizationRate, + uint256 liquidityIndex, + uint256 variableBorrowIndex, + address aTokenAddress, + uint40 lastUpdateTimestamp + ) + { + totalLiquidity = core.getReserveTotalLiquidity(_reserve); + availableLiquidity = core.getReserveAvailableLiquidity(_reserve); + totalBorrowsFixed = core.getReserveTotalBorrowsFixed(_reserve); + totalBorrowsVariable = core.getReserveTotalBorrowsVariable(_reserve); + liquidityRate = core.getReserveCurrentLiquidityRate(_reserve); + variableBorrowRate = core.getReserveCurrentVariableBorrowRate(_reserve); + fixedBorrowRate = core.getReserveCurrentFixedBorrowRate(_reserve); + averageFixedBorrowRate = core.getReserveCurrentAverageFixedBorrowRate(_reserve); + utilizationRate = core.getReserveUtilizationRate(_reserve); + liquidityIndex = core.getReserveLiquidityCumulativeIndex(_reserve); + variableBorrowIndex = core.getReserveVariableBorrowsCumulativeIndex(_reserve); + aTokenAddress = core.getReserveATokenAddress(_reserve); + lastUpdateTimestamp = core.getReserveLastUpdate(_reserve); + } + + function getUserAccountData(address _user) + external + view + returns ( + uint256 totalLiquidityETH, + uint256 totalCollateralETH, + uint256 totalBorrowsETH, + uint256 availableBorrowsETH, + uint256 currentLiquidationThreshold, + uint256 ltv, + uint256 healthFactor + ) + { + (totalLiquidityETH, + totalCollateralETH, + totalBorrowsETH, + ltv, + currentLiquidationThreshold, + healthFactor) = calculateUserGlobalData(_user); + + availableBorrowsETH = calculateAvailableBorrowsETHInternal(totalCollateralETH, totalBorrowsETH, ltv); + } + + function getUserReserveData(address _reserve, address _user) + external + view + returns ( + uint256 currentATokenBalance, + uint256 currentUnderlyingBalance, + uint256 currentBorrowBalance, + uint256 principalBorrowBalance, + uint256 borrowRateMode, + uint256 borrowRate, + uint256 liquidityRate, + uint256 originationFee, + uint256 variableBorrowIndex, + uint256 lastUpdateTimestamp, + bool usageAsCollateralEnabled + ) + { + currentATokenBalance = AToken(core.getReserveATokenAddress(_reserve)).balanceOf(_user); + currentUnderlyingBalance = AToken(core.getReserveATokenAddress(_reserve)).balanceOfUnderlying(_user); + CoreLibrary.InterestRateMode mode = core.getUserCurrentBorrowRateMode(_reserve, _user); + (principalBorrowBalance, + currentBorrowBalance,) = core.getUserBorrowBalances(_reserve, _user); + borrowRateMode = uint256(mode); + borrowRate = mode == CoreLibrary.InterestRateMode.FIXED + ? core.getUserCurrentFixedBorrowRate(_reserve, _user) + : core.getReserveCurrentVariableBorrowRate(_reserve); + liquidityRate = core.getReserveCurrentLiquidityRate(_reserve); + originationFee = core.getUserOriginationFee(_reserve, _user); + variableBorrowIndex = core.getUserVariableBorrowCumulativeIndex(_reserve, _user); + lastUpdateTimestamp = core.getUserLastUpdate(_reserve, _user); + usageAsCollateralEnabled = core.isUserUseReserveAsCollateralEnabled(_reserve, _user); + } + + /** + @dev provides the actual balance of a reserve, by checking the core balance of the underlying ERC20/Ether + */ + + function getCoreActualReserveBalance(address _reserve) external view returns(uint256){ + + address ethereumAddress = NetworkMetadataProvider(addressesProvider.getNetworkMetadataProvider()).getEthereumAddress(); + address coreAddress = address(core); + + uint balance = _reserve == ethereumAddress ? coreAddress.balance : IERC20(_reserve).balanceOf(coreAddress); + + return balance; + } +} diff --git a/contracts/lendingpool/LendingPoolLiquidationManager.sol b/contracts/lendingpool/LendingPoolLiquidationManager.sol new file mode 100755 index 0000000..dbdcd18 --- /dev/null +++ b/contracts/lendingpool/LendingPoolLiquidationManager.sol @@ -0,0 +1,237 @@ +pragma solidity ^0.5.0; + + +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; +import "openzeppelin-solidity/contracts/utils/ReentrancyGuard.sol"; +import "openzeppelin-solidity/contracts/utils/Address.sol"; +import "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol"; + +import "../configuration/LendingPoolAddressesProvider.sol"; +import "../configuration/LendingPoolParametersProvider.sol"; +import "../configuration/NetworkMetadataProvider.sol"; +import "../tokenization/AToken.sol"; +import "../libraries/CoreLibrary.sol"; +import "../libraries/WadRayMath.sol"; +import "../interfaces/IFeeProvider.sol"; +import "../flashloan/interfaces/IFlashLoanReceiver.sol"; +import "./LendingPoolCore.sol"; +import "./LendingPoolDataProvider.sol"; + + + +/************************************************************************************* +@title LiquidationManager contract +@author Aave +@notice Implements the actions of the LendingPool, and exposes accessory methods to access the core information + *************************************************************************************/ + + +contract LendingPoolLiquidationManager is ReentrancyGuard { + + using SafeMath for uint256; + using WadRayMath for uint256; + using Address for address payable; + + LendingPoolAddressesProvider public addressesProvider; + LendingPoolCore core; + LendingPoolDataProvider dataProvider; + LendingPoolParametersProvider parametersProvider; + + + uint256 constant LIQUIDATION_CLOSE_FACTOR_PERCENT = 50; + enum LiquidationErrors { + NO_ERROR, + NO_COLLATERAL_AVAILABLE, + COLLATERAL_CANNOT_BE_LIQUIDATED, + CURRRENCY_NOT_BORROWED, + HEALTH_FACTOR_ABOVE_THRESHOLD, + NOT_ENOUGH_LIQUIDITY + } + + event LiquidationCompleted(); + + struct LiquidationCallLocalVars{ + uint256 healthFactor; + uint256 userCollateralBalance; + uint256 userCompoundedBorrowBalance; + uint256 borrowBalanceIncrease; + uint256 maxPrincipalAmountToLiquidate; + uint256 actualAmountToLiquidate; + uint256 liquidationRatio; + uint256 collateralPrice; + uint256 principalCurrencyPrice; + uint256 maxAmountCollateralToLiquidate; + bool isCollateralEnabled; + + } + + /** + * @notice implements loan liquidation + * @dev _receiveAToken allows the liquidators to receive the aTokens, instead of the underlying asset. + */ + function liquidationCall(address _collateral, address _reserve, address _user, uint256 _purchaseAmount, bool _receiveAToken) + external + payable + returns(uint256, string memory) + { + LiquidationCallLocalVars memory vars; + + (,,,,,vars.healthFactor) = dataProvider.calculateUserGlobalData(_user); + + if(vars.healthFactor >= dataProvider.getHealthFactorLiquidationThreshold()){ + return (uint256(LiquidationErrors.HEALTH_FACTOR_ABOVE_THRESHOLD), "Health factor is not below the threshold"); + } + + vars.userCollateralBalance = dataProvider.getUserUnderlyingAssetBalance(_collateral, _user); + + //if _user hasn't deposited this specific collateral, nothing can be liquidated + if(vars.userCollateralBalance == 0) { + return (uint256(LiquidationErrors.NO_COLLATERAL_AVAILABLE), "Invalid collateral to liquidate"); + } + + vars.isCollateralEnabled = core.isReserveUsageAsCollateralEnabled(_collateral) || + !core.isUserUseReserveAsCollateralEnabled(_collateral, _user); + + //if _collateral isn't enabled as collateral by _user, it cannot be liquidated + if(!vars.isCollateralEnabled) { + return (uint256(LiquidationErrors.COLLATERAL_CANNOT_BE_LIQUIDATED), "The collateral chosen cannot be liuquidated"); + } + + //if the user hasn't borrowed the specific currency defined by _reserve, it cannot be liquidated + (,vars.userCompoundedBorrowBalance,vars.borrowBalanceIncrease) = core.getUserBorrowBalances(_reserve, _user); + + if(vars.userCompoundedBorrowBalance == 0){ + return (uint256(LiquidationErrors.CURRRENCY_NOT_BORROWED), "User did not borrow the specified currency"); + } + + //all clear - calculate the max principal amount that can be liquidated + vars.maxPrincipalAmountToLiquidate = vars.userCompoundedBorrowBalance.mul(LIQUIDATION_CLOSE_FACTOR_PERCENT).div(100); + + vars.actualAmountToLiquidate = _purchaseAmount > vars.maxPrincipalAmountToLiquidate + ? + vars.maxPrincipalAmountToLiquidate + : + _purchaseAmount; + + (uint256 maxCollateralToLiquidate, + uint256 principalAmountNeeded) = calculateAvailableCollateralToLiquidate(_collateral, _reserve, vars.actualAmountToLiquidate, vars.userCollateralBalance); + + //if principalAmountNeeded < vars.ActualAmountToLiquidate, there isn't enough + //of _collateral to cover the actual amount that is being liquidated, hence we liquidate + //a smaller amount + + if(principalAmountNeeded < vars.actualAmountToLiquidate){ + vars.actualAmountToLiquidate = principalAmountNeeded; + } + + //if liquidator reclaims the underlying asset, we make sure there is enough available collateral in the reserve + if(!_receiveAToken){ + uint256 currentAvailableCollateral = core.getReserveAvailableLiquidity(_collateral); + if(currentAvailableCollateral >= maxCollateralToLiquidate){ + return (uint256(LiquidationErrors.NOT_ENOUGH_LIQUIDITY), "There isn't enough liquidity available to liquidate"); + } + } + + //update principal reserve data + core.updateReserveCumulativeIndexes(_reserve); + + CoreLibrary.InterestRateMode borrowRateMode = core.getUserCurrentBorrowRateMode(_reserve,_user); + + core.increaseReserveTotalLiquidity(_reserve, vars.borrowBalanceIncrease); + + if (borrowRateMode == CoreLibrary.InterestRateMode.FIXED) { + uint256 currentFixedRate = core.getUserCurrentFixedBorrowRate(_reserve, _user); + core.decreaseReserveTotalBorrowsFixedAndUpdateAverageRate(_reserve, vars.actualAmountToLiquidate.sub(vars.borrowBalanceIncrease), currentFixedRate); + } else { + core.decreaseReserveTotalBorrowsVariable(_reserve, vars.actualAmountToLiquidate.sub(vars.borrowBalanceIncrease)); + } + + core.updateReserveInterestRates(_reserve); + core.setReserveLastUpdate(_reserve); + //step 3: update user borrow data + core.decreaseUserPrincipalBorrowBalance(_reserve, _user, vars.actualAmountToLiquidate.sub(vars.borrowBalanceIncrease)); + core.setUserLastUpdate(_reserve,_user); + + //update collateral reserve + core.updateReserveCumulativeIndexes(_collateral); + AToken collateralAtoken = AToken(core.getReserveATokenAddress(_collateral)); + + //calculating aToken equivalent amount from vars. + uint256 aTokenCollateralToLiquidate = collateralAtoken.underlyingAmountToATokenAmount(maxCollateralToLiquidate); + + //if liquidator reclaims the aToken, he receives the equivalent atoken amount + if(_receiveAToken) { + collateralAtoken.transferOnLiquidation(_user, msg.sender, aTokenCollateralToLiquidate); + } + else { //otherwise receives the underlying asset + //burn the equivalent amount of atoken + collateralAtoken.burnOnLiquidation(_user, aTokenCollateralToLiquidate); + core.decreaseReserveTotalLiquidity(_collateral, maxCollateralToLiquidate); + core.updateReserveInterestRates(_collateral); + core.transferToUser(_collateral, msg.sender, maxCollateralToLiquidate); + } + + core.setReserveLastUpdate(_collateral); + + //transfers the principal currency to the pool + + core.transferToReserve.value(msg.value)(_reserve, msg.sender, vars.actualAmountToLiquidate); + + return (uint256(LiquidationErrors.NO_ERROR), "No errors"); + } + + + + struct AvailableCollateralToLiquidateLocalVars{ + uint256 userCompoundedBorrowBalance; + uint256 liquidationDiscount; + uint256 collateralPrice; + uint256 principalCurrencyPrice; + uint256 maxAmountCollateralToLiquidate; + } + + /** + * @notice calculates how much of a specific collateral can be liquidated, given + * a certain amount of principal currency. + * @dev this function needs to be called after all the checks to validate the liquidation + * have been performed, otherwise it might fail. + */ + function calculateAvailableCollateralToLiquidate( + address _collateral, + address _principal, + uint256 _purchaseAmount, + uint256 _userCollateralBalance) internal view returns(uint256 collateralAmount, uint256 principalAmountNeeded) { + + collateralAmount = 0; + principalAmountNeeded = 0; + IPriceOracle oracle = IPriceOracle(addressesProvider.getPriceOracle()); + + AvailableCollateralToLiquidateLocalVars memory vars; + + vars.collateralPrice = oracle.getAssetPrice(_collateral); + vars.principalCurrencyPrice = oracle.getAssetPrice(_principal); + vars.liquidationDiscount = core.getReserveLiquidationDiscount(_collateral); + + //this is the maximum possible amount of the selected collateral that can be liquidated, given the + //max amount of principal currency that is available for liquidation. + vars.maxAmountCollateralToLiquidate = vars.principalCurrencyPrice.mul(_purchaseAmount) + .div(vars.collateralPrice) + .mul(vars.liquidationDiscount) + .div(100); + + if(vars.maxAmountCollateralToLiquidate > _userCollateralBalance) { + collateralAmount = _userCollateralBalance; + principalAmountNeeded = vars.collateralPrice + .mul(collateralAmount) + .div(vars.principalCurrencyPrice) + .mul(100) + .div(vars.liquidationDiscount); + } + else{ + collateralAmount = vars.maxAmountCollateralToLiquidate; + principalAmountNeeded = _purchaseAmount; + } + + return (collateralAmount, principalAmountNeeded); + } +} \ No newline at end of file diff --git a/contracts/libraries/CoreLibrary.sol b/contracts/libraries/CoreLibrary.sol new file mode 100755 index 0000000..566b702 --- /dev/null +++ b/contracts/libraries/CoreLibrary.sol @@ -0,0 +1,322 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; +import "./WadRayMath.sol"; + +/************************************************************************************* +@title CoreLibrary library +@author Aave +@notice Defines the data structures of the reserves and the user data + *************************************************************************************/ + +library CoreLibrary { + using SafeMath for uint256; + using WadRayMath for uint256; + + enum InterestRateMode {FIXED, VARIABLE} + + uint256 constant SECONDS_PER_YEAR = 365 days; + + struct UserReserveData { + //principal amount borrowed by the user + uint256 principalBorrowBalance; + //cumulated variable borrow index for the user Bvcu. Refer to the whitepaper for more information + uint256 lastVariableBorrowCumulativeIndex; + //origination fee cumulated by the user + uint256 originationFee; + // fixed borrow rate at which the user has borrowed + uint256 fixedBorrowRate; + + uint40 lastUpdateTimestamp; + + /** + @dev defines if a specific deposit should or not be used as a collateral in borrows + */ + bool useAsCollateral; + } + + struct ReserveData { + /** + @dev refer to the whitepaper, section 1.1 basic concepts for a formal description of these properties. + */ + uint256 totalLiquidity; + uint256 lastLiquidityCumulativeIndex; + uint256 currentLiquidityRate; + uint256 totalBorrowsFixed; + uint256 totalBorrowsVariable; + uint256 currentVariableBorrowRate; + uint256 currentFixedBorrowRate; + uint256 currentAverageFixedBorrowRate; + uint256 lastVariableBorrowCumulativeIndex; + uint256 baseLTVasCollateral; + uint256 liquidationThreshold; + uint256 liquidationDiscount; + uint256 decimals; + /** + * @dev address of the aToken representing the asset + */ + address aTokenAddress; + + /** + * @dev address of the interest rate strategy contract + */ + + address interestRateStrategyAddress; + + uint40 lastUpdateTimestamp; + + /** + @dev borrowingEnabled = true means users can borrow from this reserve + @dev usageAsCollateral = true means users can use this reserve as collateral + */ + bool borrowingEnabled; + bool usageAsCollateralEnabled; + bool isFixedBorrowRateEnabled; + bool isActive; + } + + /** + @notice returns the utilization rate U of a specific reserve + @dev the utilization rate is in ray (27 decimals precision) + */ + + function getReserveUtilizationRate(ReserveData storage _self) internal view returns (uint256) { + + if (_self.totalLiquidity == 0) return 0; + + uint256 totalBorrows = _self.totalBorrowsFixed.add(_self.totalBorrowsVariable); + + return totalBorrows.rayDiv(_self.totalLiquidity); + } + + /** + @notice returns the utilization rate U of a specific reserve + @dev the utilization rate is in ray (27 decimals precision) + */ + function getNormalizedIncome(CoreLibrary.ReserveData storage _reserve) + internal + view + returns (uint256) + { + + uint256 cumulated = calculateCumulatedInterest( + _reserve.currentLiquidityRate, + _reserve.lastUpdateTimestamp) + .rayMul(_reserve.lastLiquidityCumulativeIndex); + + return cumulated; + + } + + /** + @notice Updates the liquidity cumulative index Ci and variable borrow cumulative index Bvc. Refer to the whitepaper for + a formal specification. + @dev Ci and Bvc are in ray (27 decimals precision) + */ + + function updateCumulativeIndexes(ReserveData storage _self) internal{ + + uint256 utilizationRate = getReserveUtilizationRate(_self); + + if (utilizationRate > 0) { + //only cumulating if there is any income being produced + uint256 cumulatedLiquidityInterest = calculateCumulatedInterest(_self.currentLiquidityRate, _self.lastUpdateTimestamp); + + _self.lastLiquidityCumulativeIndex = cumulatedLiquidityInterest.rayMul( + _self.lastLiquidityCumulativeIndex + ); + + uint256 cumulatedVariableBorrowInterest = calculateCumulatedInterest(_self.currentVariableBorrowRate, _self.lastUpdateTimestamp); + _self.lastVariableBorrowCumulativeIndex = cumulatedVariableBorrowInterest.rayMul( + _self.lastVariableBorrowCumulativeIndex + ); + } + } + + function cumulateToLiquidityIndex(ReserveData storage _self, uint256 _amount) internal{ + + uint256 amountToLiquidityRatio = _amount.wadToRay().rayDiv(_self.totalLiquidity.wadToRay()); + + uint256 cumulatedLiquidity = amountToLiquidityRatio.add(WadRayMath.ray()); + + _self.lastLiquidityCumulativeIndex = cumulatedLiquidity.rayMul( + _self.lastLiquidityCumulativeIndex + ); + } + + /** + @notice inits a reserve + */ + + function init(ReserveData storage _self, address _aTokenAddress, uint256 _decimals, address _interestRateStrategyAddress) external{ + require(_self.aTokenAddress == address(0), "Reserve has already been initialized"); + + if (_self.lastLiquidityCumulativeIndex == 0) { + //if the reserve has not been initialized yet + _self.lastLiquidityCumulativeIndex = WadRayMath.ray(); + } + + if (_self.lastVariableBorrowCumulativeIndex == 0){ + _self.lastVariableBorrowCumulativeIndex = WadRayMath.ray(); + } + + _self.aTokenAddress = _aTokenAddress; + _self.decimals = _decimals; + + _self.interestRateStrategyAddress = _interestRateStrategyAddress; + _self.isActive = true; + + + } + + function enableBorrowing( + ReserveData storage _self, + bool _fixedBorrowRateEnabled + ) external{ + require(_self.borrowingEnabled == false, "Reserve is already enabled"); + + _self.borrowingEnabled = true; + _self.isFixedBorrowRateEnabled = _fixedBorrowRateEnabled; + + + } + + function disableBorrowing(ReserveData storage _self) external{ + _self.borrowingEnabled = false; + } + + function enableAsCollateral(ReserveData storage _self, uint256 _baseLTVasCollateral, uint256 _liquidationThreshold) + external + { + require(_self.usageAsCollateralEnabled == false, "Reserve is already enabled as collateral"); + + _self.usageAsCollateralEnabled = true; + _self.baseLTVasCollateral = _baseLTVasCollateral; + _self.liquidationThreshold = _liquidationThreshold; + + if (_self.lastLiquidityCumulativeIndex == 0) _self.lastLiquidityCumulativeIndex = WadRayMath.ray(); + + } + + function disableAsCollateral(ReserveData storage _self) external{ + _self.usageAsCollateralEnabled = false; + } + + /** + @dev user specific functions + */ + + function getCompoundedBorrowBalance( + CoreLibrary.UserReserveData storage _self, + CoreLibrary.ReserveData storage _reserve) + internal + view + returns(uint256) { + + if (_self.principalBorrowBalance == 0) return 0; + + uint256 principalBorrowBalanceRay = _self.principalBorrowBalance.wadToRay(); + uint256 compoundedBalance = 0; + uint256 cumulatedInterest = 0; + + if (_self.fixedBorrowRate > 0) { + cumulatedInterest = calculateCumulatedInterest(_self.fixedBorrowRate, _self.lastUpdateTimestamp); + } + else { + //variable interest + cumulatedInterest = calculateCumulatedInterest(_reserve.currentVariableBorrowRate, _reserve.lastUpdateTimestamp) + .rayMul(_reserve.lastVariableBorrowCumulativeIndex) + .rayDiv(_self.lastVariableBorrowCumulativeIndex); + } + + compoundedBalance = principalBorrowBalanceRay + .rayMul(cumulatedInterest) + .rayToWad(); + + if(compoundedBalance == _self.principalBorrowBalance) { + + //no interest cumulation because of the rounding - we add 1 wei + //as symbolic cumulated interest to avoid interest free loans. + + return _self.principalBorrowBalance.add(1 wei); + } + + return compoundedBalance; + } + + function increaseTotalBorrowsFixedAndUpdateAverageRate(ReserveData storage _reserve, uint256 _amount, uint256 _rate) internal{ + uint256 previousTotalBorrowFixed = _reserve.totalBorrowsFixed; + //updating reserve borrows fixed + _reserve.totalBorrowsFixed = _reserve.totalBorrowsFixed.add(_amount); + + //update the average fixed rate + //weighted average of all the borrows + uint256 weightedLastBorrow = _amount.wadToRay().rayMul(_rate); + uint256 weightedPreviousTotalBorrows = previousTotalBorrowFixed.wadToRay().rayMul(_reserve.currentAverageFixedBorrowRate); + + _reserve.currentAverageFixedBorrowRate = weightedLastBorrow.add(weightedPreviousTotalBorrows).rayDiv( + _reserve.totalBorrowsFixed.wadToRay() + ); + } + + function decreaseTotalBorrowsFixedAndUpdateAverageRate(ReserveData storage _reserve, uint256 _amount, uint256 _rate) internal{ + + require(_reserve.totalBorrowsFixed >= _amount, "Invalid amount to decrease"); + + uint256 previousTotalBorrowFixed = _reserve.totalBorrowsFixed; + + //updating reserve borrows fixed + _reserve.totalBorrowsFixed = _reserve.totalBorrowsFixed.sub(_amount); + + if (_reserve.totalBorrowsFixed == 0) { + _reserve.currentAverageFixedBorrowRate = 0; //no income if there are no fixed rate borrows + return; + } + + //update the average fixed rate + //weighted average of all the borrows + uint256 weightedLastBorrow = _amount.wadToRay().rayMul(_rate); + uint256 weightedPreviousTotalBorrows = previousTotalBorrowFixed.wadToRay().rayMul(_reserve.currentAverageFixedBorrowRate); + + require(weightedPreviousTotalBorrows >= weightedLastBorrow, "The amounts to substract don't match"); + + _reserve.currentAverageFixedBorrowRate = weightedPreviousTotalBorrows.sub(weightedLastBorrow).rayDiv( + _reserve.totalBorrowsFixed.wadToRay() + ); + } + + function increaseTotalBorrowsVariable(ReserveData storage _reserve, uint256 _amount) internal{ + _reserve.totalBorrowsVariable = _reserve.totalBorrowsVariable.add(_amount); + } + + function decreaseTotalBorrowsVariable(ReserveData storage _reserve, uint256 _amount) internal{ + require(_reserve.totalBorrowsVariable >= _amount, "The amount that is being substracted from the variable total borrows is incorrect"); + _reserve.totalBorrowsVariable = _reserve.totalBorrowsVariable.sub(_amount); + } + + function setLastUpdate(ReserveData storage _reserve) internal{ + //solium-disable-next-line + _reserve.lastUpdateTimestamp = uint40(block.timestamp); + } + + function getTotalBorrows(CoreLibrary.ReserveData storage reserve) internal view returns (uint256) { + return reserve.totalBorrowsFixed.add(reserve.totalBorrowsVariable); + } + + + /** + @dev function to calculate cumulated interest + */ + + function calculateCumulatedInterest(uint256 _rate,uint40 _lastUpdateTimestamp) internal view returns(uint256) { + + //solium-disable-next-line + uint256 timeDifference = block.timestamp.sub(_lastUpdateTimestamp); + + uint256 timeDelta = timeDifference.wadToRay().rayDiv(SECONDS_PER_YEAR.wadToRay()); + + + return _rate.rayMul(timeDelta).add(WadRayMath.ray()); + } + +} diff --git a/contracts/libraries/WadRayMath.sol b/contracts/libraries/WadRayMath.sol new file mode 100755 index 0000000..a22616e --- /dev/null +++ b/contracts/libraries/WadRayMath.sol @@ -0,0 +1,66 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; + +/****************** +@title WadRayMath library +@author Aave +@dev Provides mul and div function for wads (decimal numbers with 18 digits precision) and rays (decimals with 27 digits) + */ + +library WadRayMath { + using SafeMath for uint256; + + uint256 internal constant WAD = 1e18; + uint256 internal constant halfWAD = WAD / 2; + + uint256 internal constant RAY = 1e27; + uint256 internal constant halfRAY = RAY / 2; + + uint256 constant WAD_RAY_RATIO = 1e9; + + function ray() internal pure returns (uint256) { + return RAY; + } + function wad() internal pure returns (uint256) { + return WAD; + } + + function halfRay() internal pure returns (uint256) { + return halfRAY; + } + + function halfWad() internal pure returns (uint256) { + return halfWAD; + } + + + function wadMul(uint256 a, uint256 b) internal pure returns (uint256) { + return halfWAD.add(a.mul(b)).div(WAD); + } + + function wadDiv(uint256 a, uint256 b) internal pure returns (uint256) { + uint256 halfB = b / 2; + + return halfB.add(a.mul(WAD)).div(b); + } + + function rayMul(uint256 a, uint256 b) internal pure returns (uint256) { + return halfRAY.add(a.mul(b)).div(RAY); + } + + function rayDiv(uint256 a, uint256 b) internal pure returns (uint256) { + uint256 halfB = b / 2; + + return halfB.add(a.mul(RAY)).div(b); + } + + function rayToWad(uint256 a) internal pure returns (uint256) { + return a.div(WAD_RAY_RATIO); + } + + function wadToRay(uint256 a) internal pure returns (uint256) { + return a.mul(WAD_RAY_RATIO); + } + +} diff --git a/contracts/misc/WalletBalanceProvider.sol b/contracts/misc/WalletBalanceProvider.sol new file mode 100755 index 0000000..3b126e9 --- /dev/null +++ b/contracts/misc/WalletBalanceProvider.sol @@ -0,0 +1,78 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/utils/Address.sol"; +import "openzeppelin-solidity/contracts/token/ERC20/IERC20.sol"; + +import "../configuration/LendingPoolAddressesProvider.sol"; +import "../lendingpool/LendingPoolCore.sol"; +import "../interfaces/INetworkMetadataProvider.sol"; + + +/************************************************************************************* +@title WalletBalanceProvider contract +@author Aave, influenced by https://github.com/wbobeirne/eth-balance-checker/blob/master/contracts/BalanceChecker.sol +@notice Implements a logic of getting multiple tokens balance for one user address + +@dev NOTE: THIS CONTRACT IS NOT USED WITHIN THE AAVE PROTOCOL. It's an accessory contract used to reduce the number of calls +towards the blockchain. + + *************************************************************************************/ + + +contract WalletBalanceProvider { + + using Address for address; + + LendingPoolAddressesProvider provider; + + constructor(LendingPoolAddressesProvider _provider) public { + + provider = _provider; + + } + /** + @dev Fallback function, don't accept any ETH + **/ + function() external payable { + revert("WalletBalanceProvider does not accept payments"); + } + + /** + @dev Check the token balance of a wallet in a token contract + + Returns the balance of the token for user. Avoids possible errors: + - return 0 on non-contract address + **/ + function balanceOf(address _user, address _token) public view returns (uint) { + // check if token is actually a contract + if (_token.isContract()) { + return IERC20(_token).balanceOf(_user); + } else { + return 0; + } + } + + + /** + @dev provides balances of user wallet for all reserves available on the pool + */ + function getUserWalletBalances(address _user) public view returns (address[] memory, uint[] memory) { + + LendingPoolCore core = LendingPoolCore(provider.getLendingPoolCore()); + + address[] memory reserves = core.getReserves(); + address ethereumAddress = INetworkMetadataProvider(provider.getNetworkMetadataProvider()).getEthereumAddress(); + + uint[] memory balances = new uint[](reserves.length); + + for (uint j = 0; j < reserves.length; j++) { + if (reserves[j] != ethereumAddress) { + balances[j] = balanceOf(_user, reserves[j]); + } else { + balances[j] = _user.balance; // ETH balance + } + } + + return (reserves, balances); + } +} \ No newline at end of file diff --git a/contracts/mocks/FlashLoan/MockFlashLoanReceiver.sol b/contracts/mocks/FlashLoan/MockFlashLoanReceiver.sol new file mode 100755 index 0000000..c107a4c --- /dev/null +++ b/contracts/mocks/FlashLoan/MockFlashLoanReceiver.sol @@ -0,0 +1,53 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; +import "../../flashloan/base/FlashLoanReceiverBase.sol"; +import "../tokens/MintableERC20.sol"; + +contract MockFlashLoanReceiver is FlashLoanReceiverBase { + + using SafeMath for uint256; + event ExecutedWithFail(address _reserve, uint256 _amount, uint256 _fee); + event ExecutedWithSuccess(address _reserve, uint256 _amount, uint256 _fee); + + + bool failExecution = false; + + constructor(ILendingPoolAddressesProvider _provider) FlashLoanReceiverBase(_provider) public { + } + + function setFailExecutionTransfer(bool _fail) public { + failExecution = _fail; + } + + function executeOperation( + address _reserve, + uint256 _amount, + uint256 _fee) external returns(uint256 returnedAmount) { + //mint to this contract the specific amount + MintableERC20 token = MintableERC20(_reserve); + + + //check the contract has the specified balance + require(_amount <= getBalanceInternal(address(this), _reserve), "Invalid balance for the contract"); + + if(failExecution) { + emit ExecutedWithFail(_reserve, _amount, _fee); + //returns amount + fee, but does not transfer back funds + return _amount.add(_fee); + } + + //execution does not fail - mint tokens and return them to the _destination + //note: if the reserve is eth, the mock contract must receive at least _fee ETH before calling executeOperation + INetworkMetadataProvider dataProvider = INetworkMetadataProvider(addressesProvider.getNetworkMetadataProvider()); + + if(_reserve != dataProvider.getEthereumAddress()) { + token.mint(_fee); + } + //returning amount + fee to the destination + transferFundsBackToPoolInternal(_reserve, _amount.add(_fee)); + emit ExecutedWithSuccess(_reserve, _amount, _fee); + return _amount.add(_fee); + + } +} \ No newline at end of file diff --git a/contracts/mocks/Oracle/LendingRateOracle.sol b/contracts/mocks/Oracle/LendingRateOracle.sol new file mode 100755 index 0000000..d6e6999 --- /dev/null +++ b/contracts/mocks/Oracle/LendingRateOracle.sol @@ -0,0 +1,27 @@ +pragma solidity ^0.5.0; + +import "../../interfaces/ILendingRateOracle.sol"; + + +contract LendingRateOracle is ILendingRateOracle { + + mapping(address => uint) borrowRates; + mapping(address => uint) liquidityRates; + + + function getMarketBorrowRate(address _asset) external view returns(uint) { + return borrowRates[_asset]; + } + + function setMarketBorrowRate(address _asset, uint _rate) external { + borrowRates[_asset] = _rate; + } + + function getMarketLiquidityRate(address _asset) external view returns(uint) { + return liquidityRates[_asset]; + } + + function setMarketLiquidityRate(address _asset, uint _rate) external { + liquidityRates[_asset] = _rate; + } +} \ No newline at end of file diff --git a/contracts/mocks/Oracle/PriceOracle.sol b/contracts/mocks/Oracle/PriceOracle.sol new file mode 100755 index 0000000..3a17996 --- /dev/null +++ b/contracts/mocks/Oracle/PriceOracle.sol @@ -0,0 +1,26 @@ +pragma solidity ^0.5.0; + +import "../../interfaces/IPriceOracle.sol"; + + +contract PriceOracle is IPriceOracle { + + mapping(address => uint) prices; + uint ethPriceUsd; + + function getAssetPrice(address _asset) external view returns(uint) { + return prices[_asset]; + } + + function setAssetPrice(address _asset, uint _price) external { + prices[_asset] = _price; + } + + function getEthUsdPrice() external view returns(uint) { + return ethPriceUsd; + } + + function setEthUsdPrice(uint _price) external { + ethPriceUsd = _price; + } +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MintableERC20.sol b/contracts/mocks/tokens/MintableERC20.sol new file mode 100755 index 0000000..c148eca --- /dev/null +++ b/contracts/mocks/tokens/MintableERC20.sol @@ -0,0 +1,19 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol"; + +/** + * @title ERC20Mintable + * @dev ERC20 minting logic + */ +contract MintableERC20 is ERC20 { + /** + * @dev Function to mint tokens + * @param value The amount of tokens to mint. + * @return A boolean that indicates if the operation was successful. + */ + function mint(uint256 value) public returns (bool) { + _mint(msg.sender, value); + return true; + } +} diff --git a/contracts/mocks/tokens/MockAMPL.sol b/contracts/mocks/tokens/MockAMPL.sol new file mode 100755 index 0000000..1915d00 --- /dev/null +++ b/contracts/mocks/tokens/MockAMPL.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockAMPL is MintableERC20 { + + uint public decimals = 18; + string public symbol = "AMPL"; + string public name = "Ampleforth"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockBAT.sol b/contracts/mocks/tokens/MockBAT.sol new file mode 100755 index 0000000..dd1cccf --- /dev/null +++ b/contracts/mocks/tokens/MockBAT.sol @@ -0,0 +1,13 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + + +contract MockBAT is MintableERC20 { + + uint public decimals = 18; + string public symbol = "BAT"; + string public name = "Basic Attention Token"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockDAI.sol b/contracts/mocks/tokens/MockDAI.sol new file mode 100755 index 0000000..016f47e --- /dev/null +++ b/contracts/mocks/tokens/MockDAI.sol @@ -0,0 +1,13 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + + +contract MockDAI is MintableERC20 { + + uint public decimals = 18; + string public symbol = "DAI"; + string public name = "DAI"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockETH.sol b/contracts/mocks/tokens/MockETH.sol new file mode 100755 index 0000000..f1185d7 --- /dev/null +++ b/contracts/mocks/tokens/MockETH.sol @@ -0,0 +1,13 @@ +pragma solidity ^0.5.0; + + + +import "./MintableERC20.sol"; + + +contract MockETH is MintableERC20 { + + uint public decimals = 18; + string public symbol = "ETH"; + string public name = "Ethereum"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockKNC.sol b/contracts/mocks/tokens/MockKNC.sol new file mode 100755 index 0000000..274c616 --- /dev/null +++ b/contracts/mocks/tokens/MockKNC.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockKNC is MintableERC20 { + + uint public decimals = 18; + string public symbol = "KNC"; + string public name = "Kyber Network"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockLEND.sol b/contracts/mocks/tokens/MockLEND.sol new file mode 100755 index 0000000..d0b01c6 --- /dev/null +++ b/contracts/mocks/tokens/MockLEND.sol @@ -0,0 +1,13 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + + +contract MockLEND is MintableERC20 { + + uint public decimals = 18; + string public symbol = "LEND"; + string public name = "LEND"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockLINK.sol b/contracts/mocks/tokens/MockLINK.sol new file mode 100755 index 0000000..172ffa3 --- /dev/null +++ b/contracts/mocks/tokens/MockLINK.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockLINK is MintableERC20 { + + uint public decimals = 18; + string public symbol = "LINK"; + string public name = "ChainLink"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockMANA.sol b/contracts/mocks/tokens/MockMANA.sol new file mode 100755 index 0000000..b9a9559 --- /dev/null +++ b/contracts/mocks/tokens/MockMANA.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockMANA is MintableERC20 { + + uint public decimals = 18; + string public symbol = "MANA"; + string public name = "Decentraland"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockMKR.sol b/contracts/mocks/tokens/MockMKR.sol new file mode 100755 index 0000000..428a3c4 --- /dev/null +++ b/contracts/mocks/tokens/MockMKR.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockMKR is MintableERC20 { + + uint public decimals = 18; + string public symbol = "MKR"; + string public name = "Maker"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockREP.sol b/contracts/mocks/tokens/MockREP.sol new file mode 100755 index 0000000..6555234 --- /dev/null +++ b/contracts/mocks/tokens/MockREP.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockREP is MintableERC20 { + + uint public decimals = 18; + string public symbol = "REP"; + string public name = "Augur"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockSUSD.sol b/contracts/mocks/tokens/MockSUSD.sol new file mode 100755 index 0000000..6be7f3e --- /dev/null +++ b/contracts/mocks/tokens/MockSUSD.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockSUSD is MintableERC20 { + + uint public decimals = 6; + string public symbol = "SUSD"; + string public name = "Synthetix USD"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockTUSD.sol b/contracts/mocks/tokens/MockTUSD.sol new file mode 100755 index 0000000..48d3ea0 --- /dev/null +++ b/contracts/mocks/tokens/MockTUSD.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockTUSD is MintableERC20 { + + uint public decimals = 18; + string public symbol = "TUSD"; + string public name = "TrueUSD"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockUSDC.sol b/contracts/mocks/tokens/MockUSDC.sol new file mode 100755 index 0000000..b9c80fe --- /dev/null +++ b/contracts/mocks/tokens/MockUSDC.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockUSDC is MintableERC20 { + + uint public decimals = 6; + string public symbol = "USDC"; + string public name = "USD Coin"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockUSDT.sol b/contracts/mocks/tokens/MockUSDT.sol new file mode 100755 index 0000000..d5aa9eb --- /dev/null +++ b/contracts/mocks/tokens/MockUSDT.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockUSDT is MintableERC20 { + + uint public decimals = 6; + string public symbol = "USDT"; + string public name = "USDT Coin"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockWBTC.sol b/contracts/mocks/tokens/MockWBTC.sol new file mode 100755 index 0000000..c00b5ad --- /dev/null +++ b/contracts/mocks/tokens/MockWBTC.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockWBTC is MintableERC20 { + + uint public decimals = 18; + string public symbol = "WBTC"; + string public name = "WBTC Coin"; +} \ No newline at end of file diff --git a/contracts/mocks/tokens/MockZRX.sol b/contracts/mocks/tokens/MockZRX.sol new file mode 100755 index 0000000..062bb39 --- /dev/null +++ b/contracts/mocks/tokens/MockZRX.sol @@ -0,0 +1,12 @@ +pragma solidity ^0.5.0; + + +import "./MintableERC20.sol"; + + +contract MockZRX is MintableERC20 { + + uint public decimals = 18; + string public symbol = "ZRX"; + string public name = "0x Coin"; +} \ No newline at end of file diff --git a/contracts/tokenization/AToken.sol b/contracts/tokenization/AToken.sol new file mode 100755 index 0000000..f6532ba --- /dev/null +++ b/contracts/tokenization/AToken.sol @@ -0,0 +1,193 @@ +pragma solidity ^0.5.0; + +import "openzeppelin-solidity/contracts/math/SafeMath.sol"; +import "openzeppelin-solidity/contracts/token/ERC20/ERC20.sol"; +import "openzeppelin-solidity/contracts/token/ERC20/ERC20Detailed.sol"; + +import "../configuration/LendingPoolAddressesProvider.sol"; +import "../lendingpool/LendingPool.sol"; +import "../lendingpool/LendingPoolDataProvider.sol"; +import "../lendingpool/LendingPoolCore.sol"; +import "../libraries/WadRayMath.sol"; + +/** + * @title Aave ERC20 AToken + * + * @dev Implementation of the interest bearing token for the DLP protocol. + */ +contract AToken is ERC20, ERC20Detailed { + using WadRayMath for uint256; + + event Redeem( + address indexed _from, + uint256 _value, + uint256 _underlyingValue, + uint256 _fromBalance + ); + + event MintOnDeposit(address indexed _from, uint256 _value, uint256 _underlyingValue, uint256 _fromBalance); + event BurnOnLiquidation(address indexed _from, uint256 _value, uint256 _underlyingValue, uint256 _fromBalance); + event TransferOnLiquidation( + address indexed _from, + address indexed _to, + uint256 _value, + uint256 _underlyingValue, + uint256 _fromBalance, + uint256 _toBalance + ); + + + event BalanceTransfer( + address indexed _from, + address indexed _to, + uint256 _value, + uint256 _underlyingValue, + uint256 _fromBalance, + uint256 _toBalance + ); + + address public underlyingAssetAddress; + uint256 public underlyingAssetDecimals; + uint256 public initialExchangeRate; + + LendingPoolAddressesProvider private addressesProvider; + LendingPoolCore private core; + + modifier onlyLendingPool { + require( + msg.sender == addressesProvider.getLendingPool(), + "The caller of this function can only be a lending pool" + ); + _; + } + + modifier whenTranferAllowed(address _from, uint256 _amount) { + require(isTransferAllowed(_from, _amount), "Transfer cannot be allowed."); + _; + } + + constructor( + LendingPoolAddressesProvider _addressesProvider, + address _underlyingAsset, + uint256 _underlyingAssetDecimals, + string memory _name, + string memory _symbol, + uint8 _decimals, + uint256 _initialExchangeRate + ) public ERC20Detailed(_name, _symbol, _decimals) { + addressesProvider = _addressesProvider; + core = LendingPoolCore(addressesProvider.getLendingPoolCore()); + initialExchangeRate = _initialExchangeRate; + underlyingAssetAddress = _underlyingAsset; + underlyingAssetDecimals = _underlyingAssetDecimals; + } + + /** + * @notice ERC20 implementation internal function backing transfer() and transferFrom() + * @dev validates the transfer before allowing it. NOTE: This is not standard ERC20 behavior + */ + function _transfer(address from, address to, uint256 amount) internal whenTranferAllowed(from, amount) { + super._transfer(from, to, amount); + emit BalanceTransfer(from, to, amount, aTokenAmountToUnderlyingAmount(amount), balanceOf(from), balanceOf(to)); + } + + /** + * @notice redeems aToken for the undelying asset. + */ + function redeem(uint256 _amount) external whenTranferAllowed(msg.sender, _amount) { + // calculate underlying to redeem + uint256 underlyingAmountToRedeem = aTokenAmountToUnderlyingAmount(_amount); + + // burns tokens equivalent to the amount requested + burnOnRedeemInternal(msg.sender, _amount); + + // executes redeem of the underlying asset + LendingPool pool = LendingPool(addressesProvider.getLendingPool()); + pool.redeemUnderlying(underlyingAssetAddress, msg.sender, underlyingAmountToRedeem); + emit Redeem(msg.sender, _amount, underlyingAmountToRedeem, balanceOf(msg.sender)); + } + + /** + * @notice mints token in the event of users depositing the underlying asset into the lending pool + * @dev only lending pools can call this function + */ + function mintOnDeposit(address _account, uint256 _underlyingAmount) external onlyLendingPool { + uint256 aTokensToMint = underlyingAmountToATokenAmount(_underlyingAmount); + + _mint(_account, aTokensToMint); + emit MintOnDeposit(_account, aTokensToMint, _underlyingAmount, balanceOf(_account)); + } + + /** + * @dev burns token in the event of a borrow being liquidated, in case the liquidators reclaims the underlying asset + * @dev only lending pools can call this function + */ + function burnOnLiquidation(address account, uint256 value) external onlyLendingPool { + _burn(account, value); + emit BurnOnLiquidation(account, value, aTokenAmountToUnderlyingAmount(value), balanceOf(account)); + } + + /** + * @dev transfers tokens in the event of a borrow being liquidated, in case the liquidators reclaims the aToken + * @dev only lending pools can call this function + */ + function transferOnLiquidation(address from, address to, uint256 value) external onlyLendingPool { + super._transfer(from, to, value); + emit TransferOnLiquidation(from, to, value, aTokenAmountToUnderlyingAmount(value), balanceOf(from), balanceOf(to)); + } + + /** + * @dev returns the exchange rate of the aToken to the underlying asset + */ + function getExchangeRate() public view returns (uint256) { + uint256 currentNormalizedCumulatedInterest = core.getReserveNormalizedIncome(underlyingAssetAddress); + + return initialExchangeRate.rayDiv(currentNormalizedCumulatedInterest); + } + + function balanceOfUnderlying(address _user) public view returns (uint256) { + return aTokenAmountToUnderlyingAmount(balanceOf(_user)); + } + + function aTokenAmountToUnderlyingAmount(uint256 _amount) public view returns (uint256) { + if (_amount == 0) { + // Optmization + return 0; + } + + uint256 overlyingDecimals = 10 ** uint256(decimals()); + + return _amount + .wadToRay() + .rayDiv(getExchangeRate()) + .mul(10 ** underlyingAssetDecimals) + .div(overlyingDecimals) + .rayToWad(); + } + + /** + * @notice Used to validate transfers before actually executing them. + **/ + function isTransferAllowed(address _from, uint256 _amount) public view returns (bool) { + LendingPoolDataProvider dataProvider = LendingPoolDataProvider(addressesProvider.getLendingPoolDataProvider()); + uint256 amountUnderlying = aTokenAmountToUnderlyingAmount(_amount); + return dataProvider.balanceDecreaseAllowed(underlyingAssetAddress, _from, amountUnderlying); + } + + function underlyingAmountToATokenAmount(uint256 _amount) public view returns (uint256) { + if (_amount == 0) { + // Optmization + return 0; + } + + return _amount.mul(getExchangeRate()).div(10 ** underlyingAssetDecimals).rayToWad(); + } + + /** + * @dev burns token in the event of users redeeming the underlying asset from the lending pool + * @dev only lending pools can call this function + */ + function burnOnRedeemInternal(address account, uint256 value) internal { + _burn(account, value); + } +} diff --git a/contracts/uniswap_exchange_custom.vy b/contracts/uniswap_exchange_custom.vy new file mode 100644 index 0000000..6202ccd --- /dev/null +++ b/contracts/uniswap_exchange_custom.vy @@ -0,0 +1,502 @@ +# @title Uniswap Exchange Interface V1 +# @notice Source code found at https://github.com/uniswap +# @notice Use at your own risk + +contract Factory(): + def getExchange(token_id: uint256) -> address: constant + +contract Exchange(): + def getEthToTokenOutputPrice(tokens_bought: uint256) -> uint256(wei): constant + def ethToTokenTransferInput(min_tokens: uint256, deadline: timestamp, recipient: address) -> uint256: modifying + def ethToTokenTransferOutput(tokens_bought: uint256, deadline: timestamp, recipient: address) -> uint256(wei): modifying + +TokenPurchase: event({buyer: indexed(address), eth_sold: indexed(uint256(wei)), tokens_bought: indexed(uint256)}) +EthPurchase: event({buyer: indexed(address), tokens_sold: indexed(uint256), eth_bought: indexed(uint256(wei))}) +AddLiquidity: event({provider: indexed(address), eth_amount: indexed(uint256(wei)), token_amount: indexed(uint256)}) +RemoveLiquidity: event({provider: indexed(address), eth_amount: indexed(uint256(wei)), token_amount: indexed(uint256)}) +Transfer: event({_from: indexed(address), _to: indexed(address), _value: uint256}) +Approval: event({_owner: indexed(address), _spender: indexed(address), _value: uint256}) + +name: public(bytes32) # Uniswap V1 +symbol: public(bytes32) # UNI-V1 +decimals: public(uint256) # 18 +totalSupply: public(uint256) # total number of UNI in existence +balances: uint256[address] # UNI balance of an address +allowances: (uint256[address])[address] # UNI allowance of one address on another +token: address(ERC20) # address of the ERC20 token traded on this contract +factory: Factory # interface for the factory that created this contract +tokenId: uint256 # Custom addition - token id + +# @dev This function acts as a contract constructor which is not currently supported in contracts deployed +# using create_with_code_of(). It is called once by the factory during contract creation. +@public +def setup(token_addr: address, token_id: uint256): + assert (self.factory == ZERO_ADDRESS and self.token == ZERO_ADDRESS) and token_addr != ZERO_ADDRESS + self.factory = msg.sender + self.token = token_addr + self.tokenId = token_id + self.name = 0x556e697377617020563100000000000000000000000000000000000000000000 + self.symbol = 0x554e492d56310000000000000000000000000000000000000000000000000000 + self.decimals = 18 + +# @notice Deposit ETH and Tokens (self.token) at current ratio to mint UNI tokens. +# @dev min_liquidity does nothing when total UNI supply is 0. +# @param min_liquidity Minimum number of UNI sender will mint if total UNI supply is greater than 0. +# @param max_tokens Maximum number of tokens deposited. Deposits max amount if total UNI supply is 0. +# @param deadline Time after which this transaction can no longer be executed. +# @return The amount of UNI minted. +@public +@payable +def addLiquidity(min_liquidity: uint256, max_tokens: uint256, deadline: timestamp) -> uint256: + assert deadline > block.timestamp and (max_tokens > 0 and msg.value > 0) + total_liquidity: uint256 = self.totalSupply + if total_liquidity > 0: + assert min_liquidity > 0 + eth_reserve: uint256(wei) = self.balance - msg.value + token_reserve: uint256 = self.token.balanceOf(self) + token_amount: uint256 = msg.value * token_reserve / eth_reserve + 1 + liquidity_minted: uint256 = msg.value * total_liquidity / eth_reserve + assert max_tokens >= token_amount and liquidity_minted >= min_liquidity + self.balances[msg.sender] += liquidity_minted + self.totalSupply = total_liquidity + liquidity_minted + assert self.token.transferFrom(msg.sender, self, token_amount) + log.AddLiquidity(msg.sender, msg.value, token_amount) + log.Transfer(ZERO_ADDRESS, msg.sender, liquidity_minted) + return liquidity_minted + else: + assert (self.factory != ZERO_ADDRESS and self.token != ZERO_ADDRESS) and msg.value >= 1000000000 + assert self.factory.getExchange(self.tokenId) == self + token_amount: uint256 = max_tokens + initial_liquidity: uint256 = as_unitless_number(self.balance) + self.totalSupply = initial_liquidity + self.balances[msg.sender] = initial_liquidity + assert self.token.transferFrom(msg.sender, self, token_amount) + log.AddLiquidity(msg.sender, msg.value, token_amount) + log.Transfer(ZERO_ADDRESS, msg.sender, initial_liquidity) + return initial_liquidity + +# @dev Burn UNI tokens to withdraw ETH and Tokens at current ratio. +# @param amount Amount of UNI burned. +# @param min_eth Minimum ETH withdrawn. +# @param min_tokens Minimum Tokens withdrawn. +# @param deadline Time after which this transaction can no longer be executed. +# @return The amount of ETH and Tokens withdrawn. +@public +def removeLiquidity(amount: uint256, min_eth: uint256(wei), min_tokens: uint256, deadline: timestamp) -> (uint256(wei), uint256): + assert (amount > 0 and deadline > block.timestamp) and (min_eth > 0 and min_tokens > 0) + total_liquidity: uint256 = self.totalSupply + assert total_liquidity > 0 + token_reserve: uint256 = self.token.balanceOf(self) + eth_amount: uint256(wei) = amount * self.balance / total_liquidity + token_amount: uint256 = amount * token_reserve / total_liquidity + assert eth_amount >= min_eth and token_amount >= min_tokens + self.balances[msg.sender] -= amount + self.totalSupply = total_liquidity - amount + send(msg.sender, eth_amount) + assert self.token.transfer(msg.sender, token_amount) + log.RemoveLiquidity(msg.sender, eth_amount, token_amount) + log.Transfer(msg.sender, ZERO_ADDRESS, amount) + return eth_amount, token_amount + +# @dev Pricing function for converting between ETH and Tokens. +# @param input_amount Amount of ETH or Tokens being sold. +# @param input_reserve Amount of ETH or Tokens (input type) in exchange reserves. +# @param output_reserve Amount of ETH or Tokens (output type) in exchange reserves. +# @return Amount of ETH or Tokens bought. +@private +@constant +def getInputPrice(input_amount: uint256, input_reserve: uint256, output_reserve: uint256) -> uint256: + assert input_reserve > 0 and output_reserve > 0 + input_amount_with_fee: uint256 = input_amount * 997 + numerator: uint256 = input_amount_with_fee * output_reserve + denominator: uint256 = (input_reserve * 1000) + input_amount_with_fee + return numerator / denominator + +# @dev Pricing function for converting between ETH and Tokens. +# @param output_amount Amount of ETH or Tokens being bought. +# @param input_reserve Amount of ETH or Tokens (input type) in exchange reserves. +# @param output_reserve Amount of ETH or Tokens (output type) in exchange reserves. +# @return Amount of ETH or Tokens sold. +@private +@constant +def getOutputPrice(output_amount: uint256, input_reserve: uint256, output_reserve: uint256) -> uint256: + assert input_reserve > 0 and output_reserve > 0 + numerator: uint256 = input_reserve * output_amount * 1000 + denominator: uint256 = (output_reserve - output_amount) * 997 + return numerator / denominator + 1 + +@private +def ethToTokenInput(eth_sold: uint256(wei), min_tokens: uint256, deadline: timestamp, buyer: address, recipient: address) -> uint256: + assert deadline >= block.timestamp and (eth_sold > 0 and min_tokens > 0) + token_reserve: uint256 = self.token.balanceOf(self) + tokens_bought: uint256 = self.getInputPrice(as_unitless_number(eth_sold), as_unitless_number(self.balance - eth_sold), token_reserve) + assert tokens_bought >= min_tokens + assert self.token.transfer(recipient, tokens_bought) + log.TokenPurchase(buyer, eth_sold, tokens_bought) + return tokens_bought + +# @notice Convert ETH to Tokens. +# @dev User specifies exact input (msg.value). +# @dev User cannot specify minimum output or deadline. +@public +@payable +def __default__(): + self.ethToTokenInput(msg.value, 1, block.timestamp, msg.sender, msg.sender) + +# @notice Convert ETH to Tokens. +# @dev User specifies exact input (msg.value) and minimum output. +# @param min_tokens Minimum Tokens bought. +# @param deadline Time after which this transaction can no longer be executed. +# @return Amount of Tokens bought. +@public +@payable +def ethToTokenSwapInput(min_tokens: uint256, deadline: timestamp) -> uint256: + return self.ethToTokenInput(msg.value, min_tokens, deadline, msg.sender, msg.sender) + +# @notice Convert ETH to Tokens and transfers Tokens to recipient. +# @dev User specifies exact input (msg.value) and minimum output +# @param min_tokens Minimum Tokens bought. +# @param deadline Time after which this transaction can no longer be executed. +# @param recipient The address that receives output Tokens. +# @return Amount of Tokens bought. +@public +@payable +def ethToTokenTransferInput(min_tokens: uint256, deadline: timestamp, recipient: address) -> uint256: + assert recipient != self and recipient != ZERO_ADDRESS + return self.ethToTokenInput(msg.value, min_tokens, deadline, msg.sender, recipient) + +@private +def ethToTokenOutput(tokens_bought: uint256, max_eth: uint256(wei), deadline: timestamp, buyer: address, recipient: address) -> uint256(wei): + assert deadline >= block.timestamp and (tokens_bought > 0 and max_eth > 0) + token_reserve: uint256 = self.token.balanceOf(self) + eth_sold: uint256 = self.getOutputPrice(tokens_bought, as_unitless_number(self.balance - max_eth), token_reserve) + # Throws if eth_sold > max_eth + eth_refund: uint256(wei) = max_eth - as_wei_value(eth_sold, 'wei') + if eth_refund > 0: + send(buyer, eth_refund) + assert self.token.transfer(recipient, tokens_bought) + log.TokenPurchase(buyer, as_wei_value(eth_sold, 'wei'), tokens_bought) + return as_wei_value(eth_sold, 'wei') + +# @notice Convert ETH to Tokens. +# @dev User specifies maximum input (msg.value) and exact output. +# @param tokens_bought Amount of tokens bought. +# @param deadline Time after which this transaction can no longer be executed. +# @return Amount of ETH sold. +@public +@payable +def ethToTokenSwapOutput(tokens_bought: uint256, deadline: timestamp) -> uint256(wei): + return self.ethToTokenOutput(tokens_bought, msg.value, deadline, msg.sender, msg.sender) + +# @notice Convert ETH to Tokens and transfers Tokens to recipient. +# @dev User specifies maximum input (msg.value) and exact output. +# @param tokens_bought Amount of tokens bought. +# @param deadline Time after which this transaction can no longer be executed. +# @param recipient The address that receives output Tokens. +# @return Amount of ETH sold. +@public +@payable +def ethToTokenTransferOutput(tokens_bought: uint256, deadline: timestamp, recipient: address) -> uint256(wei): + assert recipient != self and recipient != ZERO_ADDRESS + return self.ethToTokenOutput(tokens_bought, msg.value, deadline, msg.sender, recipient) + +@private +def tokenToEthInput(tokens_sold: uint256, min_eth: uint256(wei), deadline: timestamp, buyer: address, recipient: address) -> uint256(wei): + + assert deadline >= block.timestamp and (tokens_sold > 0 and min_eth > 0) + token_reserve: uint256 = self.token.balanceOf(self) + eth_bought: uint256 = self.getInputPrice(tokens_sold, token_reserve, as_unitless_number(self.balance)) + wei_bought: uint256(wei) = as_wei_value(eth_bought, 'wei') + assert wei_bought >= min_eth + send(recipient, wei_bought) + return 0 + """ + assert self.token.transferFrom(buyer, self, tokens_sold) + log.EthPurchase(buyer, tokens_sold, wei_bought) + return wei_bought + """ + + +# @notice Convert Tokens to ETH. +# @dev User specifies exact input and minimum output. +# @param tokens_sold Amount of Tokens sold. +# @param min_eth Minimum ETH purchased. +# @param deadline Time after which this transaction can no longer be executed. +# @return Amount of ETH bought. +@public +def tokenToEthSwapInput(tokens_sold: uint256, min_eth: uint256(wei), deadline: timestamp) -> uint256(wei): + return self.tokenToEthInput(tokens_sold, min_eth, deadline, msg.sender, msg.sender) + +# @notice Convert Tokens to ETH and transfers ETH to recipient. +# @dev User specifies exact input and minimum output. +# @param tokens_sold Amount of Tokens sold. +# @param min_eth Minimum ETH purchased. +# @param deadline Time after which this transaction can no longer be executed. +# @param recipient The address that receives output ETH. +# @return Amount of ETH bought. +@public +def tokenToEthTransferInput(tokens_sold: uint256, min_eth: uint256(wei), deadline: timestamp, recipient: address) -> uint256(wei): + assert recipient != self and recipient != ZERO_ADDRESS + return self.tokenToEthInput(tokens_sold, min_eth, deadline, msg.sender, recipient) + +@private +def tokenToEthOutput(eth_bought: uint256(wei), max_tokens: uint256, deadline: timestamp, buyer: address, recipient: address) -> uint256: + assert deadline >= block.timestamp and eth_bought > 0 + token_reserve: uint256 = self.token.balanceOf(self) + tokens_sold: uint256 = self.getOutputPrice(as_unitless_number(eth_bought), token_reserve, as_unitless_number(self.balance)) + # tokens sold is always > 0 + assert max_tokens >= tokens_sold + send(recipient, eth_bought) + assert self.token.transferFrom(buyer, self, tokens_sold) + log.EthPurchase(buyer, tokens_sold, eth_bought) + return tokens_sold + +# @notice Convert Tokens to ETH. +# @dev User specifies maximum input and exact output. +# @param eth_bought Amount of ETH purchased. +# @param max_tokens Maximum Tokens sold. +# @param deadline Time after which this transaction can no longer be executed. +# @return Amount of Tokens sold. +@public +def tokenToEthSwapOutput(eth_bought: uint256(wei), max_tokens: uint256, deadline: timestamp) -> uint256: + return self.tokenToEthOutput(eth_bought, max_tokens, deadline, msg.sender, msg.sender) + +# @notice Convert Tokens to ETH and transfers ETH to recipient. +# @dev User specifies maximum input and exact output. +# @param eth_bought Amount of ETH purchased. +# @param max_tokens Maximum Tokens sold. +# @param deadline Time after which this transaction can no longer be executed. +# @param recipient The address that receives output ETH. +# @return Amount of Tokens sold. +@public +def tokenToEthTransferOutput(eth_bought: uint256(wei), max_tokens: uint256, deadline: timestamp, recipient: address) -> uint256: + assert recipient != self and recipient != ZERO_ADDRESS + return self.tokenToEthOutput(eth_bought, max_tokens, deadline, msg.sender, recipient) + +@private +def tokenToTokenInput(tokens_sold: uint256, min_tokens_bought: uint256, min_eth_bought: uint256(wei), deadline: timestamp, buyer: address, recipient: address, exchange_addr: address) -> uint256: + assert (deadline >= block.timestamp and tokens_sold > 0) and (min_tokens_bought > 0 and min_eth_bought > 0) + assert exchange_addr != self and exchange_addr != ZERO_ADDRESS + token_reserve: uint256 = self.token.balanceOf(self) + eth_bought: uint256 = self.getInputPrice(tokens_sold, token_reserve, as_unitless_number(self.balance)) + wei_bought: uint256(wei) = as_wei_value(eth_bought, 'wei') + assert wei_bought >= min_eth_bought + assert self.token.transferFrom(buyer, self, tokens_sold) + tokens_bought: uint256 = Exchange(exchange_addr).ethToTokenTransferInput(min_tokens_bought, deadline, recipient, value=wei_bought) + log.EthPurchase(buyer, tokens_sold, wei_bought) + return tokens_bought + +# @notice Convert Tokens (self.token) to Tokens (token_addr). +# @dev User specifies exact input and minimum output. +# @param tokens_sold Amount of Tokens sold. +# @param min_tokens_bought Minimum Tokens (token_addr) purchased. +# @param min_eth_bought Minimum ETH purchased as intermediary. +# @param deadline Time after which this transaction can no longer be executed. +# @param token_addr The address of the token being purchased. +# @return Amount of Tokens (token_addr) bought. +@public +def tokenToTokenSwapInput(tokens_sold: uint256, min_tokens_bought: uint256, min_eth_bought: uint256(wei), deadline: timestamp, token_addr: uint256) -> uint256: + exchange_addr: address = self.factory.getExchange(token_addr) + return self.tokenToTokenInput(tokens_sold, min_tokens_bought, min_eth_bought, deadline, msg.sender, msg.sender, exchange_addr) + +# @notice Convert Tokens (self.token) to Tokens (token_addr) and transfers +# Tokens (token_addr) to recipient. +# @dev User specifies exact input and minimum output. +# @param tokens_sold Amount of Tokens sold. +# @param min_tokens_bought Minimum Tokens (token_addr) purchased. +# @param min_eth_bought Minimum ETH purchased as intermediary. +# @param deadline Time after which this transaction can no longer be executed. +# @param recipient The address that receives output ETH. +# @param token_addr The address of the token being purchased. +# @return Amount of Tokens (token_addr) bought. +@public +def tokenToTokenTransferInput(tokens_sold: uint256, min_tokens_bought: uint256, min_eth_bought: uint256(wei), deadline: timestamp, recipient: address, token_addr: uint256) -> uint256: + exchange_addr: address = self.factory.getExchange(token_addr) + return self.tokenToTokenInput(tokens_sold, min_tokens_bought, min_eth_bought, deadline, msg.sender, recipient, exchange_addr) + +@private +def tokenToTokenOutput(tokens_bought: uint256, max_tokens_sold: uint256, max_eth_sold: uint256(wei), deadline: timestamp, buyer: address, recipient: address, exchange_addr: address) -> uint256: + assert deadline >= block.timestamp and (tokens_bought > 0 and max_eth_sold > 0) + assert exchange_addr != self and exchange_addr != ZERO_ADDRESS + eth_bought: uint256(wei) = Exchange(exchange_addr).getEthToTokenOutputPrice(tokens_bought) + token_reserve: uint256 = self.token.balanceOf(self) + tokens_sold: uint256 = self.getOutputPrice(as_unitless_number(eth_bought), token_reserve, as_unitless_number(self.balance)) + # tokens sold is always > 0 + assert max_tokens_sold >= tokens_sold and max_eth_sold >= eth_bought + assert self.token.transferFrom(buyer, self, tokens_sold) + eth_sold: uint256(wei) = Exchange(exchange_addr).ethToTokenTransferOutput(tokens_bought, deadline, recipient, value=eth_bought) + log.EthPurchase(buyer, tokens_sold, eth_bought) + return tokens_sold + +# @notice Convert Tokens (self.token) to Tokens (token_addr). +# @dev User specifies maximum input and exact output. +# @param tokens_bought Amount of Tokens (token_addr) bought. +# @param max_tokens_sold Maximum Tokens (self.token) sold. +# @param max_eth_sold Maximum ETH purchased as intermediary. +# @param deadline Time after which this transaction can no longer be executed. +# @param token_addr The address of the token being purchased. +# @return Amount of Tokens (self.token) sold. +@public +def tokenToTokenSwapOutput(tokens_bought: uint256, max_tokens_sold: uint256, max_eth_sold: uint256(wei), deadline: timestamp, token_addr: uint256) -> uint256: + exchange_addr: address = self.factory.getExchange(token_addr) + return self.tokenToTokenOutput(tokens_bought, max_tokens_sold, max_eth_sold, deadline, msg.sender, msg.sender, exchange_addr) + +# @notice Convert Tokens (self.token) to Tokens (token_addr) and transfers +# Tokens (token_addr) to recipient. +# @dev User specifies maximum input and exact output. +# @param tokens_bought Amount of Tokens (token_addr) bought. +# @param max_tokens_sold Maximum Tokens (self.token) sold. +# @param max_eth_sold Maximum ETH purchased as intermediary. +# @param deadline Time after which this transaction can no longer be executed. +# @param recipient The address that receives output ETH. +# @param token_addr The address of the token being purchased. +# @return Amount of Tokens (self.token) sold. +@public +def tokenToTokenTransferOutput(tokens_bought: uint256, max_tokens_sold: uint256, max_eth_sold: uint256(wei), deadline: timestamp, recipient: address, token_addr: uint256) -> uint256: + exchange_addr: address = self.factory.getExchange(token_addr) + return self.tokenToTokenOutput(tokens_bought, max_tokens_sold, max_eth_sold, deadline, msg.sender, recipient, exchange_addr) + +# @notice Convert Tokens (self.token) to Tokens (exchange_addr.token). +# @dev Allows trades through contracts that were not deployed from the same factory. +# @dev User specifies exact input and minimum output. +# @param tokens_sold Amount of Tokens sold. +# @param min_tokens_bought Minimum Tokens (token_addr) purchased. +# @param min_eth_bought Minimum ETH purchased as intermediary. +# @param deadline Time after which this transaction can no longer be executed. +# @param exchange_addr The address of the exchange for the token being purchased. +# @return Amount of Tokens (exchange_addr.token) bought. +@public +def tokenToExchangeSwapInput(tokens_sold: uint256, min_tokens_bought: uint256, min_eth_bought: uint256(wei), deadline: timestamp, exchange_addr: address) -> uint256: + return self.tokenToTokenInput(tokens_sold, min_tokens_bought, min_eth_bought, deadline, msg.sender, msg.sender, exchange_addr) + +# @notice Convert Tokens (self.token) to Tokens (exchange_addr.token) and transfers +# Tokens (exchange_addr.token) to recipient. +# @dev Allows trades through contracts that were not deployed from the same factory. +# @dev User specifies exact input and minimum output. +# @param tokens_sold Amount of Tokens sold. +# @param min_tokens_bought Minimum Tokens (token_addr) purchased. +# @param min_eth_bought Minimum ETH purchased as intermediary. +# @param deadline Time after which this transaction can no longer be executed. +# @param recipient The address that receives output ETH. +# @param exchange_addr The address of the exchange for the token being purchased. +# @return Amount of Tokens (exchange_addr.token) bought. +@public +def tokenToExchangeTransferInput(tokens_sold: uint256, min_tokens_bought: uint256, min_eth_bought: uint256(wei), deadline: timestamp, recipient: address, exchange_addr: address) -> uint256: + assert recipient != self + return self.tokenToTokenInput(tokens_sold, min_tokens_bought, min_eth_bought, deadline, msg.sender, recipient, exchange_addr) + +# @notice Convert Tokens (self.token) to Tokens (exchange_addr.token). +# @dev Allows trades through contracts that were not deployed from the same factory. +# @dev User specifies maximum input and exact output. +# @param tokens_bought Amount of Tokens (token_addr) bought. +# @param max_tokens_sold Maximum Tokens (self.token) sold. +# @param max_eth_sold Maximum ETH purchased as intermediary. +# @param deadline Time after which this transaction can no longer be executed. +# @param exchange_addr The address of the exchange for the token being purchased. +# @return Amount of Tokens (self.token) sold. +@public +def tokenToExchangeSwapOutput(tokens_bought: uint256, max_tokens_sold: uint256, max_eth_sold: uint256(wei), deadline: timestamp, exchange_addr: address) -> uint256: + return self.tokenToTokenOutput(tokens_bought, max_tokens_sold, max_eth_sold, deadline, msg.sender, msg.sender, exchange_addr) + +# @notice Convert Tokens (self.token) to Tokens (exchange_addr.token) and transfers +# Tokens (exchange_addr.token) to recipient. +# @dev Allows trades through contracts that were not deployed from the same factory. +# @dev User specifies maximum input and exact output. +# @param tokens_bought Amount of Tokens (token_addr) bought. +# @param max_tokens_sold Maximum Tokens (self.token) sold. +# @param max_eth_sold Maximum ETH purchased as intermediary. +# @param deadline Time after which this transaction can no longer be executed. +# @param recipient The address that receives output ETH. +# @param token_addr The address of the token being purchased. +# @return Amount of Tokens (self.token) sold. +@public +def tokenToExchangeTransferOutput(tokens_bought: uint256, max_tokens_sold: uint256, max_eth_sold: uint256(wei), deadline: timestamp, recipient: address, exchange_addr: address) -> uint256: + assert recipient != self + return self.tokenToTokenOutput(tokens_bought, max_tokens_sold, max_eth_sold, deadline, msg.sender, recipient, exchange_addr) + +# @notice Public price function for ETH to Token trades with an exact input. +# @param eth_sold Amount of ETH sold. +# @return Amount of Tokens that can be bought with input ETH. +@public +@constant +def getEthToTokenInputPrice(eth_sold: uint256(wei)) -> uint256: + assert eth_sold > 0 + token_reserve: uint256 = self.token.balanceOf(self) + return self.getInputPrice(as_unitless_number(eth_sold), as_unitless_number(self.balance), token_reserve) + +# @notice Public price function for ETH to Token trades with an exact output. +# @param tokens_bought Amount of Tokens bought. +# @return Amount of ETH needed to buy output Tokens. +@public +@constant +def getEthToTokenOutputPrice(tokens_bought: uint256) -> uint256(wei): + assert tokens_bought > 0 + token_reserve: uint256 = self.token.balanceOf(self) + eth_sold: uint256 = self.getOutputPrice(tokens_bought, as_unitless_number(self.balance), token_reserve) + return as_wei_value(eth_sold, 'wei') + +# @notice Public price function for Token to ETH trades with an exact input. +# @param tokens_sold Amount of Tokens sold. +# @return Amount of ETH that can be bought with input Tokens. +@public +@constant +def getTokenToEthInputPrice(tokens_sold: uint256) -> uint256(wei): + assert tokens_sold > 0 + token_reserve: uint256 = self.token.balanceOf(self) + eth_bought: uint256 = self.getInputPrice(tokens_sold, token_reserve, as_unitless_number(self.balance)) + return as_wei_value(eth_bought, 'wei') + +# @notice Public price function for Token to ETH trades with an exact output. +# @param eth_bought Amount of output ETH. +# @return Amount of Tokens needed to buy output ETH. +@public +@constant +def getTokenToEthOutputPrice(eth_bought: uint256(wei)) -> uint256: + assert eth_bought > 0 + token_reserve: uint256 = self.token.balanceOf(self) + return self.getOutputPrice(as_unitless_number(eth_bought), token_reserve, as_unitless_number(self.balance)) + +# @return Address of Token that is sold on this exchange. +@public +@constant +def tokenAddress() -> address: + return self.token + +# @return Address of factory that created this exchange. +@public +@constant +def factoryAddress() -> address(Factory): + return self.factory + +# ERC20 compatibility for exchange liquidity modified from +# https://github.com/ethereum/vyper/blob/master/examples/tokens/ERC20.vy +@public +@constant +def balanceOf(_owner : address) -> uint256: + return self.balances[_owner] + +@public +def transfer(_to : address, _value : uint256) -> bool: + self.balances[msg.sender] -= _value + self.balances[_to] += _value + log.Transfer(msg.sender, _to, _value) + return True + +@public +def transferFrom(_from : address, _to : address, _value : uint256) -> bool: + self.balances[_from] -= _value + self.balances[_to] += _value + self.allowances[_from][msg.sender] -= _value + log.Transfer(_from, _to, _value) + return True + +@public +def approve(_spender : address, _value : uint256) -> bool: + self.allowances[msg.sender][_spender] = _value + log.Approval(msg.sender, _spender, _value) + return True + +@public +@constant +def allowance(_owner : address, _spender : address) -> uint256: + return self.allowances[_owner][_spender] diff --git a/contracts/uniswap_factory_custom.vy b/contracts/uniswap_factory_custom.vy new file mode 100644 index 0000000..a32a783 --- /dev/null +++ b/contracts/uniswap_factory_custom.vy @@ -0,0 +1,46 @@ +contract Exchange(): + def setup(token_addr: address, token_id: uint256): modifying + +NewExchange: event({token: indexed(address), exchange: indexed(address)}) + +exchangeTemplate: public(address) +tokenCount: public(uint256) +token_to_exchange: address[uint256] +exchange_to_token: address[address] +id_to_token: address[uint256] + +@public +def initializeFactory(template: address): + assert self.exchangeTemplate == ZERO_ADDRESS + assert template != ZERO_ADDRESS + self.exchangeTemplate = template + +@public +def createExchange(token: address) -> address: + assert token != ZERO_ADDRESS + assert self.exchangeTemplate != ZERO_ADDRESS + # assert self.token_to_exchange[token] == ZERO_ADDRESS + exchange: address = create_with_code_of(self.exchangeTemplate) + Exchange(exchange).setup(token, self.tokenCount) + self.token_to_exchange[self.tokenCount] = exchange # Change to index by uint256 instead of token address + self.exchange_to_token[exchange] = token + token_id: uint256 = self.tokenCount + 1 + self.tokenCount = token_id + self.id_to_token[token_id] = token + log.NewExchange(token, exchange) + return exchange + +@public +@constant +def getExchange(token: uint256) -> address: + return self.token_to_exchange[token] + +@public +@constant +def getToken(exchange: address) -> address: + return self.exchange_to_token[exchange] + +@public +@constant +def getTokenWithId(token_id: uint256) -> address: + return self.id_to_token[token_id] diff --git a/migrations/2_deploy_contracts.js b/migrations/2_deploy_contracts.js index 0436821..ae125e3 100644 --- a/migrations/2_deploy_contracts.js +++ b/migrations/2_deploy_contracts.js @@ -2,10 +2,20 @@ var RinkebyArbContract = artifacts.require("./RinkebyArbContract.sol"); var KyberUniArbContract = artifacts.require("./KyberUniArbContract.sol"); var ERC20Token = artifacts.require("./ERC20Token.sol"); var UniswapExchange = artifacts.require("./UniswapExchange.sol"); +var uniswap_factory_custom = artifacts.require("./uniswap_factory_custom.sol"); +var uniswap_exchange_custom = artifacts.require("./uniswap_exchange_custom.sol"); +var FlashLoanReceiverExample = artifacts.require("./FlashLoanReceiverExample.sol"); module.exports = function(deployer) { + /* deployer.deploy(RinkebyArbContract); deployer.deploy(KyberUniArbContract); deployer.deploy(ERC20Token); deployer.deploy(UniswapExchange); + */ + //deployer.deploy(FlashLoanReceiverExample, '0x9C6C63aA0cD4557d7aE6D9306C06C093A2e35408'); + // deployer.deploy(FlashLoanReceiverExample, '0x9C6C63aA0cD4557d7aE6D9306C06C093A2e35408'); + // deployer.deploy(FlashLoanReceiverExample, '0x9C6C63aA0cD4557d7aE6D9306C06C093A2e35408'); + deployer.deploy(uniswap_factory_custom); + deployer.deploy(uniswap_exchange_custom); }; diff --git a/package.json b/package.json index ee04635..4db8505 100644 --- a/package.json +++ b/package.json @@ -4,6 +4,7 @@ "@uniswap/sdk": "^1.0.0-beta.4", "dotenv": "^8.1.0", "ethereumjs-tx": "^2.1.1", + "openzeppelin-solidity": "^2.4.0", "table": "^5.4.6", "truffle-assertions": "^0.9.1", "truffle-hdwallet-provider": "^1.0.17", diff --git a/test/testAave.js b/test/testAave.js new file mode 100644 index 0000000..916b039 --- /dev/null +++ b/test/testAave.js @@ -0,0 +1,136 @@ +const Web3 = require("web3"); +const fs = require('fs'); +const LendingPoolAddressesProvider = JSON.parse(fs.readFileSync("client/src/contracts/LendingPoolAddressesProvider.json")); +const LendingPool = JSON.parse(fs.readFileSync("client/src/contracts/LendingPool.json")); +const UniSwapFactory = JSON.parse(fs.readFileSync("./client/src/contracts/uniswap_factory.json")); +const ERC20Token = JSON.parse(fs.readFileSync("./client/src/contracts/ERC20Token.json")); +const FlashLoanReceiverExample = JSON.parse(fs.readFileSync("./client/src/contracts/FlashLoanReceiverExample.json")); +const {table} = require('table'); +const Util = require("../client/src/utils/utils"); +require('dotenv').config(); + +const TRADER_ACCOUNT_ADDR = '0xeE398666cA860DFb7390b5D73EE927e9Fb41a60A'; +const UNISWAP_FACTORY_ADDR = '0xD3E51Ef092B2845f10401a0159B2B96e8B6c3D30'; +const FLASH_ADDR = '0xb544f44905dBc94e096576898debAD22b6A2F3C1'; + +const web3 = new Web3(new Web3.providers.HttpProvider(process.env.INFURAKOVAN)); + +const UniSwapFactoryInstance = new web3.eth.Contract(UniSwapFactory.abi, UNISWAP_FACTORY_ADDR); +const FlashLoanReceiverExampleInstance = new web3.eth.Contract(FlashLoanReceiverExample.abi, FLASH_ADDR); + +async function run(){ + + /// Retrieve the LendingPool address + const LendingPoolAddressesProviderInstance = new web3.eth.Contract(LendingPoolAddressesProvider.abi, '0x9C6C63aA0cD4557d7aE6D9306C06C093A2e35408'); + const lendingPool = await LendingPoolAddressesProviderInstance.methods.getLendingPool().call(); + + const LendingPoolInstance = new web3.eth.Contract(LendingPool.abi, lendingPool); + + var receiverContract = '0xb544f44905dBc94e096576898debAD22b6A2F3C1'; // My contract that implements the IFLashLoanReceiver interface + // var reserveAddr = '0x804C0B38593796bD44126102C8b5e827Cf389D80'; // Should be Eth reserve address?? + var reserveAddr = '0xFf795577d9AC8bD7D90Ee22b6C1703490b6512FD'; + var amountWei = web3.utils.toWei('0.001', 'ether'); + + const reserveData = await LendingPoolInstance.methods.getReserveData(reserveAddr).call(); + console.log('Reserve Data: '); + console.log(reserveData); // This shows >9Eth available. + + console.log('FlashLoan'); + console.log('Creating tx'); + const tx = LendingPoolInstance.methods.flashLoan(receiverContract, reserveAddr, amountWei); + console.log('Sending tx'); + var rx = await Util.sendTransaction(web3, tx, TRADER_ACCOUNT_ADDR, process.env.PRIVATEKEY, lendingPool); + console.log(rx) + + // Revert - 'Invalid liquidity available' + // https://kovan.etherscan.io/tx/0x03f2084a9177cb1f36a1e034099ddc1ae2bcefde3b2c0ddb5c7f6b07a1df58a5 + console.log('Byeee') +} + +async function runOld(){ + + var amountWei = web3.utils.toWei('0.001', 'ether'); + var feeAmountWei = web3.utils.toWei('0.00001', 'ether'); + + console.log('Creating tx'); + const tx = FlashLoanReceiverExampleInstance.methods.executeOperation(reserveAddr, amountWei, feeAmountWei); + console.log('Sending tx'); + var rx = await Util.sendTransaction(web3, tx, TRADER_ACCOUNT_ADDR, process.env.PRIVATEKEY, '0xb544f44905dBc94e096576898debAD22b6A2F3C1'); + console.log(rx) + return; + + const LendingPoolAddressesProviderInstance = new web3.eth.Contract(LendingPoolAddressesProvider.abi, '0x9C6C63aA0cD4557d7aE6D9306C06C093A2e35408'); + + const lendingPool = await LendingPoolAddressesProviderInstance.methods.getLendingPool().call(); + + console.log(lendingPool) + + const LendingPoolInstance = new web3.eth.Contract(LendingPool.abi, lendingPool); + + const reserves = await LendingPoolInstance.methods.getReserves().call(); + + console.log('Reserves:'); + console.log(reserves); + + // 0x804C0B38593796bD44126102C8b5e827Cf389D80 // Eth Reserve Address + + for(var i = 0;i < reserves.length;i++){ + console.log(reserves[i]) + daiExchangeAddr = await UniSwapFactoryInstance.methods.getExchange(reserves[i]).call(); + console.log(daiExchangeAddr) + var TokenInstance = new web3.eth.Contract(ERC20Token.abi, reserves[i]); + // console.log(daiExchangeAddr); + await PoolInfo(daiExchangeAddr, TokenInstance); + } + + console.log('Byeee'); +} + +async function runOld(){ + /* + LendingPoolAddressesProvider provider = await LendingPoolAddressesProvider('0x9C6C63aA0cD4557d7aE6D9306C06C093A2e35408'); + LendingPool lendingPool = await LendingPool(provider.getLendingPool()); + + var configData = lendingPool.getReserveConfigurationData(); + console.log('Config Data:') + console.log(configData) + + var reserveData = lendingPool.getReserveData(); + console.log('Reserve Data:') + console.log(reserveData) + var reserves = lendingPool.getReserves(); + console.log('Reserves:') + console.log(reserves) + return; + /// Input variables + + // the receiver is a contract that implements the IFLashLoanReceiver interface + address receiver = //contract_address; + address daiAddress = "0x89d24a6b4ccb1b6faa2625fe562bdd9a23260359"; + uint256 amount = 1000 * 1e18; + + /// flashLoan method call + lendingPool.flashLoan(receiver, daiAddress, amount); + */ +} + +async function PoolInfo(ExchangeAddr, TokenInstance){ + var leaderExEthBalanceWei = await web3.eth.getBalance(ExchangeAddr); + var leaderExTokenBalanceWei = await TokenInstance.methods.balanceOf(ExchangeAddr).call(); + + var leaderSpotPrices = await Util.getSpotPrices(leaderExEthBalanceWei, leaderExTokenBalanceWei, false); + + data = [ + ['Pool', 'Leader Token'], + ['Eth Pool', web3.utils.fromWei(leaderExEthBalanceWei, 'ether')], + ['Token Pool', web3.utils.fromWei(leaderExTokenBalanceWei, 'ether')], + ['Eth Spot Price', leaderSpotPrices.ethPrice.toString(10)], + ['Token Spot Price', leaderSpotPrices.tokenPrice.toString(10)] + ]; + + output = table(data); + console.log(output); + return; +} + +run(); diff --git a/test/testKyber.js b/test/testKyber.js new file mode 100644 index 0000000..94e1b21 --- /dev/null +++ b/test/testKyber.js @@ -0,0 +1,70 @@ +// Useful Kyber info: +// https://developer.kyber.network/docs/Integrations-Web3Guide/ +// https://medium.com/quiknode/building-with-kyber-network-be596863772d +const fs = require('fs'); +let Web3 = require("web3"); +const BigNumber = require('bignumber.js'); +let KyberUniArbContract = JSON.parse(fs.readFileSync("client/src/contracts/KyberUniArbContract.json")); +let ERC20Token = JSON.parse(fs.readFileSync("client/src/contracts/ERC20Token.json")); +const Util = require("../client/src/utils/utils"); +const abis = JSON.parse(fs.readFileSync("./ABIs.json")); // Various Uniswap/Kyber ABI details. + +require('dotenv').config(); + +const TRADER_ACCOUNT_ADDR = '0xeE398666cA860DFb7390b5D73EE927e9Fb41a60A';; +// Token Details - Assuming initial trade token is Eth +const SRC_TOKEN = "ETH"; +const SRC_TOKEN_ADDRESS = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"; +const SRC_DECIMALS = 18; +const DST_DECIMALS = 12; + +BigNumber.set({ DECIMAL_PLACES: 18}); + +const web3 = new Web3(new Web3.providers.HttpProvider(process.env.INFURAKOVAN)); + +const DST_TOKEN = "DAI"; +const DST_TOKEN_ADDRESS = '0xC4375B7De8af5a38a93548eb8453a498222C4fF2' // DAI +const KYBER_NETWORK_PROXY_ADDRESS = "0x692f391bCc85cefCe8C237C01e1f636BbD70EA4D"; // Kovan + +// Starting Qty of Eth to trade +var TRADE_QTY_ETH = 0.001; +const TRADE_QTY_WEI = web3.utils.toWei(TRADE_QTY_ETH.toString(), 'ether'); + +// Get the KyberNetworkContract instances +const KYBER_NETWORK_PROXY_CONTRACT = new web3.eth.Contract(abis.KYBER_NETWORK_PROXY_ABI, KYBER_NETWORK_PROXY_ADDRESS); + +const DaiTokenInstance = new web3.eth.Contract(ERC20Token.abi, DST_TOKEN_ADDRESS); + +const privateKey = Buffer.from(process.env.PRIVATEKEY, 'hex',); + +async function getTradeBalances(){ + var daiBalanceWei = await DaiTokenInstance.methods.balanceOf(TRADER_ACCOUNT_ADDR).call(); + var ethBalance = await web3.eth.getBalance(TRADER_ACCOUNT_ADDR); + + console.log('Eth Balance: ' + web3.utils.fromWei(ethBalance.toString(10), 'ether')); + console.log('Dai Balance: ' + web3.utils.fromWei(daiBalanceWei.toString(10), 'ether')); +} + +async function run(){ + + await getTradeBalances(); + + var kyberRate = await KYBER_NETWORK_PROXY_CONTRACT.methods.getExpectedRate(SRC_TOKEN_ADDRESS, DST_TOKEN_ADDRESS, TRADE_QTY_WEI).call(); + var kyberRateEther = web3.utils.fromWei(kyberRate.expectedRate, 'ether'); + console.log('Kyber (Eth -> ' + DST_TOKEN + '): ' + kyberRateEther); + + var tokenTradeQtyEth = TRADE_QTY_ETH * parseFloat(kyberRateEther); + var tokenTradeQtyWei = web3.utils.toWei(tokenTradeQtyEth.toString(), 'ether'); + var tokenTradeQtyWeiBn = web3.utils.toBN(tokenTradeQtyWei); + + console.log('\nTrading - Kyber: ' + TRADE_QTY_ETH.toString() + 'Eth swapped for: ' + tokenTradeQtyEth + 'DAI'); + + // srcTokenAddr, srcAmount, destTokenAddr, maxDestAmount, minConversionRate, walletId + var tx = await KYBER_NETWORK_PROXY_CONTRACT.methods.trade(SRC_TOKEN_ADDRESS, TRADE_QTY_WEI, DST_TOKEN_ADDRESS, TRADER_ACCOUNT_ADDR, tokenTradeQtyWei, kyberRate.expectedRate, '0x0000000000000000000000000000000000000000'); + + await Util.sendTransactionWithValue(web3, tx, TRADER_ACCOUNT_ADDR, process.env.PRIVATEKEY, KYBER_NETWORK_PROXY_ADDRESS, TRADE_QTY_WEI); // Would be good to get return value here as its should be actual amount of tokens bought + + await getTradeBalances(); +} +run(); +//checkCompleteTrade() diff --git a/testScriptsUniswap.js b/testScriptsUniswap.js deleted file mode 100644 index bef573d..0000000 --- a/testScriptsUniswap.js +++ /dev/null @@ -1,310 +0,0 @@ -// const RinkebyArbContract = require("client/src/contracts/RinkebyArbContract.json"); -const fs = require('fs'); -const Tx = require('ethereumjs-tx').Transaction; -let RinkebyArbContract = JSON.parse(fs.readFileSync("client/src/contracts/RinkebyArbContract.json")); -let TokenContract = JSON.parse(fs.readFileSync("client/src/contracts/GLDToken.json")); -let Web3 = require("web3"); -const BigNumber = require('bignumber.js'); -const UniSwap = require('@uniswap/sdk'); -require('dotenv').config(); - -var abi = '[{"name":"NewExchange","inputs":[{"type":"address","name":"token","indexed":true},{"type":"address","name":"exchange","indexed":true}],"anonymous":false,"type":"event"},{"name":"initializeFactory","outputs":[],"inputs":[{"type":"address","name":"template"}],"constant":false,"payable":false,"type":"function","gas":35725},{"name":"createExchange","outputs":[{"type":"address","name":"out"}],"inputs":[{"type":"address","name":"token"}],"constant":false,"payable":false,"type":"function","gas":187911},{"name":"getExchange","outputs":[{"type":"address","name":"out"}],"inputs":[{"type":"address","name":"token"}],"constant":true,"payable":false,"type":"function","gas":715},{"name":"getToken","outputs":[{"type":"address","name":"out"}],"inputs":[{"type":"address","name":"exchange"}],"constant":true,"payable":false,"type":"function","gas":745},{"name":"getTokenWithId","outputs":[{"type":"address","name":"out"}],"inputs":[{"type":"uint256","name":"token_id"}],"constant":true,"payable":false,"type":"function","gas":736},{"name":"exchangeTemplate","outputs":[{"type":"address","name":"out"}],"inputs":[],"constant":true,"payable":false,"type":"function","gas":633},{"name":"tokenCount","outputs":[{"type":"uint256","name":"out"}],"inputs":[],"constant":true,"payable":false,"type":"function","gas":663}]' - -var exchangeAbi = '[{"name": "TokenPurchase", "inputs": [{"type": "address", "name": "buyer", "indexed": true}, {"type": "uint256", "name": "eth_sold", "indexed": true}, {"type": "uint256", "name": "tokens_bought", "indexed": true}], "anonymous": false, "type": "event"}, {"name": "EthPurchase", "inputs": [{"type": "address", "name": "buyer", "indexed": true}, {"type": "uint256", "name": "tokens_sold", "indexed": true}, {"type": "uint256", "name": "eth_bought", "indexed": true}], "anonymous": false, "type": "event"}, {"name": "AddLiquidity", "inputs": [{"type": "address", "name": "provider", "indexed": true}, {"type": "uint256", "name": "eth_amount", "indexed": true}, {"type": "uint256", "name": "token_amount", "indexed": true}], "anonymous": false, "type": "event"}, {"name": "RemoveLiquidity", "inputs": [{"type": "address", "name": "provider", "indexed": true}, {"type": "uint256", "name": "eth_amount", "indexed": true}, {"type": "uint256", "name": "token_amount", "indexed": true}], "anonymous": false, "type": "event"}, {"name": "Transfer", "inputs": [{"type": "address", "name": "_from", "indexed": true}, {"type": "address", "name": "_to", "indexed": true}, {"type": "uint256", "name": "_value", "indexed": false}], "anonymous": false, "type": "event"}, {"name": "Approval", "inputs": [{"type": "address", "name": "_owner", "indexed": true}, {"type": "address", "name": "_spender", "indexed": true}, {"type": "uint256", "name": "_value", "indexed": false}], "anonymous": false, "type": "event"}, {"name": "setup", "outputs": [], "inputs": [{"type": "address", "name": "token_addr"}], "constant": false, "payable": false, "type": "function", "gas": 175875}, {"name": "addLiquidity", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "min_liquidity"}, {"type": "uint256", "name": "max_tokens"}, {"type": "uint256", "name": "deadline"}], "constant": false, "payable": true, "type": "function", "gas": 82605}, {"name": "removeLiquidity", "outputs": [{"type": "uint256", "name": "out"}, {"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "amount"}, {"type": "uint256", "name": "min_eth"}, {"type": "uint256", "name": "min_tokens"}, {"type": "uint256", "name": "deadline"}], "constant": false, "payable": false, "type": "function", "gas": 116814}, {"name": "__default__", "outputs": [], "inputs": [], "constant": false, "payable": true, "type": "function"}, {"name": "ethToTokenSwapInput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "min_tokens"}, {"type": "uint256", "name": "deadline"}], "constant": false, "payable": true, "type": "function", "gas": 12757}, {"name": "ethToTokenTransferInput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "min_tokens"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "recipient"}], "constant": false, "payable": true, "type": "function", "gas": 12965}, {"name": "ethToTokenSwapOutput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_bought"}, {"type": "uint256", "name": "deadline"}], "constant": false, "payable": true, "type": "function", "gas": 50463}, {"name": "ethToTokenTransferOutput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_bought"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "recipient"}], "constant": false, "payable": true, "type": "function", "gas": 50671}, {"name": "tokenToEthSwapInput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_sold"}, {"type": "uint256", "name": "min_eth"}, {"type": "uint256", "name": "deadline"}], "constant": false, "payable": false, "type": "function", "gas": 47503}, {"name": "tokenToEthTransferInput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_sold"}, {"type": "uint256", "name": "min_eth"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "recipient"}], "constant": false, "payable": false, "type": "function", "gas": 47712}, {"name": "tokenToEthSwapOutput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "eth_bought"}, {"type": "uint256", "name": "max_tokens"}, {"type": "uint256", "name": "deadline"}], "constant": false, "payable": false, "type": "function", "gas": 50175}, {"name": "tokenToEthTransferOutput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "eth_bought"}, {"type": "uint256", "name": "max_tokens"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "recipient"}], "constant": false, "payable": false, "type": "function", "gas": 50384}, {"name": "tokenToTokenSwapInput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_sold"}, {"type": "uint256", "name": "min_tokens_bought"}, {"type": "uint256", "name": "min_eth_bought"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "token_addr"}], "constant": false, "payable": false, "type": "function", "gas": 51007}, {"name": "tokenToTokenTransferInput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_sold"}, {"type": "uint256", "name": "min_tokens_bought"}, {"type": "uint256", "name": "min_eth_bought"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "recipient"}, {"type": "address", "name": "token_addr"}], "constant": false, "payable": false, "type": "function", "gas": 51098}, {"name": "tokenToTokenSwapOutput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_bought"}, {"type": "uint256", "name": "max_tokens_sold"}, {"type": "uint256", "name": "max_eth_sold"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "token_addr"}], "constant": false, "payable": false, "type": "function", "gas": 54928}, {"name": "tokenToTokenTransferOutput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_bought"}, {"type": "uint256", "name": "max_tokens_sold"}, {"type": "uint256", "name": "max_eth_sold"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "recipient"}, {"type": "address", "name": "token_addr"}], "constant": false, "payable": false, "type": "function", "gas": 55019}, {"name": "tokenToExchangeSwapInput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_sold"}, {"type": "uint256", "name": "min_tokens_bought"}, {"type": "uint256", "name": "min_eth_bought"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "exchange_addr"}], "constant": false, "payable": false, "type": "function", "gas": 49342}, {"name": "tokenToExchangeTransferInput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_sold"}, {"type": "uint256", "name": "min_tokens_bought"}, {"type": "uint256", "name": "min_eth_bought"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "recipient"}, {"type": "address", "name": "exchange_addr"}], "constant": false, "payable": false, "type": "function", "gas": 49532}, {"name": "tokenToExchangeSwapOutput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_bought"}, {"type": "uint256", "name": "max_tokens_sold"}, {"type": "uint256", "name": "max_eth_sold"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "exchange_addr"}], "constant": false, "payable": false, "type": "function", "gas": 53233}, {"name": "tokenToExchangeTransferOutput", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_bought"}, {"type": "uint256", "name": "max_tokens_sold"}, {"type": "uint256", "name": "max_eth_sold"}, {"type": "uint256", "name": "deadline"}, {"type": "address", "name": "recipient"}, {"type": "address", "name": "exchange_addr"}], "constant": false, "payable": false, "type": "function", "gas": 53423}, {"name": "getEthToTokenInputPrice", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "eth_sold"}], "constant": true, "payable": false, "type": "function", "gas": 5542}, {"name": "getEthToTokenOutputPrice", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_bought"}], "constant": true, "payable": false, "type": "function", "gas": 6872}, {"name": "getTokenToEthInputPrice", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "tokens_sold"}], "constant": true, "payable": false, "type": "function", "gas": 5637}, {"name": "getTokenToEthOutputPrice", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "uint256", "name": "eth_bought"}], "constant": true, "payable": false, "type": "function", "gas": 6897}, {"name": "tokenAddress", "outputs": [{"type": "address", "name": "out"}], "inputs": [], "constant": true, "payable": false, "type": "function", "gas": 1413}, {"name": "factoryAddress", "outputs": [{"type": "address", "name": "out"}], "inputs": [], "constant": true, "payable": false, "type": "function", "gas": 1443}, {"name": "balanceOf", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "address", "name": "_owner"}], "constant": true, "payable": false, "type": "function", "gas": 1645}, {"name": "transfer", "outputs": [{"type": "bool", "name": "out"}], "inputs": [{"type": "address", "name": "_to"}, {"type": "uint256", "name": "_value"}], "constant": false, "payable": false, "type": "function", "gas": 75034}, {"name": "transferFrom", "outputs": [{"type": "bool", "name": "out"}], "inputs": [{"type": "address", "name": "_from"}, {"type": "address", "name": "_to"}, {"type": "uint256", "name": "_value"}], "constant": false, "payable": false, "type": "function", "gas": 110907}, {"name": "approve", "outputs": [{"type": "bool", "name": "out"}], "inputs": [{"type": "address", "name": "_spender"}, {"type": "uint256", "name": "_value"}], "constant": false, "payable": false, "type": "function", "gas": 38769}, {"name": "allowance", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [{"type": "address", "name": "_owner"}, {"type": "address", "name": "_spender"}], "constant": true, "payable": false, "type": "function", "gas": 1925}, {"name": "name", "outputs": [{"type": "bytes32", "name": "out"}], "inputs": [], "constant": true, "payable": false, "type": "function", "gas": 1623}, {"name": "symbol", "outputs": [{"type": "bytes32", "name": "out"}], "inputs": [], "constant": true, "payable": false, "type": "function", "gas": 1653}, {"name": "decimals", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [], "constant": true, "payable": false, "type": "function", "gas": 1683}, {"name": "totalSupply", "outputs": [{"type": "uint256", "name": "out"}], "inputs": [], "constant": true, "payable": false, "type": "function", "gas": 1713}]' - - -let web3 = new Web3(new Web3.providers.HttpProvider(process.env.INFURARINKEBY)); - -const chainIdOrProvider = 4;//1 // could be e.g. window.ethereum instead - -let tokens = []; - -const wait_time = 800 - -async function run() { - console.log(" STARTING BOT ") - tokens.unshift('DAI') - console.log(JSON.stringify(tokens)) - await sleep(wait_time); - - var blockNo = 0; - while(true){ - await trackData(); - } -} - -async function trackData() { - // console.log('----') - for (var i = 0, len = tokens.length; i < len; i++) { - // console.log('--> ' + tokens[i]) - await checkToken(tokens[i]) - await sleep(wait_time) - } - // console.log('----') -} - -var ethReserve = new BigNumber(123.4567); -var rate = new BigNumber(123.4567); - -async function checkToken(Token){ - // console.log(Token + ' Maybes aye, maybes naw...'); - const tokenReserves = await UniSwap.getTokenReserves(Token, chainIdOrProvider); - - //console.log(tokenReserves); - const marketDetails = UniSwap.getMarketDetails(undefined, tokenReserves) // ETH<>ERC20 - - var t = new BigNumber(1000000000000000000) - // console.log(marketDetails) - //console.log(marketDetails.outputReserves.ethReserve.token) - - if(marketDetails.outputReserves.ethReserve.amount.dividedBy(t).isEqualTo(ethReserve) && marketDetails.marketRate.rate.isEqualTo(rate)){ - return; - }else{ - ethReserve = marketDetails.outputReserves.ethReserve.amount.dividedBy(t); - rate = marketDetails.marketRate.rate; - console.log('New !!!!!!!') - var currentBlockNo = await web3.eth.getBlockNumber(); - console.log(currentBlockNo); - console.log(marketDetails.outputReserves.ethReserve.amount.dividedBy(t).toString()) - console.log(marketDetails.marketRate.rate.toString()) - //console.log(marketDetails.marketRate.rateInverted.toString()) - } - - //console.log(marketDetails.outputReserves.ethReserve.amount.dividedBy(t).toString()) - //console.log(marketDetails.marketRate.rate.toString()) - //console.log(marketDetails.marketRate.rateInverted.toString()) -} - -sleep = (x) => { - return new Promise(resolve => { - setTimeout(() => { resolve(true) }, x ) - }) -} - -var account = '0xeE398666cA860DFb7390b5D73EE927e9Fb41a60A'; - -async function checkEthToToken(){ - var factoryAddress = '0xf5D915570BC477f9B8D6C0E980aA81757A3AaC36'; // rinkeby - var oceanToken = '0xCC4d8eCFa6a5c1a84853EC5c0c08Cc54Cb177a6A'; - var arbContractAddress = '0x8B4Ea90f1357c7Aa975708252F6Afd480595056b'; - var accountBalance = await web3.eth.getBalance(account); - console.log(accountBalance.toString()); - - console.log(RinkebyArbContract.contractName) - const arbContract = new web3.eth.Contract(RinkebyArbContract.abi, arbContractAddress); - - var contractBalance = await web3.eth.getBalance(arbContractAddress); - console.log(contractBalance); - - const uniswap = new web3.eth.Contract(JSON.parse(abi), factoryAddress); - - let exchange = await uniswap.methods.getExchange(oceanToken).call(); - console.log("the exchange address for ERC20 token is:" + exchange); - - let exchangeContract = new web3.eth.Contract(JSON.parse(exchangeAbi), exchange); - - await checkToken(oceanToken); - - var ethToSwap = web3.utils.toWei('0.01', 'ether'); - - const tokenReserves = await UniSwap.getTokenReserves(oceanToken, chainIdOrProvider); - const tradeDetails = await UniSwap.tradeExactEthForTokensWithData(tokenReserves, ethToSwap); - const executionDetails = await UniSwap.getExecutionDetails(tradeDetails); - - console.log(executionDetails); - /* - The maximum slippage to allow, in basis points. Defaults to 200 (2%). - { exchangeAddress: '0x416F1Ac032D1eEE743b18296aB958743B1E61E81', - methodName: 'ethToTokenSwapInput', - methodId: '0xf39b5b9b', - value: BigNumber { s: 1, e: 16, c: [ 100 ] }, - methodArguments: [ BigNumber { s: 1, e: 17, c: [Array] }, 1570306770 ] } - SAME AS ABOVE: - const tradeDetails2 = await UniSwap.tradeExactEthForTokens(oceanToken, ethToSwap, 4); - const executionDetails2 = await UniSwap.getExecutionDetails(tradeDetails); - console.log('!!!!!!!') - console.log(executionDetails2); - */ - - var min_buy_tokens = web3.utils.toWei(executionDetails.methodArguments[0].toString(), 'wei'); - var value = web3.utils.toWei(executionDetails.value.toString(), 'wei'); - - //console.log(executionDetails.methodArguments[0].toString()) - console.log(min_buy_tokens) - console.log(value) - - const tx = arbContract.methods.tradeEthToToken(executionDetails.exchangeAddress, min_buy_tokens, executionDetails.methodArguments[1], value); - //const tx = exchangeContract.methods.ethToTokenSwapInput(min_buy_tokens, executionDetails.methodArguments[1]); - const encodedABI = tx.encodeABI(); - - var txCount = await web3.eth.getTransactionCount(account); - console.log('Tx Count: ' + txCount); - console.log(encodedABI) - - // construct the transaction data - const txData = { - nonce: web3.utils.toHex(txCount), - gasLimit: web3.utils.toHex(6000000), - gasPrice: web3.utils.toHex(10000000000), // 10 Gwei - //to: executionDetails.exchangeAddress, - to: arbContractAddress, - from: account, - data: encodedABI, - value: web3.utils.toHex(value) - } - - const privateKey = Buffer.from( - process.env.PRIVATEKEY, - 'hex', - ) - - const transaction = new Tx(txData, {'chain':'rinkeby'}); - transaction.sign(privateKey); - console.log('Signed...') - const serializedTx = transaction.serialize().toString('hex'); - console.log('Sending...') - var receipt = await web3.eth.sendSignedTransaction('0x' + serializedTx); - console.log('\nReceipt:') - console.log(receipt); - /* - console.log('signing...') - var txSigned = await web3.eth.accounts.signTransaction(txData, process.env.PRIVATEKEY); - console.log('\ntxSigned:') - // console.log(txSigned) - - var receipt = await web3.eth.sendSignedTransaction(txSigned.rawTransaction); - console.log('\nReceipt:') - console.log(receipt); - */ - - accountBalance = await web3.eth.getBalance(account); - console.log(accountBalance.toString()); - - contractBalance = await web3.eth.getBalance(arbContractAddress); - console.log(contractBalance.toString()); - - await checkToken(oceanToken); - -} - -async function checkTokenToEth(){ - var factoryAddress = '0xf5D915570BC477f9B8D6C0E980aA81757A3AaC36'; // rinkeby - var oceanToken = '0xCC4d8eCFa6a5c1a84853EC5c0c08Cc54Cb177a6A'; - var arbContractAddress = '0x8B4Ea90f1357c7Aa975708252F6Afd480595056b'; - var accountBalance = await web3.eth.getBalance(account); - console.log('Account Balance: ' + accountBalance.toString()); - - const arbContract = new web3.eth.Contract(RinkebyArbContract.abi, arbContractAddress); - var contractBalance = await web3.eth.getBalance(arbContractAddress); - console.log('Arb Contract Balance: ' + contractBalance); - - const uniswap = new web3.eth.Contract(JSON.parse(abi), factoryAddress); - - let exchange = await uniswap.methods.getExchange(oceanToken).call(); - console.log("the exchange address for ERC20 token is:" + exchange); - - const tokenContract = new web3.eth.Contract(TokenContract.abi, oceanToken); - var allowance = await tokenContract.methods.allowance(arbContractAddress, exchange).call(); - console.log('Allowance: ' + allowance.toString()); - - var totalSupply = await tokenContract.methods.totalSupply().call(); - console.log('Total supply: ' + totalSupply.toString()); - - var tx = await arbContract.methods.approveToken(oceanToken, exchange, totalSupply); - var encodedABI = tx.encodeABI(); - - var txCount = await web3.eth.getTransactionCount(account); - console.log('Tx Count: ' + txCount); - // console.log(encodedABI) - - // construct the transaction data - var txData = { - nonce: web3.utils.toHex(txCount), - gasLimit: web3.utils.toHex(6000000), - gasPrice: web3.utils.toHex(10000000000), // 10 Gwei - to: arbContractAddress, - from: account, - data: encodedABI - } - - const privateKey = Buffer.from( - process.env.PRIVATEKEY, - 'hex', - ) - var transaction = new Tx(txData, {'chain':'rinkeby'}); - transaction.sign(privateKey); - console.log('Signed...') - - var serializedTx = transaction.serialize().toString('hex'); - console.log('Sending...') - var receipt = await web3.eth.sendSignedTransaction('0x' + serializedTx); - console.log('\nReceipt:') - console.log(receipt); - - allowance = await tokenContract.methods.allowance(arbContractAddress, exchange).call(); - console.log('Allowance: ' + allowance.toString()); - - let exchangeContract = new web3.eth.Contract(JSON.parse(exchangeAbi), exchange); - - await checkToken(oceanToken); - - var tokensToSwap = web3.utils.toWei('0.335615845101250071', 'ether'); - - const tokenReserves = await UniSwap.getTokenReserves(oceanToken, chainIdOrProvider); - // const tradeDetails = await UniSwap.tradeExactEthForTokensWithData(tokenReserves, ethToSwap); - const tradeDetails = await UniSwap.tradeExactTokensForEthWithData(tokenReserves, tokensToSwap); - const executionDetails = await UniSwap.getExecutionDetails(tradeDetails); - - console.log(executionDetails); - - var max_sell_tokens = web3.utils.toWei(executionDetails.methodArguments[0].toString(), 'wei'); - var eth = web3.utils.toWei(executionDetails.methodArguments[1].toString(), 'wei'); - var value = web3.utils.toWei(executionDetails.value.toString(), 'wei'); - - //console.log(executionDetails.methodArguments[0].toString()) - console.log('0: ' + max_sell_tokens) - console.log('1: ' + eth) - console.log('value: ' + value) - - tx = arbContract.methods.tradeTokenToEth(executionDetails.exchangeAddress, max_sell_tokens, executionDetails.methodArguments[2], eth); - encodedABI = tx.encodeABI(); - - var txCount = await web3.eth.getTransactionCount(account); - console.log('Tx Count: ' + txCount); - // console.log(encodedABI) - - // construct the transaction data - txData = { - nonce: web3.utils.toHex(txCount), - gasLimit: web3.utils.toHex(6000000), - gasPrice: web3.utils.toHex(10000000000), // 10 Gwei - //to: executionDetails.exchangeAddress, - to: arbContractAddress, - from: account, - data: encodedABI, - value: web3.utils.toHex(value) - } - - transaction = new Tx(txData, {'chain':'rinkeby'}); - transaction.sign(privateKey); - console.log('Signed...') - - serializedTx = transaction.serialize().toString('hex'); - console.log('Sending...') - receipt = await web3.eth.sendSignedTransaction('0x' + serializedTx); - console.log('\nReceipt:') - console.log(receipt); - - accountBalance = await web3.eth.getBalance(account); - console.log(accountBalance.toString()); - - contractBalance = await web3.eth.getBalance(arbContractAddress); - console.log(contractBalance.toString()); - - await checkToken(oceanToken); -} -// run(); -checkTokenToEth() -// checkEthToToken(); -// 18557155622000000000 -// 18565872998254917095 diff --git a/truffle-config.js b/truffle-config.js index 8601ebc..9f54357 100644 --- a/truffle-config.js +++ b/truffle-config.js @@ -17,6 +17,14 @@ module.exports = { network_id: 4, gasPrice: 20000000000, // 20 GWEI gas: 3716887 // gas limit, set any number you want + }, + kovan: { + provider: function() { + return new HDWalletProvider(process.env.PRIVATEKEY, process.env.INFURAKOVAN); + }, + network_id: 42, + gasPrice: 20000000000, // 20 GWEI + gas: 3716887 // gas limit, set any number you want } } }; diff --git a/yarn.lock b/yarn.lock index 5039b89..f417df3 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1635,6 +1635,11 @@ once@^1.3.1, once@^1.4.0: dependencies: wrappy "1" +openzeppelin-solidity@^2.4.0: + version "2.4.0" + resolved "https://registry.yarnpkg.com/openzeppelin-solidity/-/openzeppelin-solidity-2.4.0.tgz#5f0a7b30571c45493449166e57b947203415349d" + integrity sha512-533gc5jkspxW5YT0qJo02Za5q1LHwXK9CJCc48jNj/22ncNM/3M/3JfWLqfpB90uqLwOKOovpl0JfaMQTR+gXQ== + p-cancelable@^0.3.0: version "0.3.0" resolved "https://registry.yarnpkg.com/p-cancelable/-/p-cancelable-0.3.0.tgz#b9e123800bcebb7ac13a479be195b507b98d30fa"