@maplelabs/core-artifacts
Version:
Consist artifacts of the maple protocol
24,750 lines • 1.25 MB
JSON
{
"id": "f9677b450a000b27caaf43249c3eb0ec",
"_format": "hh-sol-build-info-1",
"solcVersion": "0.6.11",
"solcLongVersion": "0.6.11+commit.5ef660b1",
"input": {
"language": "Solidity",
"sources": {
"contracts/core/treasury/v1/MapleTreasury.sol": {
"content": "// SPDX-License-Identifier: AGPL-3.0-or-later // hevm: flattened sources of contracts/core/treasury/v1/MapleTreasury.sol\npragma solidity =0.6.11 >=0.6.0 <0.8.0 >=0.6.2 <0.8.0;\n\n////// contracts/core/globals/v1/interfaces/IMapleGlobals.sol\n/* pragma solidity 0.6.11; */\n\n/// @title MapleGlobals maintains a central source of parameters and allowlists for the Maple protocol.\ninterface IMapleGlobals {\n\n /**\n @dev Emits an event indicating the MapleGlobals contract was created.\n */\n event Initialized();\n\n /**\n @dev Emits an event indicating the validity of a Collateral Asset was set.\n @param asset The Collateral Asset to assign validity to.\n @param decimals The number of decimal places of `asset`.\n @param symbol The symbol of `asset`.\n @param valid The new validity status of `asset`.\n */\n event CollateralAssetSet(address asset, uint256 decimals, string symbol, bool valid);\n\n /**\n @dev Emits an event indicating the validity of a Liquidity Asset was set.\n @param asset The Liquidity Asset to assign validity to.\n @param decimals The number of decimal places of `asset`.\n @param symbol The symbol of `asset`.\n @param valid The new validity status of `asset`.\n */\n event LiquidityAssetSet(address asset, uint256 decimals, string symbol, bool valid);\n\n /**\n @dev Emits an event indicating the Oracle for an asset was set.\n @param asset The asset to update price for.\n @param oracle The new Oracle to use.\n */\n event OracleSet(address asset, address oracle);\n\n /**\n @dev This is unused.\n */\n event TransferRestrictionExemptionSet(address indexed exemptedContract, bool valid);\n\n /**\n @dev Emits an event indicating the validity of a Balancer Pool was set.\n @param balancerPool The address of Balancer Pool contract.\n @param valid The new validity status of a Balancer Pool.\n */\n event BalancerPoolSet(address balancerPool, bool valid);\n\n /**\n @dev Emits an event indicating a PendingGovernor was set.\n @param pendingGovernor The address of the new Pending Governor.\n */\n event PendingGovernorSet(address indexed pendingGovernor);\n\n /**\n @dev Emits an event indicating Governorship was accepted by a new account.\n @param governor The account that has accepted Governorship.\n */\n event GovernorAccepted(address indexed governor);\n\n /**\n @dev Emits an event indicating that some Governor controlled parameter was set.\n @param which The identifier of the parameter that was set.\n @param value The value the parameter was set to.\n */\n event GlobalsParamSet(bytes32 indexed which, uint256 value);\n\n /**\n @dev Emits an event indicating that some Governor controlled address was set.\n @param which The identifier of the address that was set.\n @param addr The address that was set.\n */\n event GlobalsAddressSet(bytes32 indexed which, address addr);\n\n /**\n @dev Emits an event indicating the protocol's paused state has been set.\n @param pause Whether the protocol was paused.\n */\n event ProtocolPaused(bool pause);\n\n /**\n @dev Emits an event indicating the GlobalAdmin was set.\n @param newGlobalAdmin The address of the new GlobalAdmin.\n */\n event GlobalAdminSet(address indexed newGlobalAdmin);\n\n /**\n @dev Emits an event indicating the validity of a Pool Delegate was set.\n @param poolDelegate The address of a Pool Delegate.\n @param valid Whether `poolDelegate` is a valid Pool Delegate.\n */\n event PoolDelegateSet(address indexed poolDelegate, bool valid);\n\n /**\n @dev The ERC-2222 Maple Token for the Maple protocol.\n */\n function mpl() external pure returns (address);\n\n /**\n @dev The Governor that is declared for governorship transfer. \n @dev Must be accepted for transfer to take effect. \n */\n function pendingGovernor() external view returns (address);\n\n /**\n @dev The Governor responsible for management of global Maple variables.\n */\n function governor() external view returns (address);\n\n /**\n @dev The MapleTreasury is the Treasury where all fees pass through for conversion, prior to distribution.\n */\n function mapleTreasury() external view returns (address);\n\n /**\n @dev The Global Admin of the whole network. \n @dev Has the power to switch off/on the functionality of entire protocol. \n */\n function globalAdmin() external view returns (address);\n\n /**\n @dev The amount of time a Borrower has to make a missed payment before a default can be triggered. \n */\n function defaultGracePeriod() external view returns (uint256);\n\n /**\n @dev The minimum amount of Pool cover that a Pool Delegate has to provide before they can finalize a Pool.\n */\n function swapOutRequired() external view returns (uint256);\n\n /**\n @dev The amount of time to allow a Borrower to drawdown on their Loan after funding period ends.\n */\n function fundingPeriod() external view returns (uint256);\n\n /**\n @dev The portion of drawdown that goes to the Pool Delegates and individual Lenders.\n */\n function investorFee() external view returns (uint256);\n\n /**\n @dev The portion of drawdown that goes to the MapleTreasury.\n */\n function treasuryFee() external view returns (uint256);\n\n /**\n @dev The maximum amount of slippage for Uniswap transactions.\n */\n function maxSwapSlippage() external view returns (uint256);\n\n /**\n @dev The minimum amount of LoanFDTs required to trigger liquidations (basis points percentage of totalSupply).\n */\n function minLoanEquity() external view returns (uint256);\n\n /**\n @dev The period (in secs) after which Stakers are allowed to unstake their BPTs from a StakeLocker.\n */\n function stakerCooldownPeriod() external view returns (uint256);\n\n /**\n @dev The period (in secs) after which LPs are allowed to withdraw their funds from a Pool.\n */\n function lpCooldownPeriod() external view returns (uint256);\n\n /**\n @dev The window of time (in secs) after `stakerCooldownPeriod` that an account has to withdraw before their intent to unstake is invalidated.\n */\n function stakerUnstakeWindow() external view returns (uint256);\n\n /**\n @dev The window of time (in secs) after `lpCooldownPeriod` that an account has to withdraw before their intent to withdraw is invalidated.\n */\n function lpWithdrawWindow() external view returns (uint256);\n\n /**\n @dev Whether the functionality of the entire protocol is paused.\n */\n function protocolPaused() external view returns (bool);\n\n /**\n @param liquidityAsset The address of a Liquidity Asset.\n @return Whether `liquidityAsset` is valid.\n */\n function isValidLiquidityAsset(address liquidityAsset) external view returns (bool);\n\n /**\n @param collateralAsset The address of a Collateral Asset.\n @return Whether `collateralAsset` is valid.\n */\n function isValidCollateralAsset(address collateralAsset) external view returns (bool);\n\n /**\n @param calc The address of a Calculator.\n @return Whether `calc` is valid.\n */\n function validCalcs(address calc) external view returns (bool);\n\n /**\n @dev Prevents unauthorized/unknown addresses from creating Pools.\n @param poolDelegate The address of a Pool Delegate.\n @return Whether `poolDelegate` is valid.\n */\n function isValidPoolDelegate(address poolDelegate) external view returns (bool);\n\n /**\n @param balancerPool The address of a Balancer Pool.\n @return Whether Maple has approved `balancerPool` for BPT staking.\n */\n function isValidBalancerPool(address balancerPool) external view returns (bool);\n\n /**\n @dev Determines the liquidation path of various assets in Loans and the Treasury. \n @dev The value provided will determine whether or not to perform a bilateral or triangular swap on Uniswap. \n @dev For example, `defaultUniswapPath[WBTC][USDC]` value would indicate what asset to convert WBTC into before conversion to USDC. \n @dev If `defaultUniswapPath[WBTC][USDC] == USDC`, then the swap is bilateral and no middle asset is swapped. \n @dev If `defaultUniswapPath[WBTC][USDC] == WETH`, then swap WBTC for WETH, then WETH for USDC. \n @param tokenA The address of the asset being swapped.\n @param tokenB The address of the final asset to receive.\n @return The intermediary asset for swaps, if any.\n */\n function defaultUniswapPath(address tokenA, address tokenB) external view returns (address);\n\n /**\n @param asset The address of some token.\n @return The Chainlink Oracle for the price of `asset`.\n */\n function oracleFor(address asset) external view returns (address);\n \n /**\n @param poolFactory The address of a Pool Factory.\n @return Whether `poolFactory` is valid.\n */\n function isValidPoolFactory(address poolFactory) external view returns (bool);\n\n /**\n @param loanFactory The address of a Loan Factory.\n @return Whether `loanFactory` is valid.\n */\n function isValidLoanFactory(address loanFactory) external view returns (bool);\n \n /**\n @param superFactory The core factory (e.g. PoolFactory, LoanFactory).\n @param subFactory The sub factory used by core factory (e.g. LiquidityLockerFactory).\n @return Whether `subFactory` is valid as it relates to `superFactory`.\n */\n function validSubFactories(address superFactory, address subFactory) external view returns (bool);\n \n /**\n @dev Sets the Staker cooldown period. \n @dev This change will affect the existing cool down period for the Stakers that already intended to unstake. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param newCooldownPeriod The new value for the cool down period.\n */\n function setStakerCooldownPeriod(uint256 newCooldownPeriod) external;\n\n /**\n @dev Sets the Liquidity Pool cooldown period. \n @dev This change will affect the existing cool down period for the LPs that already intended to withdraw. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param newCooldownPeriod The new value for the cool down period.\n */\n function setLpCooldownPeriod(uint256 newCooldownPeriod) external;\n\n /**\n @dev Sets the Staker unstake window. \n @dev This change will affect the existing window for the Stakers that already intended to unstake. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param newUnstakeWindow The new value for the unstake window.\n */\n function setStakerUnstakeWindow(uint256 newUnstakeWindow) external;\n\n /**\n @dev Sets the Liquidity Pool withdraw window. \n @dev This change will affect the existing window for the LPs that already intended to withdraw. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param newLpWithdrawWindow The new value for the withdraw window.\n */\n function setLpWithdrawWindow(uint256 newLpWithdrawWindow) external;\n\n /**\n @dev Sets the allowed Uniswap slippage percentage, in basis points. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param newMaxSlippage The new max slippage percentage (in basis points)\n */\n function setMaxSwapSlippage(uint256 newMaxSlippage) external;\n\n /**\n @dev Sets the Global Admin. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalAdminSet` event. \n @param newGlobalAdmin The new global admin address.\n */\n function setGlobalAdmin(address newGlobalAdmin) external;\n\n /**\n @dev Sets the validity of a Balancer Pool. \n @dev Only the Governor can call this function. \n @dev It emits a `BalancerPoolSet` event. \n @param balancerPool The address of Balancer Pool contract.\n @param valid The new validity status of a Balancer Pool.\n */\n function setValidBalancerPool(address balancerPool, bool valid) external;\n\n /**\n @dev Sets the paused/unpaused state of the protocol. \n @dev Only the Global Admin can call this function. \n @dev It emits a `ProtocolPaused` event. \n @param pause A boolean flag to switch externally facing functionality in the protocol on/off.\n */\n function setProtocolPause(bool pause) external;\n\n /**\n @dev Sets the validity of a PoolFactory. \n @dev Only the Governor can call this function. \n @param poolFactory The address of a PoolFactory.\n @param valid The new validity status of `poolFactory`.\n */\n function setValidPoolFactory(address poolFactory, bool valid) external;\n\n /**\n @dev Sets the validity of a LoanFactory. \n @dev Only the Governor can call this function. \n @param loanFactory The address of a LoanFactory.\n @param valid The new validity status of `loanFactory`.\n */\n function setValidLoanFactory(address loanFactory, bool valid) external;\n\n /**\n @dev Sets the validity of `subFactory` as it relates to `superFactory`. \n @dev Only the Governor can call this function. \n @param superFactory The core factory (e.g. PoolFactory, LoanFactory).\n @param subFactory The sub factory used by core factory (e.g. LiquidityLockerFactory).\n @param valid The new validity status of `subFactory` within context of `superFactory`.\n */\n function setValidSubFactory(address superFactory, address subFactory, bool valid) external;\n\n /**\n @dev Sets the path to swap an asset through Uniswap. \n @dev Only the Governor can call this function. \n @dev Set to == mid to enable a bilateral swap (single path swap). \n @dev Set to != mid to enable a triangular swap (multi path swap). \n @param from The address of the asset being swapped.\n @param to The address of the final asset to receive.\n @param mid The intermediary asset for swaps, if any.\n */\n function setDefaultUniswapPath(address from, address to, address mid) external;\n\n /**\n @dev Sets the validity of a Pool Delegate (those allowed to create Pools). \n @dev Only the Governor can call this function. \n @dev It emits a `PoolDelegateSet` event. \n @param poolDelegate The address to manage permissions for.\n @param valid The new validity status of a Pool Delegate.\n */\n function setPoolDelegateAllowlist(address poolDelegate, bool valid) external;\n\n /**\n @dev Sets the validity of an asset for collateral. \n @dev Only the Governor can call this function. \n @dev It emits a `CollateralAssetSet` event. \n @param asset The asset to assign validity to.\n @param valid The new validity status of a Collateral Asset.\n */\n function setCollateralAsset(address asset, bool valid) external;\n\n /**\n @dev Sets the validity of an asset for liquidity in Pools. \n @dev Only the Governor can call this function. \n @dev It emits a `LiquidityAssetSet` event. \n @param asset The asset to assign validity to.\n @param valid The new validity status a Liquidity Asset in Pools.\n */\n function setLiquidityAsset(address asset, bool valid) external;\n\n /**\n @dev Sets the validity of a calculator contract. \n @dev Only the Governor can call this function. \n @param calc The Calculator address.\n @param valid The new validity status of a Calculator.\n */\n function setCalc(address calc, bool valid) external;\n\n /**\n @dev Sets the investor fee (in basis points). \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param _fee The fee, e.g., 50 = 0.50%.\n */\n function setInvestorFee(uint256 _fee) external;\n\n /**\n @dev Sets the treasury fee (in basis points). \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param _fee The fee, e.g., 50 = 0.50%.\n */\n function setTreasuryFee(uint256 _fee) external;\n\n /**\n @dev Sets the MapleTreasury. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param _mapleTreasury A new MapleTreasury address.\n */\n function setMapleTreasury(address _mapleTreasury) external;\n\n /**\n @dev Sets the default grace period. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param _defaultGracePeriod The new number of seconds to set the grace period to.\n */\n function setDefaultGracePeriod(uint256 _defaultGracePeriod) external;\n\n /**\n @dev Sets the minimum Loan equity. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param _minLoanEquity The new minimum percentage of Loan equity an account must have to trigger liquidations.\n */\n function setMinLoanEquity(uint256 _minLoanEquity) external;\n\n /**\n @dev Sets the funding period. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param _fundingPeriod The number of seconds to set the drawdown grace period to.\n */\n function setFundingPeriod(uint256 _fundingPeriod) external;\n\n /**\n @dev Sets the the minimum Pool cover required to finalize a Pool. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsParamSet` event. \n @param amt The new minimum swap out required.\n */\n function setSwapOutRequired(uint256 amt) external;\n\n /**\n @dev Sets a price feed's oracle. \n @dev Only the Governor can call this function. \n @dev It emits a `OracleSet` event. \n @param asset The asset to update price for.\n @param oracle The new Oracle to use for the price of `asset`.\n */\n function setPriceOracle(address asset, address oracle) external;\n\n /**\n @dev Sets a new Pending Governor. \n @dev This address can become Governor if they accept. \n @dev Only the Governor can call this function. \n @dev It emits a `PendingGovernorSet` event. \n @param _pendingGovernor The address of a new Pending Governor.\n */\n function setPendingGovernor(address _pendingGovernor) external;\n\n /**\n @dev Accept the Governor position. \n @dev Only the Pending Governor can call this function. \n @dev It emits a `GovernorAccepted` event. \n */\n function acceptGovernor() external;\n\n /**\n @dev Fetch price for asset from Chainlink oracles.\n @param asset The asset to fetch the price of.\n @return The price of asset in USD.\n */\n function getLatestPrice(address asset) external view returns (uint256);\n\n /**\n @dev Checks that a `subFactory` is valid as it relates to `superFactory`.\n @param superFactory The core factory (e.g. PoolFactory, LoanFactory).\n @param subFactory The sub factory used by core factory (e.g. LiquidityLockerFactory).\n @param factoryType The type expected for the subFactory. \n 0 = COLLATERAL_LOCKER_FACTORY, \n 1 = DEBT_LOCKER_FACTORY, \n 2 = FUNDING_LOCKER_FACTORY, \n 3 = LIQUIDITY_LOCKER_FACTORY, \n 4 = STAKE_LOCKER_FACTORY. \n */\n function isValidSubFactory(address superFactory, address subFactory, uint8 factoryType) external view returns (bool);\n\n /**\n @dev Checks that a Calculator is valid.\n @param calc The Calculator address.\n @param calcType The Calculator type.\n */\n function isValidCalc(address calc, uint8 calcType) external view returns (bool);\n\n /**\n @dev Returns the `lpCooldownPeriod` and `lpWithdrawWindow` as a tuple, for convenience.\n @return The value of `lpCooldownPeriod`.\n @return The value of `lpWithdrawWindow`.\n */\n function getLpCooldownParams() external view returns (uint256, uint256);\n\n}\n\n////// contracts/core/treasury/v1/interfaces/IMapleTreasury.sol\n/* pragma solidity 0.6.11; */\n\n/// @title MapleTreasury earns revenue from Loans and distributes it to token holders and the Maple development team.\ninterface IMapleTreasury {\n\n /**\n @dev Emits an event indicating that an amount of some asset was converted to `fundsToken`.\n @param asset The ERC-20 asset to convert to `fundsToken`.\n @param amountIn The amount of the asset being converted to `fundsToken`.\n @param amountOut The amount of `fundsToken` received from the conversion.\n */\n event ERC20Conversion(address indexed asset, uint256 amountIn, uint256 amountOut);\n\n /**\n @dev Emits an event indicating that a distribution was made to token holders.\n @param amount The amount distributed to token holders.\n */\n event DistributedToHolders(uint256 amount);\n \n /**\n @dev Emits an event indicating the Governor reclaimed some token.\n @param asset The address of the token to reclaimed.\n @param amount The amount reclaimed.\n */\n event ERC20Reclaimed(address indexed asset, uint256 amount);\n \n /**\n @dev Emits an event indicating the MapleGlobals instance has changed.\n @param newGlobals The address of a new MapleGlobals.\n */\n event GlobalsSet(address newGlobals);\n\n /**\n @dev The address of ERC-2222 Maple Token for the Maple protocol.\n */\n function mpl() external view returns (address);\n\n /**\n @dev The address of the `fundsToken` of the ERC-2222 Maple Token.\n */\n function fundsToken() external view returns (address);\n\n /**\n @dev The address of the official UniswapV2 router.\n */\n function uniswapRouter() external view returns (address);\n\n /**\n @dev The address of an instance of MapleGlobals.\n */\n function globals() external view returns (address);\n\n /**\n @dev Updates the MapleGlobals instance. \n @dev Only the Governor can call this function. \n @dev It emits a `GlobalsSet` event. \n @param newGlobals The address of a new MapleGlobals instance.\n */\n function setGlobals(address newGlobals) external;\n\n /**\n @dev Reclaims Treasury funds to the Governor. \n @dev Only the Governor can call this function. \n @dev It emits a `ERC20Reclaimed` event. \n @param asset The address of the token to be reclaimed.\n @param amount The amount reclaimed.\n */\n function reclaimERC20(address asset, uint256 amount) external;\n\n /**\n @dev Passes through the current `fundsToken` balance of the Treasury to Maple Token, where it can be claimed by MPL holders. \n @dev Only the Governor can call this function. \n @dev It emits a `DistributedToHolders` event. \n */\n function distributeToHolders() external;\n\n /**\n @dev Converts an ERC-20 asset, via Uniswap, to `fundsToken`. \n @dev Only the Governor can call this function. \n @dev It emits a `ERC20Conversion` event. \n @param asset The ERC-20 asset to convert to `fundsToken`.\n */\n function convertERC20(address asset) external;\n\n}\n\n////// contracts/external-interfaces/IMapleToken.sol\n/* pragma solidity 0.6.11; */\n\ninterface IMapleToken {\n\n function updateFundsReceived() external;\n\n}\n\n////// contracts/external-interfaces/IUniswapRouter.sol\n/* pragma solidity 0.6.11; */\n\ninterface IUniswapRouter {\n\n function swapExactTokensForTokens(\n uint256 amountIn,\n uint256 amountOutMin,\n address[] calldata path,\n address to,\n uint256 deadline\n ) external returns (uint256[] memory amounts);\n\n function swapETHForExactTokens(\n uint256 amountOut,\n address[] calldata path,\n address to,\n uint256 deadline\n ) external payable returns (uint256[] memory amounts);\n\n function quote(\n uint256 amountA,\n uint256 reserveA,\n uint256 reserveB\n ) external pure returns (uint256 amountB);\n\n function WETH() external pure returns (address);\n\n}\n\n////// lib/openzeppelin-contracts/contracts/token/ERC20/IERC20.sol\n/* pragma solidity >=0.6.0 <0.8.0; */\n\n/**\n * @dev Interface of the ERC20 standard as defined in the EIP.\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\n////// contracts/external-interfaces/IERC20Details.sol\n/* pragma solidity 0.6.11; */\n\n/* import { IERC20 } from \"../../lib/openzeppelin-contracts/contracts/token/ERC20/IERC20.sol\"; */\n\ninterface IERC20Details is IERC20 {\n\n function name() external view returns (string memory);\n\n function symbol() external view returns (string memory);\n\n function decimals() external view returns (uint256);\n\n}\n\n////// lib/openzeppelin-contracts/contracts/math/SafeMath.sol\n/* pragma solidity >=0.6.0 <0.8.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 *\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 *\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 *\n * - Subtraction cannot overflow.\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 *\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 *\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 *\n * - The divisor cannot be zero.\n */\n function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {\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 *\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 *\n * - The divisor cannot be zero.\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\n////// contracts/libraries/util/v1/Util.sol\n/* pragma solidity 0.6.11; */\n\n/* import { SafeMath } from \"../../../../lib/openzeppelin-contracts/contracts/math/SafeMath.sol\"; */\n\n/* import { IERC20Details } from \"../../../external-interfaces/IERC20Details.sol\"; */\n\n/* import { IMapleGlobals } from \"../../../core/globals/v1/interfaces/IMapleGlobals.sol\"; */\n\n/// @title Util is a library that contains utility functions.\nlibrary Util {\n\n using SafeMath for uint256;\n\n /**\n @dev Calculates the minimum amount from a swap (adjustable for price slippage).\n @param globals The instance of a MapleGlobals.\n @param fromAsset The address of ERC-20 that will be swapped.\n @param toAsset The address of ERC-20 that will returned from swap.\n @param swapAmt The amount of `fromAsset` to be swapped.\n @return The expected amount of `toAsset` to receive from swap based on current oracle prices.\n */\n function calcMinAmount(IMapleGlobals globals, address fromAsset, address toAsset, uint256 swapAmt) external view returns (uint256) {\n return\n swapAmt\n .mul(globals.getLatestPrice(fromAsset)) // Convert from `fromAsset` value.\n .mul(10 ** IERC20Details(toAsset).decimals()) // Convert to `toAsset` decimal precision.\n .div(globals.getLatestPrice(toAsset)) // Convert to `toAsset` value.\n .div(10 ** IERC20Details(fromAsset).decimals()); // Convert from `fromAsset` decimal precision.\n }\n\n}\n\n////// lib/openzeppelin-contracts/contracts/utils/Address.sol\n/* pragma solidity >=0.6.2 <0.8.0; */\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 * [IMPORTANT]\n * ====\n * It is unsafe to assume that an address for which this function returns\n * false is an externally-owned account (EOA) and not a contract.\n *\n * Among others, `isContract` will return false for the following\n * types of addresses:\n *\n * - an externally-owned account\n * - a contract in construction\n * - an address where a contract will be created\n * - an address where a contract lived, but was destroyed\n * ====\n */\n function isContract(address account) internal view returns (bool) {\n // This method relies on 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 uint256 size;\n // solhint-disable-next-line no-inline-assembly\n assembly { size := extcodesize(account) }\n return size > 0;\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 function sendValue(address payable recipient, uint256 amount) internal {\n require(address(this).balance >= amount, \"Address: insufficient balance\");\n\n // solhint-disable-next-line avoid-low-level-calls, 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 /**\n * @dev Performs a Solidity function call using a low level `call`. A\n * plain`call` is an unsafe replacement for a function call: use this\n * function instead.\n *\n * If `target` reverts with a revert reason, it is bubbled up by this\n * function (like regular Solidity function calls).\n *\n * Returns the raw returned data. To convert to the expected return value,\n * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].\n *\n * Requirements:\n *\n * - `target` must be a contract.\n * - calling `target` with `data` must not revert.\n *\n * _Available since v3.1._\n */\n function functionCall(address target, bytes memory data) internal returns (bytes memory) {\n return functionCall(target, data, \"Address: low-level call failed\");\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with\n * `errorMessage` as a fallback revert reason when `target` reverts.\n *\n * _Available since v3.1._\n */\n function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) {\n return functionCallWithValue(target, data, 0, errorMessage);\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n * but also transferring `value` wei to `target`.\n *\n * Requirements:\n *\n * - the calling contract must have an ETH balance of at least `value`.\n * - the called Solidity function must be `payable`.\n *\n * _Available since v3.1._\n */\n function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) {\n return functionCallWithValue(target, data, value, \"Address: low-level call with value failed\");\n }\n\n /**\n * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but\n * with `errorMessage` as a fallback revert reason when `target` reverts.\n *\n * _Available since v3.1._\n */\n function functionCallWithValue(address target, bytes memory data, uint256 value, string memory errorMessage) internal returns (bytes memory) {\n require(address(this).balance >= value, \"Address: insufficient balance for call\");\n require(isContract(target), \"Address: call to non-contract\");\n\n // solhint-disable-next-line avoid-low-level-calls\n (bool success, bytes memory returndata) = target.call{ value: value }(data);\n return _verifyCallResult(success, returndata, errorMessage);\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n * but performing a static call.\n *\n * _Available since v3.3._\n */\n function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) {\n return functionStaticCall(target, data, \"Address: low-level static call failed\");\n }\n\n /**\n * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\n * but performing a static call.\n *\n * _Available since v3.3._\n */\n function functionStaticCall(address target, bytes memory data, string memory errorMessage) internal view returns (bytes memory) {\n require(isContract(target), \"Address: static call to non-contract\");\n\n // solhint-disable-next-line avoid-low-level-calls\n (bool success, bytes memory returndata) = target.staticcall(data);\n return _verifyCallResult(success, returndata, errorMessage);\n }\n\n function _verifyCallResult(bool success, bytes memory returndata, string memory errorMessage) private pure returns(bytes memory) {\n if (success) {\n return returndata;\n } else {\n // Look for revert reason and bubble it up if present\n if (returndata.length > 0) {\n // The easiest way to bubble the revert reason is using memory via assembly\n\n // solhint-disable-next-line no-inline-assembly\n assembly {\n let returndata_size := mload(returndata)\n revert(add(32, returndata), returndata_size)\n }\n } else {\n revert(errorMessage);\n }\n }\n }\n}\n\n////// lib/openzeppelin-contracts/contracts/token/ERC20/SafeERC20.sol\n/* pragma solidity >=0.6.0 <0.8.0; */\n\n/* import \"./IERC20.sol\"; */\n/* import \"../../math/SafeMath.sol\"; */\n/* import \"../../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 IERC20;` 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 /**\n * @dev Deprecated. This function has issues similar to the ones found in\n * {IERC20-approve}, and its usage is discouraged.\n *\n * Whenever possible, use {safeIncreaseAllowance} and\n * {safeDecreaseAllowance} instead.\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. We use {Address.functionCall} to perform this call, which verifies that\n // the target address contains contract code and also asserts for success in the low-level call.\n\n bytes memory returndata = address(token).functionCall(data, \"SafeERC20: low-level call failed\");\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\n////// contracts/core/treasury/v1/MapleTreasury.sol\n/* pragma solidity 0.6.11; */\n\n/* import { SafeMath } from \"../../../../lib/openzeppelin-contracts/contracts/math/SafeMath.sol\"; */\n/* import { IERC20, SafeERC20 } from \"../../../../lib/openzeppelin-contracts/contracts/token/ERC20/SafeERC20.sol\"; */\n\n/* import { IMapleToken } from \"../../../external-interfaces/IMapleToken.sol\"; */\n/* import { IUniswapRouter } from \"../../../external-interfaces/IUniswapRouter.sol\"; */\n\n/* import { Util } from \"../../../libraries/util/v1/Util.sol\"; */\n\n/* import { IMapleGlobals } from \"../../globals/v1/interfaces/IMapleGlobals.sol\"; */\n\n/* import { IMapleTreasury } from \"./interfaces/IMapleTreasury.sol\"; */\n\n/// @title MapleTreasury earns revenue from Loans and distributes it to token holders and the Maple development team.\ncontract MapleTreasury is IMapleTreasury {\n\n using SafeMath for uint256;\n using SafeERC20 for IERC20;\n\n address public override immutable mpl;\n address public override immutable fundsToken;\n address public override immutable uniswapRouter;\n address public override globals;\n\n /**\n @dev Instantiates the MapleTreasury contract.\n @param _mpl The address of ERC-2222 Maple Token for the Maple protocol.\n @param _fundsToken The address of the `fundsToken` of the ERC-2222 Maple Token.\n @param _uniswapRouter The address of the official UniswapV2 router.\n @param _globals The address of an instance of MapleGlobals.\n */\n constructor(\n address _mpl,\n address _fundsToken,\n address _uniswapRouter,\n address _globals\n ) public {\n mpl = _mpl;\n fundsToken = _fundsToken;\n uniswapRouter = _uniswapRouter;\n globals = _globals;\n }\n\n /**\n @dev Checks that `msg.sender` is the Governor.\n */\n modifier isGovernor() {\n require(msg.sender == IMapleGlobals(globals).governor(), \"MT:NOT_GOV\");\n _;\n }\n\n function setGlobals(address newGlobals) isGovernor external override {\n globals = newGlobals;\n emit GlobalsSet(newGlobals);\n }\n\n function reclaimERC20(address asset, uint256 amount) isGovernor external override {\n IERC20(asset).safeTransfer(msg.sender, amount);\n emit ERC20Reclaimed(asset, amount);\n }\n\n function distributeToHolders() isGovernor external override {\n IERC20 _fundsToken = IERC20(fundsToken);\n uint256 distributeAmount = _fundsToken.balanceOf(address(this));\n _fundsToken.safeTransfer(mpl, distributeAmount);\n IMapleToken(mpl).updateFundsReceived();\n emit DistributedToHolders(distributeAmount);\n }\n\n function convertERC20(address asset) isGovernor external override {\n require(asset != fundsToken, \"MT:ASSET_IS_FUNDS_TOKEN\");\n\n IMapleGlobals _globals = IMapleGlobals(globals);\n\n uint256 assetBalance = IERC20(asset).balanceOf(address(this));\n uint256 minAmount = Util.calcMinAmount(_globals, asset, fundsToken, assetBalance);\n\n IERC20(asset).safeApprove(uniswapRouter, uint256(0));\n IERC20(asset).safeApprove(uniswapRouter, assetBalance);\n\n address uniswapAssetForPath = _globals.defaultUniswapPath(asset, fundsToken);\n bool middleAsset = uniswapAssetForPath != fundsToken && uniswapAssetForPath != address(0);\n\n address[] memory path = new address[](middleAsset ? 3 : 2);\n\n path[0] = asset;\n path[1] = middleAsset ? uniswapAssetForPath : fundsToken;\n\n if (middleAsset) path[2] = fundsToken;\n\n uint256[] memory returnAmounts = IUniswapRouter(uniswapRouter).swapExactTokensForTokens(\n assetBalance,\n minAmount.sub(minAmount.mul(_globals.maxSwapSlippage()).div(10_000)),\n path,\n address(this),\n block.timestamp\n );\n\n emit ERC20Conversion(asset, returnAmounts[0], returnAmounts[path.length - 1]);\n }\n\n}\n"
}
},
"settings": {
"optimizer": {
"enabled": true,
"runs": 200
},
"outputSelection": {
"*": {
"*": [
"abi",
"evm.bytecode",
"evm.deployedBytecode",
"evm.methodIdentifiers"
],
"": [
"ast"
]
}
}
}
},
"output": {
"contracts": {
"contracts/core/treasury/v1/MapleTreasury.sol": {
"Address": {
"abi": [],
"evm": {
"bytecode": {
"linkReferences": {},
"object": "60566023600b82828239805160001a607314601657fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220f11f6735097efd61a9a6cf047a569a56219672a00b9e4238be0f1e52456d644864736f6c634300060b0033",
"opcodes": "PUSH1 0x56 PUSH1 0x23 PUSH1 0xB DUP3 DUP3 DUP3 CODECOPY DUP1 MLOAD PUSH1 0x0 BYTE PUSH1 0x73 EQ PUSH1 0x16 JUMPI INVALID JUMPDEST ADDRESS PUSH1 0x0 MSTORE PUSH1 0x73 DUP2 MSTORE8 DUP3 DUP2 RETURN INVALID PUSH20 0x0 ADDRESS EQ PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x0 DUP1 REVERT INVALID LOG2 PUSH5 0x6970667358 0x22 SLT KECCAK256 CALL 0x1F PUSH8 0x35097EFD61A9A6CF DIV PUSH27 0x569A56219672A00B9E4238BE0F1E52456D644864736F6C63430006 SIGNEXTEND STOP CALLER ",
"sourceMap": "35247:6704:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;"
},
"deployedBytecode": {
"immutableReferences": {},
"linkReferences": {},
"object": "73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220f11f6735097efd61a9a6cf047a569a56219672a00b9e4238be0f1e52456d644864736f6c634300060b0033",
"opcodes": "PUSH20 0x0 ADDRESS EQ PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x0 DUP1 REVERT INVALID LOG2 PUSH5 0x6970667358 0x22 SLT KECCAK256 CALL 0x1F PUSH8 0x35097EFD61A9A6CF DIV PUSH27 0x569A56219672A00B9E4238BE0F1E52456D644864736F6C63430006 SIGNEXTEND STOP CALLER ",
"sourceMap": "35247:6704:0:-:0;;;;;;;;"
},
"methodIdentifiers": {}
}
},
"IERC20": {
"abi": [
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "spender",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "value",
"type": "uint256"
}
],
"name": "Approval",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "from",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "to",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "value",
"type": "uint256"
}
],
"name": "Transfer",
"type": "event"
},
{
"inputs": [
{
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"internalType": "address",
"name": "spender",
"type": "address"
}
],
"name": "allowance",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "spender",
"type": "address"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "approve",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "account",
"type": "address"
}
],
"name": "balanceOf",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "totalSupply",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "transfer",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "transferFrom",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
}
],
"evm": {
"bytecode": {
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"deployedBytecode": {
"immutableReferences": {},
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"methodIdentifiers": {
"allowance(address,address)": "dd62ed3e",
"approve(address,uint256)": "095ea7b3",
"balanceOf(address)": "70a08231",
"totalSupply()": "18160ddd",
"transfer(address,uint256)": "a9059cbb",
"transferFrom(address,address,uint256)": "23b872dd"
}
}
},
"IERC20Details": {
"abi": [
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "spender",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "value",
"type": "uint256"
}
],
"name": "Approval",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "from",
"type": "address"
},
{
"indexed": true,
"internalType": "address",
"name": "to",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "value",
"type": "uint256"
}
],
"name": "Transfer",
"type": "event"
},
{
"inputs": [
{
"internalType": "address",
"name": "owner",
"type": "address"
},
{
"internalType": "address",
"name": "spender",
"type": "address"
}
],
"name": "allowance",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "spender",
"type": "address"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "approve",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "account",
"type": "address"
}
],
"name": "balanceOf",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "decimals",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "name",
"outputs": [
{
"internalType": "string",
"name": "",
"type": "string"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "symbol",
"outputs": [
{
"internalType": "string",
"name": "",
"type": "string"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "totalSupply",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "transfer",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "address",
"name": "recipient",
"type": "address"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "transferFrom",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
}
],
"evm": {
"bytecode": {
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"deployedBytecode": {
"immutableReferences": {},
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"methodIdentifiers": {
"allowance(address,address)": "dd62ed3e",
"approve(address,uint256)": "095ea7b3",
"balanceOf(address)": "70a08231",
"decimals()": "313ce567",
"name()": "06fdde03",
"symbol()": "95d89b41",
"totalSupply()": "18160ddd",
"transfer(address,uint256)": "a9059cbb",
"transferFrom(address,address,uint256)": "23b872dd"
}
}
},
"IMapleGlobals": {
"abi": [
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "balancerPool",
"type": "address"
},
{
"indexed": false,
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "BalancerPoolSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "decimals",
"type": "uint256"
},
{
"indexed": false,
"internalType": "string",
"name": "symbol",
"type": "string"
},
{
"indexed": false,
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "CollateralAssetSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "newGlobalAdmin",
"type": "address"
}
],
"name": "GlobalAdminSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "bytes32",
"name": "which",
"type": "bytes32"
},
{
"indexed": false,
"internalType": "address",
"name": "addr",
"type": "address"
}
],
"name": "GlobalsAddressSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "bytes32",
"name": "which",
"type": "bytes32"
},
{
"indexed": false,
"internalType": "uint256",
"name": "value",
"type": "uint256"
}
],
"name": "GlobalsParamSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "governor",
"type": "address"
}
],
"name": "GovernorAccepted",
"type": "event"
},
{
"anonymous": false,
"inputs": [],
"name": "Initialized",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "decimals",
"type": "uint256"
},
{
"indexed": false,
"internalType": "string",
"name": "symbol",
"type": "string"
},
{
"indexed": false,
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "LiquidityAssetSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"indexed": false,
"internalType": "address",
"name": "oracle",
"type": "address"
}
],
"name": "OracleSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "pendingGovernor",
"type": "address"
}
],
"name": "PendingGovernorSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "poolDelegate",
"type": "address"
},
{
"indexed": false,
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "PoolDelegateSet",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "bool",
"name": "pause",
"type": "bool"
}
],
"name": "ProtocolPaused",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "exemptedContract",
"type": "address"
},
{
"indexed": false,
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "TransferRestrictionExemptionSet",
"type": "event"
},
{
"inputs": [],
"name": "acceptGovernor",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "defaultGracePeriod",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "tokenA",
"type": "address"
},
{
"internalType": "address",
"name": "tokenB",
"type": "address"
}
],
"name": "defaultUniswapPath",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "fundingPeriod",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "asset",
"type": "address"
}
],
"name": "getLatestPrice",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "getLpCooldownParams",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "globalAdmin",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "governor",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "investorFee",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "balancerPool",
"type": "address"
}
],
"name": "isValidBalancerPool",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "calc",
"type": "address"
},
{
"internalType": "uint8",
"name": "calcType",
"type": "uint8"
}
],
"name": "isValidCalc",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "collateralAsset",
"type": "address"
}
],
"name": "isValidCollateralAsset",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "liquidityAsset",
"type": "address"
}
],
"name": "isValidLiquidityAsset",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "loanFactory",
"type": "address"
}
],
"name": "isValidLoanFactory",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "poolDelegate",
"type": "address"
}
],
"name": "isValidPoolDelegate",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "poolFactory",
"type": "address"
}
],
"name": "isValidPoolFactory",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "superFactory",
"type": "address"
},
{
"internalType": "address",
"name": "subFactory",
"type": "address"
},
{
"internalType": "uint8",
"name": "factoryType",
"type": "uint8"
}
],
"name": "isValidSubFactory",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "lpCooldownPeriod",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "lpWithdrawWindow",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "mapleTreasury",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "maxSwapSlippage",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "minLoanEquity",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "mpl",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "asset",
"type": "address"
}
],
"name": "oracleFor",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "pendingGovernor",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "protocolPaused",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "calc",
"type": "address"
},
{
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "setCalc",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "setCollateralAsset",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "_defaultGracePeriod",
"type": "uint256"
}
],
"name": "setDefaultGracePeriod",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "from",
"type": "address"
},
{
"internalType": "address",
"name": "to",
"type": "address"
},
{
"internalType": "address",
"name": "mid",
"type": "address"
}
],
"name": "setDefaultUniswapPath",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "_fundingPeriod",
"type": "uint256"
}
],
"name": "setFundingPeriod",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "newGlobalAdmin",
"type": "address"
}
],
"name": "setGlobalAdmin",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "_fee",
"type": "uint256"
}
],
"name": "setInvestorFee",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "setLiquidityAsset",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "newCooldownPeriod",
"type": "uint256"
}
],
"name": "setLpCooldownPeriod",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "newLpWithdrawWindow",
"type": "uint256"
}
],
"name": "setLpWithdrawWindow",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "_mapleTreasury",
"type": "address"
}
],
"name": "setMapleTreasury",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "newMaxSlippage",
"type": "uint256"
}
],
"name": "setMaxSwapSlippage",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "_minLoanEquity",
"type": "uint256"
}
],
"name": "setMinLoanEquity",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "_pendingGovernor",
"type": "address"
}
],
"name": "setPendingGovernor",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "poolDelegate",
"type": "address"
},
{
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "setPoolDelegateAllowlist",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"internalType": "address",
"name": "oracle",
"type": "address"
}
],
"name": "setPriceOracle",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "bool",
"name": "pause",
"type": "bool"
}
],
"name": "setProtocolPause",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "newCooldownPeriod",
"type": "uint256"
}
],
"name": "setStakerCooldownPeriod",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "newUnstakeWindow",
"type": "uint256"
}
],
"name": "setStakerUnstakeWindow",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "amt",
"type": "uint256"
}
],
"name": "setSwapOutRequired",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "_fee",
"type": "uint256"
}
],
"name": "setTreasuryFee",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "balancerPool",
"type": "address"
},
{
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "setValidBalancerPool",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "loanFactory",
"type": "address"
},
{
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "setValidLoanFactory",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "poolFactory",
"type": "address"
},
{
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "setValidPoolFactory",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "superFactory",
"type": "address"
},
{
"internalType": "address",
"name": "subFactory",
"type": "address"
},
{
"internalType": "bool",
"name": "valid",
"type": "bool"
}
],
"name": "setValidSubFactory",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "stakerCooldownPeriod",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "stakerUnstakeWindow",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "swapOutRequired",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "treasuryFee",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "calc",
"type": "address"
}
],
"name": "validCalcs",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "superFactory",
"type": "address"
},
{
"internalType": "address",
"name": "subFactory",
"type": "address"
}
],
"name": "validSubFactories",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "view",
"type": "function"
}
],
"evm": {
"bytecode": {
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"deployedBytecode": {
"immutableReferences": {},
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"methodIdentifiers": {
"acceptGovernor()": "e58bb639",
"defaultGracePeriod()": "705d5f24",
"defaultUniswapPath(address,address)": "4d866592",
"fundingPeriod()": "74d7c62b",
"getLatestPrice(address)": "16345f18",
"getLpCooldownParams()": "9f51290b",
"globalAdmin()": "ec9a9368",
"governor()": "0c340a24",
"investorFee()": "16a12d7a",
"isValidBalancerPool(address)": "72a22d71",
"isValidCalc(address,uint8)": "1b5833f7",
"isValidCollateralAsset(address)": "8c14834b",
"isValidLiquidityAsset(address)": "8695118a",
"isValidLoanFactory(address)": "b53afda7",
"isValidPoolDelegate(address)": "372e3546",
"isValidPoolFactory(address)": "107c0240",
"isValidSubFactory(address,address,uint8)": "13d459fb",
"lpCooldownPeriod()": "dd02e0ec",
"lpWithdrawWindow()": "df3d02bd",
"mapleTreasury()": "a5a27605",
"maxSwapSlippage()": "55323195",
"minLoanEquity()": "4a2697c4",
"mpl()": "a0530946",
"oracleFor(address)": "aed019b9",
"pendingGovernor()": "e3056a34",
"protocolPaused()": "425fad58",
"setCalc(address,bool)": "be44ed6b",
"setCollateralAsset(address,bool)": "2fa6c88f",
"setDefaultGracePeriod(uint256)": "44c14f71",
"setDefaultUniswapPath(address,address,address)": "f3897663",
"setFundingPeriod(uint256)": "2a5aa292",
"setGlobalAdmin(address)": "c52bc31d",
"setInvestorFee(uint256)": "5e045467",
"setLiquidityAsset(address,bool)": "2daa0d89",
"setLpCooldownPeriod(uint256)": "8608a6e1",
"setLpWithdrawWindow(uint256)": "26718606",
"setMapleTreasury(address)": "7303de25",
"setMaxSwapSlippage(uint256)": "f33ef09a",
"setMinLoanEquity(uint256)": "298b795d",
"setPendingGovernor(address)": "f235757f",
"setPoolDelegateAllowlist(address,bool)": "efdb16fc",
"setPriceOracle(address,address)": "67a74ddc",
"setProtocolPause(bool)": "4e989118",
"setStakerCooldownPeriod(uint256)": "fd4a9121",
"setStakerUnstakeWindow(uint256)": "d1cdf301",
"setSwapOutRequired(uint256)": "dbc6c552",
"setTreasuryFee(uint256)": "77e741c7",
"setValidBalancerPool(address,bool)": "490dae64",
"setValidLoanFactory(address,bool)": "c9c67240",
"setValidPoolFactory(address,bool)": "6597b899",
"setValidSubFactory(address,address,bool)": "f85ee6f8",
"stakerCooldownPeriod()": "a965d6b5",
"stakerUnstakeWindow()": "2018b870",
"swapOutRequired()": "3106374c",
"treasuryFee()": "cc32d176",
"validCalcs(address)": "1beb84e7",
"validSubFactories(address,address)": "1b1804aa"
}
}
},
"IMapleToken": {
"abi": [
{
"inputs": [],
"name": "updateFundsReceived",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
}
],
"evm": {
"bytecode": {
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"deployedBytecode": {
"immutableReferences": {},
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"methodIdentifiers": {
"updateFundsReceived()": "46c162de"
}
}
},
"IMapleTreasury": {
"abi": [
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "DistributedToHolders",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amountIn",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amountOut",
"type": "uint256"
}
],
"name": "ERC20Conversion",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "ERC20Reclaimed",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "newGlobals",
"type": "address"
}
],
"name": "GlobalsSet",
"type": "event"
},
{
"inputs": [
{
"internalType": "address",
"name": "asset",
"type": "address"
}
],
"name": "convertERC20",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "distributeToHolders",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "fundsToken",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "globals",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "mpl",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "reclaimERC20",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "newGlobals",
"type": "address"
}
],
"name": "setGlobals",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "uniswapRouter",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
}
],
"evm": {
"bytecode": {
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"deployedBytecode": {
"immutableReferences": {},
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"methodIdentifiers": {
"convertERC20(address)": "817bd4fd",
"distributeToHolders()": "3153689f",
"fundsToken()": "63f04b15",
"globals()": "c3124525",
"mpl()": "a0530946",
"reclaimERC20(address,uint256)": "afdbd499",
"setGlobals(address)": "cc2e0a26",
"uniswapRouter()": "735de9f7"
}
}
},
"IUniswapRouter": {
"abi": [
{
"inputs": [],
"name": "WETH",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "amountA",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "reserveA",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "reserveB",
"type": "uint256"
}
],
"name": "quote",
"outputs": [
{
"internalType": "uint256",
"name": "amountB",
"type": "uint256"
}
],
"stateMutability": "pure",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "amountOut",
"type": "uint256"
},
{
"internalType": "address[]",
"name": "path",
"type": "address[]"
},
{
"internalType": "address",
"name": "to",
"type": "address"
},
{
"internalType": "uint256",
"name": "deadline",
"type": "uint256"
}
],
"name": "swapETHForExactTokens",
"outputs": [
{
"internalType": "uint256[]",
"name": "amounts",
"type": "uint256[]"
}
],
"stateMutability": "payable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "amountIn",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "amountOutMin",
"type": "uint256"
},
{
"internalType": "address[]",
"name": "path",
"type": "address[]"
},
{
"internalType": "address",
"name": "to",
"type": "address"
},
{
"internalType": "uint256",
"name": "deadline",
"type": "uint256"
}
],
"name": "swapExactTokensForTokens",
"outputs": [
{
"internalType": "uint256[]",
"name": "amounts",
"type": "uint256[]"
}
],
"stateMutability": "nonpayable",
"type": "function"
}
],
"evm": {
"bytecode": {
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"deployedBytecode": {
"immutableReferences": {},
"linkReferences": {},
"object": "",
"opcodes": "",
"sourceMap": ""
},
"methodIdentifiers": {
"WETH()": "ad5c4648",
"quote(uint256,uint256,uint256)": "ad615dec",
"swapETHForExactTokens(uint256,address[],address,uint256)": "fb3bdb41",
"swapExactTokensForTokens(uint256,uint256,address[],address,uint256)": "38ed1739"
}
}
},
"MapleTreasury": {
"abi": [
{
"inputs": [
{
"internalType": "address",
"name": "_mpl",
"type": "address"
},
{
"internalType": "address",
"name": "_fundsToken",
"type": "address"
},
{
"internalType": "address",
"name": "_uniswapRouter",
"type": "address"
},
{
"internalType": "address",
"name": "_globals",
"type": "address"
}
],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "DistributedToHolders",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amountIn",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amountOut",
"type": "uint256"
}
],
"name": "ERC20Conversion",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": true,
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"indexed": false,
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "ERC20Reclaimed",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "address",
"name": "newGlobals",
"type": "address"
}
],
"name": "GlobalsSet",
"type": "event"
},
{
"inputs": [
{
"internalType": "address",
"name": "asset",
"type": "address"
}
],
"name": "convertERC20",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "distributeToHolders",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "fundsToken",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "globals",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "mpl",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "asset",
"type": "address"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "reclaimERC20",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "address",
"name": "newGlobals",
"type": "address"
}
],
"name": "setGlobals",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "uniswapRouter",
"outputs": [
{
"internalType": "address",
"name": "",
"type": "address"
}
],
"stateMutability": "view",
"type": "function"
}
],
"evm": {
"bytecode": {
"linkReferences": {
"contracts/core/treasury/v1/MapleTreasury.sol": {
"Util": [
{
"length": 20,
"start": 1765
}
]
}
},
"object": "60e060405234801561001057600080fd5b506040516115b93803806115b98339818101604052608081101561003357600080fd5b5080516020820151604083015160609384015183851b6001600160601b031990811660805283861b811660a0529482901b90941660c052600080546001600160a01b0319166001600160a01b0395861617815592841693918216929116906114c9906100f09039806103b1528061066b52806106a652806108f3525080610225528061038d528061049752806105bf52806106f15280610776528061084752806108a25250806102b552806102e25280610ba852506114c96000f3fe608060405234801561001057600080fd5b50600436106100885760003560e01c8063a05309461161005b578063a0530946146100e9578063afdbd499146100f1578063c31245251461011d578063cc2e0a261461012557610088565b80633153689f1461008d57806363f04b1514610097578063735de9f7146100bb578063817bd4fd146100c3575b600080fd5b61009561014b565b005b61009f61038b565b604080516001600160a01b039092168252519081900360200190f35b61009f6103af565b610095600480360360208110156100d957600080fd5b50356001600160a01b03166103d3565b61009f610ba6565b6100956004803603604081101561010757600080fd5b506001600160a01b038135169060200135610bca565b61009f610ce9565b6100956004803603602081101561013b57600080fd5b50356001600160a01b0316610cf8565b6000809054906101000a90046001600160a01b03166001600160a01b0316630c340a246040518163ffffffff1660e01b815260040160206040518083038186803b15801561019857600080fd5b505afa1580156101ac573d6000803e3d6000fd5b505050506040513d60208110156101c257600080fd5b50516001600160a01b0316331461020d576040805162461bcd60e51b815260206004820152600a60248201526926aa1d2727aa2fa3a7ab60b11b604482015290519081900360640190fd5b604080516370a0823160e01b815230600482015290517f0000000000000000000000000000000000000000000000000000000000000000916000916001600160a01b038416916370a08231916024808301926020929190829003018186803b15801561027857600080fd5b505afa15801561028c573d6000803e3d6000fd5b505050506040513d60208110156102a257600080fd5b505190506102e06001600160a01b0383167f00000000000000000000000000000000000000000000000000000000000000008363ffffffff610e0e16565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166346c162de6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561033b57600080fd5b505af115801561034f573d6000803e3d6000fd5b50506040805184815290517faa7ec7b1d6110de9a1bf05a7214112bcaee913a07e31bd219f50af4b0ee0469d9350908190036020019150a15050565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b6000809054906101000a90046001600160a01b03166001600160a01b0316630c340a246040518163ffffffff1660e01b815260040160206040518083038186803b15801561042057600080fd5b505afa158015610434573d6000803e3d6000fd5b505050506040513d602081101561044a57600080fd5b50516001600160a01b03163314610495576040805162461bcd60e51b815260206004820152600a60248201526926aa1d2727aa2fa3a7ab60b11b604482015290519081900360640190fd5b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316816001600160a01b0316141561051c576040805162461bcd60e51b815260206004820152601760248201527f4d543a41535345545f49535f46554e44535f544f4b454e000000000000000000604482015290519081900360640190fd5b60008054604080516370a0823160e01b815230600482015290516001600160a01b0392831693928516916370a08231916024808301926020929190829003018186803b15801561056b57600080fd5b505afa15801561057f573d6000803e3d6000fd5b505050506040513d602081101561059557600080fd5b5051604080516360f1b8c360e11b81526001600160a01b03808616600483015280871660248301527f000000000000000000000000000000000000000000000000000000000000000016604482015260648101839052905191925060009173__$9a7f24476bec8cd7609119e3792aeabf73$__9163c1e37186916084808301926020929190829003018186803b15801561062e57600080fd5b505af4158015610642573d6000803e3d6000fd5b505050506040513d602081101561065857600080fd5b505190506106976001600160a01b0385167f0000000000000000000000000000000000000000000000000000000000000000600063ffffffff610e6516565b6106d16001600160a01b0385167f00000000000000000000000000000000000000000000000000000000000000008463ffffffff610e6516565b604080516326c332c960e11b81526001600160a01b0386811660048301527f0000000000000000000000000000000000000000000000000000000000000000811660248301529151600092861691634d866592916044808301926020929190829003018186803b15801561074457600080fd5b505afa158015610758573d6000803e3d6000fd5b505050506040513d602081101561076e57600080fd5b5051905060007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03908116908316148015906107b957506001600160a01b03821615155b90506060816107c95760026107cc565b60035b60ff1667ffffffffffffffff811180156107e557600080fd5b5060405190808252806020026020018201604052801561080f578160200160208202803683370190505b509050868160008151811061082057fe5b60200260200101906001600160a01b031690816001600160a01b0316815250508161086b577f000000000000000000000000000000000000000000000000000000000000000061086d565b825b8160018151811061087a57fe5b60200260200101906001600160a01b031690816001600160a01b03168152505081156108ef577f0000000000000000000000000000000000000000000000000000000000000000816002815181106108ce57fe5b60200260200101906001600160a01b031690816001600160a01b0316815250505b60607f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166338ed1739876109b86109ab61271061099f8d6001600160a01b031663553231956040518163ffffffff1660e01b815260040160206040518083038186803b15801561096657600080fd5b505afa15801561097a573d6000803e3d6000fd5b505050506040513d602081101561099057600080fd5b50518c9063ffffffff610f7816565b9063ffffffff610fda16565b899063ffffffff61101c16565b8530426040518663ffffffff1660e01b81526004018086815260200185815260200180602001846001600160a01b03166001600160a01b03168152602001838152602001828103825285818151815260200191508051906020019060200280838360005b83811015610a34578181015183820152602001610a1c565b505050509050019650505050505050600060405180830381600087803b158015610a5d57600080fd5b505af1158015610a71573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526020811015610a9a57600080fd5b8101908080516040519392919084640100000000821115610aba57600080fd5b908301906020820185811115610acf57600080fd5b8251866020820283011164010000000082111715610aec57600080fd5b82525081516020918201928201910280838360005b83811015610b19578181015183820152602001610b01565b505050509050016040525050509050876001600160a01b03167f5d9559ada0f8509a7fffb4c05fa6f4f9df6772ac68a8f6ac87c36f00ff3843a182600081518110610b6057fe5b602002602001015183600186510381518110610b7857fe5b6020026020010151604051808381526020018281526020019250505060405180910390a25050505050505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b6000809054906101000a90046001600160a01b03166001600160a01b0316630c340a246040518163ffffffff1660e01b815260040160206040518083038186803b158015610c1757600080fd5b505afa158015610c2b573d6000803e3d6000fd5b505050506040513d6020811015610c4157600080fd5b50516001600160a01b03163314610c8c576040805162461bcd60e51b815260206004820152600a60248201526926aa1d2727aa2fa3a7ab60b11b604482015290519081900360640190fd5b610ca66001600160a01b038316338363ffffffff610e0e16565b6040805182815290516001600160a01b038416917fa0ea1d68f48cd2ff8a7db3aaa2d99dbdb957e097c7cc559f7e738832678c41ff919081900360200190a25050565b6000546001600160a01b031681565b6000809054906101000a90046001600160a01b03166001600160a01b0316630c340a246040518163ffffffff1660e01b815260040160206040518083038186803b158015610d4557600080fd5b505afa158015610d59573d6000803e3d6000fd5b505050506040513d6020811015610d6f57600080fd5b50516001600160a01b03163314610dba576040805162461bcd60e51b815260206004820152600a60248201526926aa1d2727aa2fa3a7ab60b11b604482015290519081900360640190fd5b600080546001600160a01b0383166001600160a01b0319909116811790915560408051918252517fda36f26252aa35d26238345e2c339cdbfeb26ce49721030ca8e907ab1701ac8f9181900360200190a150565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052610e6090849061105e565b505050565b801580610eeb575060408051636eb1769f60e11b81523060048201526001600160a01b03848116602483015291519185169163dd62ed3e91604480820192602092909190829003018186803b158015610ebd57600080fd5b505afa158015610ed1573d6000803e3d6000fd5b505050506040513d6020811015610ee757600080fd5b5051155b610f265760405162461bcd60e51b815260040180806020018281038252603681526020018061145e6036913960400191505060405180910390fd5b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663095ea7b360e01b179052610e6090849061105e565b600082610f8757506000610fd4565b82820282848281610f9457fe5b0414610fd15760405162461bcd60e51b81526004018080602001828103825260218152602001806114136021913960400191505060405180910390fd5b90505b92915050565b6000610fd183836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061110f565b6000610fd183836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506111b3565b60606110b3826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b031661120d9092919063ffffffff16565b805190915015610e60578080602001905160208110156110d257600080fd5b5051610e605760405162461bcd60e51b815260040180806020018281038252602a815260200180611434602a913960400191505060405180910390fd5b6000818361119b5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611160578181015183820152602001611148565b50505050905090810190601f16801561118d5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816111a757fe5b049150505b9392505050565b600081848411156112055760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315611160578181015183820152602001611148565b505050900390565b606061121c8484600085611224565b949350505050565b6060824710156112655760405162461bcd60e51b81526004018080602001828103825260268152602001806113ed6026913960400191505060405180910390fd5b61126e85611380565b6112bf576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b602083106112fe5780518252601f1990920191602091820191016112df565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d8060008114611360576040519150601f19603f3d011682016040523d82523d6000602084013e611365565b606091505b5091509150611375828286611386565b979650505050505050565b3b151590565b606083156113955750816111ac565b8251156113a55782518084602001fd5b60405162461bcd60e51b815260206004820181815284516024840152845185939192839260440191908501908083836000831561116057818101518382015260200161114856fe416464726573733a20696e73756666696369656e742062616c616e636520666f722063616c6c536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f775361666545524332303a204552433230206f7065726174696f6e20646964206e6f7420737563636565645361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f20746f206e6f6e2d7a65726f20616c6c6f77616e6365a2646970667358221220973167128ef71cfea1b64a95846622fc08ca5424960b9922b901c2e3040c93de64736f6c634300060b0033",
"opcodes": "PUSH1 0xE0 PUSH1 0x40 MSTORE CALLVALUE DUP1 ISZERO PUSH2 0x10 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x40 MLOAD PUSH2 0x15B9 CODESIZE SUB DUP1 PUSH2 0x15B9 DUP4 CODECOPY DUP2 DUP2 ADD PUSH1 0x40 MSTORE PUSH1 0x80 DUP2 LT ISZERO PUSH2 0x33 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP DUP1 MLOAD PUSH1 0x20 DUP3 ADD MLOAD PUSH1 0x40 DUP4 ADD MLOAD PUSH1 0x60 SWAP4 DUP5 ADD MLOAD DUP4 DUP6 SHL PUSH1 0x1 PUSH1 0x1 PUSH1 0x60 SHL SUB NOT SWAP1 DUP2 AND PUSH1 0x80 MSTORE DUP4 DUP7 SHL DUP2 AND PUSH1 0xA0 MSTORE SWAP5 DUP3 SWAP1 SHL SWAP1 SWAP5 AND PUSH1 0xC0 MSTORE PUSH1 0x0 DUP1 SLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB NOT AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB SWAP6 DUP7 AND OR DUP2 SSTORE SWAP3 DUP5 AND SWAP4 SWAP2 DUP3 AND SWAP3 SWAP2 AND SWAP1 PUSH2 0x14C9 SWAP1 PUSH2 0xF0 SWAP1 CODECOPY DUP1 PUSH2 0x3B1 MSTORE DUP1 PUSH2 0x66B MSTORE DUP1 PUSH2 0x6A6 MSTORE DUP1 PUSH2 0x8F3 MSTORE POP DUP1 PUSH2 0x225 MSTORE DUP1 PUSH2 0x38D MSTORE DUP1 PUSH2 0x497 MSTORE DUP1 PUSH2 0x5BF MSTORE DUP1 PUSH2 0x6F1 MSTORE DUP1 PUSH2 0x776 MSTORE DUP1 PUSH2 0x847 MSTORE DUP1 PUSH2 0x8A2 MSTORE POP DUP1 PUSH2 0x2B5 MSTORE DUP1 PUSH2 0x2E2 MSTORE DUP1 PUSH2 0xBA8 MSTORE POP PUSH2 0x14C9 PUSH1 0x0 RETURN INVALID PUSH1 0x80 PUSH1 0x40 MSTORE CALLVALUE DUP1 ISZERO PUSH2 0x10 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x4 CALLDATASIZE LT PUSH2 0x88 JUMPI PUSH1 0x0 CALLDATALOAD PUSH1 0xE0 SHR DUP1 PUSH4 0xA0530946 GT PUSH2 0x5B JUMPI DUP1 PUSH4 0xA0530946 EQ PUSH2 0xE9 JUMPI DUP1 PUSH4 0xAFDBD499 EQ PUSH2 0xF1 JUMPI DUP1 PUSH4 0xC3124525 EQ PUSH2 0x11D JUMPI DUP1 PUSH4 0xCC2E0A26 EQ PUSH2 0x125 JUMPI PUSH2 0x88 JUMP JUMPDEST DUP1 PUSH4 0x3153689F EQ PUSH2 0x8D JUMPI DUP1 PUSH4 0x63F04B15 EQ PUSH2 0x97 JUMPI DUP1 PUSH4 0x735DE9F7 EQ PUSH2 0xBB JUMPI DUP1 PUSH4 0x817BD4FD EQ PUSH2 0xC3 JUMPI JUMPDEST PUSH1 0x0 DUP1 REVERT JUMPDEST PUSH2 0x95 PUSH2 0x14B JUMP JUMPDEST STOP JUMPDEST PUSH2 0x9F PUSH2 0x38B JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB SWAP1 SWAP3 AND DUP3 MSTORE MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x20 ADD SWAP1 RETURN JUMPDEST PUSH2 0x9F PUSH2 0x3AF JUMP JUMPDEST PUSH2 0x95 PUSH1 0x4 DUP1 CALLDATASIZE SUB PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xD9 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP CALLDATALOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH2 0x3D3 JUMP JUMPDEST PUSH2 0x9F PUSH2 0xBA6 JUMP JUMPDEST PUSH2 0x95 PUSH1 0x4 DUP1 CALLDATASIZE SUB PUSH1 0x40 DUP2 LT ISZERO PUSH2 0x107 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP2 CALLDATALOAD AND SWAP1 PUSH1 0x20 ADD CALLDATALOAD PUSH2 0xBCA JUMP JUMPDEST PUSH2 0x9F PUSH2 0xCE9 JUMP JUMPDEST PUSH2 0x95 PUSH1 0x4 DUP1 CALLDATASIZE SUB PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x13B JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP CALLDATALOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH2 0xCF8 JUMP JUMPDEST PUSH1 0x0 DUP1 SWAP1 SLOAD SWAP1 PUSH2 0x100 EXP SWAP1 DIV PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0xC340A24 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x198 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x1AC JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x1C2 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND CALLER EQ PUSH2 0x20D JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0xA PUSH1 0x24 DUP3 ADD MSTORE PUSH10 0x26AA1D2727AA2FA3A7AB PUSH1 0xB1 SHL PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH4 0x70A08231 PUSH1 0xE0 SHL DUP2 MSTORE ADDRESS PUSH1 0x4 DUP3 ADD MSTORE SWAP1 MLOAD PUSH32 0x0 SWAP2 PUSH1 0x0 SWAP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP5 AND SWAP2 PUSH4 0x70A08231 SWAP2 PUSH1 0x24 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x278 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x28C JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x2A2 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD SWAP1 POP PUSH2 0x2E0 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP4 AND PUSH32 0x0 DUP4 PUSH4 0xFFFFFFFF PUSH2 0xE0E AND JUMP JUMPDEST PUSH32 0x0 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0x46C162DE PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x33B JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x34F JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP PUSH1 0x40 DUP1 MLOAD DUP5 DUP2 MSTORE SWAP1 MLOAD PUSH32 0xAA7EC7B1D6110DE9A1BF05A7214112BCAEE913A07E31BD219F50AF4B0EE0469D SWAP4 POP SWAP1 DUP2 SWAP1 SUB PUSH1 0x20 ADD SWAP2 POP LOG1 POP POP JUMP JUMPDEST PUSH32 0x0 DUP2 JUMP JUMPDEST PUSH32 0x0 DUP2 JUMP JUMPDEST PUSH1 0x0 DUP1 SWAP1 SLOAD SWAP1 PUSH2 0x100 EXP SWAP1 DIV PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0xC340A24 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x420 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x434 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x44A JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND CALLER EQ PUSH2 0x495 JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0xA PUSH1 0x24 DUP3 ADD MSTORE PUSH10 0x26AA1D2727AA2FA3A7AB PUSH1 0xB1 SHL PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH32 0x0 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND EQ ISZERO PUSH2 0x51C JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0x17 PUSH1 0x24 DUP3 ADD MSTORE PUSH32 0x4D543A41535345545F49535F46554E44535F544F4B454E000000000000000000 PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH1 0x0 DUP1 SLOAD PUSH1 0x40 DUP1 MLOAD PUSH4 0x70A08231 PUSH1 0xE0 SHL DUP2 MSTORE ADDRESS PUSH1 0x4 DUP3 ADD MSTORE SWAP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB SWAP3 DUP4 AND SWAP4 SWAP3 DUP6 AND SWAP2 PUSH4 0x70A08231 SWAP2 PUSH1 0x24 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x56B JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x57F JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x595 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x40 DUP1 MLOAD PUSH4 0x60F1B8C3 PUSH1 0xE1 SHL DUP2 MSTORE PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP1 DUP7 AND PUSH1 0x4 DUP4 ADD MSTORE DUP1 DUP8 AND PUSH1 0x24 DUP4 ADD MSTORE PUSH32 0x0 AND PUSH1 0x44 DUP3 ADD MSTORE PUSH1 0x64 DUP2 ADD DUP4 SWAP1 MSTORE SWAP1 MLOAD SWAP2 SWAP3 POP PUSH1 0x0 SWAP2 PUSH20 0x0 SWAP2 PUSH4 0xC1E37186 SWAP2 PUSH1 0x84 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x62E JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS DELEGATECALL ISZERO DUP1 ISZERO PUSH2 0x642 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x658 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD SWAP1 POP PUSH2 0x697 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP6 AND PUSH32 0x0 PUSH1 0x0 PUSH4 0xFFFFFFFF PUSH2 0xE65 AND JUMP JUMPDEST PUSH2 0x6D1 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP6 AND PUSH32 0x0 DUP5 PUSH4 0xFFFFFFFF PUSH2 0xE65 AND JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH4 0x26C332C9 PUSH1 0xE1 SHL DUP2 MSTORE PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP7 DUP2 AND PUSH1 0x4 DUP4 ADD MSTORE PUSH32 0x0 DUP2 AND PUSH1 0x24 DUP4 ADD MSTORE SWAP2 MLOAD PUSH1 0x0 SWAP3 DUP7 AND SWAP2 PUSH4 0x4D866592 SWAP2 PUSH1 0x44 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x744 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x758 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x76E JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD SWAP1 POP PUSH1 0x0 PUSH32 0x0 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB SWAP1 DUP2 AND SWAP1 DUP4 AND EQ DUP1 ISZERO SWAP1 PUSH2 0x7B9 JUMPI POP PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP3 AND ISZERO ISZERO JUMPDEST SWAP1 POP PUSH1 0x60 DUP2 PUSH2 0x7C9 JUMPI PUSH1 0x2 PUSH2 0x7CC JUMP JUMPDEST PUSH1 0x3 JUMPDEST PUSH1 0xFF AND PUSH8 0xFFFFFFFFFFFFFFFF DUP2 GT DUP1 ISZERO PUSH2 0x7E5 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x40 MLOAD SWAP1 DUP1 DUP3 MSTORE DUP1 PUSH1 0x20 MUL PUSH1 0x20 ADD DUP3 ADD PUSH1 0x40 MSTORE DUP1 ISZERO PUSH2 0x80F JUMPI DUP2 PUSH1 0x20 ADD PUSH1 0x20 DUP3 MUL DUP1 CALLDATASIZE DUP4 CALLDATACOPY ADD SWAP1 POP JUMPDEST POP SWAP1 POP DUP7 DUP2 PUSH1 0x0 DUP2 MLOAD DUP2 LT PUSH2 0x820 JUMPI INVALID JUMPDEST PUSH1 0x20 MUL PUSH1 0x20 ADD ADD SWAP1 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND SWAP1 DUP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 MSTORE POP POP DUP2 PUSH2 0x86B JUMPI PUSH32 0x0 PUSH2 0x86D JUMP JUMPDEST DUP3 JUMPDEST DUP2 PUSH1 0x1 DUP2 MLOAD DUP2 LT PUSH2 0x87A JUMPI INVALID JUMPDEST PUSH1 0x20 MUL PUSH1 0x20 ADD ADD SWAP1 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND SWAP1 DUP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 MSTORE POP POP DUP2 ISZERO PUSH2 0x8EF JUMPI PUSH32 0x0 DUP2 PUSH1 0x2 DUP2 MLOAD DUP2 LT PUSH2 0x8CE JUMPI INVALID JUMPDEST PUSH1 0x20 MUL PUSH1 0x20 ADD ADD SWAP1 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND SWAP1 DUP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 MSTORE POP POP JUMPDEST PUSH1 0x60 PUSH32 0x0 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0x38ED1739 DUP8 PUSH2 0x9B8 PUSH2 0x9AB PUSH2 0x2710 PUSH2 0x99F DUP14 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0x55323195 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x966 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x97A JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x990 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD DUP13 SWAP1 PUSH4 0xFFFFFFFF PUSH2 0xF78 AND JUMP JUMPDEST SWAP1 PUSH4 0xFFFFFFFF PUSH2 0xFDA AND JUMP JUMPDEST DUP10 SWAP1 PUSH4 0xFFFFFFFF PUSH2 0x101C AND JUMP JUMPDEST DUP6 ADDRESS TIMESTAMP PUSH1 0x40 MLOAD DUP7 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP7 DUP2 MSTORE PUSH1 0x20 ADD DUP6 DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH1 0x20 ADD DUP5 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 MSTORE PUSH1 0x20 ADD DUP4 DUP2 MSTORE PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE DUP6 DUP2 DUP2 MLOAD DUP2 MSTORE PUSH1 0x20 ADD SWAP2 POP DUP1 MLOAD SWAP1 PUSH1 0x20 ADD SWAP1 PUSH1 0x20 MUL DUP1 DUP4 DUP4 PUSH1 0x0 JUMPDEST DUP4 DUP2 LT ISZERO PUSH2 0xA34 JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0xA1C JUMP JUMPDEST POP POP POP POP SWAP1 POP ADD SWAP7 POP POP POP POP POP POP POP PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0xA5D JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0xA71 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x0 DUP3 RETURNDATACOPY PUSH1 0x1F RETURNDATASIZE SWAP1 DUP2 ADD PUSH1 0x1F NOT AND DUP3 ADD PUSH1 0x40 MSTORE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xA9A JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST DUP2 ADD SWAP1 DUP1 DUP1 MLOAD PUSH1 0x40 MLOAD SWAP4 SWAP3 SWAP2 SWAP1 DUP5 PUSH5 0x100000000 DUP3 GT ISZERO PUSH2 0xABA JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST SWAP1 DUP4 ADD SWAP1 PUSH1 0x20 DUP3 ADD DUP6 DUP2 GT ISZERO PUSH2 0xACF JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST DUP3 MLOAD DUP7 PUSH1 0x20 DUP3 MUL DUP4 ADD GT PUSH5 0x100000000 DUP3 GT OR ISZERO PUSH2 0xAEC JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST DUP3 MSTORE POP DUP2 MLOAD PUSH1 0x20 SWAP2 DUP3 ADD SWAP3 DUP3 ADD SWAP2 MUL DUP1 DUP4 DUP4 PUSH1 0x0 JUMPDEST DUP4 DUP2 LT ISZERO PUSH2 0xB19 JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0xB01 JUMP JUMPDEST POP POP POP POP SWAP1 POP ADD PUSH1 0x40 MSTORE POP POP POP SWAP1 POP DUP8 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH32 0x5D9559ADA0F8509A7FFFB4C05FA6F4F9DF6772AC68A8F6AC87C36F00FF3843A1 DUP3 PUSH1 0x0 DUP2 MLOAD DUP2 LT PUSH2 0xB60 JUMPI INVALID JUMPDEST PUSH1 0x20 MUL PUSH1 0x20 ADD ADD MLOAD DUP4 PUSH1 0x1 DUP7 MLOAD SUB DUP2 MLOAD DUP2 LT PUSH2 0xB78 JUMPI INVALID JUMPDEST PUSH1 0x20 MUL PUSH1 0x20 ADD ADD MLOAD PUSH1 0x40 MLOAD DUP1 DUP4 DUP2 MSTORE PUSH1 0x20 ADD DUP3 DUP2 MSTORE PUSH1 0x20 ADD SWAP3 POP POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 LOG2 POP POP POP POP POP POP POP POP JUMP JUMPDEST PUSH32 0x0 DUP2 JUMP JUMPDEST PUSH1 0x0 DUP1 SWAP1 SLOAD SWAP1 PUSH2 0x100 EXP SWAP1 DIV PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0xC340A24 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0xC17 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0xC2B JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xC41 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND CALLER EQ PUSH2 0xC8C JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0xA PUSH1 0x24 DUP3 ADD MSTORE PUSH10 0x26AA1D2727AA2FA3A7AB PUSH1 0xB1 SHL PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH2 0xCA6 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP4 AND CALLER DUP4 PUSH4 0xFFFFFFFF PUSH2 0xE0E AND JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD DUP3 DUP2 MSTORE SWAP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP5 AND SWAP2 PUSH32 0xA0EA1D68F48CD2FF8A7DB3AAA2D99DBDB957E097C7CC559F7E738832678C41FF SWAP2 SWAP1 DUP2 SWAP1 SUB PUSH1 0x20 ADD SWAP1 LOG2 POP POP JUMP JUMPDEST PUSH1 0x0 SLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 JUMP JUMPDEST PUSH1 0x0 DUP1 SWAP1 SLOAD SWAP1 PUSH2 0x100 EXP SWAP1 DIV PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0xC340A24 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0xD45 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0xD59 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xD6F JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND CALLER EQ PUSH2 0xDBA JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0xA PUSH1 0x24 DUP3 ADD MSTORE PUSH10 0x26AA1D2727AA2FA3A7AB PUSH1 0xB1 SHL PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH1 0x0 DUP1 SLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP4 AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB NOT SWAP1 SWAP2 AND DUP2 OR SWAP1 SWAP2 SSTORE PUSH1 0x40 DUP1 MLOAD SWAP2 DUP3 MSTORE MLOAD PUSH32 0xDA36F26252AA35D26238345E2C339CDBFEB26CE49721030CA8E907AB1701AC8F SWAP2 DUP2 SWAP1 SUB PUSH1 0x20 ADD SWAP1 LOG1 POP JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP5 AND PUSH1 0x24 DUP3 ADD MSTORE PUSH1 0x44 DUP1 DUP3 ADD DUP5 SWAP1 MSTORE DUP3 MLOAD DUP1 DUP4 SUB SWAP1 SWAP2 ADD DUP2 MSTORE PUSH1 0x64 SWAP1 SWAP2 ADD SWAP1 SWAP2 MSTORE PUSH1 0x20 DUP2 ADD DUP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xE0 SHL SUB AND PUSH4 0xA9059CBB PUSH1 0xE0 SHL OR SWAP1 MSTORE PUSH2 0xE60 SWAP1 DUP5 SWAP1 PUSH2 0x105E JUMP JUMPDEST POP POP POP JUMP JUMPDEST DUP1 ISZERO DUP1 PUSH2 0xEEB JUMPI POP PUSH1 0x40 DUP1 MLOAD PUSH4 0x6EB1769F PUSH1 0xE1 SHL DUP2 MSTORE ADDRESS PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP5 DUP2 AND PUSH1 0x24 DUP4 ADD MSTORE SWAP2 MLOAD SWAP2 DUP6 AND SWAP2 PUSH4 0xDD62ED3E SWAP2 PUSH1 0x44 DUP1 DUP3 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP1 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0xEBD JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0xED1 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xEE7 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD ISZERO JUMPDEST PUSH2 0xF26 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE PUSH1 0x36 DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH2 0x145E PUSH1 0x36 SWAP2 CODECOPY PUSH1 0x40 ADD SWAP2 POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP5 AND PUSH1 0x24 DUP3 ADD MSTORE PUSH1 0x44 DUP1 DUP3 ADD DUP5 SWAP1 MSTORE DUP3 MLOAD DUP1 DUP4 SUB SWAP1 SWAP2 ADD DUP2 MSTORE PUSH1 0x64 SWAP1 SWAP2 ADD SWAP1 SWAP2 MSTORE PUSH1 0x20 DUP2 ADD DUP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xE0 SHL SUB AND PUSH4 0x95EA7B3 PUSH1 0xE0 SHL OR SWAP1 MSTORE PUSH2 0xE60 SWAP1 DUP5 SWAP1 PUSH2 0x105E JUMP JUMPDEST PUSH1 0x0 DUP3 PUSH2 0xF87 JUMPI POP PUSH1 0x0 PUSH2 0xFD4 JUMP JUMPDEST DUP3 DUP3 MUL DUP3 DUP5 DUP3 DUP2 PUSH2 0xF94 JUMPI INVALID JUMPDEST DIV EQ PUSH2 0xFD1 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE PUSH1 0x21 DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH2 0x1413 PUSH1 0x21 SWAP2 CODECOPY PUSH1 0x40 ADD SWAP2 POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST SWAP1 POP JUMPDEST SWAP3 SWAP2 POP POP JUMP JUMPDEST PUSH1 0x0 PUSH2 0xFD1 DUP4 DUP4 PUSH1 0x40 MLOAD DUP1 PUSH1 0x40 ADD PUSH1 0x40 MSTORE DUP1 PUSH1 0x1A DUP2 MSTORE PUSH1 0x20 ADD PUSH32 0x536166654D6174683A206469766973696F6E206279207A65726F000000000000 DUP2 MSTORE POP PUSH2 0x110F JUMP JUMPDEST PUSH1 0x0 PUSH2 0xFD1 DUP4 DUP4 PUSH1 0x40 MLOAD DUP1 PUSH1 0x40 ADD PUSH1 0x40 MSTORE DUP1 PUSH1 0x1E DUP2 MSTORE PUSH1 0x20 ADD PUSH32 0x536166654D6174683A207375627472616374696F6E206F766572666C6F770000 DUP2 MSTORE POP PUSH2 0x11B3 JUMP JUMPDEST PUSH1 0x60 PUSH2 0x10B3 DUP3 PUSH1 0x40 MLOAD DUP1 PUSH1 0x40 ADD PUSH1 0x40 MSTORE DUP1 PUSH1 0x20 DUP2 MSTORE PUSH1 0x20 ADD PUSH32 0x5361666545524332303A206C6F772D6C6576656C2063616C6C206661696C6564 DUP2 MSTORE POP DUP6 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH2 0x120D SWAP1 SWAP3 SWAP2 SWAP1 PUSH4 0xFFFFFFFF AND JUMP JUMPDEST DUP1 MLOAD SWAP1 SWAP2 POP ISZERO PUSH2 0xE60 JUMPI DUP1 DUP1 PUSH1 0x20 ADD SWAP1 MLOAD PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x10D2 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH2 0xE60 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE PUSH1 0x2A DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH2 0x1434 PUSH1 0x2A SWAP2 CODECOPY PUSH1 0x40 ADD SWAP2 POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST PUSH1 0x0 DUP2 DUP4 PUSH2 0x119B JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE DUP4 DUP2 DUP2 MLOAD DUP2 MSTORE PUSH1 0x20 ADD SWAP2 POP DUP1 MLOAD SWAP1 PUSH1 0x20 ADD SWAP1 DUP1 DUP4 DUP4 PUSH1 0x0 JUMPDEST DUP4 DUP2 LT ISZERO PUSH2 0x1160 JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0x1148 JUMP JUMPDEST POP POP POP POP SWAP1 POP SWAP1 DUP2 ADD SWAP1 PUSH1 0x1F AND DUP1 ISZERO PUSH2 0x118D JUMPI DUP1 DUP3 SUB DUP1 MLOAD PUSH1 0x1 DUP4 PUSH1 0x20 SUB PUSH2 0x100 EXP SUB NOT AND DUP2 MSTORE PUSH1 0x20 ADD SWAP2 POP JUMPDEST POP SWAP3 POP POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST POP PUSH1 0x0 DUP4 DUP6 DUP2 PUSH2 0x11A7 JUMPI INVALID JUMPDEST DIV SWAP2 POP POP JUMPDEST SWAP4 SWAP3 POP POP POP JUMP JUMPDEST PUSH1 0x0 DUP2 DUP5 DUP5 GT ISZERO PUSH2 0x1205 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD DUP2 DUP2 MSTORE DUP4 MLOAD PUSH1 0x24 DUP5 ADD MSTORE DUP4 MLOAD SWAP1 SWAP3 DUP4 SWAP3 PUSH1 0x44 SWAP1 SWAP2 ADD SWAP2 SWAP1 DUP6 ADD SWAP1 DUP1 DUP4 DUP4 PUSH1 0x0 DUP4 ISZERO PUSH2 0x1160 JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0x1148 JUMP JUMPDEST POP POP POP SWAP1 SUB SWAP1 JUMP JUMPDEST PUSH1 0x60 PUSH2 0x121C DUP5 DUP5 PUSH1 0x0 DUP6 PUSH2 0x1224 JUMP JUMPDEST SWAP5 SWAP4 POP POP POP POP JUMP JUMPDEST PUSH1 0x60 DUP3 SELFBALANCE LT ISZERO PUSH2 0x1265 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE PUSH1 0x26 DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH2 0x13ED PUSH1 0x26 SWAP2 CODECOPY PUSH1 0x40 ADD SWAP2 POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST PUSH2 0x126E DUP6 PUSH2 0x1380 JUMP JUMPDEST PUSH2 0x12BF JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0x1D PUSH1 0x24 DUP3 ADD MSTORE PUSH32 0x416464726573733A2063616C6C20746F206E6F6E2D636F6E7472616374000000 PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH1 0x0 PUSH1 0x60 DUP7 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP6 DUP8 PUSH1 0x40 MLOAD DUP1 DUP3 DUP1 MLOAD SWAP1 PUSH1 0x20 ADD SWAP1 DUP1 DUP4 DUP4 JUMPDEST PUSH1 0x20 DUP4 LT PUSH2 0x12FE JUMPI DUP1 MLOAD DUP3 MSTORE PUSH1 0x1F NOT SWAP1 SWAP3 ADD SWAP2 PUSH1 0x20 SWAP2 DUP3 ADD SWAP2 ADD PUSH2 0x12DF JUMP JUMPDEST PUSH1 0x1 DUP4 PUSH1 0x20 SUB PUSH2 0x100 EXP SUB DUP1 NOT DUP3 MLOAD AND DUP2 DUP5 MLOAD AND DUP1 DUP3 OR DUP6 MSTORE POP POP POP POP POP POP SWAP1 POP ADD SWAP2 POP POP PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP6 DUP8 GAS CALL SWAP3 POP POP POP RETURNDATASIZE DUP1 PUSH1 0x0 DUP2 EQ PUSH2 0x1360 JUMPI PUSH1 0x40 MLOAD SWAP2 POP PUSH1 0x1F NOT PUSH1 0x3F RETURNDATASIZE ADD AND DUP3 ADD PUSH1 0x40 MSTORE RETURNDATASIZE DUP3 MSTORE RETURNDATASIZE PUSH1 0x0 PUSH1 0x20 DUP5 ADD RETURNDATACOPY PUSH2 0x1365 JUMP JUMPDEST PUSH1 0x60 SWAP2 POP JUMPDEST POP SWAP2 POP SWAP2 POP PUSH2 0x1375 DUP3 DUP3 DUP7 PUSH2 0x1386 JUMP JUMPDEST SWAP8 SWAP7 POP POP POP POP POP POP POP JUMP JUMPDEST EXTCODESIZE ISZERO ISZERO SWAP1 JUMP JUMPDEST PUSH1 0x60 DUP4 ISZERO PUSH2 0x1395 JUMPI POP DUP2 PUSH2 0x11AC JUMP JUMPDEST DUP3 MLOAD ISZERO PUSH2 0x13A5 JUMPI DUP3 MLOAD DUP1 DUP5 PUSH1 0x20 ADD REVERT JUMPDEST PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD DUP2 DUP2 MSTORE DUP5 MLOAD PUSH1 0x24 DUP5 ADD MSTORE DUP5 MLOAD DUP6 SWAP4 SWAP2 SWAP3 DUP4 SWAP3 PUSH1 0x44 ADD SWAP2 SWAP1 DUP6 ADD SWAP1 DUP1 DUP4 DUP4 PUSH1 0x0 DUP4 ISZERO PUSH2 0x1160 JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0x1148 JUMP INVALID COINBASE PUSH5 0x6472657373 GASPRICE KECCAK256 PUSH10 0x6E73756666696369656E PUSH21 0x2062616C616E636520666F722063616C6C53616665 0x4D PUSH2 0x7468 GASPRICE KECCAK256 PUSH14 0x756C7469706C69636174696F6E20 PUSH16 0x766572666C6F77536166654552433230 GASPRICE KECCAK256 GASLIMIT MSTORE NUMBER ORIGIN ADDRESS KECCAK256 PUSH16 0x7065726174696F6E20646964206E6F74 KECCAK256 PUSH20 0x7563636565645361666545524332303A20617070 PUSH19 0x6F76652066726F6D206E6F6E2D7A65726F2074 PUSH16 0x206E6F6E2D7A65726F20616C6C6F7761 PUSH15 0x6365A2646970667358221220973167 SLT DUP15 0xF7 SHR INVALID LOG1 0xB6 0x4A SWAP6 DUP5 PUSH7 0x22FC08CA542496 SIGNEXTEND SWAP10 0x22 0xB9 ADD 0xC2 0xE3 DIV 0xC SWAP4 0xDE PUSH5 0x736F6C6343 STOP MOD SIGNEXTEND STOP CALLER ",
"sourceMap": "46566:3169:0:-:0;;;47277:282;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;47277:282:0;;;;;;;;;;;;;;;47421:20;;;-1:-1:-1;;;;;;47421:20:0;;;47277:282;47421:20;47451:27;;;;;;;47488:30;;;;;;;;;47528:7;:24;;-1:-1:-1;;;;;;47528:24:0;-1:-1:-1;;;;;47528:24:0;;;;;;46566:3169;;;;;;;;;;;;;;;;;;;;;"
},
"deployedBytecode": {
"immutableReferences": {
"1423": [
{
"length": 32,
"start": 693
},
{
"length": 32,
"start": 738
},
{
"length": 32,
"start": 2984
}
],
"1426": [
{
"length": 32,
"start": 549
},
{
"length": 32,
"start": 909
},
{
"length": 32,
"start": 1175
},
{
"length": 32,
"start": 1471
},
{
"length": 32,
"start": 1777
},
{
"length": 32,
"start": 1910
},
{
"length": 32,
"start": 2119
},
{
"length": 32,
"start": 2210
}
],
"1429": [
{
"length": 32,
"start": 945
},
{
"length": 32,
"start": 1643
},
{
"length": 32,
"start": 1702
},
{
"length": 32,
"start": 2291
}
]
},
"linkReferences": {
"contracts/core/treasury/v1/MapleTreasury.sol": {
"Util": [
{
"length": 20,
"start": 1525
}
]
}
},
"object": "608060405234801561001057600080fd5b50600436106100885760003560e01c8063a05309461161005b578063a0530946146100e9578063afdbd499146100f1578063c31245251461011d578063cc2e0a261461012557610088565b80633153689f1461008d57806363f04b1514610097578063735de9f7146100bb578063817bd4fd146100c3575b600080fd5b61009561014b565b005b61009f61038b565b604080516001600160a01b039092168252519081900360200190f35b61009f6103af565b610095600480360360208110156100d957600080fd5b50356001600160a01b03166103d3565b61009f610ba6565b6100956004803603604081101561010757600080fd5b506001600160a01b038135169060200135610bca565b61009f610ce9565b6100956004803603602081101561013b57600080fd5b50356001600160a01b0316610cf8565b6000809054906101000a90046001600160a01b03166001600160a01b0316630c340a246040518163ffffffff1660e01b815260040160206040518083038186803b15801561019857600080fd5b505afa1580156101ac573d6000803e3d6000fd5b505050506040513d60208110156101c257600080fd5b50516001600160a01b0316331461020d576040805162461bcd60e51b815260206004820152600a60248201526926aa1d2727aa2fa3a7ab60b11b604482015290519081900360640190fd5b604080516370a0823160e01b815230600482015290517f0000000000000000000000000000000000000000000000000000000000000000916000916001600160a01b038416916370a08231916024808301926020929190829003018186803b15801561027857600080fd5b505afa15801561028c573d6000803e3d6000fd5b505050506040513d60208110156102a257600080fd5b505190506102e06001600160a01b0383167f00000000000000000000000000000000000000000000000000000000000000008363ffffffff610e0e16565b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166346c162de6040518163ffffffff1660e01b8152600401600060405180830381600087803b15801561033b57600080fd5b505af115801561034f573d6000803e3d6000fd5b50506040805184815290517faa7ec7b1d6110de9a1bf05a7214112bcaee913a07e31bd219f50af4b0ee0469d9350908190036020019150a15050565b7f000000000000000000000000000000000000000000000000000000000000000081565b7f000000000000000000000000000000000000000000000000000000000000000081565b6000809054906101000a90046001600160a01b03166001600160a01b0316630c340a246040518163ffffffff1660e01b815260040160206040518083038186803b15801561042057600080fd5b505afa158015610434573d6000803e3d6000fd5b505050506040513d602081101561044a57600080fd5b50516001600160a01b03163314610495576040805162461bcd60e51b815260206004820152600a60248201526926aa1d2727aa2fa3a7ab60b11b604482015290519081900360640190fd5b7f00000000000000000000000000000000000000000000000000000000000000006001600160a01b0316816001600160a01b0316141561051c576040805162461bcd60e51b815260206004820152601760248201527f4d543a41535345545f49535f46554e44535f544f4b454e000000000000000000604482015290519081900360640190fd5b60008054604080516370a0823160e01b815230600482015290516001600160a01b0392831693928516916370a08231916024808301926020929190829003018186803b15801561056b57600080fd5b505afa15801561057f573d6000803e3d6000fd5b505050506040513d602081101561059557600080fd5b5051604080516360f1b8c360e11b81526001600160a01b03808616600483015280871660248301527f000000000000000000000000000000000000000000000000000000000000000016604482015260648101839052905191925060009173__$9a7f24476bec8cd7609119e3792aeabf73$__9163c1e37186916084808301926020929190829003018186803b15801561062e57600080fd5b505af4158015610642573d6000803e3d6000fd5b505050506040513d602081101561065857600080fd5b505190506106976001600160a01b0385167f0000000000000000000000000000000000000000000000000000000000000000600063ffffffff610e6516565b6106d16001600160a01b0385167f00000000000000000000000000000000000000000000000000000000000000008463ffffffff610e6516565b604080516326c332c960e11b81526001600160a01b0386811660048301527f0000000000000000000000000000000000000000000000000000000000000000811660248301529151600092861691634d866592916044808301926020929190829003018186803b15801561074457600080fd5b505afa158015610758573d6000803e3d6000fd5b505050506040513d602081101561076e57600080fd5b5051905060007f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03908116908316148015906107b957506001600160a01b03821615155b90506060816107c95760026107cc565b60035b60ff1667ffffffffffffffff811180156107e557600080fd5b5060405190808252806020026020018201604052801561080f578160200160208202803683370190505b509050868160008151811061082057fe5b60200260200101906001600160a01b031690816001600160a01b0316815250508161086b577f000000000000000000000000000000000000000000000000000000000000000061086d565b825b8160018151811061087a57fe5b60200260200101906001600160a01b031690816001600160a01b03168152505081156108ef577f0000000000000000000000000000000000000000000000000000000000000000816002815181106108ce57fe5b60200260200101906001600160a01b031690816001600160a01b0316815250505b60607f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03166338ed1739876109b86109ab61271061099f8d6001600160a01b031663553231956040518163ffffffff1660e01b815260040160206040518083038186803b15801561096657600080fd5b505afa15801561097a573d6000803e3d6000fd5b505050506040513d602081101561099057600080fd5b50518c9063ffffffff610f7816565b9063ffffffff610fda16565b899063ffffffff61101c16565b8530426040518663ffffffff1660e01b81526004018086815260200185815260200180602001846001600160a01b03166001600160a01b03168152602001838152602001828103825285818151815260200191508051906020019060200280838360005b83811015610a34578181015183820152602001610a1c565b505050509050019650505050505050600060405180830381600087803b158015610a5d57600080fd5b505af1158015610a71573d6000803e3d6000fd5b505050506040513d6000823e601f3d908101601f191682016040526020811015610a9a57600080fd5b8101908080516040519392919084640100000000821115610aba57600080fd5b908301906020820185811115610acf57600080fd5b8251866020820283011164010000000082111715610aec57600080fd5b82525081516020918201928201910280838360005b83811015610b19578181015183820152602001610b01565b505050509050016040525050509050876001600160a01b03167f5d9559ada0f8509a7fffb4c05fa6f4f9df6772ac68a8f6ac87c36f00ff3843a182600081518110610b6057fe5b602002602001015183600186510381518110610b7857fe5b6020026020010151604051808381526020018281526020019250505060405180910390a25050505050505050565b7f000000000000000000000000000000000000000000000000000000000000000081565b6000809054906101000a90046001600160a01b03166001600160a01b0316630c340a246040518163ffffffff1660e01b815260040160206040518083038186803b158015610c1757600080fd5b505afa158015610c2b573d6000803e3d6000fd5b505050506040513d6020811015610c4157600080fd5b50516001600160a01b03163314610c8c576040805162461bcd60e51b815260206004820152600a60248201526926aa1d2727aa2fa3a7ab60b11b604482015290519081900360640190fd5b610ca66001600160a01b038316338363ffffffff610e0e16565b6040805182815290516001600160a01b038416917fa0ea1d68f48cd2ff8a7db3aaa2d99dbdb957e097c7cc559f7e738832678c41ff919081900360200190a25050565b6000546001600160a01b031681565b6000809054906101000a90046001600160a01b03166001600160a01b0316630c340a246040518163ffffffff1660e01b815260040160206040518083038186803b158015610d4557600080fd5b505afa158015610d59573d6000803e3d6000fd5b505050506040513d6020811015610d6f57600080fd5b50516001600160a01b03163314610dba576040805162461bcd60e51b815260206004820152600a60248201526926aa1d2727aa2fa3a7ab60b11b604482015290519081900360640190fd5b600080546001600160a01b0383166001600160a01b0319909116811790915560408051918252517fda36f26252aa35d26238345e2c339cdbfeb26ce49721030ca8e907ab1701ac8f9181900360200190a150565b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663a9059cbb60e01b179052610e6090849061105e565b505050565b801580610eeb575060408051636eb1769f60e11b81523060048201526001600160a01b03848116602483015291519185169163dd62ed3e91604480820192602092909190829003018186803b158015610ebd57600080fd5b505afa158015610ed1573d6000803e3d6000fd5b505050506040513d6020811015610ee757600080fd5b5051155b610f265760405162461bcd60e51b815260040180806020018281038252603681526020018061145e6036913960400191505060405180910390fd5b604080516001600160a01b038416602482015260448082018490528251808303909101815260649091019091526020810180516001600160e01b031663095ea7b360e01b179052610e6090849061105e565b600082610f8757506000610fd4565b82820282848281610f9457fe5b0414610fd15760405162461bcd60e51b81526004018080602001828103825260218152602001806114136021913960400191505060405180910390fd5b90505b92915050565b6000610fd183836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f00000000000081525061110f565b6000610fd183836040518060400160405280601e81526020017f536166654d6174683a207375627472616374696f6e206f766572666c6f7700008152506111b3565b60606110b3826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564815250856001600160a01b031661120d9092919063ffffffff16565b805190915015610e60578080602001905160208110156110d257600080fd5b5051610e605760405162461bcd60e51b815260040180806020018281038252602a815260200180611434602a913960400191505060405180910390fd5b6000818361119b5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b83811015611160578181015183820152602001611148565b50505050905090810190601f16801561118d5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816111a757fe5b049150505b9392505050565b600081848411156112055760405162461bcd60e51b8152602060048201818152835160248401528351909283926044909101919085019080838360008315611160578181015183820152602001611148565b505050900390565b606061121c8484600085611224565b949350505050565b6060824710156112655760405162461bcd60e51b81526004018080602001828103825260268152602001806113ed6026913960400191505060405180910390fd5b61126e85611380565b6112bf576040805162461bcd60e51b815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015290519081900360640190fd5b60006060866001600160a01b031685876040518082805190602001908083835b602083106112fe5780518252601f1990920191602091820191016112df565b6001836020036101000a03801982511681845116808217855250505050505090500191505060006040518083038185875af1925050503d8060008114611360576040519150601f19603f3d011682016040523d82523d6000602084013e611365565b606091505b5091509150611375828286611386565b979650505050505050565b3b151590565b606083156113955750816111ac565b8251156113a55782518084602001fd5b60405162461bcd60e51b815260206004820181815284516024840152845185939192839260440191908501908083836000831561116057818101518382015260200161114856fe416464726573733a20696e73756666696369656e742062616c616e636520666f722063616c6c536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f775361666545524332303a204552433230206f7065726174696f6e20646964206e6f7420737563636565645361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f20746f206e6f6e2d7a65726f20616c6c6f77616e6365a2646970667358221220973167128ef71cfea1b64a95846622fc08ca5424960b9922b901c2e3040c93de64736f6c634300060b0033",
"opcodes": "PUSH1 0x80 PUSH1 0x40 MSTORE CALLVALUE DUP1 ISZERO PUSH2 0x10 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x4 CALLDATASIZE LT PUSH2 0x88 JUMPI PUSH1 0x0 CALLDATALOAD PUSH1 0xE0 SHR DUP1 PUSH4 0xA0530946 GT PUSH2 0x5B JUMPI DUP1 PUSH4 0xA0530946 EQ PUSH2 0xE9 JUMPI DUP1 PUSH4 0xAFDBD499 EQ PUSH2 0xF1 JUMPI DUP1 PUSH4 0xC3124525 EQ PUSH2 0x11D JUMPI DUP1 PUSH4 0xCC2E0A26 EQ PUSH2 0x125 JUMPI PUSH2 0x88 JUMP JUMPDEST DUP1 PUSH4 0x3153689F EQ PUSH2 0x8D JUMPI DUP1 PUSH4 0x63F04B15 EQ PUSH2 0x97 JUMPI DUP1 PUSH4 0x735DE9F7 EQ PUSH2 0xBB JUMPI DUP1 PUSH4 0x817BD4FD EQ PUSH2 0xC3 JUMPI JUMPDEST PUSH1 0x0 DUP1 REVERT JUMPDEST PUSH2 0x95 PUSH2 0x14B JUMP JUMPDEST STOP JUMPDEST PUSH2 0x9F PUSH2 0x38B JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB SWAP1 SWAP3 AND DUP3 MSTORE MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x20 ADD SWAP1 RETURN JUMPDEST PUSH2 0x9F PUSH2 0x3AF JUMP JUMPDEST PUSH2 0x95 PUSH1 0x4 DUP1 CALLDATASIZE SUB PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xD9 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP CALLDATALOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH2 0x3D3 JUMP JUMPDEST PUSH2 0x9F PUSH2 0xBA6 JUMP JUMPDEST PUSH2 0x95 PUSH1 0x4 DUP1 CALLDATASIZE SUB PUSH1 0x40 DUP2 LT ISZERO PUSH2 0x107 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP2 CALLDATALOAD AND SWAP1 PUSH1 0x20 ADD CALLDATALOAD PUSH2 0xBCA JUMP JUMPDEST PUSH2 0x9F PUSH2 0xCE9 JUMP JUMPDEST PUSH2 0x95 PUSH1 0x4 DUP1 CALLDATASIZE SUB PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x13B JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP CALLDATALOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH2 0xCF8 JUMP JUMPDEST PUSH1 0x0 DUP1 SWAP1 SLOAD SWAP1 PUSH2 0x100 EXP SWAP1 DIV PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0xC340A24 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x198 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x1AC JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x1C2 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND CALLER EQ PUSH2 0x20D JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0xA PUSH1 0x24 DUP3 ADD MSTORE PUSH10 0x26AA1D2727AA2FA3A7AB PUSH1 0xB1 SHL PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH4 0x70A08231 PUSH1 0xE0 SHL DUP2 MSTORE ADDRESS PUSH1 0x4 DUP3 ADD MSTORE SWAP1 MLOAD PUSH32 0x0 SWAP2 PUSH1 0x0 SWAP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP5 AND SWAP2 PUSH4 0x70A08231 SWAP2 PUSH1 0x24 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x278 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x28C JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x2A2 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD SWAP1 POP PUSH2 0x2E0 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP4 AND PUSH32 0x0 DUP4 PUSH4 0xFFFFFFFF PUSH2 0xE0E AND JUMP JUMPDEST PUSH32 0x0 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0x46C162DE PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x33B JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0x34F JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP PUSH1 0x40 DUP1 MLOAD DUP5 DUP2 MSTORE SWAP1 MLOAD PUSH32 0xAA7EC7B1D6110DE9A1BF05A7214112BCAEE913A07E31BD219F50AF4B0EE0469D SWAP4 POP SWAP1 DUP2 SWAP1 SUB PUSH1 0x20 ADD SWAP2 POP LOG1 POP POP JUMP JUMPDEST PUSH32 0x0 DUP2 JUMP JUMPDEST PUSH32 0x0 DUP2 JUMP JUMPDEST PUSH1 0x0 DUP1 SWAP1 SLOAD SWAP1 PUSH2 0x100 EXP SWAP1 DIV PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0xC340A24 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x420 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x434 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x44A JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND CALLER EQ PUSH2 0x495 JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0xA PUSH1 0x24 DUP3 ADD MSTORE PUSH10 0x26AA1D2727AA2FA3A7AB PUSH1 0xB1 SHL PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH32 0x0 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND EQ ISZERO PUSH2 0x51C JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0x17 PUSH1 0x24 DUP3 ADD MSTORE PUSH32 0x4D543A41535345545F49535F46554E44535F544F4B454E000000000000000000 PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH1 0x0 DUP1 SLOAD PUSH1 0x40 DUP1 MLOAD PUSH4 0x70A08231 PUSH1 0xE0 SHL DUP2 MSTORE ADDRESS PUSH1 0x4 DUP3 ADD MSTORE SWAP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB SWAP3 DUP4 AND SWAP4 SWAP3 DUP6 AND SWAP2 PUSH4 0x70A08231 SWAP2 PUSH1 0x24 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x56B JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x57F JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x595 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x40 DUP1 MLOAD PUSH4 0x60F1B8C3 PUSH1 0xE1 SHL DUP2 MSTORE PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP1 DUP7 AND PUSH1 0x4 DUP4 ADD MSTORE DUP1 DUP8 AND PUSH1 0x24 DUP4 ADD MSTORE PUSH32 0x0 AND PUSH1 0x44 DUP3 ADD MSTORE PUSH1 0x64 DUP2 ADD DUP4 SWAP1 MSTORE SWAP1 MLOAD SWAP2 SWAP3 POP PUSH1 0x0 SWAP2 PUSH20 0x0 SWAP2 PUSH4 0xC1E37186 SWAP2 PUSH1 0x84 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x62E JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS DELEGATECALL ISZERO DUP1 ISZERO PUSH2 0x642 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x658 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD SWAP1 POP PUSH2 0x697 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP6 AND PUSH32 0x0 PUSH1 0x0 PUSH4 0xFFFFFFFF PUSH2 0xE65 AND JUMP JUMPDEST PUSH2 0x6D1 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP6 AND PUSH32 0x0 DUP5 PUSH4 0xFFFFFFFF PUSH2 0xE65 AND JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH4 0x26C332C9 PUSH1 0xE1 SHL DUP2 MSTORE PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP7 DUP2 AND PUSH1 0x4 DUP4 ADD MSTORE PUSH32 0x0 DUP2 AND PUSH1 0x24 DUP4 ADD MSTORE SWAP2 MLOAD PUSH1 0x0 SWAP3 DUP7 AND SWAP2 PUSH4 0x4D866592 SWAP2 PUSH1 0x44 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x744 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x758 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x76E JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD SWAP1 POP PUSH1 0x0 PUSH32 0x0 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB SWAP1 DUP2 AND SWAP1 DUP4 AND EQ DUP1 ISZERO SWAP1 PUSH2 0x7B9 JUMPI POP PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP3 AND ISZERO ISZERO JUMPDEST SWAP1 POP PUSH1 0x60 DUP2 PUSH2 0x7C9 JUMPI PUSH1 0x2 PUSH2 0x7CC JUMP JUMPDEST PUSH1 0x3 JUMPDEST PUSH1 0xFF AND PUSH8 0xFFFFFFFFFFFFFFFF DUP2 GT DUP1 ISZERO PUSH2 0x7E5 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x40 MLOAD SWAP1 DUP1 DUP3 MSTORE DUP1 PUSH1 0x20 MUL PUSH1 0x20 ADD DUP3 ADD PUSH1 0x40 MSTORE DUP1 ISZERO PUSH2 0x80F JUMPI DUP2 PUSH1 0x20 ADD PUSH1 0x20 DUP3 MUL DUP1 CALLDATASIZE DUP4 CALLDATACOPY ADD SWAP1 POP JUMPDEST POP SWAP1 POP DUP7 DUP2 PUSH1 0x0 DUP2 MLOAD DUP2 LT PUSH2 0x820 JUMPI INVALID JUMPDEST PUSH1 0x20 MUL PUSH1 0x20 ADD ADD SWAP1 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND SWAP1 DUP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 MSTORE POP POP DUP2 PUSH2 0x86B JUMPI PUSH32 0x0 PUSH2 0x86D JUMP JUMPDEST DUP3 JUMPDEST DUP2 PUSH1 0x1 DUP2 MLOAD DUP2 LT PUSH2 0x87A JUMPI INVALID JUMPDEST PUSH1 0x20 MUL PUSH1 0x20 ADD ADD SWAP1 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND SWAP1 DUP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 MSTORE POP POP DUP2 ISZERO PUSH2 0x8EF JUMPI PUSH32 0x0 DUP2 PUSH1 0x2 DUP2 MLOAD DUP2 LT PUSH2 0x8CE JUMPI INVALID JUMPDEST PUSH1 0x20 MUL PUSH1 0x20 ADD ADD SWAP1 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND SWAP1 DUP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 MSTORE POP POP JUMPDEST PUSH1 0x60 PUSH32 0x0 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0x38ED1739 DUP8 PUSH2 0x9B8 PUSH2 0x9AB PUSH2 0x2710 PUSH2 0x99F DUP14 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0x55323195 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x966 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x97A JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x990 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD DUP13 SWAP1 PUSH4 0xFFFFFFFF PUSH2 0xF78 AND JUMP JUMPDEST SWAP1 PUSH4 0xFFFFFFFF PUSH2 0xFDA AND JUMP JUMPDEST DUP10 SWAP1 PUSH4 0xFFFFFFFF PUSH2 0x101C AND JUMP JUMPDEST DUP6 ADDRESS TIMESTAMP PUSH1 0x40 MLOAD DUP7 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP7 DUP2 MSTORE PUSH1 0x20 ADD DUP6 DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH1 0x20 ADD DUP5 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 MSTORE PUSH1 0x20 ADD DUP4 DUP2 MSTORE PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE DUP6 DUP2 DUP2 MLOAD DUP2 MSTORE PUSH1 0x20 ADD SWAP2 POP DUP1 MLOAD SWAP1 PUSH1 0x20 ADD SWAP1 PUSH1 0x20 MUL DUP1 DUP4 DUP4 PUSH1 0x0 JUMPDEST DUP4 DUP2 LT ISZERO PUSH2 0xA34 JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0xA1C JUMP JUMPDEST POP POP POP POP SWAP1 POP ADD SWAP7 POP POP POP POP POP POP POP PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 PUSH1 0x0 DUP8 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0xA5D JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS CALL ISZERO DUP1 ISZERO PUSH2 0xA71 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x0 DUP3 RETURNDATACOPY PUSH1 0x1F RETURNDATASIZE SWAP1 DUP2 ADD PUSH1 0x1F NOT AND DUP3 ADD PUSH1 0x40 MSTORE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xA9A JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST DUP2 ADD SWAP1 DUP1 DUP1 MLOAD PUSH1 0x40 MLOAD SWAP4 SWAP3 SWAP2 SWAP1 DUP5 PUSH5 0x100000000 DUP3 GT ISZERO PUSH2 0xABA JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST SWAP1 DUP4 ADD SWAP1 PUSH1 0x20 DUP3 ADD DUP6 DUP2 GT ISZERO PUSH2 0xACF JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST DUP3 MLOAD DUP7 PUSH1 0x20 DUP3 MUL DUP4 ADD GT PUSH5 0x100000000 DUP3 GT OR ISZERO PUSH2 0xAEC JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST DUP3 MSTORE POP DUP2 MLOAD PUSH1 0x20 SWAP2 DUP3 ADD SWAP3 DUP3 ADD SWAP2 MUL DUP1 DUP4 DUP4 PUSH1 0x0 JUMPDEST DUP4 DUP2 LT ISZERO PUSH2 0xB19 JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0xB01 JUMP JUMPDEST POP POP POP POP SWAP1 POP ADD PUSH1 0x40 MSTORE POP POP POP SWAP1 POP DUP8 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH32 0x5D9559ADA0F8509A7FFFB4C05FA6F4F9DF6772AC68A8F6AC87C36F00FF3843A1 DUP3 PUSH1 0x0 DUP2 MLOAD DUP2 LT PUSH2 0xB60 JUMPI INVALID JUMPDEST PUSH1 0x20 MUL PUSH1 0x20 ADD ADD MLOAD DUP4 PUSH1 0x1 DUP7 MLOAD SUB DUP2 MLOAD DUP2 LT PUSH2 0xB78 JUMPI INVALID JUMPDEST PUSH1 0x20 MUL PUSH1 0x20 ADD ADD MLOAD PUSH1 0x40 MLOAD DUP1 DUP4 DUP2 MSTORE PUSH1 0x20 ADD DUP3 DUP2 MSTORE PUSH1 0x20 ADD SWAP3 POP POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 LOG2 POP POP POP POP POP POP POP POP JUMP JUMPDEST PUSH32 0x0 DUP2 JUMP JUMPDEST PUSH1 0x0 DUP1 SWAP1 SLOAD SWAP1 PUSH2 0x100 EXP SWAP1 DIV PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0xC340A24 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0xC17 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0xC2B JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xC41 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND CALLER EQ PUSH2 0xC8C JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0xA PUSH1 0x24 DUP3 ADD MSTORE PUSH10 0x26AA1D2727AA2FA3A7AB PUSH1 0xB1 SHL PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH2 0xCA6 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP4 AND CALLER DUP4 PUSH4 0xFFFFFFFF PUSH2 0xE0E AND JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD DUP3 DUP2 MSTORE SWAP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP5 AND SWAP2 PUSH32 0xA0EA1D68F48CD2FF8A7DB3AAA2D99DBDB957E097C7CC559F7E738832678C41FF SWAP2 SWAP1 DUP2 SWAP1 SUB PUSH1 0x20 ADD SWAP1 LOG2 POP POP JUMP JUMPDEST PUSH1 0x0 SLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP2 JUMP JUMPDEST PUSH1 0x0 DUP1 SWAP1 SLOAD SWAP1 PUSH2 0x100 EXP SWAP1 DIV PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0xC340A24 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0xD45 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0xD59 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xD6F JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND CALLER EQ PUSH2 0xDBA JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0xA PUSH1 0x24 DUP3 ADD MSTORE PUSH10 0x26AA1D2727AA2FA3A7AB PUSH1 0xB1 SHL PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH1 0x0 DUP1 SLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP4 AND PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB NOT SWAP1 SWAP2 AND DUP2 OR SWAP1 SWAP2 SSTORE PUSH1 0x40 DUP1 MLOAD SWAP2 DUP3 MSTORE MLOAD PUSH32 0xDA36F26252AA35D26238345E2C339CDBFEB26CE49721030CA8E907AB1701AC8F SWAP2 DUP2 SWAP1 SUB PUSH1 0x20 ADD SWAP1 LOG1 POP JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP5 AND PUSH1 0x24 DUP3 ADD MSTORE PUSH1 0x44 DUP1 DUP3 ADD DUP5 SWAP1 MSTORE DUP3 MLOAD DUP1 DUP4 SUB SWAP1 SWAP2 ADD DUP2 MSTORE PUSH1 0x64 SWAP1 SWAP2 ADD SWAP1 SWAP2 MSTORE PUSH1 0x20 DUP2 ADD DUP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xE0 SHL SUB AND PUSH4 0xA9059CBB PUSH1 0xE0 SHL OR SWAP1 MSTORE PUSH2 0xE60 SWAP1 DUP5 SWAP1 PUSH2 0x105E JUMP JUMPDEST POP POP POP JUMP JUMPDEST DUP1 ISZERO DUP1 PUSH2 0xEEB JUMPI POP PUSH1 0x40 DUP1 MLOAD PUSH4 0x6EB1769F PUSH1 0xE1 SHL DUP2 MSTORE ADDRESS PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP5 DUP2 AND PUSH1 0x24 DUP4 ADD MSTORE SWAP2 MLOAD SWAP2 DUP6 AND SWAP2 PUSH4 0xDD62ED3E SWAP2 PUSH1 0x44 DUP1 DUP3 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP1 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0xEBD JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0xED1 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xEE7 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD ISZERO JUMPDEST PUSH2 0xF26 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE PUSH1 0x36 DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH2 0x145E PUSH1 0x36 SWAP2 CODECOPY PUSH1 0x40 ADD SWAP2 POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST PUSH1 0x40 DUP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP5 AND PUSH1 0x24 DUP3 ADD MSTORE PUSH1 0x44 DUP1 DUP3 ADD DUP5 SWAP1 MSTORE DUP3 MLOAD DUP1 DUP4 SUB SWAP1 SWAP2 ADD DUP2 MSTORE PUSH1 0x64 SWAP1 SWAP2 ADD SWAP1 SWAP2 MSTORE PUSH1 0x20 DUP2 ADD DUP1 MLOAD PUSH1 0x1 PUSH1 0x1 PUSH1 0xE0 SHL SUB AND PUSH4 0x95EA7B3 PUSH1 0xE0 SHL OR SWAP1 MSTORE PUSH2 0xE60 SWAP1 DUP5 SWAP1 PUSH2 0x105E JUMP JUMPDEST PUSH1 0x0 DUP3 PUSH2 0xF87 JUMPI POP PUSH1 0x0 PUSH2 0xFD4 JUMP JUMPDEST DUP3 DUP3 MUL DUP3 DUP5 DUP3 DUP2 PUSH2 0xF94 JUMPI INVALID JUMPDEST DIV EQ PUSH2 0xFD1 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE PUSH1 0x21 DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH2 0x1413 PUSH1 0x21 SWAP2 CODECOPY PUSH1 0x40 ADD SWAP2 POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST SWAP1 POP JUMPDEST SWAP3 SWAP2 POP POP JUMP JUMPDEST PUSH1 0x0 PUSH2 0xFD1 DUP4 DUP4 PUSH1 0x40 MLOAD DUP1 PUSH1 0x40 ADD PUSH1 0x40 MSTORE DUP1 PUSH1 0x1A DUP2 MSTORE PUSH1 0x20 ADD PUSH32 0x536166654D6174683A206469766973696F6E206279207A65726F000000000000 DUP2 MSTORE POP PUSH2 0x110F JUMP JUMPDEST PUSH1 0x0 PUSH2 0xFD1 DUP4 DUP4 PUSH1 0x40 MLOAD DUP1 PUSH1 0x40 ADD PUSH1 0x40 MSTORE DUP1 PUSH1 0x1E DUP2 MSTORE PUSH1 0x20 ADD PUSH32 0x536166654D6174683A207375627472616374696F6E206F766572666C6F770000 DUP2 MSTORE POP PUSH2 0x11B3 JUMP JUMPDEST PUSH1 0x60 PUSH2 0x10B3 DUP3 PUSH1 0x40 MLOAD DUP1 PUSH1 0x40 ADD PUSH1 0x40 MSTORE DUP1 PUSH1 0x20 DUP2 MSTORE PUSH1 0x20 ADD PUSH32 0x5361666545524332303A206C6F772D6C6576656C2063616C6C206661696C6564 DUP2 MSTORE POP DUP6 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH2 0x120D SWAP1 SWAP3 SWAP2 SWAP1 PUSH4 0xFFFFFFFF AND JUMP JUMPDEST DUP1 MLOAD SWAP1 SWAP2 POP ISZERO PUSH2 0xE60 JUMPI DUP1 DUP1 PUSH1 0x20 ADD SWAP1 MLOAD PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x10D2 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH2 0xE60 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE PUSH1 0x2A DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH2 0x1434 PUSH1 0x2A SWAP2 CODECOPY PUSH1 0x40 ADD SWAP2 POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST PUSH1 0x0 DUP2 DUP4 PUSH2 0x119B JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE DUP4 DUP2 DUP2 MLOAD DUP2 MSTORE PUSH1 0x20 ADD SWAP2 POP DUP1 MLOAD SWAP1 PUSH1 0x20 ADD SWAP1 DUP1 DUP4 DUP4 PUSH1 0x0 JUMPDEST DUP4 DUP2 LT ISZERO PUSH2 0x1160 JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0x1148 JUMP JUMPDEST POP POP POP POP SWAP1 POP SWAP1 DUP2 ADD SWAP1 PUSH1 0x1F AND DUP1 ISZERO PUSH2 0x118D JUMPI DUP1 DUP3 SUB DUP1 MLOAD PUSH1 0x1 DUP4 PUSH1 0x20 SUB PUSH2 0x100 EXP SUB NOT AND DUP2 MSTORE PUSH1 0x20 ADD SWAP2 POP JUMPDEST POP SWAP3 POP POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST POP PUSH1 0x0 DUP4 DUP6 DUP2 PUSH2 0x11A7 JUMPI INVALID JUMPDEST DIV SWAP2 POP POP JUMPDEST SWAP4 SWAP3 POP POP POP JUMP JUMPDEST PUSH1 0x0 DUP2 DUP5 DUP5 GT ISZERO PUSH2 0x1205 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD DUP2 DUP2 MSTORE DUP4 MLOAD PUSH1 0x24 DUP5 ADD MSTORE DUP4 MLOAD SWAP1 SWAP3 DUP4 SWAP3 PUSH1 0x44 SWAP1 SWAP2 ADD SWAP2 SWAP1 DUP6 ADD SWAP1 DUP1 DUP4 DUP4 PUSH1 0x0 DUP4 ISZERO PUSH2 0x1160 JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0x1148 JUMP JUMPDEST POP POP POP SWAP1 SUB SWAP1 JUMP JUMPDEST PUSH1 0x60 PUSH2 0x121C DUP5 DUP5 PUSH1 0x0 DUP6 PUSH2 0x1224 JUMP JUMPDEST SWAP5 SWAP4 POP POP POP POP JUMP JUMPDEST PUSH1 0x60 DUP3 SELFBALANCE LT ISZERO PUSH2 0x1265 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE PUSH1 0x26 DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH2 0x13ED PUSH1 0x26 SWAP2 CODECOPY PUSH1 0x40 ADD SWAP2 POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST PUSH2 0x126E DUP6 PUSH2 0x1380 JUMP JUMPDEST PUSH2 0x12BF JUMPI PUSH1 0x40 DUP1 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD MSTORE PUSH1 0x1D PUSH1 0x24 DUP3 ADD MSTORE PUSH32 0x416464726573733A2063616C6C20746F206E6F6E2D636F6E7472616374000000 PUSH1 0x44 DUP3 ADD MSTORE SWAP1 MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x64 ADD SWAP1 REVERT JUMPDEST PUSH1 0x0 PUSH1 0x60 DUP7 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND DUP6 DUP8 PUSH1 0x40 MLOAD DUP1 DUP3 DUP1 MLOAD SWAP1 PUSH1 0x20 ADD SWAP1 DUP1 DUP4 DUP4 JUMPDEST PUSH1 0x20 DUP4 LT PUSH2 0x12FE JUMPI DUP1 MLOAD DUP3 MSTORE PUSH1 0x1F NOT SWAP1 SWAP3 ADD SWAP2 PUSH1 0x20 SWAP2 DUP3 ADD SWAP2 ADD PUSH2 0x12DF JUMP JUMPDEST PUSH1 0x1 DUP4 PUSH1 0x20 SUB PUSH2 0x100 EXP SUB DUP1 NOT DUP3 MLOAD AND DUP2 DUP5 MLOAD AND DUP1 DUP3 OR DUP6 MSTORE POP POP POP POP POP POP SWAP1 POP ADD SWAP2 POP POP PUSH1 0x0 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP6 DUP8 GAS CALL SWAP3 POP POP POP RETURNDATASIZE DUP1 PUSH1 0x0 DUP2 EQ PUSH2 0x1360 JUMPI PUSH1 0x40 MLOAD SWAP2 POP PUSH1 0x1F NOT PUSH1 0x3F RETURNDATASIZE ADD AND DUP3 ADD PUSH1 0x40 MSTORE RETURNDATASIZE DUP3 MSTORE RETURNDATASIZE PUSH1 0x0 PUSH1 0x20 DUP5 ADD RETURNDATACOPY PUSH2 0x1365 JUMP JUMPDEST PUSH1 0x60 SWAP2 POP JUMPDEST POP SWAP2 POP SWAP2 POP PUSH2 0x1375 DUP3 DUP3 DUP7 PUSH2 0x1386 JUMP JUMPDEST SWAP8 SWAP7 POP POP POP POP POP POP POP JUMP JUMPDEST EXTCODESIZE ISZERO ISZERO SWAP1 JUMP JUMPDEST PUSH1 0x60 DUP4 ISZERO PUSH2 0x1395 JUMPI POP DUP2 PUSH2 0x11AC JUMP JUMPDEST DUP3 MLOAD ISZERO PUSH2 0x13A5 JUMPI DUP3 MLOAD DUP1 DUP5 PUSH1 0x20 ADD REVERT JUMPDEST PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x20 PUSH1 0x4 DUP3 ADD DUP2 DUP2 MSTORE DUP5 MLOAD PUSH1 0x24 DUP5 ADD MSTORE DUP5 MLOAD DUP6 SWAP4 SWAP2 SWAP3 DUP4 SWAP3 PUSH1 0x44 ADD SWAP2 SWAP1 DUP6 ADD SWAP1 DUP1 DUP4 DUP4 PUSH1 0x0 DUP4 ISZERO PUSH2 0x1160 JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0x1148 JUMP INVALID COINBASE PUSH5 0x6472657373 GASPRICE KECCAK256 PUSH10 0x6E73756666696369656E PUSH21 0x2062616C616E636520666F722063616C6C53616665 0x4D PUSH2 0x7468 GASPRICE KECCAK256 PUSH14 0x756C7469706C69636174696F6E20 PUSH16 0x766572666C6F77536166654552433230 GASPRICE KECCAK256 GASLIMIT MSTORE NUMBER ORIGIN ADDRESS KECCAK256 PUSH16 0x7065726174696F6E20646964206E6F74 KECCAK256 PUSH20 0x7563636565645361666545524332303A20617070 PUSH19 0x6F76652066726F6D206E6F6E2D7A65726F2074 PUSH16 0x206E6F6E2D7A65726F20616C6C6F7761 PUSH15 0x6365A2646970667358221220973167 SLT DUP15 0xF7 SHR INVALID LOG1 0xB6 0x4A SWAP6 DUP5 PUSH7 0x22FC08CA542496 SIGNEXTEND SWAP10 0x22 0xB9 ADD 0xC2 0xE3 DIV 0xC SWAP4 0xDE PUSH5 0x736F6C6343 STOP MOD SIGNEXTEND STOP CALLER ",
"sourceMap": "46566:3169:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;48106:347;;;:::i;:::-;;46723:44;;;:::i;:::-;;;;-1:-1:-1;;;;;46723:44:0;;;;;;;;;;;;;;46773:47;;;:::i;48459:1273::-;;;;;;;;;;;;;;;;-1:-1:-1;48459:1273:0;-1:-1:-1;;;;;48459:1273:0;;:::i;46680:37::-;;;:::i;47911:189::-;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;47911:189:0;;;;;;;;:::i;46826:41::-;;;:::i;47762:143::-;;;;;;;;;;;;;;;;-1:-1:-1;47762:143:0;-1:-1:-1;;;;;47762:143:0;;:::i;48106:347::-;47704:7;;;;;;;;;-1:-1:-1;;;;;47704:7:0;-1:-1:-1;;;;;47690:31:0;;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;47690:33:0;-1:-1:-1;;;;;47676:47:0;:10;:47;47668:70;;;;;-1:-1:-1;;;47668:70:0;;;;;;;;;;;;-1:-1:-1;;;47668:70:0;;;;;;;;;;;;;;;48252:36:::1;::::0;;-1:-1:-1;;;48252:36:0;;48282:4:::1;48252:36;::::0;::::1;::::0;;;48204:10:::1;::::0;48176:18:::1;::::0;-1:-1:-1;;;;;48252:21:0;::::1;::::0;::::1;::::0;:36;;;;;::::1;::::0;;;;;;;;:21;:36;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;::::0;::::1;;-1:-1:-1::0;48252:36:0;;-1:-1:-1;48298:47:0::1;-1:-1:-1::0;;;;;48298:24:0;::::1;48323:3;48252:36:::0;48298:47:::1;:24;:47;:::i;:::-;48367:3;-1:-1:-1::0;;;;;48355:36:0::1;;:38;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;-1:-1:-1::0;;48408:38:0::1;::::0;;;;;;;::::1;::::0;-1:-1:-1;48408:38:0;;;;::::1;::::0;;-1:-1:-1;48408:38:0::1;47748:1;;48106:347::o:0;46723:44::-;;;:::o;46773:47::-;;;:::o;48459:1273::-;47704:7;;;;;;;;;-1:-1:-1;;;;;47704:7:0;-1:-1:-1;;;;;47690:31:0;;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;47690:33:0;-1:-1:-1;;;;;47676:47:0;:10;:47;47668:70;;;;;-1:-1:-1;;;47668:70:0;;;;;;;;;;;;-1:-1:-1;;;47668:70:0;;;;;;;;;;;;;;;48552:10:::1;-1:-1:-1::0;;;;;48543:19:0::1;:5;-1:-1:-1::0;;;;;48543:19:0::1;;;48535:55;;;::::0;;-1:-1:-1;;;48535:55:0;;::::1;;::::0;::::1;::::0;::::1;::::0;;;;::::1;::::0;;;;;;;;;;;;;::::1;;48601:22;48640:7:::0;;48682:38:::1;::::0;;-1:-1:-1;;;48682:38:0;;48714:4:::1;48682:38;::::0;::::1;::::0;;;-1:-1:-1;;;;;48640:7:0;;::::1;::::0;48601:22;48682:23;::::1;::::0;::::1;::::0;:38;;;;;::::1;::::0;;;;;;;;:23;:38;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;::::0;::::1;;-1:-1:-1::0;48682:38:0;48753:61:::1;::::0;;-1:-1:-1;;;48753:61:0;;-1:-1:-1;;;;;48753:61:0;;::::1;;::::0;::::1;::::0;;;::::1;::::0;;;;48789:10:::1;48753:61;::::0;;;;;;;;;;;;48682:38;;-1:-1:-1;48730:17:0::1;::::0;48753:4:::1;::::0;:18:::1;::::0;:61;;;;;48682:38:::1;::::0;48753:61;;;;;;;:4;:61;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;::::0;::::1;;-1:-1:-1::0;48753:61:0;;-1:-1:-1;48825:52:0::1;-1:-1:-1::0;;;;;48825:25:0;::::1;48851:13;48874:1;48825:52;:25;:52;:::i;:::-;48887:54;-1:-1:-1::0;;;;;48887:25:0;::::1;48913:13;48928:12:::0;48887:54:::1;:25;:54;:::i;:::-;48982:46;::::0;;-1:-1:-1;;;48982:46:0;;-1:-1:-1;;;;;48982:46:0;;::::1;;::::0;::::1;::::0;49017:10:::1;48982:46:::0;::::1;::::0;;;;;;48952:27:::1;::::0;48982;::::1;::::0;::::1;::::0;:46;;;;;::::1;::::0;;;;;;;;:27;:46;::::1;;::::0;::::1;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;::::0;::::1;;-1:-1:-1::0;48982:46:0;;-1:-1:-1;49038:19:0::1;49091:10;-1:-1:-1::0;;;;;49068:33:0;;::::1;::::0;;::::1;;::::0;::::1;::::0;:70:::1;;-1:-1:-1::0;;;;;;49105:33:0;::::1;::::0;::::1;49068:70;49038:100;;49149:21;49187:11;:19;;49205:1;49187:19;;;49201:1;49187:19;49173:34;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;-1:-1:-1;49173:34:0::1;;49149:58;;49228:5;49218:4;49223:1;49218:7;;;;;;;;;;;;;:15;-1:-1:-1::0;;;;;49218:15:0::1;;;-1:-1:-1::0;;;;;49218:15:0::1;;;::::0;::::1;49253:11;:46;;49289:10;49253:46;;;49267:19;49253:46;49243:4;49248:1;49243:7;;;;;;;;;;;;;:56;-1:-1:-1::0;;;;;49243:56:0::1;;;-1:-1:-1::0;;;;;49243:56:0::1;;;::::0;::::1;49314:11;49310:37;;;49337:10;49327:4;49332:1;49327:7;;;;;;;;;;;;;:20;-1:-1:-1::0;;;;;49327:20:0::1;;;-1:-1:-1::0;;;;;49327:20:0::1;;;::::0;::::1;49310:37;49358:30;49406:13;-1:-1:-1::0;;;;;49391:54:0::1;;49459:12;49485:68;49499:53;49545:6;49499:41;49513:8;-1:-1:-1::0;;;;;49513:24:0::1;;:26;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;::::0;::::1;;-1:-1:-1::0;49513:26:0;49499:9;;:41:::1;:13;:41;:::i;:::-;:45:::0;:53:::1;:45;:53;:::i;:::-;49485:9:::0;;:68:::1;:13;:68;:::i;:::-;49567:4;49593;49612:15;49391:246;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1::0;;;;;49391:246:0::1;-1:-1:-1::0;;;;;49391:246:0::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;;::::1;::::0;;;::::1;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;::::0;::::1;;;;;;;;;;;;;;;;;::::0;;::::1;-1:-1:-1::0;;49391:246:0::1;::::0;::::1;;::::0;::::1;::::0;::::1;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;;;;::::0;::::1;;::::0;;::::1;::::0;::::1;::::0;::::1;::::0;;::::1;;;;;::::0;::::1;;;;;;;;;;;;;;;;;;;::::0;::::1;;::::0;;-1:-1:-1;49391:246:0;;::::1;::::0;;::::1;::::0;;::::1;::::0;::::1;::::0;;;::::1;;;;;;;;::::0;;::::1;::::0;;;::::1;::::0;::::1;;;;;;;;;;;;;;::::0;::::1;;49358:279;;49669:5;-1:-1:-1::0;;;;;49653:72:0::1;;49676:13;49690:1;49676:16;;;;;;;;;;;;;;49694:13;49722:1;49708:4;:11;:15;49694:30;;;;;;;;;;;;;;49653:72;;;;;;;;;;;;;;;;;;;;;;;;47748:1;;;;;;;48459:1273:::0;:::o;46680:37::-;;;:::o;47911:189::-;47704:7;;;;;;;;;-1:-1:-1;;;;;47704:7:0;-1:-1:-1;;;;;47690:31:0;;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;47690:33:0;-1:-1:-1;;;;;47676:47:0;:10;:47;47668:70;;;;;-1:-1:-1;;;47668:70:0;;;;;;;;;;;;-1:-1:-1;;;47668:70:0;;;;;;;;;;;;;;;48003:46:::1;-1:-1:-1::0;;;;;48003:26:0;::::1;48030:10;48042:6:::0;48003:46:::1;:26;:46;:::i;:::-;48064:29;::::0;;;;;;;-1:-1:-1;;;;;48064:29:0;::::1;::::0;::::1;::::0;;;;;::::1;::::0;;::::1;47911:189:::0;;:::o;46826:41::-;;;-1:-1:-1;;;;;46826:41:0;;:::o;47762:143::-;47704:7;;;;;;;;;-1:-1:-1;;;;;47704:7:0;-1:-1:-1;;;;;47690:31:0;;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;47690:33:0;-1:-1:-1;;;;;47676:47:0;:10;:47;47668:70;;;;;-1:-1:-1;;;47668:70:0;;;;;;;;;;;;-1:-1:-1;;;47668:70:0;;;;;;;;;;;;;;;47841:7:::1;:20:::0;;-1:-1:-1;;;;;47841:20:0;::::1;-1:-1:-1::0;;;;;;47841:20:0;;::::1;::::0;::::1;::::0;;;47876:22:::1;::::0;;;;;;::::1;::::0;;;;::::1;::::0;;::::1;47762:143:::0;:::o;42718:175::-;42827:58;;;-1:-1:-1;;;;;42827:58:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;42827:58:0;-1:-1:-1;;;42827:58:0;;;42800:86;;42820:5;;42800:19;:86::i;:::-;42718:175;;;:::o;43362:613::-;43727:10;;;43726:62;;-1:-1:-1;43743:39:0;;;-1:-1:-1;;;43743:39:0;;43767:4;43743:39;;;;-1:-1:-1;;;;;43743:39:0;;;;;;;;;:15;;;;;;:39;;;;;;;;;;;;;;;:15;:39;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;43743:39:0;:44;43726:62;43718:150;;;;-1:-1:-1;;;43718:150:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;43905:62;;;-1:-1:-1;;;;;43905:62:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;;;43905:62:0;-1:-1:-1;;;43905:62:0;;;43878:90;;43898:5;;43878:19;:90::i;30503:459::-;30561:7;30802:6;30798:45;;-1:-1:-1;30831:1:0;30824:8;;30798:45;30865:5;;;30869:1;30865;:5;:1;30888:5;;;;;:10;30880:56;;;;-1:-1:-1;;;30880:56:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30954:1;-1:-1:-1;30503:459:0;;;;;:::o;31424:130::-;31482:7;31508:39;31512:1;31515;31508:39;;;;;;;;;;;;;;;;;:3;:39::i;29644:134::-;29702:7;29728:43;29732:1;29735;29728:43;;;;;;;;;;;;;;;;;:3;:43::i;44981:751::-;45400:23;45426:69;45454:4;45426:69;;;;;;;;;;;;;;;;;45434:5;-1:-1:-1;;;;;45426:27:0;;;:69;;;;;:::i;:::-;45509:17;;45400:95;;-1:-1:-1;45509:21:0;45505:221;;45649:10;45638:30;;;;;;;;;;;;;;;-1:-1:-1;45638:30:0;45630:85;;;;-1:-1:-1;;;45630:85:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;32036:272;32122:7;32156:12;32149:5;32141:28;;;;-1:-1:-1;;;32141:28:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;32179:9;32195:1;32191;:5;;;;;;;-1:-1:-1;;32036:272:0;;;;;;:::o;30069:187::-;30155:7;30190:12;30182:6;;;;30174:29;;;;-1:-1:-1;;;30174:29:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;;30225:5:0;;;30069:187::o;38694:193::-;38797:12;38828:52;38850:6;38858:4;38864:1;38867:12;38828:21;:52::i;:::-;38821:59;38694:193;-1:-1:-1;;;;38694:193:0:o;39721:523::-;39848:12;39905:5;39880:21;:30;;39872:81;;;;-1:-1:-1;;;39872:81:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;39971:18;39982:6;39971:10;:18::i;:::-;39963:60;;;;;-1:-1:-1;;;39963:60:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;40094:12;40108:23;40135:6;-1:-1:-1;;;;;40135:11:0;40155:5;40163:4;40135:33;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;;40135:33:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;40093:75;;;;40185:52;40203:7;40212:10;40224:12;40185:17;:52::i;:::-;40178:59;39721:523;-1:-1:-1;;;;;;;39721:523:0:o;35839:413::-;36199:20;36237:8;;;35839:413::o;41224:725::-;41339:12;41367:7;41363:580;;;-1:-1:-1;41397:10:0;41390:17;;41363:580;41508:17;;:21;41504:429;;41766:10;41760:17;41826:15;41813:10;41809:2;41805:19;41798:44;41715:145;41898:20;;-1:-1:-1;;;41898:20:0;;;;;;;;;;;;;;;;;41905:12;;41898:20;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"
},
"methodIdentifiers": {
"convertERC20(address)": "817bd4fd",
"distributeToHolders()": "3153689f",
"fundsToken()": "63f04b15",
"globals()": "c3124525",
"mpl()": "a0530946",
"reclaimERC20(address,uint256)": "afdbd499",
"setGlobals(address)": "cc2e0a26",
"uniswapRouter()": "735de9f7"
}
}
},
"SafeERC20": {
"abi": [],
"evm": {
"bytecode": {
"linkReferences": {},
"object": "60566023600b82828239805160001a607314601657fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212201b00b926d268b3fd253a725d04a67bd110139402c4363db9913427a0893a825f64736f6c634300060b0033",
"opcodes": "PUSH1 0x56 PUSH1 0x23 PUSH1 0xB DUP3 DUP3 DUP3 CODECOPY DUP1 MLOAD PUSH1 0x0 BYTE PUSH1 0x73 EQ PUSH1 0x16 JUMPI INVALID JUMPDEST ADDRESS PUSH1 0x0 MSTORE PUSH1 0x73 DUP2 MSTORE8 DUP3 DUP2 RETURN INVALID PUSH20 0x0 ADDRESS EQ PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x0 DUP1 REVERT INVALID LOG2 PUSH5 0x6970667358 0x22 SLT KECCAK256 SHL STOP 0xB9 0x26 0xD2 PUSH9 0xB3FD253A725D04A67B 0xD1 LT SGT SWAP5 MUL 0xC4 CALLDATASIZE RETURNDATASIZE 0xB9 SWAP2 CALLVALUE 0x27 LOG0 DUP10 GASPRICE DUP3 0x5F PUSH5 0x736F6C6343 STOP MOD SIGNEXTEND STOP CALLER ",
"sourceMap": "42630:3104:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;"
},
"deployedBytecode": {
"immutableReferences": {},
"linkReferences": {},
"object": "73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212201b00b926d268b3fd253a725d04a67bd110139402c4363db9913427a0893a825f64736f6c634300060b0033",
"opcodes": "PUSH20 0x0 ADDRESS EQ PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x0 DUP1 REVERT INVALID LOG2 PUSH5 0x6970667358 0x22 SLT KECCAK256 SHL STOP 0xB9 0x26 0xD2 PUSH9 0xB3FD253A725D04A67B 0xD1 LT SGT SWAP5 MUL 0xC4 CALLDATASIZE RETURNDATASIZE 0xB9 SWAP2 CALLVALUE 0x27 LOG0 DUP10 GASPRICE DUP3 0x5F PUSH5 0x736F6C6343 STOP MOD SIGNEXTEND STOP CALLER ",
"sourceMap": "42630:3104:0:-:0;;;;;;;;"
},
"methodIdentifiers": {}
}
},
"SafeMath": {
"abi": [],
"evm": {
"bytecode": {
"linkReferences": {},
"object": "60566023600b82828239805160001a607314601657fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212207747787c57c2feb71913ee96c1f4510a2edad96774396558e3e786f3735f48ca64736f6c634300060b0033",
"opcodes": "PUSH1 0x56 PUSH1 0x23 PUSH1 0xB DUP3 DUP3 DUP3 CODECOPY DUP1 MLOAD PUSH1 0x0 BYTE PUSH1 0x73 EQ PUSH1 0x16 JUMPI INVALID JUMPDEST ADDRESS PUSH1 0x0 MSTORE PUSH1 0x73 DUP2 MSTORE8 DUP3 DUP2 RETURN INVALID PUSH20 0x0 ADDRESS EQ PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x0 DUP1 REVERT INVALID LOG2 PUSH5 0x6970667358 0x22 SLT KECCAK256 PUSH24 0x47787C57C2FEB71913EE96C1F4510A2EDAD96774396558E3 0xE7 DUP7 RETURN PUSH20 0x5F48CA64736F6C634300060B0033000000000000 ",
"sourceMap": "28945:4578:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;"
},
"deployedBytecode": {
"immutableReferences": {},
"linkReferences": {},
"object": "73000000000000000000000000000000000000000030146080604052600080fdfea26469706673582212207747787c57c2feb71913ee96c1f4510a2edad96774396558e3e786f3735f48ca64736f6c634300060b0033",
"opcodes": "PUSH20 0x0 ADDRESS EQ PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x0 DUP1 REVERT INVALID LOG2 PUSH5 0x6970667358 0x22 SLT KECCAK256 PUSH24 0x47787C57C2FEB71913EE96C1F4510A2EDAD96774396558E3 0xE7 DUP7 RETURN PUSH20 0x5F48CA64736F6C634300060B0033000000000000 ",
"sourceMap": "28945:4578:0:-:0;;;;;;;;"
},
"methodIdentifiers": {}
}
},
"Util": {
"abi": [
{
"inputs": [
{
"internalType": "contract IMapleGlobals",
"name": "globals",
"type": "IMapleGlobals"
},
{
"internalType": "address",
"name": "fromAsset",
"type": "address"
},
{
"internalType": "address",
"name": "toAsset",
"type": "address"
},
{
"internalType": "uint256",
"name": "swapAmt",
"type": "uint256"
}
],
"name": "calcMinAmount",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
}
],
"evm": {
"bytecode": {
"linkReferences": {},
"object": "610427610026600b82828239805160001a60731461001957fe5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600436106100355760003560e01c8063c1e371861461003a575b600080fd5b6100766004803603608081101561005057600080fd5b506001600160a01b03813581169160208101358216916040820135169060600135610088565b60408051918252519081900360200190f35b6000610286846001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b1580156100c657600080fd5b505afa1580156100da573d6000803e3d6000fd5b505050506040513d60208110156100f057600080fd5b5051604080516302c68be360e31b81526001600160a01b0387811660048301529151600a9390930a9261027a928a16916316345f18916024808301926020929190829003018186803b15801561014557600080fd5b505afa158015610159573d6000803e3d6000fd5b505050506040513d602081101561016f57600080fd5b50516040805163313ce56760e01b8152905161027a916001600160a01b038a169163313ce56791600480820192602092909190829003018186803b1580156101b657600080fd5b505afa1580156101ca573d6000803e3d6000fd5b505050506040513d60208110156101e057600080fd5b5051604080516302c68be360e31b81526001600160a01b038c811660048301529151600a9390930a9261026e928e16916316345f18916024808301926020929190829003018186803b15801561023557600080fd5b505afa158015610249573d6000803e3d6000fd5b505050506040513d602081101561025f57600080fd5b5051899063ffffffff61028f16565b9063ffffffff61028f16565b9063ffffffff6102f116565b95945050505050565b60008261029e575060006102eb565b828202828482816102ab57fe5b04146102e85760405162461bcd60e51b81526004018080602001828103825260218152602001806103d16021913960400191505060405180910390fd5b90505b92915050565b60006102e883836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250600081836103ba5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561037f578181015183820152602001610367565b50505050905090810190601f1680156103ac5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816103c657fe5b049594505050505056fe536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a2646970667358221220b1bb55176540392a53031a5992c34a6fa25da7f0a28f415e6a3230af396c65ef64736f6c634300060b0033",
"opcodes": "PUSH2 0x427 PUSH2 0x26 PUSH1 0xB DUP3 DUP3 DUP3 CODECOPY DUP1 MLOAD PUSH1 0x0 BYTE PUSH1 0x73 EQ PUSH2 0x19 JUMPI INVALID JUMPDEST ADDRESS PUSH1 0x0 MSTORE PUSH1 0x73 DUP2 MSTORE8 DUP3 DUP2 RETURN INVALID PUSH20 0x0 ADDRESS EQ PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x4 CALLDATASIZE LT PUSH2 0x35 JUMPI PUSH1 0x0 CALLDATALOAD PUSH1 0xE0 SHR DUP1 PUSH4 0xC1E37186 EQ PUSH2 0x3A JUMPI JUMPDEST PUSH1 0x0 DUP1 REVERT JUMPDEST PUSH2 0x76 PUSH1 0x4 DUP1 CALLDATASIZE SUB PUSH1 0x80 DUP2 LT ISZERO PUSH2 0x50 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP2 CALLDATALOAD DUP2 AND SWAP2 PUSH1 0x20 DUP2 ADD CALLDATALOAD DUP3 AND SWAP2 PUSH1 0x40 DUP3 ADD CALLDATALOAD AND SWAP1 PUSH1 0x60 ADD CALLDATALOAD PUSH2 0x88 JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD SWAP2 DUP3 MSTORE MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x20 ADD SWAP1 RETURN JUMPDEST PUSH1 0x0 PUSH2 0x286 DUP5 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0x313CE567 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0xC6 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0xDA JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xF0 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x40 DUP1 MLOAD PUSH4 0x2C68BE3 PUSH1 0xE3 SHL DUP2 MSTORE PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP8 DUP2 AND PUSH1 0x4 DUP4 ADD MSTORE SWAP2 MLOAD PUSH1 0xA SWAP4 SWAP1 SWAP4 EXP SWAP3 PUSH2 0x27A SWAP3 DUP11 AND SWAP2 PUSH4 0x16345F18 SWAP2 PUSH1 0x24 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x145 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x159 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x16F JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x40 DUP1 MLOAD PUSH4 0x313CE567 PUSH1 0xE0 SHL DUP2 MSTORE SWAP1 MLOAD PUSH2 0x27A SWAP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP11 AND SWAP2 PUSH4 0x313CE567 SWAP2 PUSH1 0x4 DUP1 DUP3 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP1 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x1B6 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x1CA JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x1E0 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x40 DUP1 MLOAD PUSH4 0x2C68BE3 PUSH1 0xE3 SHL DUP2 MSTORE PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP13 DUP2 AND PUSH1 0x4 DUP4 ADD MSTORE SWAP2 MLOAD PUSH1 0xA SWAP4 SWAP1 SWAP4 EXP SWAP3 PUSH2 0x26E SWAP3 DUP15 AND SWAP2 PUSH4 0x16345F18 SWAP2 PUSH1 0x24 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x235 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x249 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x25F JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD DUP10 SWAP1 PUSH4 0xFFFFFFFF PUSH2 0x28F AND JUMP JUMPDEST SWAP1 PUSH4 0xFFFFFFFF PUSH2 0x28F AND JUMP JUMPDEST SWAP1 PUSH4 0xFFFFFFFF PUSH2 0x2F1 AND JUMP JUMPDEST SWAP6 SWAP5 POP POP POP POP POP JUMP JUMPDEST PUSH1 0x0 DUP3 PUSH2 0x29E JUMPI POP PUSH1 0x0 PUSH2 0x2EB JUMP JUMPDEST DUP3 DUP3 MUL DUP3 DUP5 DUP3 DUP2 PUSH2 0x2AB JUMPI INVALID JUMPDEST DIV EQ PUSH2 0x2E8 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE PUSH1 0x21 DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH2 0x3D1 PUSH1 0x21 SWAP2 CODECOPY PUSH1 0x40 ADD SWAP2 POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST SWAP1 POP JUMPDEST SWAP3 SWAP2 POP POP JUMP JUMPDEST PUSH1 0x0 PUSH2 0x2E8 DUP4 DUP4 PUSH1 0x40 MLOAD DUP1 PUSH1 0x40 ADD PUSH1 0x40 MSTORE DUP1 PUSH1 0x1A DUP2 MSTORE PUSH1 0x20 ADD PUSH32 0x536166654D6174683A206469766973696F6E206279207A65726F000000000000 DUP2 MSTORE POP PUSH1 0x0 DUP2 DUP4 PUSH2 0x3BA JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE DUP4 DUP2 DUP2 MLOAD DUP2 MSTORE PUSH1 0x20 ADD SWAP2 POP DUP1 MLOAD SWAP1 PUSH1 0x20 ADD SWAP1 DUP1 DUP4 DUP4 PUSH1 0x0 JUMPDEST DUP4 DUP2 LT ISZERO PUSH2 0x37F JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0x367 JUMP JUMPDEST POP POP POP POP SWAP1 POP SWAP1 DUP2 ADD SWAP1 PUSH1 0x1F AND DUP1 ISZERO PUSH2 0x3AC JUMPI DUP1 DUP3 SUB DUP1 MLOAD PUSH1 0x1 DUP4 PUSH1 0x20 SUB PUSH2 0x100 EXP SUB NOT AND DUP2 MSTORE PUSH1 0x20 ADD SWAP2 POP JUMPDEST POP SWAP3 POP POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST POP PUSH1 0x0 DUP4 DUP6 DUP2 PUSH2 0x3C6 JUMPI INVALID JUMPDEST DIV SWAP6 SWAP5 POP POP POP POP POP JUMP INVALID MSTORE8 PUSH2 0x6665 0x4D PUSH2 0x7468 GASPRICE KECCAK256 PUSH14 0x756C7469706C69636174696F6E20 PUSH16 0x766572666C6F77A26469706673582212 KECCAK256 0xB1 0xBB SSTORE OR PUSH6 0x40392A53031A MSIZE SWAP3 0xC3 0x4A PUSH16 0xA25DA7F0A28F415E6A3230AF396C65EF PUSH5 0x736F6C6343 STOP MOD SIGNEXTEND STOP CALLER ",
"sourceMap": "33945:1131:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;;"
},
"deployedBytecode": {
"immutableReferences": {},
"linkReferences": {},
"object": "73000000000000000000000000000000000000000030146080604052600436106100355760003560e01c8063c1e371861461003a575b600080fd5b6100766004803603608081101561005057600080fd5b506001600160a01b03813581169160208101358216916040820135169060600135610088565b60408051918252519081900360200190f35b6000610286846001600160a01b031663313ce5676040518163ffffffff1660e01b815260040160206040518083038186803b1580156100c657600080fd5b505afa1580156100da573d6000803e3d6000fd5b505050506040513d60208110156100f057600080fd5b5051604080516302c68be360e31b81526001600160a01b0387811660048301529151600a9390930a9261027a928a16916316345f18916024808301926020929190829003018186803b15801561014557600080fd5b505afa158015610159573d6000803e3d6000fd5b505050506040513d602081101561016f57600080fd5b50516040805163313ce56760e01b8152905161027a916001600160a01b038a169163313ce56791600480820192602092909190829003018186803b1580156101b657600080fd5b505afa1580156101ca573d6000803e3d6000fd5b505050506040513d60208110156101e057600080fd5b5051604080516302c68be360e31b81526001600160a01b038c811660048301529151600a9390930a9261026e928e16916316345f18916024808301926020929190829003018186803b15801561023557600080fd5b505afa158015610249573d6000803e3d6000fd5b505050506040513d602081101561025f57600080fd5b5051899063ffffffff61028f16565b9063ffffffff61028f16565b9063ffffffff6102f116565b95945050505050565b60008261029e575060006102eb565b828202828482816102ab57fe5b04146102e85760405162461bcd60e51b81526004018080602001828103825260218152602001806103d16021913960400191505060405180910390fd5b90505b92915050565b60006102e883836040518060400160405280601a81526020017f536166654d6174683a206469766973696f6e206279207a65726f000000000000815250600081836103ba5760405162461bcd60e51b81526004018080602001828103825283818151815260200191508051906020019080838360005b8381101561037f578181015183820152602001610367565b50505050905090810190601f1680156103ac5780820380516001836020036101000a031916815260200191505b509250505060405180910390fd5b5060008385816103c657fe5b049594505050505056fe536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77a2646970667358221220b1bb55176540392a53031a5992c34a6fa25da7f0a28f415e6a3230af396c65ef64736f6c634300060b0033",
"opcodes": "PUSH20 0x0 ADDRESS EQ PUSH1 0x80 PUSH1 0x40 MSTORE PUSH1 0x4 CALLDATASIZE LT PUSH2 0x35 JUMPI PUSH1 0x0 CALLDATALOAD PUSH1 0xE0 SHR DUP1 PUSH4 0xC1E37186 EQ PUSH2 0x3A JUMPI JUMPDEST PUSH1 0x0 DUP1 REVERT JUMPDEST PUSH2 0x76 PUSH1 0x4 DUP1 CALLDATASIZE SUB PUSH1 0x80 DUP2 LT ISZERO PUSH2 0x50 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP2 CALLDATALOAD DUP2 AND SWAP2 PUSH1 0x20 DUP2 ADD CALLDATALOAD DUP3 AND SWAP2 PUSH1 0x40 DUP3 ADD CALLDATALOAD AND SWAP1 PUSH1 0x60 ADD CALLDATALOAD PUSH2 0x88 JUMP JUMPDEST PUSH1 0x40 DUP1 MLOAD SWAP2 DUP3 MSTORE MLOAD SWAP1 DUP2 SWAP1 SUB PUSH1 0x20 ADD SWAP1 RETURN JUMPDEST PUSH1 0x0 PUSH2 0x286 DUP5 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB AND PUSH4 0x313CE567 PUSH1 0x40 MLOAD DUP2 PUSH4 0xFFFFFFFF AND PUSH1 0xE0 SHL DUP2 MSTORE PUSH1 0x4 ADD PUSH1 0x20 PUSH1 0x40 MLOAD DUP1 DUP4 SUB DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0xC6 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0xDA JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0xF0 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x40 DUP1 MLOAD PUSH4 0x2C68BE3 PUSH1 0xE3 SHL DUP2 MSTORE PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP8 DUP2 AND PUSH1 0x4 DUP4 ADD MSTORE SWAP2 MLOAD PUSH1 0xA SWAP4 SWAP1 SWAP4 EXP SWAP3 PUSH2 0x27A SWAP3 DUP11 AND SWAP2 PUSH4 0x16345F18 SWAP2 PUSH1 0x24 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x145 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x159 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x16F JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x40 DUP1 MLOAD PUSH4 0x313CE567 PUSH1 0xE0 SHL DUP2 MSTORE SWAP1 MLOAD PUSH2 0x27A SWAP2 PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP11 AND SWAP2 PUSH4 0x313CE567 SWAP2 PUSH1 0x4 DUP1 DUP3 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP1 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x1B6 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x1CA JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x1E0 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD PUSH1 0x40 DUP1 MLOAD PUSH4 0x2C68BE3 PUSH1 0xE3 SHL DUP2 MSTORE PUSH1 0x1 PUSH1 0x1 PUSH1 0xA0 SHL SUB DUP13 DUP2 AND PUSH1 0x4 DUP4 ADD MSTORE SWAP2 MLOAD PUSH1 0xA SWAP4 SWAP1 SWAP4 EXP SWAP3 PUSH2 0x26E SWAP3 DUP15 AND SWAP2 PUSH4 0x16345F18 SWAP2 PUSH1 0x24 DUP1 DUP4 ADD SWAP3 PUSH1 0x20 SWAP3 SWAP2 SWAP1 DUP3 SWAP1 SUB ADD DUP2 DUP7 DUP1 EXTCODESIZE ISZERO DUP1 ISZERO PUSH2 0x235 JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP GAS STATICCALL ISZERO DUP1 ISZERO PUSH2 0x249 JUMPI RETURNDATASIZE PUSH1 0x0 DUP1 RETURNDATACOPY RETURNDATASIZE PUSH1 0x0 REVERT JUMPDEST POP POP POP POP PUSH1 0x40 MLOAD RETURNDATASIZE PUSH1 0x20 DUP2 LT ISZERO PUSH2 0x25F JUMPI PUSH1 0x0 DUP1 REVERT JUMPDEST POP MLOAD DUP10 SWAP1 PUSH4 0xFFFFFFFF PUSH2 0x28F AND JUMP JUMPDEST SWAP1 PUSH4 0xFFFFFFFF PUSH2 0x28F AND JUMP JUMPDEST SWAP1 PUSH4 0xFFFFFFFF PUSH2 0x2F1 AND JUMP JUMPDEST SWAP6 SWAP5 POP POP POP POP POP JUMP JUMPDEST PUSH1 0x0 DUP3 PUSH2 0x29E JUMPI POP PUSH1 0x0 PUSH2 0x2EB JUMP JUMPDEST DUP3 DUP3 MUL DUP3 DUP5 DUP3 DUP2 PUSH2 0x2AB JUMPI INVALID JUMPDEST DIV EQ PUSH2 0x2E8 JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE PUSH1 0x21 DUP2 MSTORE PUSH1 0x20 ADD DUP1 PUSH2 0x3D1 PUSH1 0x21 SWAP2 CODECOPY PUSH1 0x40 ADD SWAP2 POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST SWAP1 POP JUMPDEST SWAP3 SWAP2 POP POP JUMP JUMPDEST PUSH1 0x0 PUSH2 0x2E8 DUP4 DUP4 PUSH1 0x40 MLOAD DUP1 PUSH1 0x40 ADD PUSH1 0x40 MSTORE DUP1 PUSH1 0x1A DUP2 MSTORE PUSH1 0x20 ADD PUSH32 0x536166654D6174683A206469766973696F6E206279207A65726F000000000000 DUP2 MSTORE POP PUSH1 0x0 DUP2 DUP4 PUSH2 0x3BA JUMPI PUSH1 0x40 MLOAD PUSH3 0x461BCD PUSH1 0xE5 SHL DUP2 MSTORE PUSH1 0x4 ADD DUP1 DUP1 PUSH1 0x20 ADD DUP3 DUP2 SUB DUP3 MSTORE DUP4 DUP2 DUP2 MLOAD DUP2 MSTORE PUSH1 0x20 ADD SWAP2 POP DUP1 MLOAD SWAP1 PUSH1 0x20 ADD SWAP1 DUP1 DUP4 DUP4 PUSH1 0x0 JUMPDEST DUP4 DUP2 LT ISZERO PUSH2 0x37F JUMPI DUP2 DUP2 ADD MLOAD DUP4 DUP3 ADD MSTORE PUSH1 0x20 ADD PUSH2 0x367 JUMP JUMPDEST POP POP POP POP SWAP1 POP SWAP1 DUP2 ADD SWAP1 PUSH1 0x1F AND DUP1 ISZERO PUSH2 0x3AC JUMPI DUP1 DUP3 SUB DUP1 MLOAD PUSH1 0x1 DUP4 PUSH1 0x20 SUB PUSH2 0x100 EXP SUB NOT AND DUP2 MSTORE PUSH1 0x20 ADD SWAP2 POP JUMPDEST POP SWAP3 POP POP POP PUSH1 0x40 MLOAD DUP1 SWAP2 SUB SWAP1 REVERT JUMPDEST POP PUSH1 0x0 DUP4 DUP6 DUP2 PUSH2 0x3C6 JUMPI INVALID JUMPDEST DIV SWAP6 SWAP5 POP POP POP POP POP JUMP INVALID MSTORE8 PUSH2 0x6665 0x4D PUSH2 0x7468 GASPRICE KECCAK256 PUSH14 0x756C7469706C69636174696F6E20 PUSH16 0x766572666C6F77A26469706673582212 KECCAK256 0xB1 0xBB SSTORE OR PUSH6 0x40392A53031A MSIZE SWAP3 0xC3 0x4A PUSH16 0xA25DA7F0A28F415E6A3230AF396C65EF PUSH5 0x736F6C6343 STOP MOD SIGNEXTEND STOP CALLER ",
"sourceMap": "33945:1131:0:-:0;;;;;;;;;;;;;;;;;;;;;;;;34480:593;;;;;;;;;;;;;;;;-1:-1:-1;;;;;;34480:593:0;;;;;;;;;;;;;;;;;;;;;;:::i;:::-;;;;;;;;;;;;;;;;;34602:7;34640:378;34996:9;-1:-1:-1;;;;;34982:33:0;;:35;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34982:35:0;34879:31;;;-1:-1:-1;;;34879:31:0;;-1:-1:-1;;;;;34879:31:0;;;;;;;;;34976:2;:41;;;;;34640:271;;34879:22;;;;;:31;;;;;34982:35;;34879:31;;;;;;;:22;:31;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34879:31:0;34776:33;;;-1:-1:-1;;;34776:33:0;;;;34640:170;;-1:-1:-1;;;;;34776:31:0;;;;;:33;;;;;34879:31;;34776:33;;;;;;;;:31;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34776:33:0;34669;;;-1:-1:-1;;;34669:33:0;;-1:-1:-1;;;;;34669:33:0;;;;;;;;;34770:2;:39;;;;;34640:63;;34669:22;;;;;:33;;;;;34776;;34669;;;;;;;:22;:33;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;-1:-1:-1;34669:33:0;34640:7;;:63;:28;:63;:::i;:::-;:129;:170;:129;:170;:::i;:::-;:238;:271;:238;:271;:::i;:378::-;34621:397;34480:593;-1:-1:-1;;;;;34480:593:0:o;30503:459::-;30561:7;30802:6;30798:45;;-1:-1:-1;30831:1:0;30824:8;;30798:45;30865:5;;;30869:1;30865;:5;:1;30888:5;;;;;:10;30880:56;;;;-1:-1:-1;;;30880:56:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;30954:1;-1:-1:-1;30503:459:0;;;;;:::o;31424:130::-;31482:7;31508:39;31512:1;31515;31508:39;;;;;;;;;;;;;;;;;32122:7;32156:12;32149:5;32141:28;;;;-1:-1:-1;;;32141:28:0;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;32179:9;32195:1;32191;:5;;;;;;;32036:272;-1:-1:-1;;;;;32036:272:0:o"
},
"methodIdentifiers": {
"calcMinAmount(IMapleGlobals,address,address,uint256)": "c1e37186"
}
}
}
}
},
"sources": {
"contracts/core/treasury/v1/MapleTreasury.sol": {
"ast": {
"absolutePath": "contracts/core/treasury/v1/MapleTreasury.sol",
"exportedSymbols": {
"Address": [
1203
],
"IERC20": [
697
],
"IERC20Details": [
715
],
"IMapleGlobals": [
492
],
"IMapleToken": [
572
],
"IMapleTreasury": [
568
],
"IUniswapRouter": [
621
],
"MapleTreasury": [
1726
],
"SafeERC20": [
1411
],
"SafeMath": [
909
],
"Util": [
961
]
},
"id": 1727,
"license": "AGPL-3.0-or-later",
"nodeType": "SourceUnit",
"nodes": [
{
"id": 1,
"literals": [
"solidity",
"=",
"0.6",
".11",
">=",
"0.6",
".0",
"<",
"0.8",
".0",
">=",
"0.6",
".2",
"<",
"0.8",
".0"
],
"nodeType": "PragmaDirective",
"src": "121:54:0"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "interface",
"documentation": {
"id": 2,
"nodeType": "StructuredDocumentation",
"src": "270:104:0",
"text": "@title MapleGlobals maintains a central source of parameters and allowlists for the Maple protocol."
},
"fullyImplemented": false,
"id": 492,
"linearizedBaseContracts": [
492
],
"name": "IMapleGlobals",
"nodeType": "ContractDefinition",
"nodes": [
{
"anonymous": false,
"documentation": {
"id": 3,
"nodeType": "StructuredDocumentation",
"src": "405:91:0",
"text": "@dev Emits an event indicating the MapleGlobals contract was created."
},
"id": 5,
"name": "Initialized",
"nodeType": "EventDefinition",
"parameters": {
"id": 4,
"nodeType": "ParameterList",
"parameters": [],
"src": "518:2:0"
},
"src": "501:20:0"
},
{
"anonymous": false,
"documentation": {
"id": 6,
"nodeType": "StructuredDocumentation",
"src": "527:336:0",
"text": "@dev Emits an event indicating the validity of a Collateral Asset was set.\n@param asset The Collateral Asset to assign validity to.\n@param decimals The number of decimal places of `asset`.\n@param symbol The symbol of `asset`.\n@param valid The new validity status of `asset`."
},
"id": 16,
"name": "CollateralAssetSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 15,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 8,
"indexed": false,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 16,
"src": "893:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 7,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "893:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 10,
"indexed": false,
"mutability": "mutable",
"name": "decimals",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 16,
"src": "908:16:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 9,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "908:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 12,
"indexed": false,
"mutability": "mutable",
"name": "symbol",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 16,
"src": "926:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 11,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "926:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 14,
"indexed": false,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 16,
"src": "941:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 13,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "941:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "892:60:0"
},
"src": "868:85:0"
},
{
"anonymous": false,
"documentation": {
"id": 17,
"nodeType": "StructuredDocumentation",
"src": "959:334:0",
"text": "@dev Emits an event indicating the validity of a Liquidity Asset was set.\n@param asset The Liquidity Asset to assign validity to.\n@param decimals The number of decimal places of `asset`.\n@param symbol The symbol of `asset`.\n@param valid The new validity status of `asset`."
},
"id": 27,
"name": "LiquidityAssetSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 26,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 19,
"indexed": false,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 27,
"src": "1322:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 18,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1322:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 21,
"indexed": false,
"mutability": "mutable",
"name": "decimals",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 27,
"src": "1337:16:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 20,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "1337:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 23,
"indexed": false,
"mutability": "mutable",
"name": "symbol",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 27,
"src": "1355:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 22,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "1355:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 25,
"indexed": false,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 27,
"src": "1370:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 24,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "1370:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1321:60:0"
},
"src": "1298:84:0"
},
{
"anonymous": false,
"documentation": {
"id": 28,
"nodeType": "StructuredDocumentation",
"src": "1388:183:0",
"text": "@dev Emits an event indicating the Oracle for an asset was set.\n@param asset The asset to update price for.\n@param oracle The new Oracle to use."
},
"id": 34,
"name": "OracleSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 33,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 30,
"indexed": false,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 34,
"src": "1592:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 29,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1592:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 32,
"indexed": false,
"mutability": "mutable",
"name": "oracle",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 34,
"src": "1607:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 31,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1607:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1591:31:0"
},
"src": "1576:47:0"
},
{
"anonymous": false,
"documentation": {
"id": 35,
"nodeType": "StructuredDocumentation",
"src": "1629:40:0",
"text": "@dev This is unused."
},
"id": 41,
"name": "TransferRestrictionExemptionSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 40,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 37,
"indexed": true,
"mutability": "mutable",
"name": "exemptedContract",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 41,
"src": "1712:32:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 36,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "1712:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 39,
"indexed": false,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 41,
"src": "1746:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 38,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "1746:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "1711:46:0"
},
"src": "1674:84:0"
},
{
"anonymous": false,
"documentation": {
"id": 42,
"nodeType": "StructuredDocumentation",
"src": "1764:232:0",
"text": "@dev Emits an event indicating the validity of a Balancer Pool was set.\n@param balancerPool The address of Balancer Pool contract.\n@param valid The new validity status of a Balancer Pool."
},
"id": 48,
"name": "BalancerPoolSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 47,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 44,
"indexed": false,
"mutability": "mutable",
"name": "balancerPool",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 48,
"src": "2023:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 43,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2023:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 46,
"indexed": false,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 48,
"src": "2045:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 45,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "2045:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2022:34:0"
},
"src": "2001:56:0"
},
{
"anonymous": false,
"documentation": {
"id": 49,
"nodeType": "StructuredDocumentation",
"src": "2063:151:0",
"text": "@dev Emits an event indicating a PendingGovernor was set.\n@param pendingGovernor The address of the new Pending Governor."
},
"id": 53,
"name": "PendingGovernorSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 52,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 51,
"indexed": true,
"mutability": "mutable",
"name": "pendingGovernor",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 53,
"src": "2244:31:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 50,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2244:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2243:33:0"
},
"src": "2219:58:0"
},
{
"anonymous": false,
"documentation": {
"id": 54,
"nodeType": "StructuredDocumentation",
"src": "2283:164:0",
"text": "@dev Emits an event indicating Governorship was accepted by a new account.\n@param governor The account that has accepted Governorship."
},
"id": 58,
"name": "GovernorAccepted",
"nodeType": "EventDefinition",
"parameters": {
"id": 57,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 56,
"indexed": true,
"mutability": "mutable",
"name": "governor",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 58,
"src": "2475:24:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 55,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "2475:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2474:26:0"
},
"src": "2452:49:0"
},
{
"anonymous": false,
"documentation": {
"id": 59,
"nodeType": "StructuredDocumentation",
"src": "2507:225:0",
"text": "@dev Emits an event indicating that some Governor controlled parameter was set.\n@param which The identifier of the parameter that was set.\n@param value The value the parameter was set to."
},
"id": 65,
"name": "GlobalsParamSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 64,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 61,
"indexed": true,
"mutability": "mutable",
"name": "which",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 65,
"src": "2759:21:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 60,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "2759:7:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 63,
"indexed": false,
"mutability": "mutable",
"name": "value",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 65,
"src": "2782:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 62,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "2782:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "2758:38:0"
},
"src": "2737:60:0"
},
{
"anonymous": false,
"documentation": {
"id": 66,
"nodeType": "StructuredDocumentation",
"src": "2803:211:0",
"text": "@dev Emits an event indicating that some Governor controlled address was set.\n@param which The identifier of the address that was set.\n@param addr The address that was set."
},
"id": 72,
"name": "GlobalsAddressSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 71,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 68,
"indexed": true,
"mutability": "mutable",
"name": "which",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 72,
"src": "3043:21:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
},
"typeName": {
"id": 67,
"name": "bytes32",
"nodeType": "ElementaryTypeName",
"src": "3043:7:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes32",
"typeString": "bytes32"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 70,
"indexed": false,
"mutability": "mutable",
"name": "addr",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 72,
"src": "3066:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 69,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3066:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3042:37:0"
},
"src": "3019:61:0"
},
{
"anonymous": false,
"documentation": {
"id": 73,
"nodeType": "StructuredDocumentation",
"src": "3086:148:0",
"text": "@dev Emits an event indicating the protocol's paused state has been set.\n@param pause Whether the protocol was paused."
},
"id": 77,
"name": "ProtocolPaused",
"nodeType": "EventDefinition",
"parameters": {
"id": 76,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 75,
"indexed": false,
"mutability": "mutable",
"name": "pause",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 77,
"src": "3260:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 74,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "3260:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3259:12:0"
},
"src": "3239:33:0"
},
{
"anonymous": false,
"documentation": {
"id": 78,
"nodeType": "StructuredDocumentation",
"src": "3278:143:0",
"text": "@dev Emits an event indicating the GlobalAdmin was set.\n@param newGlobalAdmin The address of the new GlobalAdmin."
},
"id": 82,
"name": "GlobalAdminSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 81,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 80,
"indexed": true,
"mutability": "mutable",
"name": "newGlobalAdmin",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 82,
"src": "3447:30:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 79,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3447:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3446:32:0"
},
"src": "3426:53:0"
},
{
"anonymous": false,
"documentation": {
"id": 83,
"nodeType": "StructuredDocumentation",
"src": "3485:230:0",
"text": "@dev Emits an event indicating the validity of a Pool Delegate was set.\n@param poolDelegate The address of a Pool Delegate.\n@param valid Whether `poolDelegate` is a valid Pool Delegate."
},
"id": 89,
"name": "PoolDelegateSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 88,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 85,
"indexed": true,
"mutability": "mutable",
"name": "poolDelegate",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 89,
"src": "3742:28:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 84,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3742:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 87,
"indexed": false,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 89,
"src": "3772:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 86,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "3772:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3741:42:0"
},
"src": "3720:64:0"
},
{
"body": null,
"documentation": {
"id": 90,
"nodeType": "StructuredDocumentation",
"src": "3790:73:0",
"text": "@dev The ERC-2222 Maple Token for the Maple protocol."
},
"functionSelector": "a0530946",
"id": 95,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "mpl",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 91,
"nodeType": "ParameterList",
"parameters": [],
"src": "3880:2:0"
},
"returnParameters": {
"id": 94,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 93,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 95,
"src": "3906:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 92,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "3906:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "3905:9:0"
},
"scope": 492,
"src": "3868:47:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 96,
"nodeType": "StructuredDocumentation",
"src": "3921:142:0",
"text": "@dev The Governor that is declared for governorship transfer. \n@dev Must be accepted for transfer to take effect. "
},
"functionSelector": "e3056a34",
"id": 101,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "pendingGovernor",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 97,
"nodeType": "ParameterList",
"parameters": [],
"src": "4092:2:0"
},
"returnParameters": {
"id": 100,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 99,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 101,
"src": "4118:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 98,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "4118:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4117:9:0"
},
"scope": 492,
"src": "4068:59:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 102,
"nodeType": "StructuredDocumentation",
"src": "4133:91:0",
"text": "@dev The Governor responsible for management of global Maple variables."
},
"functionSelector": "0c340a24",
"id": 107,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "governor",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 103,
"nodeType": "ParameterList",
"parameters": [],
"src": "4246:2:0"
},
"returnParameters": {
"id": 106,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 105,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 107,
"src": "4272:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 104,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "4272:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4271:9:0"
},
"scope": 492,
"src": "4229:52:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 108,
"nodeType": "StructuredDocumentation",
"src": "4287:125:0",
"text": "@dev The MapleTreasury is the Treasury where all fees pass through for conversion, prior to distribution."
},
"functionSelector": "a5a27605",
"id": 113,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "mapleTreasury",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 109,
"nodeType": "ParameterList",
"parameters": [],
"src": "4439:2:0"
},
"returnParameters": {
"id": 112,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 111,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 113,
"src": "4465:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 110,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "4465:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4464:9:0"
},
"scope": 492,
"src": "4417:57:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 114,
"nodeType": "StructuredDocumentation",
"src": "4480:147:0",
"text": "@dev The Global Admin of the whole network. \n@dev Has the power to switch off/on the functionality of entire protocol. "
},
"functionSelector": "ec9a9368",
"id": 119,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "globalAdmin",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 115,
"nodeType": "ParameterList",
"parameters": [],
"src": "4652:2:0"
},
"returnParameters": {
"id": 118,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 117,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 119,
"src": "4678:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 116,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "4678:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4677:9:0"
},
"scope": 492,
"src": "4632:55:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 120,
"nodeType": "StructuredDocumentation",
"src": "4693:119:0",
"text": "@dev The amount of time a Borrower has to make a missed payment before a default can be triggered. "
},
"functionSelector": "705d5f24",
"id": 125,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "defaultGracePeriod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 121,
"nodeType": "ParameterList",
"parameters": [],
"src": "4844:2:0"
},
"returnParameters": {
"id": 124,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 123,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 125,
"src": "4870:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 122,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "4870:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "4869:9:0"
},
"scope": 492,
"src": "4817:62:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 126,
"nodeType": "StructuredDocumentation",
"src": "4885:126:0",
"text": "@dev The minimum amount of Pool cover that a Pool Delegate has to provide before they can finalize a Pool."
},
"functionSelector": "3106374c",
"id": 131,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "swapOutRequired",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 127,
"nodeType": "ParameterList",
"parameters": [],
"src": "5040:2:0"
},
"returnParameters": {
"id": 130,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 129,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 131,
"src": "5066:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 128,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "5066:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "5065:9:0"
},
"scope": 492,
"src": "5016:59:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 132,
"nodeType": "StructuredDocumentation",
"src": "5081:116:0",
"text": "@dev The amount of time to allow a Borrower to drawdown on their Loan after funding period ends."
},
"functionSelector": "74d7c62b",
"id": 137,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "fundingPeriod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 133,
"nodeType": "ParameterList",
"parameters": [],
"src": "5224:2:0"
},
"returnParameters": {
"id": 136,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 135,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 137,
"src": "5250:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 134,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "5250:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "5249:9:0"
},
"scope": 492,
"src": "5202:57:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 138,
"nodeType": "StructuredDocumentation",
"src": "5265:104:0",
"text": "@dev The portion of drawdown that goes to the Pool Delegates and individual Lenders."
},
"functionSelector": "16a12d7a",
"id": 143,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "investorFee",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 139,
"nodeType": "ParameterList",
"parameters": [],
"src": "5394:2:0"
},
"returnParameters": {
"id": 142,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 141,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 143,
"src": "5420:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 140,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "5420:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "5419:9:0"
},
"scope": 492,
"src": "5374:55:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 144,
"nodeType": "StructuredDocumentation",
"src": "5435:80:0",
"text": "@dev The portion of drawdown that goes to the MapleTreasury."
},
"functionSelector": "cc32d176",
"id": 149,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "treasuryFee",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 145,
"nodeType": "ParameterList",
"parameters": [],
"src": "5540:2:0"
},
"returnParameters": {
"id": 148,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 147,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 149,
"src": "5566:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 146,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "5566:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "5565:9:0"
},
"scope": 492,
"src": "5520:55:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 150,
"nodeType": "StructuredDocumentation",
"src": "5581:81:0",
"text": "@dev The maximum amount of slippage for Uniswap transactions."
},
"functionSelector": "55323195",
"id": 155,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "maxSwapSlippage",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 151,
"nodeType": "ParameterList",
"parameters": [],
"src": "5691:2:0"
},
"returnParameters": {
"id": 154,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 153,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 155,
"src": "5717:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 152,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "5717:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "5716:9:0"
},
"scope": 492,
"src": "5667:59:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 156,
"nodeType": "StructuredDocumentation",
"src": "5732:130:0",
"text": "@dev The minimum amount of LoanFDTs required to trigger liquidations (basis points percentage of totalSupply)."
},
"functionSelector": "4a2697c4",
"id": 161,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "minLoanEquity",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 157,
"nodeType": "ParameterList",
"parameters": [],
"src": "5889:2:0"
},
"returnParameters": {
"id": 160,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 159,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 161,
"src": "5915:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 158,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "5915:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "5914:9:0"
},
"scope": 492,
"src": "5867:57:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 162,
"nodeType": "StructuredDocumentation",
"src": "5930:119:0",
"text": "@dev The period (in secs) after which Stakers are allowed to unstake their BPTs from a StakeLocker."
},
"functionSelector": "a965d6b5",
"id": 167,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "stakerCooldownPeriod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 163,
"nodeType": "ParameterList",
"parameters": [],
"src": "6083:2:0"
},
"returnParameters": {
"id": 166,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 165,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 167,
"src": "6109:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 164,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "6109:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "6108:9:0"
},
"scope": 492,
"src": "6054:64:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 168,
"nodeType": "StructuredDocumentation",
"src": "6124:110:0",
"text": "@dev The period (in secs) after which LPs are allowed to withdraw their funds from a Pool."
},
"functionSelector": "dd02e0ec",
"id": 173,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "lpCooldownPeriod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 169,
"nodeType": "ParameterList",
"parameters": [],
"src": "6264:2:0"
},
"returnParameters": {
"id": 172,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 171,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 173,
"src": "6290:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 170,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "6290:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "6289:9:0"
},
"scope": 492,
"src": "6239:60:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 174,
"nodeType": "StructuredDocumentation",
"src": "6305:161:0",
"text": "@dev The window of time (in secs) after `stakerCooldownPeriod` that an account has to withdraw before their intent to unstake is invalidated."
},
"functionSelector": "2018b870",
"id": 179,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "stakerUnstakeWindow",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 175,
"nodeType": "ParameterList",
"parameters": [],
"src": "6499:2:0"
},
"returnParameters": {
"id": 178,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 177,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 179,
"src": "6525:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 176,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "6525:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "6524:9:0"
},
"scope": 492,
"src": "6471:63:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 180,
"nodeType": "StructuredDocumentation",
"src": "6540:158:0",
"text": "@dev The window of time (in secs) after `lpCooldownPeriod` that an account has to withdraw before their intent to withdraw is invalidated."
},
"functionSelector": "df3d02bd",
"id": 185,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "lpWithdrawWindow",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 181,
"nodeType": "ParameterList",
"parameters": [],
"src": "6728:2:0"
},
"returnParameters": {
"id": 184,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 183,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 185,
"src": "6754:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 182,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "6754:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "6753:9:0"
},
"scope": 492,
"src": "6703:60:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 186,
"nodeType": "StructuredDocumentation",
"src": "6769:84:0",
"text": "@dev Whether the functionality of the entire protocol is paused."
},
"functionSelector": "425fad58",
"id": 191,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "protocolPaused",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 187,
"nodeType": "ParameterList",
"parameters": [],
"src": "6881:2:0"
},
"returnParameters": {
"id": 190,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 189,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 191,
"src": "6907:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 188,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "6907:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "6906:6:0"
},
"scope": 492,
"src": "6858:55:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 192,
"nodeType": "StructuredDocumentation",
"src": "6919:127:0",
"text": "@param liquidityAsset The address of a Liquidity Asset.\n@return Whether `liquidityAsset` is valid."
},
"functionSelector": "8695118a",
"id": 199,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "isValidLiquidityAsset",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 195,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 194,
"mutability": "mutable",
"name": "liquidityAsset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 199,
"src": "7082:22:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 193,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "7082:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7081:24:0"
},
"returnParameters": {
"id": 198,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 197,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 199,
"src": "7129:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 196,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "7129:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7128:6:0"
},
"scope": 492,
"src": "7051:84:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 200,
"nodeType": "StructuredDocumentation",
"src": "7141:130:0",
"text": "@param collateralAsset The address of a Collateral Asset.\n@return Whether `collateralAsset` is valid."
},
"functionSelector": "8c14834b",
"id": 207,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "isValidCollateralAsset",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 203,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 202,
"mutability": "mutable",
"name": "collateralAsset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 207,
"src": "7308:23:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 201,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "7308:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7307:25:0"
},
"returnParameters": {
"id": 206,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 205,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 207,
"src": "7356:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 204,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "7356:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7355:6:0"
},
"scope": 492,
"src": "7276:86:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 208,
"nodeType": "StructuredDocumentation",
"src": "7368:102:0",
"text": "@param calc The address of a Calculator.\n@return Whether `calc` is valid."
},
"functionSelector": "1beb84e7",
"id": 215,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "validCalcs",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 211,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 210,
"mutability": "mutable",
"name": "calc",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 215,
"src": "7495:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 209,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "7495:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7494:14:0"
},
"returnParameters": {
"id": 214,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 213,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 215,
"src": "7532:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 212,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "7532:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7531:6:0"
},
"scope": 492,
"src": "7475:63:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 216,
"nodeType": "StructuredDocumentation",
"src": "7544:198:0",
"text": "@dev Prevents unauthorized/unknown addresses from creating Pools.\n@param poolDelegate The address of a Pool Delegate.\n@return Whether `poolDelegate` is valid."
},
"functionSelector": "372e3546",
"id": 223,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "isValidPoolDelegate",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 219,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 218,
"mutability": "mutable",
"name": "poolDelegate",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 223,
"src": "7776:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 217,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "7776:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7775:22:0"
},
"returnParameters": {
"id": 222,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 221,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 223,
"src": "7821:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 220,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "7821:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "7820:6:0"
},
"scope": 492,
"src": "7747:80:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 224,
"nodeType": "StructuredDocumentation",
"src": "7833:147:0",
"text": "@param balancerPool The address of a Balancer Pool.\n@return Whether Maple has approved `balancerPool` for BPT staking."
},
"functionSelector": "72a22d71",
"id": 231,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "isValidBalancerPool",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 227,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 226,
"mutability": "mutable",
"name": "balancerPool",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 231,
"src": "8014:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 225,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "8014:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "8013:22:0"
},
"returnParameters": {
"id": 230,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 229,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 231,
"src": "8059:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 228,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "8059:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "8058:6:0"
},
"scope": 492,
"src": "7985:80:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 232,
"nodeType": "StructuredDocumentation",
"src": "8071:768:0",
"text": "@dev Determines the liquidation path of various assets in Loans and the Treasury. \n@dev The value provided will determine whether or not to perform a bilateral or triangular swap on Uniswap. \n@dev For example, `defaultUniswapPath[WBTC][USDC]` value would indicate what asset to convert WBTC into before conversion to USDC. \n@dev If `defaultUniswapPath[WBTC][USDC] == USDC`, then the swap is bilateral and no middle asset is swapped. \n@dev If `defaultUniswapPath[WBTC][USDC] == WETH`, then swap WBTC for WETH, then WETH for USDC. \n@param tokenA The address of the asset being swapped.\n@param tokenB The address of the final asset to receive.\n@return The intermediary asset for swaps, if any."
},
"functionSelector": "4d866592",
"id": 241,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "defaultUniswapPath",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 237,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 234,
"mutability": "mutable",
"name": "tokenA",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 241,
"src": "8872:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 233,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "8872:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 236,
"mutability": "mutable",
"name": "tokenB",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 241,
"src": "8888:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 235,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "8888:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "8871:32:0"
},
"returnParameters": {
"id": 240,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 239,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 241,
"src": "8927:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 238,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "8927:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "8926:9:0"
},
"scope": 492,
"src": "8844:92:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 242,
"nodeType": "StructuredDocumentation",
"src": "8942:123:0",
"text": "@param asset The address of some token.\n@return The Chainlink Oracle for the price of `asset`."
},
"functionSelector": "aed019b9",
"id": 249,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "oracleFor",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 245,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 244,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 249,
"src": "9089:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 243,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "9089:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9088:15:0"
},
"returnParameters": {
"id": 248,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 247,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 249,
"src": "9127:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 246,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "9127:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9126:9:0"
},
"scope": 492,
"src": "9070:66:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 250,
"nodeType": "StructuredDocumentation",
"src": "9146:118:0",
"text": "@param poolFactory The address of a Pool Factory.\n@return Whether `poolFactory` is valid."
},
"functionSelector": "107c0240",
"id": 257,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "isValidPoolFactory",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 253,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 252,
"mutability": "mutable",
"name": "poolFactory",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 257,
"src": "9297:19:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 251,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "9297:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9296:21:0"
},
"returnParameters": {
"id": 256,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 255,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 257,
"src": "9341:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 254,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "9341:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9340:6:0"
},
"scope": 492,
"src": "9269:78:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 258,
"nodeType": "StructuredDocumentation",
"src": "9353:118:0",
"text": "@param loanFactory The address of a Loan Factory.\n@return Whether `loanFactory` is valid."
},
"functionSelector": "b53afda7",
"id": 265,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "isValidLoanFactory",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 261,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 260,
"mutability": "mutable",
"name": "loanFactory",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 265,
"src": "9504:19:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 259,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "9504:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9503:21:0"
},
"returnParameters": {
"id": 264,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 263,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 265,
"src": "9548:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 262,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "9548:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9547:6:0"
},
"scope": 492,
"src": "9476:78:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 266,
"nodeType": "StructuredDocumentation",
"src": "9564:266:0",
"text": "@param superFactory The core factory (e.g. PoolFactory, LoanFactory).\n@param subFactory The sub factory used by core factory (e.g. LiquidityLockerFactory).\n@return Whether `subFactory` is valid as it relates to `superFactory`."
},
"functionSelector": "1b1804aa",
"id": 275,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "validSubFactories",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 271,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 268,
"mutability": "mutable",
"name": "superFactory",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 275,
"src": "9862:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 267,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "9862:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 270,
"mutability": "mutable",
"name": "subFactory",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 275,
"src": "9884:18:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 269,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "9884:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9861:42:0"
},
"returnParameters": {
"id": 274,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 273,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 275,
"src": "9927:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 272,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "9927:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "9926:6:0"
},
"scope": 492,
"src": "9835:98:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 276,
"nodeType": "StructuredDocumentation",
"src": "9943:363:0",
"text": "@dev Sets the Staker cooldown period. \n@dev This change will affect the existing cool down period for the Stakers that already intended to unstake. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param newCooldownPeriod The new value for the cool down period."
},
"functionSelector": "fd4a9121",
"id": 281,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setStakerCooldownPeriod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 279,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 278,
"mutability": "mutable",
"name": "newCooldownPeriod",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 281,
"src": "10344:25:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 277,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "10344:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "10343:27:0"
},
"returnParameters": {
"id": 280,
"nodeType": "ParameterList",
"parameters": [],
"src": "10379:0:0"
},
"scope": 492,
"src": "10311:69:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 282,
"nodeType": "StructuredDocumentation",
"src": "10386:368:0",
"text": "@dev Sets the Liquidity Pool cooldown period. \n@dev This change will affect the existing cool down period for the LPs that already intended to withdraw. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param newCooldownPeriod The new value for the cool down period."
},
"functionSelector": "8608a6e1",
"id": 287,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setLpCooldownPeriod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 285,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 284,
"mutability": "mutable",
"name": "newCooldownPeriod",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 287,
"src": "10788:25:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 283,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "10788:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "10787:27:0"
},
"returnParameters": {
"id": 286,
"nodeType": "ParameterList",
"parameters": [],
"src": "10823:0:0"
},
"scope": 492,
"src": "10759:65:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 288,
"nodeType": "StructuredDocumentation",
"src": "10830:349:0",
"text": "@dev Sets the Staker unstake window. \n@dev This change will affect the existing window for the Stakers that already intended to unstake. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param newUnstakeWindow The new value for the unstake window."
},
"functionSelector": "d1cdf301",
"id": 293,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setStakerUnstakeWindow",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 291,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 290,
"mutability": "mutable",
"name": "newUnstakeWindow",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 293,
"src": "11216:24:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 289,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "11216:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "11215:26:0"
},
"returnParameters": {
"id": 292,
"nodeType": "ParameterList",
"parameters": [],
"src": "11250:0:0"
},
"scope": 492,
"src": "11184:67:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 294,
"nodeType": "StructuredDocumentation",
"src": "11257:359:0",
"text": "@dev Sets the Liquidity Pool withdraw window. \n@dev This change will affect the existing window for the LPs that already intended to withdraw. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param newLpWithdrawWindow The new value for the withdraw window."
},
"functionSelector": "26718606",
"id": 299,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setLpWithdrawWindow",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 297,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 296,
"mutability": "mutable",
"name": "newLpWithdrawWindow",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 299,
"src": "11650:27:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 295,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "11650:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "11649:29:0"
},
"returnParameters": {
"id": 298,
"nodeType": "ParameterList",
"parameters": [],
"src": "11687:0:0"
},
"scope": 492,
"src": "11621:67:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 300,
"nodeType": "StructuredDocumentation",
"src": "11694:280:0",
"text": "@dev Sets the allowed Uniswap slippage percentage, in basis points. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param newMaxSlippage The new max slippage percentage (in basis points)"
},
"functionSelector": "f33ef09a",
"id": 305,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setMaxSwapSlippage",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 303,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 302,
"mutability": "mutable",
"name": "newMaxSlippage",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 305,
"src": "12007:22:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 301,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "12007:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "12006:24:0"
},
"returnParameters": {
"id": 304,
"nodeType": "ParameterList",
"parameters": [],
"src": "12039:0:0"
},
"scope": 492,
"src": "11979:61:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 306,
"nodeType": "StructuredDocumentation",
"src": "12046:211:0",
"text": "@dev Sets the Global Admin. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalAdminSet` event. \n@param newGlobalAdmin The new global admin address."
},
"functionSelector": "c52bc31d",
"id": 311,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setGlobalAdmin",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 309,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 308,
"mutability": "mutable",
"name": "newGlobalAdmin",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 311,
"src": "12286:22:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 307,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "12286:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "12285:24:0"
},
"returnParameters": {
"id": 310,
"nodeType": "ParameterList",
"parameters": [],
"src": "12318:0:0"
},
"scope": 492,
"src": "12262:57:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 312,
"nodeType": "StructuredDocumentation",
"src": "12325:314:0",
"text": "@dev Sets the validity of a Balancer Pool. \n@dev Only the Governor can call this function. \n@dev It emits a `BalancerPoolSet` event. \n@param balancerPool The address of Balancer Pool contract.\n@param valid The new validity status of a Balancer Pool."
},
"functionSelector": "490dae64",
"id": 319,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setValidBalancerPool",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 317,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 314,
"mutability": "mutable",
"name": "balancerPool",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 319,
"src": "12674:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 313,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "12674:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 316,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 319,
"src": "12696:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 315,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "12696:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "12673:34:0"
},
"returnParameters": {
"id": 318,
"nodeType": "ParameterList",
"parameters": [],
"src": "12716:0:0"
},
"scope": 492,
"src": "12644:73:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 320,
"nodeType": "StructuredDocumentation",
"src": "12723:290:0",
"text": "@dev Sets the paused/unpaused state of the protocol. \n@dev Only the Global Admin can call this function. \n@dev It emits a `ProtocolPaused` event. \n@param pause A boolean flag to switch externally facing functionality in the protocol on/off."
},
"functionSelector": "4e989118",
"id": 325,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setProtocolPause",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 323,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 322,
"mutability": "mutable",
"name": "pause",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 325,
"src": "13044:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 321,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "13044:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "13043:12:0"
},
"returnParameters": {
"id": 324,
"nodeType": "ParameterList",
"parameters": [],
"src": "13064:0:0"
},
"scope": 492,
"src": "13018:47:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 326,
"nodeType": "StructuredDocumentation",
"src": "13071:247:0",
"text": "@dev Sets the validity of a PoolFactory. \n@dev Only the Governor can call this function. \n@param poolFactory The address of a PoolFactory.\n@param valid The new validity status of `poolFactory`."
},
"functionSelector": "6597b899",
"id": 333,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setValidPoolFactory",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 331,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 328,
"mutability": "mutable",
"name": "poolFactory",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 333,
"src": "13352:19:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 327,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "13352:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 330,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 333,
"src": "13373:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 329,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "13373:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "13351:33:0"
},
"returnParameters": {
"id": 332,
"nodeType": "ParameterList",
"parameters": [],
"src": "13393:0:0"
},
"scope": 492,
"src": "13323:71:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 334,
"nodeType": "StructuredDocumentation",
"src": "13400:247:0",
"text": "@dev Sets the validity of a LoanFactory. \n@dev Only the Governor can call this function. \n@param loanFactory The address of a LoanFactory.\n@param valid The new validity status of `loanFactory`."
},
"functionSelector": "c9c67240",
"id": 341,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setValidLoanFactory",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 339,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 336,
"mutability": "mutable",
"name": "loanFactory",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 341,
"src": "13681:19:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 335,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "13681:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 338,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 341,
"src": "13702:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 337,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "13702:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "13680:33:0"
},
"returnParameters": {
"id": 340,
"nodeType": "ParameterList",
"parameters": [],
"src": "13722:0:0"
},
"scope": 492,
"src": "13652:71:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 342,
"nodeType": "StructuredDocumentation",
"src": "13729:428:0",
"text": "@dev Sets the validity of `subFactory` as it relates to `superFactory`. \n@dev Only the Governor can call this function. \n@param superFactory The core factory (e.g. PoolFactory, LoanFactory).\n@param subFactory The sub factory used by core factory (e.g. LiquidityLockerFactory).\n@param valid The new validity status of `subFactory` within context of `superFactory`."
},
"functionSelector": "f85ee6f8",
"id": 351,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setValidSubFactory",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 349,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 344,
"mutability": "mutable",
"name": "superFactory",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 351,
"src": "14190:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 343,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "14190:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 346,
"mutability": "mutable",
"name": "subFactory",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 351,
"src": "14212:18:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 345,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "14212:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 348,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 351,
"src": "14232:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 347,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "14232:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "14189:54:0"
},
"returnParameters": {
"id": 350,
"nodeType": "ParameterList",
"parameters": [],
"src": "14252:0:0"
},
"scope": 492,
"src": "14162:91:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 352,
"nodeType": "StructuredDocumentation",
"src": "14259:472:0",
"text": "@dev Sets the path to swap an asset through Uniswap. \n@dev Only the Governor can call this function. \n@dev Set to == mid to enable a bilateral swap (single path swap). \n@dev Set to != mid to enable a triangular swap (multi path swap). \n@param from The address of the asset being swapped.\n@param to The address of the final asset to receive.\n@param mid The intermediary asset for swaps, if any."
},
"functionSelector": "f3897663",
"id": 361,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setDefaultUniswapPath",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 359,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 354,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 361,
"src": "14767:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 353,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "14767:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 356,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 361,
"src": "14781:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 355,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "14781:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 358,
"mutability": "mutable",
"name": "mid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 361,
"src": "14793:11:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 357,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "14793:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "14766:39:0"
},
"returnParameters": {
"id": 360,
"nodeType": "ParameterList",
"parameters": [],
"src": "14814:0:0"
},
"scope": 492,
"src": "14736:79:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 362,
"nodeType": "StructuredDocumentation",
"src": "14821:346:0",
"text": "@dev Sets the validity of a Pool Delegate (those allowed to create Pools). \n@dev Only the Governor can call this function. \n@dev It emits a `PoolDelegateSet` event. \n@param poolDelegate The address to manage permissions for.\n@param valid The new validity status of a Pool Delegate."
},
"functionSelector": "efdb16fc",
"id": 369,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setPoolDelegateAllowlist",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 367,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 364,
"mutability": "mutable",
"name": "poolDelegate",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 369,
"src": "15206:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 363,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "15206:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 366,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 369,
"src": "15228:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 365,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "15228:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "15205:34:0"
},
"returnParameters": {
"id": 368,
"nodeType": "ParameterList",
"parameters": [],
"src": "15248:0:0"
},
"scope": 492,
"src": "15172:77:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 370,
"nodeType": "StructuredDocumentation",
"src": "15255:308:0",
"text": "@dev Sets the validity of an asset for collateral. \n@dev Only the Governor can call this function. \n@dev It emits a `CollateralAssetSet` event. \n@param asset The asset to assign validity to.\n@param valid The new validity status of a Collateral Asset."
},
"functionSelector": "2fa6c88f",
"id": 377,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setCollateralAsset",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 375,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 372,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 377,
"src": "15596:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 371,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "15596:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 374,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 377,
"src": "15611:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 373,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "15611:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "15595:27:0"
},
"returnParameters": {
"id": 376,
"nodeType": "ParameterList",
"parameters": [],
"src": "15631:0:0"
},
"scope": 492,
"src": "15568:64:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 378,
"nodeType": "StructuredDocumentation",
"src": "15638:320:0",
"text": "@dev Sets the validity of an asset for liquidity in Pools. \n@dev Only the Governor can call this function. \n@dev It emits a `LiquidityAssetSet` event. \n@param asset The asset to assign validity to.\n@param valid The new validity status a Liquidity Asset in Pools."
},
"functionSelector": "2daa0d89",
"id": 385,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setLiquidityAsset",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 383,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 380,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 385,
"src": "15990:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 379,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "15990:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 382,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 385,
"src": "16005:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 381,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "16005:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "15989:27:0"
},
"returnParameters": {
"id": 384,
"nodeType": "ParameterList",
"parameters": [],
"src": "16025:0:0"
},
"scope": 492,
"src": "15963:63:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 386,
"nodeType": "StructuredDocumentation",
"src": "16032:236:0",
"text": "@dev Sets the validity of a calculator contract. \n@dev Only the Governor can call this function. \n@param calc The Calculator address.\n@param valid The new validity status of a Calculator."
},
"functionSelector": "be44ed6b",
"id": 393,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setCalc",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 391,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 388,
"mutability": "mutable",
"name": "calc",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 393,
"src": "16290:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 387,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "16290:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 390,
"mutability": "mutable",
"name": "valid",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 393,
"src": "16304:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 389,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "16304:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "16289:26:0"
},
"returnParameters": {
"id": 392,
"nodeType": "ParameterList",
"parameters": [],
"src": "16324:0:0"
},
"scope": 492,
"src": "16273:52:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 394,
"nodeType": "StructuredDocumentation",
"src": "16331:225:0",
"text": "@dev Sets the investor fee (in basis points). \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param _fee The fee, e.g., 50 = 0.50%."
},
"functionSelector": "5e045467",
"id": 399,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setInvestorFee",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 397,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 396,
"mutability": "mutable",
"name": "_fee",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 399,
"src": "16585:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 395,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "16585:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "16584:14:0"
},
"returnParameters": {
"id": 398,
"nodeType": "ParameterList",
"parameters": [],
"src": "16607:0:0"
},
"scope": 492,
"src": "16561:47:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 400,
"nodeType": "StructuredDocumentation",
"src": "16614:225:0",
"text": "@dev Sets the treasury fee (in basis points). \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param _fee The fee, e.g., 50 = 0.50%."
},
"functionSelector": "77e741c7",
"id": 405,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setTreasuryFee",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 403,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 402,
"mutability": "mutable",
"name": "_fee",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 405,
"src": "16868:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 401,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "16868:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "16867:14:0"
},
"returnParameters": {
"id": 404,
"nodeType": "ParameterList",
"parameters": [],
"src": "16890:0:0"
},
"scope": 492,
"src": "16844:47:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 406,
"nodeType": "StructuredDocumentation",
"src": "16897:220:0",
"text": "@dev Sets the MapleTreasury. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param _mapleTreasury A new MapleTreasury address."
},
"functionSelector": "7303de25",
"id": 411,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setMapleTreasury",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 409,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 408,
"mutability": "mutable",
"name": "_mapleTreasury",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 411,
"src": "17148:22:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 407,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "17148:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "17147:24:0"
},
"returnParameters": {
"id": 410,
"nodeType": "ParameterList",
"parameters": [],
"src": "17180:0:0"
},
"scope": 492,
"src": "17122:59:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 412,
"nodeType": "StructuredDocumentation",
"src": "17187:257:0",
"text": "@dev Sets the default grace period. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param _defaultGracePeriod The new number of seconds to set the grace period to."
},
"functionSelector": "44c14f71",
"id": 417,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setDefaultGracePeriod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 415,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 414,
"mutability": "mutable",
"name": "_defaultGracePeriod",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 417,
"src": "17480:27:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 413,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "17480:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "17479:29:0"
},
"returnParameters": {
"id": 416,
"nodeType": "ParameterList",
"parameters": [],
"src": "17517:0:0"
},
"scope": 492,
"src": "17449:69:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 418,
"nodeType": "StructuredDocumentation",
"src": "17524:285:0",
"text": "@dev Sets the minimum Loan equity. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param _minLoanEquity The new minimum percentage of Loan equity an account must have to trigger liquidations."
},
"functionSelector": "298b795d",
"id": 423,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setMinLoanEquity",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 421,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 420,
"mutability": "mutable",
"name": "_minLoanEquity",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 423,
"src": "17840:22:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 419,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "17840:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "17839:24:0"
},
"returnParameters": {
"id": 422,
"nodeType": "ParameterList",
"parameters": [],
"src": "17872:0:0"
},
"scope": 492,
"src": "17814:59:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 424,
"nodeType": "StructuredDocumentation",
"src": "17879:251:0",
"text": "@dev Sets the funding period. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param _fundingPeriod The number of seconds to set the drawdown grace period to."
},
"functionSelector": "2a5aa292",
"id": 429,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setFundingPeriod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 427,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 426,
"mutability": "mutable",
"name": "_fundingPeriod",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 429,
"src": "18161:22:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 425,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "18161:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "18160:24:0"
},
"returnParameters": {
"id": 428,
"nodeType": "ParameterList",
"parameters": [],
"src": "18193:0:0"
},
"scope": 492,
"src": "18135:59:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 430,
"nodeType": "StructuredDocumentation",
"src": "18200:252:0",
"text": "@dev Sets the the minimum Pool cover required to finalize a Pool. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsParamSet` event. \n@param amt The new minimum swap out required."
},
"functionSelector": "dbc6c552",
"id": 435,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setSwapOutRequired",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 433,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 432,
"mutability": "mutable",
"name": "amt",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 435,
"src": "18485:11:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 431,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "18485:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "18484:13:0"
},
"returnParameters": {
"id": 434,
"nodeType": "ParameterList",
"parameters": [],
"src": "18506:0:0"
},
"scope": 492,
"src": "18457:50:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 436,
"nodeType": "StructuredDocumentation",
"src": "18513:282:0",
"text": "@dev Sets a price feed's oracle. \n@dev Only the Governor can call this function. \n@dev It emits a `OracleSet` event. \n@param asset The asset to update price for.\n@param oracle The new Oracle to use for the price of `asset`."
},
"functionSelector": "67a74ddc",
"id": 443,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setPriceOracle",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 441,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 438,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 443,
"src": "18824:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 437,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "18824:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 440,
"mutability": "mutable",
"name": "oracle",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 443,
"src": "18839:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 439,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "18839:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "18823:31:0"
},
"returnParameters": {
"id": 442,
"nodeType": "ParameterList",
"parameters": [],
"src": "18863:0:0"
},
"scope": 492,
"src": "18800:64:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 444,
"nodeType": "StructuredDocumentation",
"src": "18870:305:0",
"text": "@dev Sets a new Pending Governor. \n@dev This address can become Governor if they accept. \n@dev Only the Governor can call this function. \n@dev It emits a `PendingGovernorSet` event. \n@param _pendingGovernor The address of a new Pending Governor."
},
"functionSelector": "f235757f",
"id": 449,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setPendingGovernor",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 447,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 446,
"mutability": "mutable",
"name": "_pendingGovernor",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 449,
"src": "19208:24:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 445,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "19208:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "19207:26:0"
},
"returnParameters": {
"id": 448,
"nodeType": "ParameterList",
"parameters": [],
"src": "19242:0:0"
},
"scope": 492,
"src": "19180:63:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 450,
"nodeType": "StructuredDocumentation",
"src": "19249:170:0",
"text": "@dev Accept the Governor position. \n@dev Only the Pending Governor can call this function. \n@dev It emits a `GovernorAccepted` event. "
},
"functionSelector": "e58bb639",
"id": 453,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "acceptGovernor",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 451,
"nodeType": "ParameterList",
"parameters": [],
"src": "19447:2:0"
},
"returnParameters": {
"id": 452,
"nodeType": "ParameterList",
"parameters": [],
"src": "19458:0:0"
},
"scope": 492,
"src": "19424:35:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 454,
"nodeType": "StructuredDocumentation",
"src": "19465:171:0",
"text": "@dev Fetch price for asset from Chainlink oracles.\n@param asset The asset to fetch the price of.\n@return The price of asset in USD."
},
"functionSelector": "16345f18",
"id": 461,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "getLatestPrice",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 457,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 456,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 461,
"src": "19665:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 455,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "19665:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "19664:15:0"
},
"returnParameters": {
"id": 460,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 459,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 461,
"src": "19703:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 458,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "19703:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "19702:9:0"
},
"scope": 492,
"src": "19641:71:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 462,
"nodeType": "StructuredDocumentation",
"src": "19718:641:0",
"text": "@dev Checks that a `subFactory` is valid as it relates to `superFactory`.\n@param superFactory The core factory (e.g. PoolFactory, LoanFactory).\n@param subFactory The sub factory used by core factory (e.g. LiquidityLockerFactory).\n@param factoryType The type expected for the subFactory. \n0 = COLLATERAL_LOCKER_FACTORY, \n1 = DEBT_LOCKER_FACTORY, \n2 = FUNDING_LOCKER_FACTORY, \n3 = LIQUIDITY_LOCKER_FACTORY, \n4 = STAKE_LOCKER_FACTORY. "
},
"functionSelector": "13d459fb",
"id": 473,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "isValidSubFactory",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 469,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 464,
"mutability": "mutable",
"name": "superFactory",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 473,
"src": "20391:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 463,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "20391:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 466,
"mutability": "mutable",
"name": "subFactory",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 473,
"src": "20413:18:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 465,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "20413:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 468,
"mutability": "mutable",
"name": "factoryType",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 473,
"src": "20433:17:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint8",
"typeString": "uint8"
},
"typeName": {
"id": 467,
"name": "uint8",
"nodeType": "ElementaryTypeName",
"src": "20433:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint8",
"typeString": "uint8"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "20390:61:0"
},
"returnParameters": {
"id": 472,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 471,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 473,
"src": "20475:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 470,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "20475:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "20474:6:0"
},
"scope": 492,
"src": "20364:117:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 474,
"nodeType": "StructuredDocumentation",
"src": "20487:154:0",
"text": "@dev Checks that a Calculator is valid.\n@param calc The Calculator address.\n@param calcType The Calculator type."
},
"functionSelector": "1b5833f7",
"id": 483,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "isValidCalc",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 479,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 476,
"mutability": "mutable",
"name": "calc",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 483,
"src": "20667:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 475,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "20667:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 478,
"mutability": "mutable",
"name": "calcType",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 483,
"src": "20681:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint8",
"typeString": "uint8"
},
"typeName": {
"id": 477,
"name": "uint8",
"nodeType": "ElementaryTypeName",
"src": "20681:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint8",
"typeString": "uint8"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "20666:30:0"
},
"returnParameters": {
"id": 482,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 481,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 483,
"src": "20720:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 480,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "20720:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "20719:6:0"
},
"scope": 492,
"src": "20646:80:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 484,
"nodeType": "StructuredDocumentation",
"src": "20732:208:0",
"text": "@dev Returns the `lpCooldownPeriod` and `lpWithdrawWindow` as a tuple, for convenience.\n@return The value of `lpCooldownPeriod`.\n@return The value of `lpWithdrawWindow`."
},
"functionSelector": "9f51290b",
"id": 491,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "getLpCooldownParams",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 485,
"nodeType": "ParameterList",
"parameters": [],
"src": "20973:2:0"
},
"returnParameters": {
"id": 490,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 487,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 491,
"src": "20999:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 486,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "20999:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 489,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 491,
"src": "21008:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 488,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "21008:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "20998:18:0"
},
"scope": 492,
"src": "20945:72:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
}
],
"scope": 1727,
"src": "374:20646:0"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "interface",
"documentation": {
"id": 493,
"nodeType": "StructuredDocumentation",
"src": "21117:118:0",
"text": "@title MapleTreasury earns revenue from Loans and distributes it to token holders and the Maple development team."
},
"fullyImplemented": false,
"id": 568,
"linearizedBaseContracts": [
568
],
"name": "IMapleTreasury",
"nodeType": "ContractDefinition",
"nodes": [
{
"anonymous": false,
"documentation": {
"id": 494,
"nodeType": "StructuredDocumentation",
"src": "21267:346:0",
"text": "@dev Emits an event indicating that an amount of some asset was converted to `fundsToken`.\n@param asset The ERC-20 asset to convert to `fundsToken`.\n@param amountIn The amount of the asset being converted to `fundsToken`.\n@param amountOut The amount of `fundsToken` received from the conversion."
},
"id": 502,
"name": "ERC20Conversion",
"nodeType": "EventDefinition",
"parameters": {
"id": 501,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 496,
"indexed": true,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 502,
"src": "21640:21:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 495,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "21640:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 498,
"indexed": false,
"mutability": "mutable",
"name": "amountIn",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 502,
"src": "21663:16:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 497,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "21663:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 500,
"indexed": false,
"mutability": "mutable",
"name": "amountOut",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 502,
"src": "21681:17:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 499,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "21681:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "21639:60:0"
},
"src": "21618:82:0"
},
{
"anonymous": false,
"documentation": {
"id": 503,
"nodeType": "StructuredDocumentation",
"src": "21706:162:0",
"text": "@dev Emits an event indicating that a distribution was made to token holders.\n@param amount The amount distributed to token holders."
},
"id": 507,
"name": "DistributedToHolders",
"nodeType": "EventDefinition",
"parameters": {
"id": 506,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 505,
"indexed": false,
"mutability": "mutable",
"name": "amount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 507,
"src": "21900:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 504,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "21900:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "21899:16:0"
},
"src": "21873:43:0"
},
{
"anonymous": false,
"documentation": {
"id": 508,
"nodeType": "StructuredDocumentation",
"src": "21926:192:0",
"text": "@dev Emits an event indicating the Governor reclaimed some token.\n@param asset The address of the token to reclaimed.\n@param amount The amount reclaimed."
},
"id": 514,
"name": "ERC20Reclaimed",
"nodeType": "EventDefinition",
"parameters": {
"id": 513,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 510,
"indexed": true,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 514,
"src": "22144:21:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 509,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "22144:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 512,
"indexed": false,
"mutability": "mutable",
"name": "amount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 514,
"src": "22167:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 511,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "22167:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "22143:39:0"
},
"src": "22123:60:0"
},
{
"anonymous": false,
"documentation": {
"id": 515,
"nodeType": "StructuredDocumentation",
"src": "22193:152:0",
"text": "@dev Emits an event indicating the MapleGlobals instance has changed.\n@param newGlobals The address of a new MapleGlobals."
},
"id": 519,
"name": "GlobalsSet",
"nodeType": "EventDefinition",
"parameters": {
"id": 518,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 517,
"indexed": false,
"mutability": "mutable",
"name": "newGlobals",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 519,
"src": "22367:18:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 516,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "22367:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "22366:20:0"
},
"src": "22350:37:0"
},
{
"body": null,
"documentation": {
"id": 520,
"nodeType": "StructuredDocumentation",
"src": "22393:84:0",
"text": "@dev The address of ERC-2222 Maple Token for the Maple protocol."
},
"functionSelector": "a0530946",
"id": 525,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "mpl",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 521,
"nodeType": "ParameterList",
"parameters": [],
"src": "22494:2:0"
},
"returnParameters": {
"id": 524,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 523,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 525,
"src": "22520:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 522,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "22520:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "22519:9:0"
},
"scope": 568,
"src": "22482:47:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 526,
"nodeType": "StructuredDocumentation",
"src": "22535:85:0",
"text": "@dev The address of the `fundsToken` of the ERC-2222 Maple Token."
},
"functionSelector": "63f04b15",
"id": 531,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "fundsToken",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 527,
"nodeType": "ParameterList",
"parameters": [],
"src": "22644:2:0"
},
"returnParameters": {
"id": 530,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 529,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 531,
"src": "22670:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 528,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "22670:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "22669:9:0"
},
"scope": 568,
"src": "22625:54:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 532,
"nodeType": "StructuredDocumentation",
"src": "22685:70:0",
"text": "@dev The address of the official UniswapV2 router."
},
"functionSelector": "735de9f7",
"id": 537,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "uniswapRouter",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 533,
"nodeType": "ParameterList",
"parameters": [],
"src": "22782:2:0"
},
"returnParameters": {
"id": 536,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 535,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 537,
"src": "22808:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 534,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "22808:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "22807:9:0"
},
"scope": 568,
"src": "22760:57:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 538,
"nodeType": "StructuredDocumentation",
"src": "22823:68:0",
"text": "@dev The address of an instance of MapleGlobals."
},
"functionSelector": "c3124525",
"id": 543,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "globals",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 539,
"nodeType": "ParameterList",
"parameters": [],
"src": "22912:2:0"
},
"returnParameters": {
"id": 542,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 541,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 543,
"src": "22938:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 540,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "22938:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "22937:9:0"
},
"scope": 568,
"src": "22896:51:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 544,
"nodeType": "StructuredDocumentation",
"src": "22953:237:0",
"text": "@dev Updates the MapleGlobals instance. \n@dev Only the Governor can call this function. \n@dev It emits a `GlobalsSet` event. \n@param newGlobals The address of a new MapleGlobals instance."
},
"functionSelector": "cc2e0a26",
"id": 549,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "setGlobals",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 547,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 546,
"mutability": "mutable",
"name": "newGlobals",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 549,
"src": "23215:18:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 545,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "23215:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "23214:20:0"
},
"returnParameters": {
"id": 548,
"nodeType": "ParameterList",
"parameters": [],
"src": "23243:0:0"
},
"scope": 568,
"src": "23195:49:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 550,
"nodeType": "StructuredDocumentation",
"src": "23250:285:0",
"text": "@dev Reclaims Treasury funds to the Governor. \n@dev Only the Governor can call this function. \n@dev It emits a `ERC20Reclaimed` event. \n@param asset The address of the token to be reclaimed.\n@param amount The amount reclaimed."
},
"functionSelector": "afdbd499",
"id": 557,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "reclaimERC20",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 555,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 552,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 557,
"src": "23562:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 551,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "23562:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 554,
"mutability": "mutable",
"name": "amount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 557,
"src": "23577:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 553,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "23577:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "23561:31:0"
},
"returnParameters": {
"id": 556,
"nodeType": "ParameterList",
"parameters": [],
"src": "23601:0:0"
},
"scope": 568,
"src": "23540:62:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 558,
"nodeType": "StructuredDocumentation",
"src": "23608:256:0",
"text": "@dev Passes through the current `fundsToken` balance of the Treasury to Maple Token, where it can be claimed by MPL holders. \n@dev Only the Governor can call this function. \n@dev It emits a `DistributedToHolders` event. "
},
"functionSelector": "3153689f",
"id": 561,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "distributeToHolders",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 559,
"nodeType": "ParameterList",
"parameters": [],
"src": "23897:2:0"
},
"returnParameters": {
"id": 560,
"nodeType": "ParameterList",
"parameters": [],
"src": "23908:0:0"
},
"scope": 568,
"src": "23869:40:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 562,
"nodeType": "StructuredDocumentation",
"src": "23915:259:0",
"text": "@dev Converts an ERC-20 asset, via Uniswap, to `fundsToken`. \n@dev Only the Governor can call this function. \n@dev It emits a `ERC20Conversion` event. \n@param asset The ERC-20 asset to convert to `fundsToken`."
},
"functionSelector": "817bd4fd",
"id": 567,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "convertERC20",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 565,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 564,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 567,
"src": "24201:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 563,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "24201:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "24200:15:0"
},
"returnParameters": {
"id": 566,
"nodeType": "ParameterList",
"parameters": [],
"src": "24224:0:0"
},
"scope": 568,
"src": "24179:46:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
}
],
"scope": 1727,
"src": "21235:2993:0"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "interface",
"documentation": null,
"fullyImplemented": false,
"id": 572,
"linearizedBaseContracts": [
572
],
"name": "IMapleToken",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": null,
"documentation": null,
"functionSelector": "46c162de",
"id": 571,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "updateFundsReceived",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 569,
"nodeType": "ParameterList",
"parameters": [],
"src": "24371:2:0"
},
"returnParameters": {
"id": 570,
"nodeType": "ParameterList",
"parameters": [],
"src": "24382:0:0"
},
"scope": 572,
"src": "24343:40:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
}
],
"scope": 1727,
"src": "24314:72:0"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "interface",
"documentation": null,
"fullyImplemented": false,
"id": 621,
"linearizedBaseContracts": [
621
],
"name": "IUniswapRouter",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": null,
"documentation": null,
"functionSelector": "38ed1739",
"id": 589,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "swapExactTokensForTokens",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 584,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 574,
"mutability": "mutable",
"name": "amountIn",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 589,
"src": "24550:16:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 573,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24550:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 576,
"mutability": "mutable",
"name": "amountOutMin",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 589,
"src": "24576:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 575,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24576:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 579,
"mutability": "mutable",
"name": "path",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 589,
"src": "24606:23:0",
"stateVariable": false,
"storageLocation": "calldata",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_calldata_ptr",
"typeString": "address[]"
},
"typeName": {
"baseType": {
"id": 577,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "24606:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 578,
"length": null,
"nodeType": "ArrayTypeName",
"src": "24606:9:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
"typeString": "address[]"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 581,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 589,
"src": "24639:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 580,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "24639:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 583,
"mutability": "mutable",
"name": "deadline",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 589,
"src": "24659:16:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 582,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24659:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "24540:141:0"
},
"returnParameters": {
"id": 588,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 587,
"mutability": "mutable",
"name": "amounts",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 589,
"src": "24700:24:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
"typeString": "uint256[]"
},
"typeName": {
"baseType": {
"id": 585,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24700:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 586,
"length": null,
"nodeType": "ArrayTypeName",
"src": "24700:9:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
"typeString": "uint256[]"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "24699:26:0"
},
"scope": 621,
"src": "24507:219:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": null,
"functionSelector": "fb3bdb41",
"id": 604,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "swapETHForExactTokens",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 599,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 591,
"mutability": "mutable",
"name": "amountOut",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 604,
"src": "24772:17:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 590,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24772:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 594,
"mutability": "mutable",
"name": "path",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 604,
"src": "24799:23:0",
"stateVariable": false,
"storageLocation": "calldata",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_calldata_ptr",
"typeString": "address[]"
},
"typeName": {
"baseType": {
"id": 592,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "24799:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 593,
"length": null,
"nodeType": "ArrayTypeName",
"src": "24799:9:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
"typeString": "address[]"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 596,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 604,
"src": "24832:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 595,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "24832:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 598,
"mutability": "mutable",
"name": "deadline",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 604,
"src": "24852:16:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 597,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24852:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "24762:112:0"
},
"returnParameters": {
"id": 603,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 602,
"mutability": "mutable",
"name": "amounts",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 604,
"src": "24901:24:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
"typeString": "uint256[]"
},
"typeName": {
"baseType": {
"id": 600,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24901:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 601,
"length": null,
"nodeType": "ArrayTypeName",
"src": "24901:9:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
"typeString": "uint256[]"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "24900:26:0"
},
"scope": 621,
"src": "24732:195:0",
"stateMutability": "payable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": null,
"functionSelector": "ad615dec",
"id": 615,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "quote",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 611,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 606,
"mutability": "mutable",
"name": "amountA",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 615,
"src": "24957:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 605,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24957:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 608,
"mutability": "mutable",
"name": "reserveA",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 615,
"src": "24982:16:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 607,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "24982:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 610,
"mutability": "mutable",
"name": "reserveB",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 615,
"src": "25008:16:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 609,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "25008:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "24947:83:0"
},
"returnParameters": {
"id": 614,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 613,
"mutability": "mutable",
"name": "amountB",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 615,
"src": "25054:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 612,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "25054:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "25053:17:0"
},
"scope": 621,
"src": "24933:138:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": null,
"functionSelector": "ad5c4648",
"id": 620,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "WETH",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 616,
"nodeType": "ParameterList",
"parameters": [],
"src": "25090:2:0"
},
"returnParameters": {
"id": 619,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 618,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 620,
"src": "25116:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 617,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "25116:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "25115:9:0"
},
"scope": 621,
"src": "25077:48:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "external"
}
],
"scope": 1727,
"src": "24475:653:0"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "interface",
"documentation": {
"id": 622,
"nodeType": "StructuredDocumentation",
"src": "25236:70:0",
"text": " @dev Interface of the ERC20 standard as defined in the EIP."
},
"fullyImplemented": false,
"id": 697,
"linearizedBaseContracts": [
697
],
"name": "IERC20",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": null,
"documentation": {
"id": 623,
"nodeType": "StructuredDocumentation",
"src": "25330:66:0",
"text": " @dev Returns the amount of tokens in existence."
},
"functionSelector": "18160ddd",
"id": 628,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "totalSupply",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 624,
"nodeType": "ParameterList",
"parameters": [],
"src": "25421:2:0"
},
"returnParameters": {
"id": 627,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 626,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 628,
"src": "25447:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 625,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "25447:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "25446:9:0"
},
"scope": 697,
"src": "25401:55:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 629,
"nodeType": "StructuredDocumentation",
"src": "25462:72:0",
"text": " @dev Returns the amount of tokens owned by `account`."
},
"functionSelector": "70a08231",
"id": 636,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "balanceOf",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 632,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 631,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 636,
"src": "25558:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 630,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "25558:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "25557:17:0"
},
"returnParameters": {
"id": 635,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 634,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 636,
"src": "25598:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 633,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "25598:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "25597:9:0"
},
"scope": 697,
"src": "25539:68:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 637,
"nodeType": "StructuredDocumentation",
"src": "25613:209:0",
"text": " @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."
},
"functionSelector": "a9059cbb",
"id": 646,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "transfer",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 642,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 639,
"mutability": "mutable",
"name": "recipient",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 646,
"src": "25845:17:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 638,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "25845:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 641,
"mutability": "mutable",
"name": "amount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 646,
"src": "25864:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 640,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "25864:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "25844:35:0"
},
"returnParameters": {
"id": 645,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 644,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 646,
"src": "25898:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 643,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "25898:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "25897:6:0"
},
"scope": 697,
"src": "25827:77:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 647,
"nodeType": "StructuredDocumentation",
"src": "25910:264:0",
"text": " @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 This value changes when {approve} or {transferFrom} are called."
},
"functionSelector": "dd62ed3e",
"id": 656,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "allowance",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 652,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 649,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 656,
"src": "26198:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 648,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "26198:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 651,
"mutability": "mutable",
"name": "spender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 656,
"src": "26213:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 650,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "26213:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "26197:32:0"
},
"returnParameters": {
"id": 655,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 654,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 656,
"src": "26253:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 653,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "26253:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "26252:9:0"
},
"scope": 697,
"src": "26179:83:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 657,
"nodeType": "StructuredDocumentation",
"src": "26268:642:0",
"text": " @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\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 Emits an {Approval} event."
},
"functionSelector": "095ea7b3",
"id": 666,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "approve",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 662,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 659,
"mutability": "mutable",
"name": "spender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 666,
"src": "26932:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 658,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "26932:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 661,
"mutability": "mutable",
"name": "amount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 666,
"src": "26949:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 660,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "26949:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "26931:33:0"
},
"returnParameters": {
"id": 665,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 664,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 666,
"src": "26983:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 663,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "26983:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "26982:6:0"
},
"scope": 697,
"src": "26915:74:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": {
"id": 667,
"nodeType": "StructuredDocumentation",
"src": "26995:296:0",
"text": " @dev Moves `amount` tokens from `sender` to `recipient` using the\n allowance mechanism. `amount` is then deducted from the caller's\n allowance.\n Returns a boolean value indicating whether the operation succeeded.\n Emits a {Transfer} event."
},
"functionSelector": "23b872dd",
"id": 678,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "transferFrom",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 674,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 669,
"mutability": "mutable",
"name": "sender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 678,
"src": "27318:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 668,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "27318:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 671,
"mutability": "mutable",
"name": "recipient",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 678,
"src": "27334:17:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 670,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "27334:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 673,
"mutability": "mutable",
"name": "amount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 678,
"src": "27353:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 672,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "27353:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "27317:51:0"
},
"returnParameters": {
"id": 677,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 676,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 678,
"src": "27387:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 675,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "27387:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "27386:6:0"
},
"scope": 697,
"src": "27296:97:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"anonymous": false,
"documentation": {
"id": 679,
"nodeType": "StructuredDocumentation",
"src": "27399:158:0",
"text": " @dev Emitted when `value` tokens are moved from one account (`from`) to\n another (`to`).\n Note that `value` may be zero."
},
"id": 687,
"name": "Transfer",
"nodeType": "EventDefinition",
"parameters": {
"id": 686,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 681,
"indexed": true,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 687,
"src": "27577:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 680,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "27577:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 683,
"indexed": true,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 687,
"src": "27599:18:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 682,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "27599:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 685,
"indexed": false,
"mutability": "mutable",
"name": "value",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 687,
"src": "27619:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 684,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "27619:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "27576:57:0"
},
"src": "27562:72:0"
},
{
"anonymous": false,
"documentation": {
"id": 688,
"nodeType": "StructuredDocumentation",
"src": "27640:148:0",
"text": " @dev Emitted when the allowance of a `spender` for an `owner` is set by\n a call to {approve}. `value` is the new allowance."
},
"id": 696,
"name": "Approval",
"nodeType": "EventDefinition",
"parameters": {
"id": 695,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 690,
"indexed": true,
"mutability": "mutable",
"name": "owner",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 696,
"src": "27808:21:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 689,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "27808:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 692,
"indexed": true,
"mutability": "mutable",
"name": "spender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 696,
"src": "27831:23:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 691,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "27831:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 694,
"indexed": false,
"mutability": "mutable",
"name": "value",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 696,
"src": "27856:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 693,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "27856:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "27807:63:0"
},
"src": "27793:78:0"
}
],
"scope": 1727,
"src": "25307:2566:0"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 698,
"name": "IERC20",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 697,
"src": "28087:6:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 699,
"nodeType": "InheritanceSpecifier",
"src": "28087:6:0"
}
],
"contractDependencies": [
697
],
"contractKind": "interface",
"documentation": null,
"fullyImplemented": false,
"id": 715,
"linearizedBaseContracts": [
715,
697
],
"name": "IERC20Details",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": null,
"documentation": null,
"functionSelector": "06fdde03",
"id": 704,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "name",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 700,
"nodeType": "ParameterList",
"parameters": [],
"src": "28114:2:0"
},
"returnParameters": {
"id": 703,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 702,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 704,
"src": "28140:13:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 701,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "28140:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "28139:15:0"
},
"scope": 715,
"src": "28101:54:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": null,
"functionSelector": "95d89b41",
"id": 709,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "symbol",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 705,
"nodeType": "ParameterList",
"parameters": [],
"src": "28176:2:0"
},
"returnParameters": {
"id": 708,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 707,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 709,
"src": "28202:13:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 706,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "28202:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "28201:15:0"
},
"scope": 715,
"src": "28161:56:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
},
{
"body": null,
"documentation": null,
"functionSelector": "313ce567",
"id": 714,
"implemented": false,
"kind": "function",
"modifiers": [],
"name": "decimals",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 710,
"nodeType": "ParameterList",
"parameters": [],
"src": "28240:2:0"
},
"returnParameters": {
"id": 713,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 712,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 714,
"src": "28266:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 711,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "28266:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "28265:9:0"
},
"scope": 715,
"src": "28223:52:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
}
],
"scope": 1727,
"src": "28060:218:0"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "library",
"documentation": {
"id": 716,
"nodeType": "StructuredDocumentation",
"src": "28381:563:0",
"text": " @dev Wrappers over Solidity's arithmetic operations with added overflow\n checks.\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 Using this library instead of the unchecked operations eliminates an entire\n class of bugs, so it's recommended to use it always."
},
"fullyImplemented": true,
"id": 909,
"linearizedBaseContracts": [
909
],
"name": "SafeMath",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 741,
"nodeType": "Block",
"src": "29264:109:0",
"statements": [
{
"assignments": [
727
],
"declarations": [
{
"constant": false,
"id": 727,
"mutability": "mutable",
"name": "c",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 741,
"src": "29274:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 726,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "29274:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 731,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 730,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 728,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 719,
"src": "29286:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "+",
"rightExpression": {
"argumentTypes": null,
"id": 729,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 721,
"src": "29290:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "29286:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "29274:17:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 735,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 733,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 727,
"src": "29309:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">=",
"rightExpression": {
"argumentTypes": null,
"id": 734,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 719,
"src": "29314:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "29309:6:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "536166654d6174683a206164646974696f6e206f766572666c6f77",
"id": 736,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "29317:29:0",
"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": 732,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "29301:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 737,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "29301:46:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 738,
"nodeType": "ExpressionStatement",
"src": "29301:46:0"
},
{
"expression": {
"argumentTypes": null,
"id": 739,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 727,
"src": "29365:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 725,
"id": 740,
"nodeType": "Return",
"src": "29358:8:0"
}
]
},
"documentation": {
"id": 717,
"nodeType": "StructuredDocumentation",
"src": "28968:224:0",
"text": " @dev Returns the addition of two unsigned integers, reverting on\n overflow.\n Counterpart to Solidity's `+` operator.\n Requirements:\n - Addition cannot overflow."
},
"id": 742,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "add",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 722,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 719,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 742,
"src": "29210:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 718,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "29210:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 721,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 742,
"src": "29221:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 720,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "29221:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "29209:22:0"
},
"returnParameters": {
"id": 725,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 724,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 742,
"src": "29255:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 723,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "29255:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "29254:9:0"
},
"scope": 909,
"src": "29197:176:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 758,
"nodeType": "Block",
"src": "29711:67:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 753,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 745,
"src": "29732:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"id": 754,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 747,
"src": "29735:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"hexValue": "536166654d6174683a207375627472616374696f6e206f766572666c6f77",
"id": 755,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "29738:32:0",
"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": 752,
"name": "sub",
"nodeType": "Identifier",
"overloadedDeclarations": [
759,
787
],
"referencedDeclaration": 787,
"src": "29728:3:0",
"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": 756,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "29728:43:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 751,
"id": 757,
"nodeType": "Return",
"src": "29721:50:0"
}
]
},
"documentation": {
"id": 743,
"nodeType": "StructuredDocumentation",
"src": "29379:260:0",
"text": " @dev Returns the subtraction of two unsigned integers, reverting on\n overflow (when the result is negative).\n Counterpart to Solidity's `-` operator.\n Requirements:\n - Subtraction cannot overflow."
},
"id": 759,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "sub",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 748,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 745,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 759,
"src": "29657:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 744,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "29657:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 747,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 759,
"src": "29668:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 746,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "29668:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "29656:22:0"
},
"returnParameters": {
"id": 751,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 750,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 759,
"src": "29702:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 749,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "29702:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "29701:9:0"
},
"scope": 909,
"src": "29644:134:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 786,
"nodeType": "Block",
"src": "30164:92:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 774,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 772,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 764,
"src": "30182:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "<=",
"rightExpression": {
"argumentTypes": null,
"id": 773,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 762,
"src": "30187:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "30182:6:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"id": 775,
"name": "errorMessage",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 766,
"src": "30190:12:0",
"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": 771,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "30174:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 776,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "30174:29:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 777,
"nodeType": "ExpressionStatement",
"src": "30174:29:0"
},
{
"assignments": [
779
],
"declarations": [
{
"constant": false,
"id": 779,
"mutability": "mutable",
"name": "c",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 786,
"src": "30213:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 778,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "30213:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 783,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 782,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 780,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 762,
"src": "30225:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "-",
"rightExpression": {
"argumentTypes": null,
"id": 781,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 764,
"src": "30229:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "30225:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "30213:17:0"
},
{
"expression": {
"argumentTypes": null,
"id": 784,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 779,
"src": "30248:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 770,
"id": 785,
"nodeType": "Return",
"src": "30241:8:0"
}
]
},
"documentation": {
"id": 760,
"nodeType": "StructuredDocumentation",
"src": "29784:280:0",
"text": " @dev Returns the subtraction of two unsigned integers, reverting with custom message on\n overflow (when the result is negative).\n Counterpart to Solidity's `-` operator.\n Requirements:\n - Subtraction cannot overflow."
},
"id": 787,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "sub",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 767,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 762,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 787,
"src": "30082:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 761,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "30082:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 764,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 787,
"src": "30093:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 763,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "30093:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 766,
"mutability": "mutable",
"name": "errorMessage",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 787,
"src": "30104:26:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 765,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "30104:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "30081:50:0"
},
"returnParameters": {
"id": 770,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 769,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 787,
"src": "30155:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 768,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "30155:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "30154:9:0"
},
"scope": 909,
"src": "30069:187:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 821,
"nodeType": "Block",
"src": "30570:392:0",
"statements": [
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 799,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 797,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 790,
"src": "30802:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 798,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "30807:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "30802:6:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 803,
"nodeType": "IfStatement",
"src": "30798:45:0",
"trueBody": {
"id": 802,
"nodeType": "Block",
"src": "30810:33:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"hexValue": "30",
"id": 800,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "30831:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"functionReturnParameters": 796,
"id": 801,
"nodeType": "Return",
"src": "30824:8:0"
}
]
}
},
{
"assignments": [
805
],
"declarations": [
{
"constant": false,
"id": 805,
"mutability": "mutable",
"name": "c",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 821,
"src": "30853:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 804,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "30853:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 809,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 808,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 806,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 790,
"src": "30865:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "*",
"rightExpression": {
"argumentTypes": null,
"id": 807,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 792,
"src": "30869:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "30865:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "30853:17:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 815,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 813,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 811,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 805,
"src": "30888:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "/",
"rightExpression": {
"argumentTypes": null,
"id": 812,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 790,
"src": "30892:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "30888:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"id": 814,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 792,
"src": "30897:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "30888:10:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "536166654d6174683a206d756c7469706c69636174696f6e206f766572666c6f77",
"id": 816,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "30900:35:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_9113bb53c2876a3805b2c9242029423fc540a728243ce887ab24c82cf119fba3",
"typeString": "literal_string \"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": 810,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "30880:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 817,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "30880:56:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 818,
"nodeType": "ExpressionStatement",
"src": "30880:56:0"
},
{
"expression": {
"argumentTypes": null,
"id": 819,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 805,
"src": "30954:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 796,
"id": 820,
"nodeType": "Return",
"src": "30947:8:0"
}
]
},
"documentation": {
"id": 788,
"nodeType": "StructuredDocumentation",
"src": "30262:236:0",
"text": " @dev Returns the multiplication of two unsigned integers, reverting on\n overflow.\n Counterpart to Solidity's `*` operator.\n Requirements:\n - Multiplication cannot overflow."
},
"id": 822,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "mul",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 793,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 790,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 822,
"src": "30516:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 789,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "30516:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 792,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 822,
"src": "30527:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 791,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "30527:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "30515:22:0"
},
"returnParameters": {
"id": 796,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 795,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 822,
"src": "30561:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 794,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "30561:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "30560:9:0"
},
"scope": 909,
"src": "30503:459:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 838,
"nodeType": "Block",
"src": "31491:63:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 833,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 825,
"src": "31512:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"id": 834,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 827,
"src": "31515:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"hexValue": "536166654d6174683a206469766973696f6e206279207a65726f",
"id": 835,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "31518:28:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_5b7cc70dda4dc2143e5adb63bd5d1f349504f461dbdfd9bc76fac1f8ca6d019f",
"typeString": "literal_string \"SafeMath: division by zero\""
},
"value": "SafeMath: division by zero"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
{
"typeIdentifier": "t_stringliteral_5b7cc70dda4dc2143e5adb63bd5d1f349504f461dbdfd9bc76fac1f8ca6d019f",
"typeString": "literal_string \"SafeMath: division by zero\""
}
],
"id": 832,
"name": "div",
"nodeType": "Identifier",
"overloadedDeclarations": [
839,
867
],
"referencedDeclaration": 867,
"src": "31508:3:0",
"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": 836,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "31508:39:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 831,
"id": 837,
"nodeType": "Return",
"src": "31501:46:0"
}
]
},
"documentation": {
"id": 823,
"nodeType": "StructuredDocumentation",
"src": "30968:451:0",
"text": " @dev Returns the integer division of two unsigned integers. Reverts on\n division 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\n uses an invalid opcode to revert (consuming all remaining gas).\n Requirements:\n - The divisor cannot be zero."
},
"id": 839,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "div",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 828,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 825,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 839,
"src": "31437:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 824,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "31437:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 827,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 839,
"src": "31448:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 826,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "31448:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "31436:22:0"
},
"returnParameters": {
"id": 831,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 830,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 839,
"src": "31482:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 829,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "31482:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "31481:9:0"
},
"scope": 909,
"src": "31424:130:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 866,
"nodeType": "Block",
"src": "32131:177:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 854,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 852,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 844,
"src": "32149:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 853,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "32153:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "32149:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"id": 855,
"name": "errorMessage",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 846,
"src": "32156:12:0",
"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": 851,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "32141:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 856,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32141:28:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 857,
"nodeType": "ExpressionStatement",
"src": "32141:28:0"
},
{
"assignments": [
859
],
"declarations": [
{
"constant": false,
"id": 859,
"mutability": "mutable",
"name": "c",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 866,
"src": "32179:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 858,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "32179:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 863,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 862,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 860,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 842,
"src": "32191:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "/",
"rightExpression": {
"argumentTypes": null,
"id": 861,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 844,
"src": "32195:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "32191:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "32179:17:0"
},
{
"expression": {
"argumentTypes": null,
"id": 864,
"name": "c",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 859,
"src": "32300:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 850,
"id": 865,
"nodeType": "Return",
"src": "32293:8:0"
}
]
},
"documentation": {
"id": 840,
"nodeType": "StructuredDocumentation",
"src": "31560:471:0",
"text": " @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 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 Requirements:\n - The divisor cannot be zero."
},
"id": 867,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "div",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 847,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 842,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 867,
"src": "32049:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 841,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "32049:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 844,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 867,
"src": "32060:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 843,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "32060:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 846,
"mutability": "mutable",
"name": "errorMessage",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 867,
"src": "32071:26:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 845,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "32071:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "32048:50:0"
},
"returnParameters": {
"id": 850,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 849,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 867,
"src": "32122:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 848,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "32122:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "32121:9:0"
},
"scope": 909,
"src": "32036:272:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 883,
"nodeType": "Block",
"src": "32826:61:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 878,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 870,
"src": "32847:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"id": 879,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 872,
"src": "32850:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"hexValue": "536166654d6174683a206d6f64756c6f206279207a65726f",
"id": 880,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "32853:26:0",
"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": 877,
"name": "mod",
"nodeType": "Identifier",
"overloadedDeclarations": [
884,
908
],
"referencedDeclaration": 908,
"src": "32843:3:0",
"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": 881,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "32843:37:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 876,
"id": 882,
"nodeType": "Return",
"src": "32836:44:0"
}
]
},
"documentation": {
"id": 868,
"nodeType": "StructuredDocumentation",
"src": "32314:440:0",
"text": " @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\n Reverts when dividing by zero.\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 Requirements:\n - The divisor cannot be zero."
},
"id": 884,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "mod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 873,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 870,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 884,
"src": "32772:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 869,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "32772:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 872,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 884,
"src": "32783:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 871,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "32783:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "32771:22:0"
},
"returnParameters": {
"id": 876,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 875,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 884,
"src": "32817:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 874,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "32817:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "32816:9:0"
},
"scope": 909,
"src": "32759:128:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 907,
"nodeType": "Block",
"src": "33453:68:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 899,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 897,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 889,
"src": "33471:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 898,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "33476:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "33471:6:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"id": 900,
"name": "errorMessage",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 891,
"src": "33479:12:0",
"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": 896,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "33463:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 901,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "33463:29:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 902,
"nodeType": "ExpressionStatement",
"src": "33463:29:0"
},
{
"expression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 905,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 903,
"name": "a",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 887,
"src": "33509:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "%",
"rightExpression": {
"argumentTypes": null,
"id": 904,
"name": "b",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 889,
"src": "33513:1:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "33509:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 895,
"id": 906,
"nodeType": "Return",
"src": "33502:12:0"
}
]
},
"documentation": {
"id": 885,
"nodeType": "StructuredDocumentation",
"src": "32893:460:0",
"text": " @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),\n Reverts with custom message when dividing by zero.\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 Requirements:\n - The divisor cannot be zero."
},
"id": 908,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "mod",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 892,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 887,
"mutability": "mutable",
"name": "a",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 908,
"src": "33371:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 886,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "33371:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 889,
"mutability": "mutable",
"name": "b",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 908,
"src": "33382:9:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 888,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "33382:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 891,
"mutability": "mutable",
"name": "errorMessage",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 908,
"src": "33393:26:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 890,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "33393:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "33370:50:0"
},
"returnParameters": {
"id": 895,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 894,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 908,
"src": "33444:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 893,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "33444:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "33443:9:0"
},
"scope": 909,
"src": "33358:163:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "internal"
}
],
"scope": 1727,
"src": "28945:4578:0"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "library",
"documentation": {
"id": 910,
"nodeType": "StructuredDocumentation",
"src": "33883:62:0",
"text": "@title Util is a library that contains utility functions."
},
"fullyImplemented": true,
"id": 961,
"linearizedBaseContracts": [
961
],
"name": "Util",
"nodeType": "ContractDefinition",
"nodes": [
{
"id": 913,
"libraryName": {
"contractScope": null,
"id": 911,
"name": "SafeMath",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 909,
"src": "33971:8:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SafeMath_$909",
"typeString": "library SafeMath"
}
},
"nodeType": "UsingForDirective",
"src": "33965:27:0",
"typeName": {
"id": 912,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "33984:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
{
"body": {
"id": 959,
"nodeType": "Block",
"src": "34611:462:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 956,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"hexValue": "3130",
"id": 950,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "34976:2:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_10_by_1",
"typeString": "int_const 10"
},
"value": "10"
},
"nodeType": "BinaryOperation",
"operator": "**",
"rightExpression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 952,
"name": "fromAsset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 918,
"src": "34996:9:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 951,
"name": "IERC20Details",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 715,
"src": "34982:13:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IERC20Details_$715_$",
"typeString": "type(contract IERC20Details)"
}
},
"id": 953,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34982:24:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20Details_$715",
"typeString": "contract IERC20Details"
}
},
"id": 954,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "decimals",
"nodeType": "MemberAccess",
"referencedDeclaration": 714,
"src": "34982:33:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
"typeString": "function () view external returns (uint256)"
}
},
"id": 955,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34982:35:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "34976:41:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 946,
"name": "toAsset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 920,
"src": "34902:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 944,
"name": "globals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 916,
"src": "34879:7:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
}
},
"id": 945,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "getLatestPrice",
"nodeType": "MemberAccess",
"referencedDeclaration": 461,
"src": "34879:22:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$",
"typeString": "function (address) view external returns (uint256)"
}
},
"id": 947,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34879:31:0",
"tryCall": false,
"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": 941,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"hexValue": "3130",
"id": 935,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "34770:2:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_10_by_1",
"typeString": "int_const 10"
},
"value": "10"
},
"nodeType": "BinaryOperation",
"operator": "**",
"rightExpression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 937,
"name": "toAsset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 920,
"src": "34790:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 936,
"name": "IERC20Details",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 715,
"src": "34776:13:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IERC20Details_$715_$",
"typeString": "type(contract IERC20Details)"
}
},
"id": 938,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34776:22:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20Details_$715",
"typeString": "contract IERC20Details"
}
},
"id": 939,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "decimals",
"nodeType": "MemberAccess",
"referencedDeclaration": 714,
"src": "34776:31:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
"typeString": "function () view external returns (uint256)"
}
},
"id": 940,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34776:33:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "34770:39:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 931,
"name": "fromAsset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 918,
"src": "34692:9:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 929,
"name": "globals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 916,
"src": "34669:7:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
}
},
"id": 930,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "getLatestPrice",
"nodeType": "MemberAccess",
"referencedDeclaration": 461,
"src": "34669:22:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$",
"typeString": "function (address) view external returns (uint256)"
}
},
"id": 932,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34669:33:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 927,
"name": "swapAmt",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 922,
"src": "34640:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 928,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "mul",
"nodeType": "MemberAccess",
"referencedDeclaration": 822,
"src": "34640:28:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 933,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34640:63:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 934,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "mul",
"nodeType": "MemberAccess",
"referencedDeclaration": 822,
"src": "34640:129:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 942,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34640:170:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 943,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "div",
"nodeType": "MemberAccess",
"referencedDeclaration": 839,
"src": "34640:238:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 948,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34640:271:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 949,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "div",
"nodeType": "MemberAccess",
"referencedDeclaration": 839,
"src": "34640:335:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 957,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "34640:378:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"functionReturnParameters": 926,
"id": 958,
"nodeType": "Return",
"src": "34621:397:0"
}
]
},
"documentation": {
"id": 914,
"nodeType": "StructuredDocumentation",
"src": "33998:477:0",
"text": "@dev Calculates the minimum amount from a swap (adjustable for price slippage).\n@param globals The instance of a MapleGlobals.\n@param fromAsset The address of ERC-20 that will be swapped.\n@param toAsset The address of ERC-20 that will returned from swap.\n@param swapAmt The amount of `fromAsset` to be swapped.\n@return The expected amount of `toAsset` to receive from swap based on current oracle prices."
},
"functionSelector": "c1e37186",
"id": 960,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "calcMinAmount",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 923,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 916,
"mutability": "mutable",
"name": "globals",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 960,
"src": "34503:21:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
},
"typeName": {
"contractScope": null,
"id": 915,
"name": "IMapleGlobals",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 492,
"src": "34503:13:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 918,
"mutability": "mutable",
"name": "fromAsset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 960,
"src": "34526:17:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 917,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "34526:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 920,
"mutability": "mutable",
"name": "toAsset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 960,
"src": "34545:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 919,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "34545:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 922,
"mutability": "mutable",
"name": "swapAmt",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 960,
"src": "34562:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 921,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "34562:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "34502:76:0"
},
"returnParameters": {
"id": 926,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 925,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 960,
"src": "34602:7:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 924,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "34602:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "34601:9:0"
},
"scope": 961,
"src": "34480:593:0",
"stateMutability": "view",
"virtual": false,
"visibility": "external"
}
],
"scope": 1727,
"src": "33945:1131:0"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "library",
"documentation": {
"id": 962,
"nodeType": "StructuredDocumentation",
"src": "35179:67:0",
"text": " @dev Collection of functions related to the address type"
},
"fullyImplemented": true,
"id": 1203,
"linearizedBaseContracts": [
1203
],
"name": "Address",
"nodeType": "ContractDefinition",
"nodes": [
{
"body": {
"id": 978,
"nodeType": "Block",
"src": "35905:347:0",
"statements": [
{
"assignments": [
971
],
"declarations": [
{
"constant": false,
"id": 971,
"mutability": "mutable",
"name": "size",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 978,
"src": "36102:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 970,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "36102:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 972,
"initialValue": null,
"nodeType": "VariableDeclarationStatement",
"src": "36102:12:0"
},
{
"AST": {
"nodeType": "YulBlock",
"src": "36189:32:0",
"statements": [
{
"nodeType": "YulAssignment",
"src": "36191:28:0",
"value": {
"arguments": [
{
"name": "account",
"nodeType": "YulIdentifier",
"src": "36211:7:0"
}
],
"functionName": {
"name": "extcodesize",
"nodeType": "YulIdentifier",
"src": "36199:11:0"
},
"nodeType": "YulFunctionCall",
"src": "36199:20:0"
},
"variableNames": [
{
"name": "size",
"nodeType": "YulIdentifier",
"src": "36191:4:0"
}
]
}
]
},
"evmVersion": "istanbul",
"externalReferences": [
{
"declaration": 965,
"isOffset": false,
"isSlot": false,
"src": "36211:7:0",
"valueSize": 1
},
{
"declaration": 971,
"isOffset": false,
"isSlot": false,
"src": "36191:4:0",
"valueSize": 1
}
],
"id": 973,
"nodeType": "InlineAssembly",
"src": "36180:41:0"
},
{
"expression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 976,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 974,
"name": "size",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 971,
"src": "36237:4:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 975,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "36244:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "36237:8:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"functionReturnParameters": 969,
"id": 977,
"nodeType": "Return",
"src": "36230:15:0"
}
]
},
"documentation": {
"id": 963,
"nodeType": "StructuredDocumentation",
"src": "35269:565:0",
"text": " @dev Returns true if `account` is a contract.\n [IMPORTANT]\n ====\n It is unsafe to assume that an address for which this function returns\n false is an externally-owned account (EOA) and not a contract.\n Among others, `isContract` will return false for the following\n types of addresses:\n - an externally-owned account\n - a contract in construction\n - an address where a contract will be created\n - an address where a contract lived, but was destroyed\n ===="
},
"id": 979,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "isContract",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 966,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 965,
"mutability": "mutable",
"name": "account",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 979,
"src": "35859:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 964,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "35859:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "35858:17:0"
},
"returnParameters": {
"id": 969,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 968,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 979,
"src": "35899:4:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 967,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "35899:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "35898:6:0"
},
"scope": 1203,
"src": "35839:413:0",
"stateMutability": "view",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1012,
"nodeType": "Block",
"src": "37240:320:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 994,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 990,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "37266:4:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Address_$1203",
"typeString": "library Address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_Address_$1203",
"typeString": "library Address"
}
],
"id": 989,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "37258:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 988,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "37258:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 991,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "37258:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 992,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "balance",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "37258:21:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">=",
"rightExpression": {
"argumentTypes": null,
"id": 993,
"name": "amount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 984,
"src": "37283:6:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "37258:31:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "416464726573733a20696e73756666696369656e742062616c616e6365",
"id": 995,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "37291:31:0",
"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": 987,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "37250:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 996,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "37250:73:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 997,
"nodeType": "ExpressionStatement",
"src": "37250:73:0"
},
{
"assignments": [
999,
null
],
"declarations": [
{
"constant": false,
"id": 999,
"mutability": "mutable",
"name": "success",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1012,
"src": "37412:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 998,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "37412:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
},
null
],
"id": 1006,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "",
"id": 1004,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "37462:2:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
"typeString": "literal_string \"\""
},
"value": ""
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_stringliteral_c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
"typeString": "literal_string \"\""
}
],
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1000,
"name": "recipient",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 982,
"src": "37430:9:0",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"id": 1001,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "call",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "37430:14:0",
"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": 1003,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"names": [
"value"
],
"nodeType": "FunctionCallOptions",
"options": [
{
"argumentTypes": null,
"id": 1002,
"name": "amount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 984,
"src": "37453:6:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"src": "37430:31:0",
"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": 1005,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "37430:35:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
"typeString": "tuple(bool,bytes memory)"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "37411:54:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1008,
"name": "success",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 999,
"src": "37483:7:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "416464726573733a20756e61626c6520746f2073656e642076616c75652c20726563697069656e74206d61792068617665207265766572746564",
"id": 1009,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "37492:60:0",
"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": 1007,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "37475:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 1010,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "37475:78:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1011,
"nodeType": "ExpressionStatement",
"src": "37475:78:0"
}
]
},
"documentation": {
"id": 980,
"nodeType": "StructuredDocumentation",
"src": "36258:906:0",
"text": " @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\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 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\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]."
},
"id": 1013,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "sendValue",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 985,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 982,
"mutability": "mutable",
"name": "recipient",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1013,
"src": "37188:25:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
},
"typeName": {
"id": 981,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "37188:15:0",
"stateMutability": "payable",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 984,
"mutability": "mutable",
"name": "amount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1013,
"src": "37215:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 983,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "37215:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "37187:43:0"
},
"returnParameters": {
"id": 986,
"nodeType": "ParameterList",
"parameters": [],
"src": "37240:0:0"
},
"scope": 1203,
"src": "37169:391:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1029,
"nodeType": "Block",
"src": "38390:82:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1024,
"name": "target",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1016,
"src": "38418:6:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1025,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1018,
"src": "38426:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
{
"argumentTypes": null,
"hexValue": "416464726573733a206c6f772d6c6576656c2063616c6c206661696c6564",
"id": 1026,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "38432:32:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_24d7ab5d382116e64324f19950ca9340b8af1ddeb09a8d026e0a3c6a01dcc9df",
"typeString": "literal_string \"Address: low-level call failed\""
},
"value": "Address: low-level call failed"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
},
{
"typeIdentifier": "t_stringliteral_24d7ab5d382116e64324f19950ca9340b8af1ddeb09a8d026e0a3c6a01dcc9df",
"typeString": "literal_string \"Address: low-level call failed\""
}
],
"id": 1023,
"name": "functionCall",
"nodeType": "Identifier",
"overloadedDeclarations": [
1030,
1050
],
"referencedDeclaration": 1050,
"src": "38405:12:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (address,bytes memory,string memory) returns (bytes memory)"
}
},
"id": 1027,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "38405:60:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"functionReturnParameters": 1022,
"id": 1028,
"nodeType": "Return",
"src": "38398:67:0"
}
]
},
"documentation": {
"id": 1014,
"nodeType": "StructuredDocumentation",
"src": "37566:730:0",
"text": " @dev Performs a Solidity function call using a low level `call`. A\n plain`call` is an unsafe replacement for a function call: use this\n function instead.\n If `target` reverts with a revert reason, it is bubbled up by this\n function (like regular Solidity function calls).\n Returns the raw returned data. To convert to the expected return value,\n use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`].\n Requirements:\n - `target` must be a contract.\n - calling `target` with `data` must not revert.\n _Available since v3.1._"
},
"id": 1030,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "functionCall",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1019,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1016,
"mutability": "mutable",
"name": "target",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1030,
"src": "38323:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1015,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "38323:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1018,
"mutability": "mutable",
"name": "data",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1030,
"src": "38339:17:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1017,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "38339:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "38322:35:0"
},
"returnParameters": {
"id": 1022,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1021,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1030,
"src": "38376:12:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1020,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "38376:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "38375:14:0"
},
"scope": 1203,
"src": "38301:171:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1049,
"nodeType": "Block",
"src": "38811:76:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1043,
"name": "target",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1033,
"src": "38850:6:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1044,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1035,
"src": "38858:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
{
"argumentTypes": null,
"hexValue": "30",
"id": 1045,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "38864:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
{
"argumentTypes": null,
"id": 1046,
"name": "errorMessage",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1037,
"src": "38867:12:0",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
},
{
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
{
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
],
"id": 1042,
"name": "functionCallWithValue",
"nodeType": "Identifier",
"overloadedDeclarations": [
1070,
1120
],
"referencedDeclaration": 1120,
"src": "38828:21:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_bytes_memory_ptr_$_t_uint256_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (address,bytes memory,uint256,string memory) returns (bytes memory)"
}
},
"id": 1047,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "38828:52:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"functionReturnParameters": 1041,
"id": 1048,
"nodeType": "Return",
"src": "38821:59:0"
}
]
},
"documentation": {
"id": 1031,
"nodeType": "StructuredDocumentation",
"src": "38478:211:0",
"text": " @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with\n `errorMessage` as a fallback revert reason when `target` reverts.\n _Available since v3.1._"
},
"id": 1050,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "functionCall",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1038,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1033,
"mutability": "mutable",
"name": "target",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1050,
"src": "38716:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1032,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "38716:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1035,
"mutability": "mutable",
"name": "data",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1050,
"src": "38732:17:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1034,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "38732:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1037,
"mutability": "mutable",
"name": "errorMessage",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1050,
"src": "38751:26:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 1036,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "38751:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "38715:63:0"
},
"returnParameters": {
"id": 1041,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1040,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1050,
"src": "38797:12:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1039,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "38797:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "38796:14:0"
},
"scope": 1203,
"src": "38694:193:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1069,
"nodeType": "Block",
"src": "39362:111:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1063,
"name": "target",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1053,
"src": "39401:6:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1064,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1055,
"src": "39409:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
{
"argumentTypes": null,
"id": 1065,
"name": "value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1057,
"src": "39415:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"hexValue": "416464726573733a206c6f772d6c6576656c2063616c6c20776974682076616c7565206661696c6564",
"id": 1066,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "39422:43:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_88a4a0b5e975840320a0475d4027005235904fdb5ece94df156f3d717cb2dbfc",
"typeString": "literal_string \"Address: low-level call with value failed\""
},
"value": "Address: low-level call with value failed"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
{
"typeIdentifier": "t_stringliteral_88a4a0b5e975840320a0475d4027005235904fdb5ece94df156f3d717cb2dbfc",
"typeString": "literal_string \"Address: low-level call with value failed\""
}
],
"id": 1062,
"name": "functionCallWithValue",
"nodeType": "Identifier",
"overloadedDeclarations": [
1070,
1120
],
"referencedDeclaration": 1120,
"src": "39379:21:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_bytes_memory_ptr_$_t_uint256_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (address,bytes memory,uint256,string memory) returns (bytes memory)"
}
},
"id": 1067,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39379:87:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"functionReturnParameters": 1061,
"id": 1068,
"nodeType": "Return",
"src": "39372:94:0"
}
]
},
"documentation": {
"id": 1051,
"nodeType": "StructuredDocumentation",
"src": "38893:351:0",
"text": " @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n but also transferring `value` wei to `target`.\n Requirements:\n - the calling contract must have an ETH balance of at least `value`.\n - the called Solidity function must be `payable`.\n _Available since v3.1._"
},
"id": 1070,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "functionCallWithValue",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1058,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1053,
"mutability": "mutable",
"name": "target",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1070,
"src": "39280:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1052,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "39280:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1055,
"mutability": "mutable",
"name": "data",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1070,
"src": "39296:17:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1054,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "39296:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1057,
"mutability": "mutable",
"name": "value",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1070,
"src": "39315:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1056,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "39315:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "39279:50:0"
},
"returnParameters": {
"id": 1061,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1060,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1070,
"src": "39348:12:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1059,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "39348:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "39347:14:0"
},
"scope": 1203,
"src": "39249:224:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1119,
"nodeType": "Block",
"src": "39862:382:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 1091,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1087,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "39888:4:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Address_$1203",
"typeString": "library Address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_Address_$1203",
"typeString": "library Address"
}
],
"id": 1086,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "39880:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 1085,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "39880:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 1088,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39880:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1089,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "balance",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "39880:21:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">=",
"rightExpression": {
"argumentTypes": null,
"id": 1090,
"name": "value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1077,
"src": "39905:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"src": "39880:30:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "416464726573733a20696e73756666696369656e742062616c616e636520666f722063616c6c",
"id": 1092,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "39912:40:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_565f1a77334fc4792800921178c71e4521acffab18ff9e7885b49377ee80ab4c",
"typeString": "literal_string \"Address: insufficient balance for call\""
},
"value": "Address: insufficient balance for call"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_565f1a77334fc4792800921178c71e4521acffab18ff9e7885b49377ee80ab4c",
"typeString": "literal_string \"Address: insufficient balance for call\""
}
],
"id": 1084,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "39872:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 1093,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39872:81:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1094,
"nodeType": "ExpressionStatement",
"src": "39872:81:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1097,
"name": "target",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1073,
"src": "39982:6:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1096,
"name": "isContract",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 979,
"src": "39971:10:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$",
"typeString": "function (address) view returns (bool)"
}
},
"id": 1098,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39971:18:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374",
"id": 1099,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "39991:31:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_cc2e4e38850b7c0a3e942cfed89b71c77302df25bcb2ec297a0c4ff9ff6b90ad",
"typeString": "literal_string \"Address: call to non-contract\""
},
"value": "Address: call to non-contract"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_cc2e4e38850b7c0a3e942cfed89b71c77302df25bcb2ec297a0c4ff9ff6b90ad",
"typeString": "literal_string \"Address: call to non-contract\""
}
],
"id": 1095,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "39963:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 1100,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "39963:60:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1101,
"nodeType": "ExpressionStatement",
"src": "39963:60:0"
},
{
"assignments": [
1103,
1105
],
"declarations": [
{
"constant": false,
"id": 1103,
"mutability": "mutable",
"name": "success",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1119,
"src": "40094:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 1102,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "40094:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1105,
"mutability": "mutable",
"name": "returndata",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1119,
"src": "40108:23:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1104,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "40108:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1112,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1110,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1075,
"src": "40163:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1106,
"name": "target",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1073,
"src": "40135:6:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1107,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "call",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "40135:11:0",
"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": 1109,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"names": [
"value"
],
"nodeType": "FunctionCallOptions",
"options": [
{
"argumentTypes": null,
"id": 1108,
"name": "value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1077,
"src": "40155:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"src": "40135:27:0",
"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": 1111,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "40135:33:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
"typeString": "tuple(bool,bytes memory)"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "40093:75:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1114,
"name": "success",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1103,
"src": "40203:7:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"id": 1115,
"name": "returndata",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1105,
"src": "40212:10:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
{
"argumentTypes": null,
"id": 1116,
"name": "errorMessage",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1079,
"src": "40224:12:0",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
},
{
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
],
"id": 1113,
"name": "_verifyCallResult",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1202,
"src": "40185:17:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_bool_$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (bool,bytes memory,string memory) pure returns (bytes memory)"
}
},
"id": 1117,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "40185:52:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"functionReturnParameters": 1083,
"id": 1118,
"nodeType": "Return",
"src": "40178:59:0"
}
]
},
"documentation": {
"id": 1071,
"nodeType": "StructuredDocumentation",
"src": "39479:237:0",
"text": " @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but\n with `errorMessage` as a fallback revert reason when `target` reverts.\n _Available since v3.1._"
},
"id": 1120,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "functionCallWithValue",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1080,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1073,
"mutability": "mutable",
"name": "target",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1120,
"src": "39752:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1072,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "39752:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1075,
"mutability": "mutable",
"name": "data",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1120,
"src": "39768:17:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1074,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "39768:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1077,
"mutability": "mutable",
"name": "value",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1120,
"src": "39787:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1076,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "39787:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1079,
"mutability": "mutable",
"name": "errorMessage",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1120,
"src": "39802:26:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 1078,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "39802:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "39751:78:0"
},
"returnParameters": {
"id": 1083,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1082,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1120,
"src": "39848:12:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1081,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "39848:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "39847:14:0"
},
"scope": 1203,
"src": "39721:523:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1136,
"nodeType": "Block",
"src": "40521:97:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1131,
"name": "target",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1123,
"src": "40557:6:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1132,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1125,
"src": "40565:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
{
"argumentTypes": null,
"hexValue": "416464726573733a206c6f772d6c6576656c207374617469632063616c6c206661696c6564",
"id": 1133,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "40571:39:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_90ec82aa826a536a4cbfae44ecfa384680faa9a4b77344bce96aa761ad904df0",
"typeString": "literal_string \"Address: low-level static call failed\""
},
"value": "Address: low-level static call failed"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
},
{
"typeIdentifier": "t_stringliteral_90ec82aa826a536a4cbfae44ecfa384680faa9a4b77344bce96aa761ad904df0",
"typeString": "literal_string \"Address: low-level static call failed\""
}
],
"id": 1130,
"name": "functionStaticCall",
"nodeType": "Identifier",
"overloadedDeclarations": [
1137,
1172
],
"referencedDeclaration": 1172,
"src": "40538:18:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (address,bytes memory,string memory) view returns (bytes memory)"
}
},
"id": 1134,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "40538:73:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"functionReturnParameters": 1129,
"id": 1135,
"nodeType": "Return",
"src": "40531:80:0"
}
]
},
"documentation": {
"id": 1121,
"nodeType": "StructuredDocumentation",
"src": "40250:166:0",
"text": " @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`],\n but performing a static call.\n _Available since v3.3._"
},
"id": 1137,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "functionStaticCall",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1126,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1123,
"mutability": "mutable",
"name": "target",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1137,
"src": "40449:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1122,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "40449:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1125,
"mutability": "mutable",
"name": "data",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1137,
"src": "40465:17:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1124,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "40465:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "40448:35:0"
},
"returnParameters": {
"id": 1129,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1128,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1137,
"src": "40507:12:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1127,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "40507:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "40506:14:0"
},
"scope": 1203,
"src": "40421:197:0",
"stateMutability": "view",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1171,
"nodeType": "Block",
"src": "40930:288:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1151,
"name": "target",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1140,
"src": "40959:6:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1150,
"name": "isContract",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 979,
"src": "40948:10:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_view$_t_address_$returns$_t_bool_$",
"typeString": "function (address) view returns (bool)"
}
},
"id": 1152,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "40948:18:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "416464726573733a207374617469632063616c6c20746f206e6f6e2d636f6e7472616374",
"id": 1153,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "40968:38:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_c79cc78e4f16ce3933a42b84c73868f93bb4a59c031a0acf576679de98c608a9",
"typeString": "literal_string \"Address: static call to non-contract\""
},
"value": "Address: static call to non-contract"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_c79cc78e4f16ce3933a42b84c73868f93bb4a59c031a0acf576679de98c608a9",
"typeString": "literal_string \"Address: static call to non-contract\""
}
],
"id": 1149,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "40940:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 1154,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "40940:67:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1155,
"nodeType": "ExpressionStatement",
"src": "40940:67:0"
},
{
"assignments": [
1157,
1159
],
"declarations": [
{
"constant": false,
"id": 1157,
"mutability": "mutable",
"name": "success",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1171,
"src": "41078:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 1156,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "41078:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1159,
"mutability": "mutable",
"name": "returndata",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1171,
"src": "41092:23:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1158,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "41092:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1164,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1162,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1142,
"src": "41137:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"expression": {
"argumentTypes": null,
"id": 1160,
"name": "target",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1140,
"src": "41119:6:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1161,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "staticcall",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "41119:17:0",
"typeDescriptions": {
"typeIdentifier": "t_function_barestaticcall_view$_t_bytes_memory_ptr_$returns$_t_bool_$_t_bytes_memory_ptr_$",
"typeString": "function (bytes memory) view returns (bool,bytes memory)"
}
},
"id": 1163,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "41119:23:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$_t_bool_$_t_bytes_memory_ptr_$",
"typeString": "tuple(bool,bytes memory)"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "41077:65:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1166,
"name": "success",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1157,
"src": "41177:7:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"id": 1167,
"name": "returndata",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1159,
"src": "41186:10:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
{
"argumentTypes": null,
"id": 1168,
"name": "errorMessage",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1144,
"src": "41198:12:0",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
},
{
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
],
"id": 1165,
"name": "_verifyCallResult",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1202,
"src": "41159:17:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_bool_$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (bool,bytes memory,string memory) pure returns (bytes memory)"
}
},
"id": 1169,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "41159:52:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"functionReturnParameters": 1148,
"id": 1170,
"nodeType": "Return",
"src": "41152:59:0"
}
]
},
"documentation": {
"id": 1138,
"nodeType": "StructuredDocumentation",
"src": "40624:173:0",
"text": " @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`],\n but performing a static call.\n _Available since v3.3._"
},
"id": 1172,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "functionStaticCall",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1145,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1140,
"mutability": "mutable",
"name": "target",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1172,
"src": "40830:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1139,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "40830:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1142,
"mutability": "mutable",
"name": "data",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1172,
"src": "40846:17:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1141,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "40846:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1144,
"mutability": "mutable",
"name": "errorMessage",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1172,
"src": "40865:26:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 1143,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "40865:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "40829:63:0"
},
"returnParameters": {
"id": 1148,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1147,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1172,
"src": "40916:12:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1146,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "40916:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "40915:14:0"
},
"scope": 1203,
"src": "40802:416:0",
"stateMutability": "view",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1201,
"nodeType": "Block",
"src": "41353:596:0",
"statements": [
{
"condition": {
"argumentTypes": null,
"id": 1183,
"name": "success",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1174,
"src": "41367:7:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": {
"id": 1199,
"nodeType": "Block",
"src": "41424:519:0",
"statements": [
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 1190,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1187,
"name": "returndata",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1176,
"src": "41508:10:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"id": 1188,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "41508:17:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 1189,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "41528:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "41508:21:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": {
"id": 1197,
"nodeType": "Block",
"src": "41880:53:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1194,
"name": "errorMessage",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1178,
"src": "41905:12:0",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string memory"
}
],
"id": 1193,
"name": "revert",
"nodeType": "Identifier",
"overloadedDeclarations": [
-19,
-19
],
"referencedDeclaration": -19,
"src": "41898:6:0",
"typeDescriptions": {
"typeIdentifier": "t_function_revert_pure$_t_string_memory_ptr_$returns$__$",
"typeString": "function (string memory) pure"
}
},
"id": 1195,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "41898:20:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1196,
"nodeType": "ExpressionStatement",
"src": "41898:20:0"
}
]
},
"id": 1198,
"nodeType": "IfStatement",
"src": "41504:429:0",
"trueBody": {
"id": 1192,
"nodeType": "Block",
"src": "41531:343:0",
"statements": [
{
"AST": {
"nodeType": "YulBlock",
"src": "41715:145:0",
"statements": [
{
"nodeType": "YulVariableDeclaration",
"src": "41737:40:0",
"value": {
"arguments": [
{
"name": "returndata",
"nodeType": "YulIdentifier",
"src": "41766:10:0"
}
],
"functionName": {
"name": "mload",
"nodeType": "YulIdentifier",
"src": "41760:5:0"
},
"nodeType": "YulFunctionCall",
"src": "41760:17:0"
},
"variables": [
{
"name": "returndata_size",
"nodeType": "YulTypedName",
"src": "41741:15:0",
"type": ""
}
]
},
{
"expression": {
"arguments": [
{
"arguments": [
{
"kind": "number",
"nodeType": "YulLiteral",
"src": "41809:2:0",
"type": "",
"value": "32"
},
{
"name": "returndata",
"nodeType": "YulIdentifier",
"src": "41813:10:0"
}
],
"functionName": {
"name": "add",
"nodeType": "YulIdentifier",
"src": "41805:3:0"
},
"nodeType": "YulFunctionCall",
"src": "41805:19:0"
},
{
"name": "returndata_size",
"nodeType": "YulIdentifier",
"src": "41826:15:0"
}
],
"functionName": {
"name": "revert",
"nodeType": "YulIdentifier",
"src": "41798:6:0"
},
"nodeType": "YulFunctionCall",
"src": "41798:44:0"
},
"nodeType": "YulExpressionStatement",
"src": "41798:44:0"
}
]
},
"evmVersion": "istanbul",
"externalReferences": [
{
"declaration": 1176,
"isOffset": false,
"isSlot": false,
"src": "41766:10:0",
"valueSize": 1
},
{
"declaration": 1176,
"isOffset": false,
"isSlot": false,
"src": "41813:10:0",
"valueSize": 1
}
],
"id": 1191,
"nodeType": "InlineAssembly",
"src": "41706:154:0"
}
]
}
}
]
},
"id": 1200,
"nodeType": "IfStatement",
"src": "41363:580:0",
"trueBody": {
"id": 1186,
"nodeType": "Block",
"src": "41376:42:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 1184,
"name": "returndata",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1176,
"src": "41397:10:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"functionReturnParameters": 1182,
"id": 1185,
"nodeType": "Return",
"src": "41390:17:0"
}
]
}
}
]
},
"documentation": null,
"id": 1202,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_verifyCallResult",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1179,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1174,
"mutability": "mutable",
"name": "success",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1202,
"src": "41251:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 1173,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "41251:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1176,
"mutability": "mutable",
"name": "returndata",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1202,
"src": "41265:23:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1175,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "41265:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1178,
"mutability": "mutable",
"name": "errorMessage",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1202,
"src": "41290:26:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_string_memory_ptr",
"typeString": "string"
},
"typeName": {
"id": 1177,
"name": "string",
"nodeType": "ElementaryTypeName",
"src": "41290:6:0",
"typeDescriptions": {
"typeIdentifier": "t_string_storage_ptr",
"typeString": "string"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "41250:67:0"
},
"returnParameters": {
"id": 1182,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1181,
"mutability": "mutable",
"name": "",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1202,
"src": "41339:12:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1180,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "41339:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "41338:14:0"
},
"scope": 1203,
"src": "41224:725:0",
"stateMutability": "pure",
"virtual": false,
"visibility": "private"
}
],
"scope": 1727,
"src": "35247:6704:0"
},
{
"abstract": false,
"baseContracts": [],
"contractDependencies": [],
"contractKind": "library",
"documentation": {
"id": 1204,
"nodeType": "StructuredDocumentation",
"src": "42172:457:0",
"text": " @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 IERC20;` statement to your contract,\n which allows you to call the safe operations as `token.safeTransfer(...)`, etc."
},
"fullyImplemented": true,
"id": 1411,
"linearizedBaseContracts": [
1411
],
"name": "SafeERC20",
"nodeType": "ContractDefinition",
"nodes": [
{
"id": 1207,
"libraryName": {
"contractScope": null,
"id": 1205,
"name": "SafeMath",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 909,
"src": "42660:8:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SafeMath_$909",
"typeString": "library SafeMath"
}
},
"nodeType": "UsingForDirective",
"src": "42654:27:0",
"typeName": {
"id": 1206,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "42673:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
{
"id": 1210,
"libraryName": {
"contractScope": null,
"id": 1208,
"name": "Address",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 1203,
"src": "42692:7:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_Address_$1203",
"typeString": "library Address"
}
},
"nodeType": "UsingForDirective",
"src": "42686:26:0",
"typeName": {
"id": 1209,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "42704:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
},
{
"body": {
"id": 1231,
"nodeType": "Block",
"src": "42790:103:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1220,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1212,
"src": "42820:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1223,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1212,
"src": "42850:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1224,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "transfer",
"nodeType": "MemberAccess",
"referencedDeclaration": 646,
"src": "42850:14:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,uint256) external returns (bool)"
}
},
"id": 1225,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "selector",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "42850:23:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
{
"argumentTypes": null,
"id": 1226,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1214,
"src": "42875:2:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1227,
"name": "value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1216,
"src": "42879:5:0",
"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": 1221,
"name": "abi",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -1,
"src": "42827:3:0",
"typeDescriptions": {
"typeIdentifier": "t_magic_abi",
"typeString": "abi"
}
},
"id": 1222,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"memberName": "encodeWithSelector",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "42827:22:0",
"typeDescriptions": {
"typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (bytes4) pure returns (bytes memory)"
}
},
"id": 1228,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "42827:58:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"id": 1219,
"name": "_callOptionalReturn",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1410,
"src": "42800:19:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$697_$_t_bytes_memory_ptr_$returns$__$",
"typeString": "function (contract IERC20,bytes memory)"
}
},
"id": 1229,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "42800:86:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1230,
"nodeType": "ExpressionStatement",
"src": "42800:86:0"
}
]
},
"documentation": null,
"id": 1232,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "safeTransfer",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1217,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1212,
"mutability": "mutable",
"name": "token",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1232,
"src": "42740:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
"typeName": {
"contractScope": null,
"id": 1211,
"name": "IERC20",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 697,
"src": "42740:6:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1214,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1232,
"src": "42754:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1213,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "42754:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1216,
"mutability": "mutable",
"name": "value",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1232,
"src": "42766:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1215,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "42766:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "42739:41:0"
},
"returnParameters": {
"id": 1218,
"nodeType": "ParameterList",
"parameters": [],
"src": "42790:0:0"
},
"scope": 1411,
"src": "42718:175:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1256,
"nodeType": "Block",
"src": "42989:113:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1244,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1234,
"src": "43019:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1247,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1234,
"src": "43049:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1248,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "transferFrom",
"nodeType": "MemberAccess",
"referencedDeclaration": 678,
"src": "43049:18:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,address,uint256) external returns (bool)"
}
},
"id": 1249,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "selector",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "43049:27:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
{
"argumentTypes": null,
"id": 1250,
"name": "from",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1236,
"src": "43078:4:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1251,
"name": "to",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1238,
"src": "43084:2:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1252,
"name": "value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1240,
"src": "43088:5:0",
"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": 1245,
"name": "abi",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -1,
"src": "43026:3:0",
"typeDescriptions": {
"typeIdentifier": "t_magic_abi",
"typeString": "abi"
}
},
"id": 1246,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"memberName": "encodeWithSelector",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "43026:22:0",
"typeDescriptions": {
"typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (bytes4) pure returns (bytes memory)"
}
},
"id": 1253,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "43026:68:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"id": 1243,
"name": "_callOptionalReturn",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1410,
"src": "42999:19:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$697_$_t_bytes_memory_ptr_$returns$__$",
"typeString": "function (contract IERC20,bytes memory)"
}
},
"id": 1254,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "42999:96:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1255,
"nodeType": "ExpressionStatement",
"src": "42999:96:0"
}
]
},
"documentation": null,
"id": 1257,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "safeTransferFrom",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1241,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1234,
"mutability": "mutable",
"name": "token",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1257,
"src": "42925:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
"typeName": {
"contractScope": null,
"id": 1233,
"name": "IERC20",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 697,
"src": "42925:6:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1236,
"mutability": "mutable",
"name": "from",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1257,
"src": "42939:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1235,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "42939:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1238,
"mutability": "mutable",
"name": "to",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1257,
"src": "42953:10:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1237,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "42953:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1240,
"mutability": "mutable",
"name": "value",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1257,
"src": "42965:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1239,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "42965:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "42924:55:0"
},
"returnParameters": {
"id": 1242,
"nodeType": "ParameterList",
"parameters": [],
"src": "42989:0:0"
},
"scope": 1411,
"src": "42899:203:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1299,
"nodeType": "Block",
"src": "43438:537:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"id": 1283,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"components": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 1270,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 1268,
"name": "value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1264,
"src": "43727:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 1269,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "43736:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "43727:10:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"id": 1271,
"isConstant": false,
"isInlineArray": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "TupleExpression",
"src": "43726:12:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "BinaryOperation",
"operator": "||",
"rightExpression": {
"argumentTypes": null,
"components": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 1281,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1276,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "43767:4:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SafeERC20_$1411",
"typeString": "library SafeERC20"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_SafeERC20_$1411",
"typeString": "library SafeERC20"
}
],
"id": 1275,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "43759:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 1274,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "43759:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 1277,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "43759:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1278,
"name": "spender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1262,
"src": "43774:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 1272,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1260,
"src": "43743:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1273,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "allowance",
"nodeType": "MemberAccess",
"referencedDeclaration": 656,
"src": "43743:15:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$",
"typeString": "function (address,address) view external returns (uint256)"
}
},
"id": 1279,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "43743:39:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 1280,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "43786:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "43743:44:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
}
],
"id": 1282,
"isConstant": false,
"isInlineArray": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "TupleExpression",
"src": "43742:46:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"src": "43726:62:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "5361666545524332303a20617070726f76652066726f6d206e6f6e2d7a65726f20746f206e6f6e2d7a65726f20616c6c6f77616e6365",
"id": 1284,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "43802:56:0",
"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": 1267,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "43718:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 1285,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "43718:150:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1286,
"nodeType": "ExpressionStatement",
"src": "43718:150:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1288,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1260,
"src": "43898:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1291,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1260,
"src": "43928:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1292,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "approve",
"nodeType": "MemberAccess",
"referencedDeclaration": 666,
"src": "43928:13:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,uint256) external returns (bool)"
}
},
"id": 1293,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "selector",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "43928:22:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
{
"argumentTypes": null,
"id": 1294,
"name": "spender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1262,
"src": "43952:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1295,
"name": "value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1264,
"src": "43961:5:0",
"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": 1289,
"name": "abi",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -1,
"src": "43905:3:0",
"typeDescriptions": {
"typeIdentifier": "t_magic_abi",
"typeString": "abi"
}
},
"id": 1290,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"memberName": "encodeWithSelector",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "43905:22:0",
"typeDescriptions": {
"typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (bytes4) pure returns (bytes memory)"
}
},
"id": 1296,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "43905:62:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"id": 1287,
"name": "_callOptionalReturn",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1410,
"src": "43878:19:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$697_$_t_bytes_memory_ptr_$returns$__$",
"typeString": "function (contract IERC20,bytes memory)"
}
},
"id": 1297,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "43878:90:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1298,
"nodeType": "ExpressionStatement",
"src": "43878:90:0"
}
]
},
"documentation": {
"id": 1258,
"nodeType": "StructuredDocumentation",
"src": "43108:249:0",
"text": " @dev Deprecated. This function has issues similar to the ones found in\n {IERC20-approve}, and its usage is discouraged.\n Whenever possible, use {safeIncreaseAllowance} and\n {safeDecreaseAllowance} instead."
},
"id": 1300,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "safeApprove",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1265,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1260,
"mutability": "mutable",
"name": "token",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1300,
"src": "43383:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
"typeName": {
"contractScope": null,
"id": 1259,
"name": "IERC20",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 697,
"src": "43383:6:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1262,
"mutability": "mutable",
"name": "spender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1300,
"src": "43397:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1261,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "43397:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1264,
"mutability": "mutable",
"name": "value",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1300,
"src": "43414:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1263,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "43414:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "43382:46:0"
},
"returnParameters": {
"id": 1266,
"nodeType": "ParameterList",
"parameters": [],
"src": "43438:0:0"
},
"scope": 1411,
"src": "43362:613:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1335,
"nodeType": "Block",
"src": "44067:197:0",
"statements": [
{
"assignments": [
1310
],
"declarations": [
{
"constant": false,
"id": 1310,
"mutability": "mutable",
"name": "newAllowance",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1335,
"src": "44077:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1309,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "44077:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1322,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1320,
"name": "value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1306,
"src": "44144:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1315,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "44124:4:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SafeERC20_$1411",
"typeString": "library SafeERC20"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_SafeERC20_$1411",
"typeString": "library SafeERC20"
}
],
"id": 1314,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "44116:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 1313,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "44116:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 1316,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "44116:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1317,
"name": "spender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1304,
"src": "44131:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 1311,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1302,
"src": "44100:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1312,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "allowance",
"nodeType": "MemberAccess",
"referencedDeclaration": 656,
"src": "44100:15:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$",
"typeString": "function (address,address) view external returns (uint256)"
}
},
"id": 1318,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "44100:39:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 1319,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "add",
"nodeType": "MemberAccess",
"referencedDeclaration": 742,
"src": "44100:43:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 1321,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "44100:50:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "44077:73:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1324,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1302,
"src": "44180:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1327,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1302,
"src": "44210:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1328,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "approve",
"nodeType": "MemberAccess",
"referencedDeclaration": 666,
"src": "44210:13:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,uint256) external returns (bool)"
}
},
"id": 1329,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "selector",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "44210:22:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
{
"argumentTypes": null,
"id": 1330,
"name": "spender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1304,
"src": "44234:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1331,
"name": "newAllowance",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1310,
"src": "44243:12:0",
"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": 1325,
"name": "abi",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -1,
"src": "44187:3:0",
"typeDescriptions": {
"typeIdentifier": "t_magic_abi",
"typeString": "abi"
}
},
"id": 1326,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"memberName": "encodeWithSelector",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "44187:22:0",
"typeDescriptions": {
"typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (bytes4) pure returns (bytes memory)"
}
},
"id": 1332,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "44187:69:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"id": 1323,
"name": "_callOptionalReturn",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1410,
"src": "44160:19:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$697_$_t_bytes_memory_ptr_$returns$__$",
"typeString": "function (contract IERC20,bytes memory)"
}
},
"id": 1333,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "44160:97:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1334,
"nodeType": "ExpressionStatement",
"src": "44160:97:0"
}
]
},
"documentation": null,
"id": 1336,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "safeIncreaseAllowance",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1307,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1302,
"mutability": "mutable",
"name": "token",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1336,
"src": "44012:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
"typeName": {
"contractScope": null,
"id": 1301,
"name": "IERC20",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 697,
"src": "44012:6:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1304,
"mutability": "mutable",
"name": "spender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1336,
"src": "44026:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1303,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "44026:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1306,
"mutability": "mutable",
"name": "value",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1336,
"src": "44043:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1305,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "44043:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "44011:46:0"
},
"returnParameters": {
"id": 1308,
"nodeType": "ParameterList",
"parameters": [],
"src": "44067:0:0"
},
"scope": 1411,
"src": "43981:283:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1372,
"nodeType": "Block",
"src": "44356:242:0",
"statements": [
{
"assignments": [
1346
],
"declarations": [
{
"constant": false,
"id": 1346,
"mutability": "mutable",
"name": "newAllowance",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1372,
"src": "44366:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1345,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "44366:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1359,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1356,
"name": "value",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1342,
"src": "44433:5:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"hexValue": "5361666545524332303a2064656372656173656420616c6c6f77616e63652062656c6f77207a65726f",
"id": 1357,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "44440:43:0",
"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": 1351,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "44413:4:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SafeERC20_$1411",
"typeString": "library SafeERC20"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_SafeERC20_$1411",
"typeString": "library SafeERC20"
}
],
"id": 1350,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "44405:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 1349,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "44405:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 1352,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "44405:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1353,
"name": "spender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1340,
"src": "44420:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 1347,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1338,
"src": "44389:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1348,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "allowance",
"nodeType": "MemberAccess",
"referencedDeclaration": 656,
"src": "44389:15:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_uint256_$",
"typeString": "function (address,address) view external returns (uint256)"
}
},
"id": 1354,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "44389:39:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 1355,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 787,
"src": "44389:43:0",
"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": 1358,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "44389:95:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "44366:118:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1361,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1338,
"src": "44514:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1364,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1338,
"src": "44544:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1365,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "approve",
"nodeType": "MemberAccess",
"referencedDeclaration": 666,
"src": "44544:13:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_nonpayable$_t_address_$_t_uint256_$returns$_t_bool_$",
"typeString": "function (address,uint256) external returns (bool)"
}
},
"id": 1366,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "selector",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "44544:22:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes4",
"typeString": "bytes4"
}
},
{
"argumentTypes": null,
"id": 1367,
"name": "spender",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1340,
"src": "44568:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1368,
"name": "newAllowance",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1346,
"src": "44577:12:0",
"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": 1362,
"name": "abi",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -1,
"src": "44521:3:0",
"typeDescriptions": {
"typeIdentifier": "t_magic_abi",
"typeString": "abi"
}
},
"id": 1363,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"memberName": "encodeWithSelector",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "44521:22:0",
"typeDescriptions": {
"typeIdentifier": "t_function_abiencodewithselector_pure$_t_bytes4_$returns$_t_bytes_memory_ptr_$",
"typeString": "function (bytes4) pure returns (bytes memory)"
}
},
"id": 1369,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "44521:69:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
{
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
],
"id": 1360,
"name": "_callOptionalReturn",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1410,
"src": "44494:19:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$697_$_t_bytes_memory_ptr_$returns$__$",
"typeString": "function (contract IERC20,bytes memory)"
}
},
"id": 1370,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "44494:97:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1371,
"nodeType": "ExpressionStatement",
"src": "44494:97:0"
}
]
},
"documentation": null,
"id": 1373,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "safeDecreaseAllowance",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1343,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1338,
"mutability": "mutable",
"name": "token",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1373,
"src": "44301:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
"typeName": {
"contractScope": null,
"id": 1337,
"name": "IERC20",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 697,
"src": "44301:6:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1340,
"mutability": "mutable",
"name": "spender",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1373,
"src": "44315:15:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1339,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "44315:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1342,
"mutability": "mutable",
"name": "value",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1373,
"src": "44332:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1341,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "44332:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "44300:46:0"
},
"returnParameters": {
"id": 1344,
"nodeType": "ParameterList",
"parameters": [],
"src": "44356:0:0"
},
"scope": 1411,
"src": "44270:328:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "internal"
},
{
"body": {
"id": 1409,
"nodeType": "Block",
"src": "45051:681:0",
"statements": [
{
"assignments": [
1382
],
"declarations": [
{
"constant": false,
"id": 1382,
"mutability": "mutable",
"name": "returndata",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1409,
"src": "45400:23:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1381,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "45400:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1391,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1388,
"name": "data",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1378,
"src": "45454:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
{
"argumentTypes": null,
"hexValue": "5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c6564",
"id": 1389,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "45460:34:0",
"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_bytes_memory_ptr",
"typeString": "bytes memory"
},
{
"typeIdentifier": "t_stringliteral_47fb62c2c272651d2f0f342bac006756b8ba07f21cc5cb87e0fbb9d50c0c585b",
"typeString": "literal_string \"SafeERC20: low-level call failed\""
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1385,
"name": "token",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1376,
"src": "45434:5:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
],
"id": 1384,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "45426:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 1383,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "45426:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 1386,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "45426:14:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1387,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "functionCall",
"nodeType": "MemberAccess",
"referencedDeclaration": 1050,
"src": "45426:27:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_address_$_t_bytes_memory_ptr_$_t_string_memory_ptr_$returns$_t_bytes_memory_ptr_$bound_to$_t_address_$",
"typeString": "function (address,bytes memory,string memory) returns (bytes memory)"
}
},
"id": 1390,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "45426:69:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "45400:95:0"
},
{
"condition": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 1395,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1392,
"name": "returndata",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1382,
"src": "45509:10:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
"id": 1393,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "45509:17:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": ">",
"rightExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 1394,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "45529:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"src": "45509:21:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 1408,
"nodeType": "IfStatement",
"src": "45505:221:0",
"trueBody": {
"id": 1407,
"nodeType": "Block",
"src": "45532:194:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1399,
"name": "returndata",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1382,
"src": "45649:10:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes memory"
}
},
{
"argumentTypes": null,
"components": [
{
"argumentTypes": null,
"id": 1401,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "45662:4:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_bool_$",
"typeString": "type(bool)"
},
"typeName": {
"id": 1400,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "45662:4:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
}
],
"id": 1402,
"isConstant": false,
"isInlineArray": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "TupleExpression",
"src": "45661:6:0",
"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": 1397,
"name": "abi",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -1,
"src": "45638:3:0",
"typeDescriptions": {
"typeIdentifier": "t_magic_abi",
"typeString": "abi"
}
},
"id": 1398,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"memberName": "decode",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "45638:10:0",
"typeDescriptions": {
"typeIdentifier": "t_function_abidecode_pure$__$returns$__$",
"typeString": "function () pure"
}
},
"id": 1403,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "45638:30:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "5361666545524332303a204552433230206f7065726174696f6e20646964206e6f742073756363656564",
"id": 1404,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "45670:44:0",
"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": 1396,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "45630:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 1405,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "45630:85:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1406,
"nodeType": "ExpressionStatement",
"src": "45630:85:0"
}
]
}
}
]
},
"documentation": {
"id": 1374,
"nodeType": "StructuredDocumentation",
"src": "44604:372:0",
"text": " @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)."
},
"id": 1410,
"implemented": true,
"kind": "function",
"modifiers": [],
"name": "_callOptionalReturn",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1379,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1376,
"mutability": "mutable",
"name": "token",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1410,
"src": "45010:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
"typeName": {
"contractScope": null,
"id": 1375,
"name": "IERC20",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 697,
"src": "45010:6:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1378,
"mutability": "mutable",
"name": "data",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1410,
"src": "45024:17:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_bytes_memory_ptr",
"typeString": "bytes"
},
"typeName": {
"id": 1377,
"name": "bytes",
"nodeType": "ElementaryTypeName",
"src": "45024:5:0",
"typeDescriptions": {
"typeIdentifier": "t_bytes_storage_ptr",
"typeString": "bytes"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "45009:33:0"
},
"returnParameters": {
"id": 1380,
"nodeType": "ParameterList",
"parameters": [],
"src": "45051:0:0"
},
"scope": 1411,
"src": "44981:751:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "private"
}
],
"scope": 1727,
"src": "42630:3104:0"
},
{
"abstract": false,
"baseContracts": [
{
"arguments": null,
"baseName": {
"contractScope": null,
"id": 1413,
"name": "IMapleTreasury",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 568,
"src": "46592:14:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleTreasury_$568",
"typeString": "contract IMapleTreasury"
}
},
"id": 1414,
"nodeType": "InheritanceSpecifier",
"src": "46592:14:0"
}
],
"contractDependencies": [
568
],
"contractKind": "contract",
"documentation": {
"id": 1412,
"nodeType": "StructuredDocumentation",
"src": "46448:118:0",
"text": "@title MapleTreasury earns revenue from Loans and distributes it to token holders and the Maple development team."
},
"fullyImplemented": true,
"id": 1726,
"linearizedBaseContracts": [
1726,
568
],
"name": "MapleTreasury",
"nodeType": "ContractDefinition",
"nodes": [
{
"id": 1417,
"libraryName": {
"contractScope": null,
"id": 1415,
"name": "SafeMath",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 909,
"src": "46620:8:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SafeMath_$909",
"typeString": "library SafeMath"
}
},
"nodeType": "UsingForDirective",
"src": "46614:28:0",
"typeName": {
"id": 1416,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "46634:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
},
{
"id": 1420,
"libraryName": {
"contractScope": null,
"id": 1418,
"name": "SafeERC20",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 1411,
"src": "46653:9:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_SafeERC20_$1411",
"typeString": "library SafeERC20"
}
},
"nodeType": "UsingForDirective",
"src": "46647:27:0",
"typeName": {
"contractScope": null,
"id": 1419,
"name": "IERC20",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 697,
"src": "46667:6:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
}
},
{
"baseFunctions": [
525
],
"constant": false,
"functionSelector": "a0530946",
"id": 1423,
"mutability": "immutable",
"name": "mpl",
"nodeType": "VariableDeclaration",
"overrides": {
"id": 1422,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "46695:8:0"
},
"scope": 1726,
"src": "46680:37:0",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1421,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "46680:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "public"
},
{
"baseFunctions": [
531
],
"constant": false,
"functionSelector": "63f04b15",
"id": 1426,
"mutability": "immutable",
"name": "fundsToken",
"nodeType": "VariableDeclaration",
"overrides": {
"id": 1425,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "46738:8:0"
},
"scope": 1726,
"src": "46723:44:0",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1424,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "46723:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "public"
},
{
"baseFunctions": [
537
],
"constant": false,
"functionSelector": "735de9f7",
"id": 1429,
"mutability": "immutable",
"name": "uniswapRouter",
"nodeType": "VariableDeclaration",
"overrides": {
"id": 1428,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "46788:8:0"
},
"scope": 1726,
"src": "46773:47:0",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1427,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "46773:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "public"
},
{
"baseFunctions": [
543
],
"constant": false,
"functionSelector": "c3124525",
"id": 1432,
"mutability": "mutable",
"name": "globals",
"nodeType": "VariableDeclaration",
"overrides": {
"id": 1431,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "46841:8:0"
},
"scope": 1726,
"src": "46826:41:0",
"stateVariable": true,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1430,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "46826:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "public"
},
{
"body": {
"id": 1460,
"nodeType": "Block",
"src": "47411:148:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 1446,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 1444,
"name": "mpl",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1423,
"src": "47421:3:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 1445,
"name": "_mpl",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1435,
"src": "47437:4:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "47421:20:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1447,
"nodeType": "ExpressionStatement",
"src": "47421:20:0"
},
{
"expression": {
"argumentTypes": null,
"id": 1450,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 1448,
"name": "fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1426,
"src": "47451:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 1449,
"name": "_fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1437,
"src": "47467:11:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "47451:27:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1451,
"nodeType": "ExpressionStatement",
"src": "47451:27:0"
},
{
"expression": {
"argumentTypes": null,
"id": 1454,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 1452,
"name": "uniswapRouter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1429,
"src": "47488:13:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 1453,
"name": "_uniswapRouter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1439,
"src": "47504:14:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "47488:30:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1455,
"nodeType": "ExpressionStatement",
"src": "47488:30:0"
},
{
"expression": {
"argumentTypes": null,
"id": 1458,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 1456,
"name": "globals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1432,
"src": "47528:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 1457,
"name": "_globals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1441,
"src": "47544:8:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "47528:24:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1459,
"nodeType": "ExpressionStatement",
"src": "47528:24:0"
}
]
},
"documentation": {
"id": 1433,
"nodeType": "StructuredDocumentation",
"src": "46874:398:0",
"text": "@dev Instantiates the MapleTreasury contract.\n@param _mpl The address of ERC-2222 Maple Token for the Maple protocol.\n@param _fundsToken The address of the `fundsToken` of the ERC-2222 Maple Token.\n@param _uniswapRouter The address of the official UniswapV2 router.\n@param _globals The address of an instance of MapleGlobals."
},
"id": 1461,
"implemented": true,
"kind": "constructor",
"modifiers": [],
"name": "",
"nodeType": "FunctionDefinition",
"overrides": null,
"parameters": {
"id": 1442,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1435,
"mutability": "mutable",
"name": "_mpl",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1461,
"src": "47298:12:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1434,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "47298:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1437,
"mutability": "mutable",
"name": "_fundsToken",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1461,
"src": "47320:19:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1436,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "47320:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1439,
"mutability": "mutable",
"name": "_uniswapRouter",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1461,
"src": "47349:22:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1438,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "47349:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1441,
"mutability": "mutable",
"name": "_globals",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1461,
"src": "47381:16:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1440,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "47381:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "47288:115:0"
},
"returnParameters": {
"id": 1443,
"nodeType": "ParameterList",
"parameters": [],
"src": "47411:0:0"
},
"scope": 1726,
"src": "47277:282:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "public"
},
{
"body": {
"id": 1477,
"nodeType": "Block",
"src": "47658:98:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 1472,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1465,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "47676:3:0",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 1466,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "47676:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"nodeType": "BinaryOperation",
"operator": "==",
"rightExpression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1468,
"name": "globals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1432,
"src": "47704:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1467,
"name": "IMapleGlobals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 492,
"src": "47690:13:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IMapleGlobals_$492_$",
"typeString": "type(contract IMapleGlobals)"
}
},
"id": 1469,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "47690:22:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
}
},
"id": 1470,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "governor",
"nodeType": "MemberAccess",
"referencedDeclaration": 107,
"src": "47690:31:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$__$returns$_t_address_$",
"typeString": "function () view external returns (address)"
}
},
"id": 1471,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "47690:33:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "47676:47:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4d543a4e4f545f474f56",
"id": 1473,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "47725:12:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_434d2ea0b6623a33823995a8146fc738f60bb78379f9e16e3ddc163aefc55387",
"typeString": "literal_string \"MT:NOT_GOV\""
},
"value": "MT:NOT_GOV"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_434d2ea0b6623a33823995a8146fc738f60bb78379f9e16e3ddc163aefc55387",
"typeString": "literal_string \"MT:NOT_GOV\""
}
],
"id": 1464,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "47668:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 1474,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "47668:70:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1475,
"nodeType": "ExpressionStatement",
"src": "47668:70:0"
},
{
"id": 1476,
"nodeType": "PlaceholderStatement",
"src": "47748:1:0"
}
]
},
"documentation": {
"id": 1462,
"nodeType": "StructuredDocumentation",
"src": "47565:66:0",
"text": "@dev Checks that `msg.sender` is the Governor."
},
"id": 1478,
"name": "isGovernor",
"nodeType": "ModifierDefinition",
"overrides": null,
"parameters": {
"id": 1463,
"nodeType": "ParameterList",
"parameters": [],
"src": "47655:2:0"
},
"src": "47636:120:0",
"virtual": false,
"visibility": "internal"
},
{
"baseFunctions": [
549
],
"body": {
"id": 1494,
"nodeType": "Block",
"src": "47831:74:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"id": 1488,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"id": 1486,
"name": "globals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1432,
"src": "47841:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 1487,
"name": "newGlobals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1480,
"src": "47851:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "47841:20:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1489,
"nodeType": "ExpressionStatement",
"src": "47841:20:0"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1491,
"name": "newGlobals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1480,
"src": "47887:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1490,
"name": "GlobalsSet",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 519,
"src": "47876:10:0",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$returns$__$",
"typeString": "function (address)"
}
},
"id": 1492,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "47876:22:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1493,
"nodeType": "EmitStatement",
"src": "47871:27:0"
}
]
},
"documentation": null,
"functionSelector": "cc2e0a26",
"id": 1495,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 1483,
"modifierName": {
"argumentTypes": null,
"id": 1482,
"name": "isGovernor",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1478,
"src": "47802:10:0",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "47802:10:0"
}
],
"name": "setGlobals",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 1484,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "47822:8:0"
},
"parameters": {
"id": 1481,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1480,
"mutability": "mutable",
"name": "newGlobals",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1495,
"src": "47782:18:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1479,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "47782:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "47781:20:0"
},
"returnParameters": {
"id": 1485,
"nodeType": "ParameterList",
"parameters": [],
"src": "47831:0:0"
},
"scope": 1726,
"src": "47762:143:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"baseFunctions": [
557
],
"body": {
"id": 1519,
"nodeType": "Block",
"src": "47993:107:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1509,
"name": "msg",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -15,
"src": "48030:3:0",
"typeDescriptions": {
"typeIdentifier": "t_magic_message",
"typeString": "msg"
}
},
"id": 1510,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sender",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "48030:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
{
"argumentTypes": null,
"id": 1511,
"name": "amount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1499,
"src": "48042:6:0",
"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": 1506,
"name": "asset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1497,
"src": "48010:5:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1505,
"name": "IERC20",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 697,
"src": "48003:6:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IERC20_$697_$",
"typeString": "type(contract IERC20)"
}
},
"id": 1507,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48003:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1508,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "safeTransfer",
"nodeType": "MemberAccess",
"referencedDeclaration": 1232,
"src": "48003:26:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$697_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$697_$",
"typeString": "function (contract IERC20,address,uint256)"
}
},
"id": 1512,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48003:46:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1513,
"nodeType": "ExpressionStatement",
"src": "48003:46:0"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1515,
"name": "asset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1497,
"src": "48079:5:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1516,
"name": "amount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1499,
"src": "48086:6:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 1514,
"name": "ERC20Reclaimed",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 514,
"src": "48064:14:0",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256)"
}
},
"id": 1517,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48064:29:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1518,
"nodeType": "EmitStatement",
"src": "48059:34:0"
}
]
},
"documentation": null,
"functionSelector": "afdbd499",
"id": 1520,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 1502,
"modifierName": {
"argumentTypes": null,
"id": 1501,
"name": "isGovernor",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1478,
"src": "47964:10:0",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "47964:10:0"
}
],
"name": "reclaimERC20",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 1503,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "47984:8:0"
},
"parameters": {
"id": 1500,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1497,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1520,
"src": "47933:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1496,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "47933:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
},
{
"constant": false,
"id": 1499,
"mutability": "mutable",
"name": "amount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1520,
"src": "47948:14:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1498,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "47948:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "47932:31:0"
},
"returnParameters": {
"id": 1504,
"nodeType": "ParameterList",
"parameters": [],
"src": "47993:0:0"
},
"scope": 1726,
"src": "47911:189:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"baseFunctions": [
561
],
"body": {
"id": 1559,
"nodeType": "Block",
"src": "48166:287:0",
"statements": [
{
"assignments": [
1527
],
"declarations": [
{
"constant": false,
"id": 1527,
"mutability": "mutable",
"name": "_fundsToken",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1559,
"src": "48176:18:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
},
"typeName": {
"contractScope": null,
"id": 1526,
"name": "IERC20",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 697,
"src": "48176:6:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1531,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1529,
"name": "fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1426,
"src": "48204:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1528,
"name": "IERC20",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 697,
"src": "48197:6:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IERC20_$697_$",
"typeString": "type(contract IERC20)"
}
},
"id": 1530,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48197:18:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "48176:39:0"
},
{
"assignments": [
1533
],
"declarations": [
{
"constant": false,
"id": 1533,
"mutability": "mutable",
"name": "distributeAmount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1559,
"src": "48225:24:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1532,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "48225:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1541,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1538,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "48282:4:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MapleTreasury_$1726",
"typeString": "contract MapleTreasury"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_MapleTreasury_$1726",
"typeString": "contract MapleTreasury"
}
],
"id": 1537,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "48274:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 1536,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "48274:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 1539,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48274:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 1534,
"name": "_fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1527,
"src": "48252:11:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1535,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "balanceOf",
"nodeType": "MemberAccess",
"referencedDeclaration": 636,
"src": "48252:21:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$",
"typeString": "function (address) view external returns (uint256)"
}
},
"id": 1540,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48252:36:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "48225:63:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1545,
"name": "mpl",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1423,
"src": "48323:3:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1546,
"name": "distributeAmount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1533,
"src": "48328:16:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 1542,
"name": "_fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1527,
"src": "48298:11:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1544,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "safeTransfer",
"nodeType": "MemberAccess",
"referencedDeclaration": 1232,
"src": "48298:24:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$697_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$697_$",
"typeString": "function (contract IERC20,address,uint256)"
}
},
"id": 1547,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48298:47:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1548,
"nodeType": "ExpressionStatement",
"src": "48298:47:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1550,
"name": "mpl",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1423,
"src": "48367:3:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1549,
"name": "IMapleToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 572,
"src": "48355:11:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IMapleToken_$572_$",
"typeString": "type(contract IMapleToken)"
}
},
"id": 1551,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48355:16:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleToken_$572",
"typeString": "contract IMapleToken"
}
},
"id": 1552,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "updateFundsReceived",
"nodeType": "MemberAccess",
"referencedDeclaration": 571,
"src": "48355:36:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_nonpayable$__$returns$__$",
"typeString": "function () external"
}
},
"id": 1553,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48355:38:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1554,
"nodeType": "ExpressionStatement",
"src": "48355:38:0"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1556,
"name": "distributeAmount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1533,
"src": "48429:16:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 1555,
"name": "DistributedToHolders",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 507,
"src": "48408:20:0",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_uint256_$returns$__$",
"typeString": "function (uint256)"
}
},
"id": 1557,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48408:38:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1558,
"nodeType": "EmitStatement",
"src": "48403:43:0"
}
]
},
"documentation": null,
"functionSelector": "3153689f",
"id": 1560,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 1523,
"modifierName": {
"argumentTypes": null,
"id": 1522,
"name": "isGovernor",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1478,
"src": "48137:10:0",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "48137:10:0"
}
],
"name": "distributeToHolders",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 1524,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "48157:8:0"
},
"parameters": {
"id": 1521,
"nodeType": "ParameterList",
"parameters": [],
"src": "48134:2:0"
},
"returnParameters": {
"id": 1525,
"nodeType": "ParameterList",
"parameters": [],
"src": "48166:0:0"
},
"scope": 1726,
"src": "48106:347:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
},
{
"baseFunctions": [
567
],
"body": {
"id": 1724,
"nodeType": "Block",
"src": "48525:1207:0",
"statements": [
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 1571,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 1569,
"name": "asset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1562,
"src": "48543:5:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"id": 1570,
"name": "fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1426,
"src": "48552:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "48543:19:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
{
"argumentTypes": null,
"hexValue": "4d543a41535345545f49535f46554e44535f544f4b454e",
"id": 1572,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "string",
"lValueRequested": false,
"nodeType": "Literal",
"src": "48564:25:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_stringliteral_5e567772f8be230a0a78861224b764d4e32f7eeb4437efb12af1c88140274b6f",
"typeString": "literal_string \"MT:ASSET_IS_FUNDS_TOKEN\""
},
"value": "MT:ASSET_IS_FUNDS_TOKEN"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_bool",
"typeString": "bool"
},
{
"typeIdentifier": "t_stringliteral_5e567772f8be230a0a78861224b764d4e32f7eeb4437efb12af1c88140274b6f",
"typeString": "literal_string \"MT:ASSET_IS_FUNDS_TOKEN\""
}
],
"id": 1568,
"name": "require",
"nodeType": "Identifier",
"overloadedDeclarations": [
-18,
-18
],
"referencedDeclaration": -18,
"src": "48535:7:0",
"typeDescriptions": {
"typeIdentifier": "t_function_require_pure$_t_bool_$_t_string_memory_ptr_$returns$__$",
"typeString": "function (bool,string memory) pure"
}
},
"id": 1573,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48535:55:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1574,
"nodeType": "ExpressionStatement",
"src": "48535:55:0"
},
{
"assignments": [
1576
],
"declarations": [
{
"constant": false,
"id": 1576,
"mutability": "mutable",
"name": "_globals",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1724,
"src": "48601:22:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
},
"typeName": {
"contractScope": null,
"id": 1575,
"name": "IMapleGlobals",
"nodeType": "UserDefinedTypeName",
"referencedDeclaration": 492,
"src": "48601:13:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1580,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1578,
"name": "globals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1432,
"src": "48640:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1577,
"name": "IMapleGlobals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 492,
"src": "48626:13:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IMapleGlobals_$492_$",
"typeString": "type(contract IMapleGlobals)"
}
},
"id": 1579,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48626:22:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "48601:47:0"
},
{
"assignments": [
1582
],
"declarations": [
{
"constant": false,
"id": 1582,
"mutability": "mutable",
"name": "assetBalance",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1724,
"src": "48659:20:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1581,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "48659:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1592,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1589,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "48714:4:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MapleTreasury_$1726",
"typeString": "contract MapleTreasury"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_MapleTreasury_$1726",
"typeString": "contract MapleTreasury"
}
],
"id": 1588,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "48706:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 1587,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "48706:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 1590,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48706:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1584,
"name": "asset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1562,
"src": "48689:5:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1583,
"name": "IERC20",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 697,
"src": "48682:6:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IERC20_$697_$",
"typeString": "type(contract IERC20)"
}
},
"id": 1585,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48682:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1586,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "balanceOf",
"nodeType": "MemberAccess",
"referencedDeclaration": 636,
"src": "48682:23:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$_t_address_$returns$_t_uint256_$",
"typeString": "function (address) view external returns (uint256)"
}
},
"id": 1591,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48682:38:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "48659:61:0"
},
{
"assignments": [
1594
],
"declarations": [
{
"constant": false,
"id": 1594,
"mutability": "mutable",
"name": "minAmount",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1724,
"src": "48730:17:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"typeName": {
"id": 1593,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "48730:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1602,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1597,
"name": "_globals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1576,
"src": "48772:8:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
}
},
{
"argumentTypes": null,
"id": 1598,
"name": "asset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1562,
"src": "48782:5:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1599,
"name": "fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1426,
"src": "48789:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1600,
"name": "assetBalance",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1582,
"src": "48801:12:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 1595,
"name": "Util",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 961,
"src": "48753:4:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_Util_$961_$",
"typeString": "type(library Util)"
}
},
"id": 1596,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "calcMinAmount",
"nodeType": "MemberAccess",
"referencedDeclaration": 960,
"src": "48753:18:0",
"typeDescriptions": {
"typeIdentifier": "t_function_delegatecall_view$_t_contract$_IMapleGlobals_$492_$_t_address_$_t_address_$_t_uint256_$returns$_t_uint256_$",
"typeString": "function (contract IMapleGlobals,address,address,uint256) view returns (uint256)"
}
},
"id": 1601,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48753:61:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "48730:84:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1607,
"name": "uniswapRouter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1429,
"src": "48851:13:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 1610,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "48874:1:0",
"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": 1609,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "48866:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_uint256_$",
"typeString": "type(uint256)"
},
"typeName": {
"id": 1608,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "48866:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 1611,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48866:10:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1604,
"name": "asset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1562,
"src": "48832:5:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1603,
"name": "IERC20",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 697,
"src": "48825:6:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IERC20_$697_$",
"typeString": "type(contract IERC20)"
}
},
"id": 1605,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48825:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1606,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "safeApprove",
"nodeType": "MemberAccess",
"referencedDeclaration": 1300,
"src": "48825:25:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$697_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$697_$",
"typeString": "function (contract IERC20,address,uint256)"
}
},
"id": 1612,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48825:52:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1613,
"nodeType": "ExpressionStatement",
"src": "48825:52:0"
},
{
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1618,
"name": "uniswapRouter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1429,
"src": "48913:13:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1619,
"name": "assetBalance",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1582,
"src": "48928:12:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1615,
"name": "asset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1562,
"src": "48894:5:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1614,
"name": "IERC20",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 697,
"src": "48887:6:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IERC20_$697_$",
"typeString": "type(contract IERC20)"
}
},
"id": 1616,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48887:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IERC20_$697",
"typeString": "contract IERC20"
}
},
"id": 1617,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "safeApprove",
"nodeType": "MemberAccess",
"referencedDeclaration": 1300,
"src": "48887:25:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_nonpayable$_t_contract$_IERC20_$697_$_t_address_$_t_uint256_$returns$__$bound_to$_t_contract$_IERC20_$697_$",
"typeString": "function (contract IERC20,address,uint256)"
}
},
"id": 1620,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48887:54:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1621,
"nodeType": "ExpressionStatement",
"src": "48887:54:0"
},
{
"assignments": [
1623
],
"declarations": [
{
"constant": false,
"id": 1623,
"mutability": "mutable",
"name": "uniswapAssetForPath",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1724,
"src": "48952:27:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1622,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "48952:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1629,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1626,
"name": "asset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1562,
"src": "49010:5:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"id": 1627,
"name": "fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1426,
"src": "49017:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"expression": {
"argumentTypes": null,
"id": 1624,
"name": "_globals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1576,
"src": "48982:8:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
}
},
"id": 1625,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "defaultUniswapPath",
"nodeType": "MemberAccess",
"referencedDeclaration": 241,
"src": "48982:27:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$_t_address_$_t_address_$returns$_t_address_$",
"typeString": "function (address,address) view external returns (address)"
}
},
"id": 1628,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "48982:46:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "48952:76:0"
},
{
"assignments": [
1631
],
"declarations": [
{
"constant": false,
"id": 1631,
"mutability": "mutable",
"name": "middleAsset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1724,
"src": "49038:19:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"typeName": {
"id": 1630,
"name": "bool",
"nodeType": "ElementaryTypeName",
"src": "49038:4:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1642,
"initialValue": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_bool",
"typeString": "bool"
},
"id": 1641,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 1634,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 1632,
"name": "uniswapAssetForPath",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1623,
"src": "49068:19:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"id": 1633,
"name": "fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1426,
"src": "49091:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "49068:33:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "BinaryOperation",
"operator": "&&",
"rightExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"id": 1640,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"id": 1635,
"name": "uniswapAssetForPath",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1623,
"src": "49105:19:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "BinaryOperation",
"operator": "!=",
"rightExpression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "30",
"id": 1638,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "49136:1:0",
"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": 1637,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "49128:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 1636,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "49128:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 1639,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "49128:10:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address_payable",
"typeString": "address payable"
}
},
"src": "49105:33:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"src": "49068:70:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "49038:100:0"
},
{
"assignments": [
1647
],
"declarations": [
{
"constant": false,
"id": 1647,
"mutability": "mutable",
"name": "path",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1724,
"src": "49149:21:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[]"
},
"typeName": {
"baseType": {
"id": 1645,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "49149:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1646,
"length": null,
"nodeType": "ArrayTypeName",
"src": "49149:9:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
"typeString": "address[]"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1656,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"condition": {
"argumentTypes": null,
"id": 1651,
"name": "middleAsset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1631,
"src": "49187:11:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseExpression": {
"argumentTypes": null,
"hexValue": "32",
"id": 1653,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "49205:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_2_by_1",
"typeString": "int_const 2"
},
"value": "2"
},
"id": 1654,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "Conditional",
"src": "49187:19:0",
"trueExpression": {
"argumentTypes": null,
"hexValue": "33",
"id": 1652,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "49201:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_3_by_1",
"typeString": "int_const 3"
},
"value": "3"
},
"typeDescriptions": {
"typeIdentifier": "t_uint8",
"typeString": "uint8"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint8",
"typeString": "uint8"
}
],
"id": 1650,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "NewExpression",
"src": "49173:13:0",
"typeDescriptions": {
"typeIdentifier": "t_function_objectcreation_pure$_t_uint256_$returns$_t_array$_t_address_$dyn_memory_ptr_$",
"typeString": "function (uint256) pure returns (address[] memory)"
},
"typeName": {
"baseType": {
"id": 1648,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "49177:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1649,
"length": null,
"nodeType": "ArrayTypeName",
"src": "49177:9:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_storage_ptr",
"typeString": "address[]"
}
}
},
"id": 1655,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "49173:34:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "49149:58:0"
},
{
"expression": {
"argumentTypes": null,
"id": 1661,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 1657,
"name": "path",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1647,
"src": "49218:4:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 1659,
"indexExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 1658,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "49223:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "49218:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 1660,
"name": "asset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1562,
"src": "49228:5:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "49218:15:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1662,
"nodeType": "ExpressionStatement",
"src": "49218:15:0"
},
{
"expression": {
"argumentTypes": null,
"id": 1670,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 1663,
"name": "path",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1647,
"src": "49243:4:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 1665,
"indexExpression": {
"argumentTypes": null,
"hexValue": "31",
"id": 1664,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "49248:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
},
"value": "1"
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "49243:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"condition": {
"argumentTypes": null,
"id": 1666,
"name": "middleAsset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1631,
"src": "49253:11:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseExpression": {
"argumentTypes": null,
"id": 1668,
"name": "fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1426,
"src": "49289:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1669,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"nodeType": "Conditional",
"src": "49253:46:0",
"trueExpression": {
"argumentTypes": null,
"id": 1667,
"name": "uniswapAssetForPath",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1623,
"src": "49267:19:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "49243:56:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1671,
"nodeType": "ExpressionStatement",
"src": "49243:56:0"
},
{
"condition": {
"argumentTypes": null,
"id": 1672,
"name": "middleAsset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1631,
"src": "49314:11:0",
"typeDescriptions": {
"typeIdentifier": "t_bool",
"typeString": "bool"
}
},
"falseBody": null,
"id": 1679,
"nodeType": "IfStatement",
"src": "49310:37:0",
"trueBody": {
"expression": {
"argumentTypes": null,
"id": 1677,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftHandSide": {
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 1673,
"name": "path",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1647,
"src": "49327:4:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 1675,
"indexExpression": {
"argumentTypes": null,
"hexValue": "32",
"id": 1674,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "49332:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_2_by_1",
"typeString": "int_const 2"
},
"value": "2"
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": true,
"nodeType": "IndexAccess",
"src": "49327:7:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"nodeType": "Assignment",
"operator": "=",
"rightHandSide": {
"argumentTypes": null,
"id": 1676,
"name": "fundsToken",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1426,
"src": "49337:10:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"src": "49327:20:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"id": 1678,
"nodeType": "ExpressionStatement",
"src": "49327:20:0"
}
},
{
"assignments": [
1684
],
"declarations": [
{
"constant": false,
"id": 1684,
"mutability": "mutable",
"name": "returnAmounts",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1724,
"src": "49358:30:0",
"stateVariable": false,
"storageLocation": "memory",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
"typeString": "uint256[]"
},
"typeName": {
"baseType": {
"id": 1682,
"name": "uint256",
"nodeType": "ElementaryTypeName",
"src": "49358:7:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 1683,
"length": null,
"nodeType": "ArrayTypeName",
"src": "49358:9:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_storage_ptr",
"typeString": "uint256[]"
}
},
"value": null,
"visibility": "internal"
}
],
"id": 1710,
"initialValue": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1689,
"name": "assetBalance",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1582,
"src": "49459:12:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"hexValue": "31305f303030",
"id": 1699,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "49545:6:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_10000_by_1",
"typeString": "int_const 10000"
},
"value": "10_000"
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_rational_10000_by_1",
"typeString": "int_const 10000"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"arguments": [],
"expression": {
"argumentTypes": [],
"expression": {
"argumentTypes": null,
"id": 1694,
"name": "_globals",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1576,
"src": "49513:8:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_IMapleGlobals_$492",
"typeString": "contract IMapleGlobals"
}
},
"id": 1695,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "maxSwapSlippage",
"nodeType": "MemberAccess",
"referencedDeclaration": 155,
"src": "49513:24:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_view$__$returns$_t_uint256_$",
"typeString": "function () view external returns (uint256)"
}
},
"id": 1696,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "49513:26:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 1692,
"name": "minAmount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1594,
"src": "49499:9:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 1693,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "mul",
"nodeType": "MemberAccess",
"referencedDeclaration": 822,
"src": "49499:13:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 1697,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "49499:41:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 1698,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "div",
"nodeType": "MemberAccess",
"referencedDeclaration": 839,
"src": "49499:45:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 1700,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "49499:53:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"id": 1690,
"name": "minAmount",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1594,
"src": "49485:9:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"id": 1691,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "sub",
"nodeType": "MemberAccess",
"referencedDeclaration": 759,
"src": "49485:13:0",
"typeDescriptions": {
"typeIdentifier": "t_function_internal_pure$_t_uint256_$_t_uint256_$returns$_t_uint256_$bound_to$_t_uint256_$",
"typeString": "function (uint256,uint256) pure returns (uint256)"
}
},
"id": 1701,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "49485:68:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"id": 1702,
"name": "path",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1647,
"src": "49567:4:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
{
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1705,
"name": "this",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -28,
"src": "49593:4:0",
"typeDescriptions": {
"typeIdentifier": "t_contract$_MapleTreasury_$1726",
"typeString": "contract MapleTreasury"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_contract$_MapleTreasury_$1726",
"typeString": "contract MapleTreasury"
}
],
"id": 1704,
"isConstant": false,
"isLValue": false,
"isPure": true,
"lValueRequested": false,
"nodeType": "ElementaryTypeNameExpression",
"src": "49585:7:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_address_$",
"typeString": "type(address)"
},
"typeName": {
"id": 1703,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "49585:7:0",
"typeDescriptions": {
"typeIdentifier": null,
"typeString": null
}
}
},
"id": 1706,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "49585:13:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1707,
"name": "block",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": -4,
"src": "49612:5:0",
"typeDescriptions": {
"typeIdentifier": "t_magic_block",
"typeString": "block"
}
},
"id": 1708,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "timestamp",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "49612:15:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
{
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
},
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"expression": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1686,
"name": "uniswapRouter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1429,
"src": "49406:13:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
}
],
"id": 1685,
"name": "IUniswapRouter",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 621,
"src": "49391:14:0",
"typeDescriptions": {
"typeIdentifier": "t_type$_t_contract$_IUniswapRouter_$621_$",
"typeString": "type(contract IUniswapRouter)"
}
},
"id": 1687,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "typeConversion",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "49391:29:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_contract$_IUniswapRouter_$621",
"typeString": "contract IUniswapRouter"
}
},
"id": 1688,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "swapExactTokensForTokens",
"nodeType": "MemberAccess",
"referencedDeclaration": 589,
"src": "49391:54:0",
"typeDescriptions": {
"typeIdentifier": "t_function_external_nonpayable$_t_uint256_$_t_uint256_$_t_array$_t_address_$dyn_memory_ptr_$_t_address_$_t_uint256_$returns$_t_array$_t_uint256_$dyn_memory_ptr_$",
"typeString": "function (uint256,uint256,address[] memory,address,uint256) external returns (uint256[] memory)"
}
},
"id": 1709,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "49391:246:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
"typeString": "uint256[] memory"
}
},
"nodeType": "VariableDeclarationStatement",
"src": "49358:279:0"
},
{
"eventCall": {
"argumentTypes": null,
"arguments": [
{
"argumentTypes": null,
"id": 1712,
"name": "asset",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1562,
"src": "49669:5:0",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 1713,
"name": "returnAmounts",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1684,
"src": "49676:13:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
"typeString": "uint256[] memory"
}
},
"id": 1715,
"indexExpression": {
"argumentTypes": null,
"hexValue": "30",
"id": 1714,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "49690:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_0_by_1",
"typeString": "int_const 0"
},
"value": "0"
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "49676:16:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
{
"argumentTypes": null,
"baseExpression": {
"argumentTypes": null,
"id": 1716,
"name": "returnAmounts",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1684,
"src": "49694:13:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_uint256_$dyn_memory_ptr",
"typeString": "uint256[] memory"
}
},
"id": 1721,
"indexExpression": {
"argumentTypes": null,
"commonType": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
"id": 1720,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"leftExpression": {
"argumentTypes": null,
"expression": {
"argumentTypes": null,
"id": 1717,
"name": "path",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1647,
"src": "49708:4:0",
"typeDescriptions": {
"typeIdentifier": "t_array$_t_address_$dyn_memory_ptr",
"typeString": "address[] memory"
}
},
"id": 1718,
"isConstant": false,
"isLValue": false,
"isPure": false,
"lValueRequested": false,
"memberName": "length",
"nodeType": "MemberAccess",
"referencedDeclaration": null,
"src": "49708:11:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"nodeType": "BinaryOperation",
"operator": "-",
"rightExpression": {
"argumentTypes": null,
"hexValue": "31",
"id": 1719,
"isConstant": false,
"isLValue": false,
"isPure": true,
"kind": "number",
"lValueRequested": false,
"nodeType": "Literal",
"src": "49722:1:0",
"subdenomination": null,
"typeDescriptions": {
"typeIdentifier": "t_rational_1_by_1",
"typeString": "int_const 1"
},
"value": "1"
},
"src": "49708:15:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
},
"isConstant": false,
"isLValue": true,
"isPure": false,
"lValueRequested": false,
"nodeType": "IndexAccess",
"src": "49694:30:0",
"typeDescriptions": {
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
}
],
"expression": {
"argumentTypes": [
{
"typeIdentifier": "t_address",
"typeString": "address"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
},
{
"typeIdentifier": "t_uint256",
"typeString": "uint256"
}
],
"id": 1711,
"name": "ERC20Conversion",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 502,
"src": "49653:15:0",
"typeDescriptions": {
"typeIdentifier": "t_function_event_nonpayable$_t_address_$_t_uint256_$_t_uint256_$returns$__$",
"typeString": "function (address,uint256,uint256)"
}
},
"id": 1722,
"isConstant": false,
"isLValue": false,
"isPure": false,
"kind": "functionCall",
"lValueRequested": false,
"names": [],
"nodeType": "FunctionCall",
"src": "49653:72:0",
"tryCall": false,
"typeDescriptions": {
"typeIdentifier": "t_tuple$__$",
"typeString": "tuple()"
}
},
"id": 1723,
"nodeType": "EmitStatement",
"src": "49648:77:0"
}
]
},
"documentation": null,
"functionSelector": "817bd4fd",
"id": 1725,
"implemented": true,
"kind": "function",
"modifiers": [
{
"arguments": null,
"id": 1565,
"modifierName": {
"argumentTypes": null,
"id": 1564,
"name": "isGovernor",
"nodeType": "Identifier",
"overloadedDeclarations": [],
"referencedDeclaration": 1478,
"src": "48496:10:0",
"typeDescriptions": {
"typeIdentifier": "t_modifier$__$",
"typeString": "modifier ()"
}
},
"nodeType": "ModifierInvocation",
"src": "48496:10:0"
}
],
"name": "convertERC20",
"nodeType": "FunctionDefinition",
"overrides": {
"id": 1566,
"nodeType": "OverrideSpecifier",
"overrides": [],
"src": "48516:8:0"
},
"parameters": {
"id": 1563,
"nodeType": "ParameterList",
"parameters": [
{
"constant": false,
"id": 1562,
"mutability": "mutable",
"name": "asset",
"nodeType": "VariableDeclaration",
"overrides": null,
"scope": 1725,
"src": "48481:13:0",
"stateVariable": false,
"storageLocation": "default",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
},
"typeName": {
"id": 1561,
"name": "address",
"nodeType": "ElementaryTypeName",
"src": "48481:7:0",
"stateMutability": "nonpayable",
"typeDescriptions": {
"typeIdentifier": "t_address",
"typeString": "address"
}
},
"value": null,
"visibility": "internal"
}
],
"src": "48480:15:0"
},
"returnParameters": {
"id": 1567,
"nodeType": "ParameterList",
"parameters": [],
"src": "48525:0:0"
},
"scope": 1726,
"src": "48459:1273:0",
"stateMutability": "nonpayable",
"virtual": false,
"visibility": "external"
}
],
"scope": 1727,
"src": "46566:3169:0"
}
],
"src": "121:49615:0"
},
"id": 0
}
}
}
}